-2

I am trying to deploy a Flask app on Heroku which responds to JSON post requests after doing some data analysis on a big JSON dataset. I referred to this question: No package 'gobject-introspection-1.0' found while deploying to Heroku but it's still not working.

requirements.txt:

flask
pandas
gunicorn
flask_cors
gdown
Package gobject-introspection-1.0 was not found in the pkg-config search path.
remote:            Perhaps you should add the directory containing `gobject-introspection-1.0.pc'
remote:            to the PKG_CONFIG_PATH environment variable
remote:            No package 'gobject-introspection-1.0' found
remote:            Command '('pkg-config', '--print-errors', '--exists', 'gobject-introspection-1.0 >= 1.46.0')' returned non-zero exit status 1.
remote:            
remote:            Try installing it with: 'sudo apt install libgirepository1.0-dev'
remote:            
remote:            ----------------------------------------
remote:        Command "/app/.heroku/python/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-3ejh6vw4/PyGObject/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-lgaouqha-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-3ejh6vw4/PyGObject/
remote:  !     Push rejected, failed to compile Python app.
remote: 
remote:  !     Push failed
remote: Verifying deploy...
remote: 
remote: !   Push rejected to stormy-castle-60587.
davidism
  • 121,510
  • 29
  • 395
  • 339
  • You can try to reach your slug with `heroku run bash --app appname` and then try to install `libgirepository1.0-dev`. In case of failure, use `heroku-community/apt`, more info at: https://elements.heroku.com/buildpacks/heroku/heroku-buildpack-apt. – bc291 Feb 05 '20 at 20:05
  • thanks it worked,I was successfully able to deploy my Flask app – Raptor King Feb 07 '20 at 03:43
  • Ok, I've converted my comment to an answer. Please accept and upvote it if you found that helpful. – bc291 Feb 07 '20 at 07:47

1 Answers1

0

You can try to reach your slug with heroku run bash --app appname and then try to install libgirepository1.0-dev. In case of failure, use heroku-community/apt, more info at heroku-buildpack-apt

bc291
  • 1,071
  • 11
  • 23