Error Loading Psycopg Module S E
Contents |
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack django error loading psycopg2 module: no module named 'psycopg2' Overflow the company Business Learn more about hiring developers or posting ads with us error loading psycopg2 module: no module named psycopg2 mac Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a install psycopg2 on windows community of 4.7 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up Django runserver error (psycopg2) up vote 1 down vote favorite I'm trying to do this:
Importerror No Module Named Psycopg2 Windows
python3.3 manage.py runserver In my Django project folder. I get this error message: File "/usr/local/lib/python3.3/site-packages/django/db/backends/postgresql_psycopg2/base.py", line 25, in
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and no module named psycopg2 _psycopg policies of this site About Us Learn more about Stack Overflow the
./psycopg/psycopg.h:30:20: Fatal Error: Python.h: No Such File Or Directory
company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users
Error: Pg_config Executable Not Found.
Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 4.7 million programmers, just like you, helping each other. Join them; it only takes http://stackoverflow.com/questions/21516847/django-runserver-error-psycopg2 a minute: Sign up Django, mod_wsgi, psycopg2 ImproperlyConfigured: Error loading psycopg2 module: No module named _psycopg up vote 5 down vote favorite 2 I have a Django 1.5, Python 2.7 site running under Apache with mod_wsgi on a CentOS 6.4 server. I have rebuilt this site using Django 1.6 and Python 3.3. Deploying it to the same server and changing the paths http://stackoverflow.com/questions/21158918/django-mod-wsgi-psycopg2-improperlyconfigured-error-loading-psycopg2-module in httpd.conf I get the subject error. This new install works as expected using ./manage.py runserver. Here are the two WSGI definitions from httpd.conf: WSGIScriptAlias / /home/ccdgen/CCDGEN2/apache/wsgi.py WSGIPythonPath /home/ccdgen/CCDGEN2/ccdgen/ccdgen:/home/ccdgen/CCDGEN2/ccdgen:/home/ccdgen/CCDGEN2/lib/python3.3/site-packages
Start here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About http://serverfault.com/questions/619879/psycopg2-not-found-by-django-after-installing-in-virtualenv Us Learn more about Stack Overflow the company Business Learn more about hiring http://djbook.ru/forum/topic/2647/ developers or posting ads with us Server Fault Questions Tags Users Badges Unanswered Ask Question _ Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute: Sign up Here's how it works: Anybody can ask a question Anybody can answer The best answers are no module voted up and rise to the top psycopg2 not found by django after installing in virtualenv up vote 5 down vote favorite 1 I want to use postgresql with django so did the following: sudo apt-get install libpq-dev python-dev sudo apt-get update workon myenv sudo pip install psycopg2 And after configuring my settings.py correctly, I run ./manage.py syncdb But an exception gets thrown: django.core.exceptions.ImproperlyConfigured: Error loading psycopg2 no module named module: No module named psycopg2 The database configuration: DATABASES = { 'default': { 'ENGINE': 'django.db.backends.postgresql_psycopg2', 'NAME': 'mydb', 'USER': 'postgres', 'PASSWORD': 'password1234', 'HOST': 'localhost', 'PORT': '', } } postgresql django virtualenv share|improve this question edited Aug 14 '14 at 16:01 xofer 2,679518 asked Aug 12 '14 at 15:27 Joren 2816 Check permissions in the venv -- you installed w/ sudo. –xofer Aug 12 '14 at 15:39 Also can you confirm that you installed psycopg2 (and not psycpg2) with pip. –xofer Aug 12 '14 at 15:43 @xofer I did install psycopg2 –Joren Aug 12 '14 at 15:45 add a comment| 1 Answer 1 active oldest votes up vote 3 down vote accepted Installing with sudo (sudo pip install ...) causes the installed files to be owned by root, and Django (run without sudo) cannot read them. You can sudo pip uninstall psycopg2 and then install without sudo. (If that doesn't work, try sudo chown -R $USER ~/.virtualenvs/myvenv first (assumes that's your virtualenv path). share|improve this answer answered Aug 14 '14 at 13:50 xofer 2,679518 2 you are my savior –Suoinguon Dec 16 '14 at 19:16 add a comment| Your Answer draft saved draft
ORM Разное Формы Основы Админка Декораторы Python Django CMS Архив Миграции Jobs О проекте Join Gitter Django на русском If PHP was originally designed explicitly for non-programmers, does that mean you write non-programs with it ? Разработка на Python / Python & Django / Django 1.7 Python 3.4 Postgresql 9.3 psycopg2 error Ответ 14 Окт. 2014, 1:39 Runnko Отклики: 46 14 Окт. 2014, 1:39 Runnko Отклики: 46 Всем привет, уже второй или третий день мучаюсь с некой проблемой: Хотел развернуть Джанго 1.7 с питоном 3.4 и использовать при этом postgresql всё это соответственно в виртуальном окружении virtualenv. Взял этот туториал http://habrahabr.ru/post/181556/ и дойдя до первого использования python manage.py sycndb Получил следующий результат: runnko@RunnkoPC:~/Web/virtualenv/mysite$ python3 manage.py syncdb Traceback (most recent call last): File "/usr/local/lib/python3.4/dist-packages/django/db/backends/postgresql_psycopg2/base.py", line 23, in