gnue
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [GNUe] packages?


From: Adrian Maier
Subject: Re: [GNUe] packages?
Date: Thu, 18 Mar 2004 16:57:43 +0200
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.5b) Gecko/20030901 Thunderbird/0.2

Stefan Elwesthal wrote:

I thought that SuSE had a package called postgresql-python, or something similar, which would provide you with the pygresql module. But anyway, you could try compiling pygresql or psycopg or popy from sources.

Adrian Maier

Hello again! Thanks for all the info, It would be nice to get this one going. And yes, I have this version installed: address@hidden:/opt/gnue/bin> rpm -q postgresql-python postgresql-python-7.3.4-53 This is my entry in Connection.conf which gives me a missing psycvopg error when I try to use it in the wizard? [adressbok] comment = Pgsql adressbok #aliases = dcl test provider = psycopg host = localhost dbname = adressbok this is the error: Gdk-CRITICAL **: file gdkgc.c: line 689 (gdk_gc_set_clip_rectangle): assertion `gc != NULL' failed. DB000: Traceback (most recent call last): DB000: File "/opt/gnue//lib/python/gnue/designer/base/TemplateParser.py", line 222, in OnNextStep DB000: self.setStep(self.nextStep) DB000: File "/opt/gnue//lib/python/gnue/designer/base/TemplateParser.py", line 178, in setStep DB000: self.stepInfo = self.parser.template.GetStep(step) DB000: File "/opt/gnue//lib/python/gnue/designer/templates/forms/FormBuilder.py", line 196, in GetStep DB000: set=self.GetAvailableSources(self.variables['connection%s'%iteration])), DB000: File "/opt/gnue//lib/python/gnue/designer/base/TemplateBase.py", line 171, in GetAvailableSources DB000: self.__cachedSources[connection_name] = \ DB000: File "/opt/gnue//lib/python/gnue/designer/base/TemplateBase.py", line 165, in GetTemporaryConnection DB000: return self._connections.getConnection(connection_name,1) DB000: File "/opt/gnue//lib/python/gnue/common/datasources/GConnections.py", line 255, in getConnection DB000: conn = dbdriver.Connection(self, connection_name, parameters) DB000: File "/opt/gnue//lib/python/gnue/common/datasources/drivers/postgresql/psycopg/__init__.py", line 42, in Connection DB000: from Driver import Connection as C DB000: File "/opt/gnue//lib/python/gnue/common/datasources/drivers/postgresql/psycopg/Driver.py", line 34, in ? DB000: import psycopg DB000: ImportError: No module named psycopg


There are 4 providers which can be used to access PostgreSQL from
python , and consequently from gnue:    pygresql, psycopg, pypgsql,
popy.  Their names are very similar, and they are intended do
the same thing.  (a real madness!   because it's so easy to confuse
them).


It looks like the postgresql-python package doesn't provide the psycopg
module.  I think it provides pygresql.

You can verify it like this:
you run the python interpreter and you just write:

import pg

If it doesn't give any error, it means that you have indeed the
pygresql module.  And you'll have to change in the connections.conf:

provider=postgresql



Good luck!


Adrian Maier













reply via email to

[Prev in Thread] Current Thread [Next in Thread]