0

Everything works fine Locally.

However when I try pushing the project to heroku, the following error comes up. enter image description here

Here is my Procfile: web: sh setup.sh && streamlit run application.py

setup.sh:

mkdir -p ~/.streamlit/

echo "\
[general]\n\
email = \"__@gmail.com\"\n\
" > ~/.streamlit/credentials.toml

echo "\
[server]\n\
headless = true\n\
enableCORS=false\n\
port = $PORT\n\
" > ~/.streamlit/config.toml

and requirements.txt:

streamlit==0.81.1
pandas==1.1.0
matplotlib==3.3.0
plotly==4.14.3
seaborn==0.11.1
numpy==1.18.5
scikit_learn==0.23.2

Although I'm new to this framework, I have a bit of understanding of python and a complete disaster with deploying live web app.

Any one who can point me in the right direction?

Your help is greatly anticipated and helpful.

torek
  • 448,244
  • 59
  • 642
  • 775
  • This isn't a [tag:git] or [tag:github] issue. It's a heroku and/or pip issue, apparently; see [this related question](https://stackoverflow.com/q/61365790/1256452). – torek May 12 '21 at 00:51
  • Search for the combination of "pep517" with "pandas". My guess is that, to install pandas, it is trying to compile some C code. You can perhaps work around it by declaring the pandas requirement is a precompiled version of pandas, but I don't know how to do that. Perhaps via the OS as a distro package? It works locally because it was able to compile pandas on your host system. – John Mee May 12 '21 at 01:02

1 Answers1

0

Thank you for your replies @torek and @John Mee.

Apparently all I had to do was simple.

  1. Modify pandas == 1.2.0 to pandas < 1.2.0 in the requirements.txt file.
  2. git add, commit and push to origin and to heroku.

That's it.

Thanks again.