working with psycopg2

[email protected] Thu, 16 Jul 2009 12:15:15 +0100
Newsgroups gmane.comp.python.modeling
Message-ID <[email protected]>
I had psycopg working doing Zope user authentication against postgresql,
so I knew psycopg was working.  I saw the latest versions of psycopg
install into /usr/local/lib/python/site-packages/psycopg2.

However, when I tried to run mdl_validate_model.py as a test of the
Modeling install, I got errors concerning python not being able to load
psycopg.  Dropping into the interpreter and following an example of
working with psycopg2 (which did 'import psycopg2'), I was able to fetch
data from the database.

Having recently seen someone on the Zope users list having trouble with
psycopg imports, and seeing the solution involved importing psycopg2, I
guessed this was the issue with Modeling.

I created a symlink in site-packages from psycopg2 for psycopg.

Running mdl_validate_model.py sample_pymodel.py now gave no errors, but
returned nothing.  I'm assuming that is following the unix philosophy of
being silent when there is nothing to report.

Bernard


------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge  
This is your chance to win up to $100,000 in prizes! For a limited time, 
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full prize  
details at: http://p.sf.net/sfu/Challenge