py25-psycopg2 is installed, and it is the psycopg2 for python 2.5
If I install py-psycopg, Ports also installs Python 2.4. These issues
consumed my Tuesday.

I had postgres81 and postgres82, Python 2.4 and Python 2.5 installed
because of the dependencies thing with Ports and my own downloading of
dmg files. I finally uninstalled everything and then did
sudo port install py25-psycopg2
and MacPorts installed postgresql81 and python25 as dependencies

Then I did
sudo port install postgresql81-server subversion

And I should have been done, but I am getting the above error that
indicates that Python cannot find psycopg2.

On Dec 19, 11:34 pm, David Reynolds <[EMAIL PROTECTED]>
wrote:
> On 19 Dec 2007, at 8:49 am, Shinmaikeru wrote:
>
>
>
>
>
> > Django newbie here just trying to get an environment going so that I
> > can say goodbye to PHP and make python/django my native tongue.
>
> > I went through several installs using various images and then
> > uninstalls and such before finally installing everything through
> > MacPorts. However...
>
> > When I run `python manage.py runserver`, I get:
>
> > File "/Library/Frameworks/Python.framework/Versions/2.5/lib/python2.5/
> > site-packages/django/db/backends/postgresql_psycopg2/base.py", line
> > 15, in <module>
> >     raise ImproperlyConfigured("Error loading psycopg2 module: %s" %
> > e)
> > django.core.exceptions.ImproperlyConfigured: Error loading psycopg2
> > module: dlopen(/Library/Frameworks/Python.framework/Versions/2.5/lib/
> > python2.5/site-packages/psycopg2/_psycopg.so, 2): Library not
> > loaded: /
> > usr/local/pgsql/lib/libpq.4.dylib
> >   Referenced from: /Library/Frameworks/Python.framework/Versions/2.5/
> > lib/python2.5/site-packages/psycopg2/_psycopg.so
> >   Reason: image not found
>
> > Then I do `locate libpq.4` and get:
> > /opt/local/lib/postgresql81/libpq.4.1.dylib
> > /opt/local/lib/postgresql81/libpq.4.dylib
> > /opt/local/var/macports/software/postgresql81/8.1.10_0+darwin_8/opt/
> > local/lib/postgresql81/libpq.4.1.dylib
> > /opt/local/var/macports/software/postgresql81/8.1.10_0+darwin_8/opt/
> > local/lib/postgresql81/libpq.4.dylib
>
> > So why is the program looking in /usr/local/pgsql/lib/ when the
> > library is in /opt/local/lib/postgresql81/ ? All of these programs
> > were installed with MacPorts, so shouldn't they know where each other
> > reside?
>
> You'll need to also do:
>
> port install py-psycopg2
>
> This will install the library that lets python talk to posgres.
>
> Thanks,
>
> David
>
> --
> David Reynolds
> [EMAIL PROTECTED]
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to