diff options
-rw-r--r-- | snekbox/nsjail.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/snekbox/nsjail.py b/snekbox/nsjail.py index 30e6ecd..128172d 100644 --- a/snekbox/nsjail.py +++ b/snekbox/nsjail.py @@ -212,7 +212,8 @@ class NsJail: # Parse attachments try: - attachments = list(temp_dir.attachments()) + # Sort attachments by name lexically + attachments = sorted(temp_dir.attachments(), key=lambda a: a.name) log.info(f"Found {len(attachments)} attachments.") except AttachmentError as err: log.error(f"Failed to parse attachments: {err}") |