Re: Connection errors
Oleg Broytman <[email protected]> Sat, 28 Sep 2013 13:22:26 +0400
| Newsgroups | gmane.comp.python.sqlobject |
|---|---|
| Message-ID | <[email protected]> |
Hi! On Thu, Sep 26, 2013 at 11:52:08AM -0300, Francisco Chiotta <[email protected]> wrote: > It doesn't work for me either. I have installed the psycopg 2.5.1 (the > latest), and I always get None if the authentication fails or the server is > not working in the given IP. I don't know why. > > 2013/9/15 Oleg Broytman <[email protected]> > > > On Fri, Sep 13, 2013 at 11:40:09AM -0300, Francisco Chiotta < > > [email protected]> wrote: > > > It would be great. Sure, I can test the results. > > > > The patch is attached. The code and error string are available: > > > > try: > > do_something() > > except OperationalError, e: > > print e.args[0].code > > print e.args[0].error > > > > Doesn't work for me, though -- pgcode/pgerror are always None. > > Perhaps I'm using old version of psycopg2 -- 2.4.5. I returned from the vacation. Will test if psycopg w/o SQLObject returns the code/error. Oleg. -- Oleg Broytman http://phdru.name/ [email protected] Programmers don't die, they just GOSUB without RETURN. ------------------------------------------------------------------------------ October Webinars: Code for Performance Free Intel webinars can help you accelerate application performance. Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from the latest Intel processors and coprocessors. See abstracts and register > http://pubads.g.doubleclick.net/gampad/clk?id=60133471&iu=/4140/ostg.clktrk