Error trying to install Postgres for python (psycopg2)

This page summarizes the projects mentioned and recommended in the original post on /r/codehunter

InfluxDB - Power Real-Time Data Analytics at Scale
Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.
www.influxdata.com
featured
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
www.saashub.com
featured
  • python-getting-started

    Getting Started with Python on Heroku.

  • (venv)avlahop@apostolos-laptop:~/development/django/rhombus-dental$ sudo pip install psycopg2Downloading/unpacking psycopg2,Downloading psycopg2-2.5.2.tar.gz (685kB): 685kB downloadedRunning setup.py egg_info for package psycopg2Installing collected packages: psycopg2 Running setup.py install for psycopg2 building 'psycopg2.\_psycopg' extension x86_64-linux-gnu-gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.2 (dt dec pq3 ext)" -DPG_VERSION_HEX=0x09010D -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/usr/include/python2.7 -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.1/server -c psycopg/psycopgmodule.c -o build/temp.linux-x86_64-2.7/psycopg/psycopgmodule.o -Wdeclaration-after-statement In file included from psycopg/psycopgmodule.c:27:0: ./psycopg/psycopg.h:30:20: fatal error: Python.h: Δεν υπάρχει τέτοιο αρχείο ή κατάλογος #include ^ compilation terminated. error: command 'x86\_64-linux-gnu-gcc' failed with exit status 1 Complete output from command /usr/bin/python -c "import setuptools;\_\_file\_\_='/tmp/pip\_build\_root/psycopg2/setup.py';exec(compile(open(\_\_file\_\_).read().replace('\r\n', '\n'), \_\_file\_\_, 'exec'))" install --record /tmp/pip-SgfQCA-record/install-record.txt --single-version-externally-managed:running installrunning buildrunning build_pycreating buildcreating build/lib.linux-x86_64-2.7creating build/lib.linux-x86_64-2.7/psycopg2copying lib/pool.py -> build/lib.linux-x86_64-2.7/psycopg2copying lib/errorcodes.py -> build/lib.linux-x86_64-2.7/psycopg2copying lib/__init__.py -> build/lib.linux-x86_64-2.7/psycopg2copying lib/_json.py -> build/lib.linux-x86_64-2.7/psycopg2copying lib/_range.py -> build/lib.linux-x86_64-2.7/psycopg2copying lib/extensions.py -> build/lib.linux-x86_64-2.7/psycopg2copying lib/psycopg1.py -> build/lib.linux-x86_64-2.7/psycopg2copying lib/tz.py -> build/lib.linux-x86_64-2.7/psycopg2copying lib/extras.py -> build/lib.linux-x86_64-2.7/psycopg2creating build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/testconfig.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopyng tests/test_bug_gc.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_dates.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_copy.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_cancel.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_bugX000.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_extras_dictcursor.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_psycopg2_dbapi20.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_types_basic.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_async.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_lobject.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_cursor.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_with.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/__init__.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_types_extras.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/testutils.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_notify.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_green.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_quote.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_connection.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_transaction.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/dbapi20.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/test_module.py -> build/lib.linux-x86_64-2.7/psycopg2/testscopying tests/dbapi20_tpc.py -> build/lib.linux-x86_64-2.7/psycopg2/testsrunning build_extbuilding 'psycopg2.\_psycopg' extensioncreating build/temp.linux-x86_64-2.7creating build/temp.linux-x86_64-2.7/psycopgx86_64-linux-gnu-gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -DPSYCOPG_DEFAULT_PYDATETIME=1 -DPSYCOPG_VERSION="2.5.2 (dt dec pq3 ext)" -DPG_VERSION_HEX=0x09010D -DPSYCOPG_EXTENSIONS=1 -DPSYCOPG_NEW_BOOLEAN=1 -DHAVE_PQFREEMEM=1 -I/usr/include/python2.7 -I. -I/usr/include/postgresql -I/usr/include/postgresql/9.1/server -c psycopg/psycopgmodule.c -o build/temp.linux-x86_64-2.7/psycopg/psycopgmodule.o -Wdeclaration-after-statementIn file included from psycopg/psycopgmodule.c:27:0:./psycopg/psycopg.h:30:20: fatal error: Python.h: No such file or directory #include ^compilation terminated.error: command 'x86\_64-linux-gnu-gcc' failed with exit status 1----------------------------------------Cleaning up...Command /usr/bin/python -c "import setuptools;\_\_file\_\_='/tmp/pip\_build\_root/psycopg2/setup.py';exec(compile(open(\_\_file\_\_).read().replace('\r\n', '\n'), \_\_file\_\_, 'exec'))" install --record /tmp/pip-SgfQCA-record/install-record.txt --single-version-externally-managed failed with error code 1 in /tmp/pip_build_root/psycopg2Traceback (most recent call last): File "/usr/bin/pip", line 9, in load_entry_point('pip==1.4.1', 'console\_scripts', 'pip')() File "/usr/lib/python2.7/dist-packages/pip/\_\_init\_\_.py", line 148, in main return command.main(args[1:], options) File "/usr/lib/python2.7/dist-packages/pip/basecommand.py", line 169, in main text = '\n'.join(complete_log)UnicodeDecodeError: 'ascii' codec can't decode byte 0xce in position 54: ordinal not in range(128) I also get errors trying to install gunicorn. I followed this example here but nothing. My virtual environment was created using the --no-site-packagesflag. I use ubuntu 13.10 and greek environment. Maybe it's that?

  • InfluxDB

    Power Real-Time Data Analytics at Scale. Get real-time insights from all types of time series data with InfluxDB. Ingest, query, and analyze billions of data points in real-time with unbounded cardinality.

    InfluxDB logo
NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts

  • Having issues with static file storage when deploying a django 4.2 project

    1 project | /r/django | 7 Jun 2023
  • Good free tier deployment apps for Django and sqllite3 ?

    1 project | /r/learnpython | 27 Jan 2023
  • My first python project and my friends don't care and dont want to open it

    6 projects | /r/Python | 13 Sep 2022
  • what is needed next to deploy my django webapp?

    1 project | /r/learnpython | 23 Aug 2022
  • How to use heroic for excel python app

    1 project | /r/Heroku | 25 Jul 2022