Error Deploying StreamLit

First time trying to deploy a stream lit app and this error message pops up in the terminal. This might be a noob question but could someone take a look and tell me whats wrong? Also I upgraded pip to 21.1 so I’m unsure why it says I still need to upgrade. Link to the repo is here

[manager] Starting up for owner: 'rolekanma', repository: 'howdoteamsdefend', branch: 'master', main module: 'how_do_teams_defend.py'

[manager] Cloning repository ...

[manager] Cloning into 'howdoteamsdefend'...

[manager] Cloned repository!

[manager] Processing dependencies ...

Processing /opt/concourse/worker/volumes/live/0291c9e1-4b15-459f-623e-2770f55be269/volume/appnope_1594338395037/work

ERROR: Could not install packages due to an OSError: [Errno 2] No such file or directory: '/opt/concourse/worker/volumes/live/0291c9e1-4b15-459f-623e-2770f55be269/volume/appnope_1594338395037/work'

WARNING: You are using pip version 21.0.1; however, version 21.1 is available.

You should consider upgrading via the '/home/appuser/venv/bin/python -m pip install --upgrade pip' command.

[manager] installer returned a non-zero exit code
[manager] Error during processing dependencies! Please fix the error and push an update, or try restarting the app.
```

Hey @Marisa_Smith just saw your email. Tagging you here if thats ok

Hi @rolekanma

Your requirements file has loads of lines pointing to local libraries.

It looks like your code just need these ones:

streamlit==0.81.0
numpy==1.20.2
pandas==1.2.4

Cheers

Francisco

Hey @rolekanma,

First welcome to the Streamlit Community! :partying_face: :star_struck: :sparkles: :tada: :tada: :partying_face: :partying_face:

I have taken a quick look at your repo and there are 2 things I see here:

Your requirements.txt file

Currently, your requirements file looks like it was auto-generated from your main computer environment (not a clean one), so you have 230 specific packages that the Sharing platform is trying to upload. @franciscoed is right you only need the few that you actually use in your app.

Actually, you can even simplify your requirements further by removing the streamlit and pandas requirements if you wanted. The Sharing platform always installs Streamlit and all its dependencies, so you could have a requirements file as simple as:

numpy
math
Your main python file (how_do_teams_defend.py)

I don’t know if this will cause an issue or not, but your main python file seems to have metas (the ^M) at the end of the line instead of enters. When you view it on GitHub and even when I fork your repo and use my text editor to view your code it’s all crammed into one line.

What editor did you use when writing your code? In the best-case scenario, it doesn’t matter, but if you change your requirements file and are still running into issues I suspect these might be the culprit.

Happy Streamlit-ing!
Marisa

Hey Marisa, thanks for the response! I’ll remove those from the requirements and check if it works. The editor I used is spyder and just uploaded it as a .py file. Should I change it?

Hey @rolekanma,

Check the requirements first and then if your still having issues that’s what I would try next (save yourself some work up front!)

Happy Streamlit-ing!
Marisa