Make sure you run web2py source (not binary) and use the same Python
version that you installed psycopg2 for.

On Nov 8, 5:14 pm, Steve <[email protected]> wrote:
> After some initial success with Web2py on a PC, I set it up on a
> Macbook Pro.  It worked but had problems with the database being
> locked when multiple web requests came in and compute times were long
> (running student game agents online).  So I installed Postgresql and
> psycopg2.  However, I am having a problem getting gluon to find it.
> I have my db=DAL('postgres://myacct:mypas...@localhost:5432/
> aitourney')
>
> The error I get is this:
> NameError: global name 'psycopg2' is not defined
>
> The traceback says this is in line 902 of gluon/sql.py in <lambda>
>
> How do I get past this error?  Is there a particular config file where
> I have to indicate how to find psycopg2?.
> How is that done?  I used Macports to install psycopg2 in the default
> location.
>
> Thanks.  Web2py generally seems to be an awesome tool.
>
> --Steve
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to