Submission fails

I got the following error ‘ERROR: Could not find main.py in submission.zip’ but the main.py is already there and unpacked:

  • echo ‘Unpacking submission…’
    Unpacking submission…
  • unzip ./submission/submission.zip -d ./
    Archive: ./submission/submission.zip
    creating: ./submission/assets/
    inflating: ./submission/assets/cloud_model.pt
    inflating: ./submission/cloud_dataset.py
    inflating: ./submission/cloud_model.py
    inflating: ./submission/main.py
    creating: ./submission/predictions/
1 Like

Looks like submission folder should not be in it, see below

benchmark_src
├── pycache
│ ├── cloud_dataset.cpython-38.pyc
│ ├── cloud_model.cpython-38.pyc
│ ├── losses.cpython-38.pyc
│ └── main.cpython-38.pyc
├── assets
│ └── cloud_model.pt
├── cloud_dataset.py
├── cloud_model.py
├── losses.py
├── main.py
└── predictions

it is no in it, but folder’s name is submission instead of benchmark_src

Hello, have you figured out a fix for this? I’m facing this exact same issue.

I’m currently trying to run the submission on the Code execution runtime I cloned from Github, to see if debugging’ll be easier there.

Code execution definitely has its complications, relative to just submitting model predictions.

No, I haven’t. It looks weird error I followed the same structure and applied the same code in baseline notebook.

Capture

I’ve just tested submissions.zip on the cloned Code execution runtime. It’s the exact same issue.

The issue was the same, even when submissions.zip contained just one file: main.py.

The issue seems clearly with the runtime and not submissions.zip, but I’m wondering how other people have gotten their own code to run.

@rbgb Support’ll be very appreciated on this, thanks.

1 Like

YES, exactly. two days of submissions and same issue and no clue what is wrong

1 Like

@glipstein @Emily

Support’ll be very appreciated on this, thanks.

@tglazer @bull

Support’ll be very appreciated on this, thanks.

@ajijohn Pointed out the issue correctly. Your zip archive contains an extra folder named submission in it. You can tell because in the screenshot you provide in the list of files after it runs ls -alh it lists a folder called “submission,” but it does not list a file called main.py.

If you are using linux or macos, you can look at the structure of your zip archive with unzip -l. For example, if your submission just had a single file named main.py in it, the output might look like this:

❯ unzip -l submission.zip
Archive:  submission.zip
  Length      Date    Time    Name
---------  ---------- -----   ----
        0  01-15-2022 16:50   main.py
---------                     -------
        0                     1 file

However, this is what it would look like if your submission contained an extra folder named submission:

❯ unzip -l submission.zip
Archive:  submission.zip
  Length      Date    Time    Name
---------  ---------- -----   ----
        0  01-15-2022 17:18   submission/main.py
---------                     -------
        0                     1 file

You may need to look at the manual for the tool you are using to create the archive so that it does not contain the extra folder. The exact syntax will depend on your operating system and version of your tools.

2 Likes

Ah great, thanks!

It wasn’t at all clear to me why I was experiencing that issue. The “zip” command seems to nest the given folder by default.

Getting past that enables the execution runtime find main.py, thanks again! :slightly_smiling_face: