Error with plpython

From: Efraín Déctor <efraindector(at)motumweb(dot)com>
To: <pgsql-general(at)postgresql(dot)org>
Subject: Error with plpython
Date: 2012-07-10 21:59:45
Message-ID: BB66537FEA8E4F2590889A6029E91898@CMOTUM25PC
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hello.

Strange thing happening:

We rencently installed plpython in one of our test servers and installed an extension to use the google api (http://pypi.python.org/pypi/googlemaps ) , everything went fine we tested this function:

CREATE OR REPLACE FUNCTION google_reverse_geocode(lat numeric, lon numeric)
RETURNS text AS
$BODY$

from googlemaps import GoogleMaps
gmaps= GoogleMaps()
address = gmaps.latlng_to_address(lat,lon)
return (address)
$BODY$
LANGUAGE plpythonu VOLATILE
COST 100;
ALTER FUNCTION google_reverse_geocode(numeric, numeric)
OWNER TO pgsql;

However, once we installed it on our production server that function doesnt work, it keeps sending this message:

ERROR: ImportError: cannot import name SSLError
CONTEXT: Traceback (most recent call last):

The strange thing is that our server are the same in everything so we don’t know why is failing in our production eviroment.

Thanks in advance.

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2012-07-10 22:03:28 Re: BUG? Regular expression matching of optional character group at beginning of RE
Previous Message Jeff Ross 2012-07-10 20:06:29 Transaction question