update web2py to 2.9.11 please.

On Saturday, October 18, 2014 5:13:46 AM UTC+2, Sebastian Echeverria wrote:
>
> Ok, so installing psycopg2 did make web2py use it instead of pg8000. And I 
> stopped getting the error I was seeing before.
>
> However, when trying to start the scheduler, I get another error, which 
> from what I see comes from the line right after the one generating the 
> previous error:
>
> web2py.scheduler.localhost#20734 - ERROR - Error retrieving status
> scheduler_worker
> localhost#20734
> Traceback (most recent call last):
>   File "/home/www-data/web2py/gluon/scheduler.py", line 963, in 
> send_heartbeat
>     worker_stats=self.w_stats)
>   File "/home/www-data/web2py/gluon/dal.py", line 9293, in insert
>     ret =  self._db._adapter.insert(self, self._listify(fields))
>   File "/home/www-data/web2py/gluon/dal.py", line 1361, in insert
>     raise e
> DataError: invalid input syntax for type json
> LINE 1: ...heartbeat) VALUES ('ACTIVE','2014-10-17 23:54:59','<Storage ...
>                                                              ^
> DETAIL:  Token "<" is invalid.
> CONTEXT:  JSON data, line 1: <...
>
> Up to here, I am just trying to start the scheduler. I don't even have any 
> tasks added to the queue yet. There seems to be a problem with the 
> worker_stats Storage object, it seems it is not being converted to JSON but 
> just passed with quotes around it. But again, this seems to be inside 
> web2py, not anyting that I am doing in my code. Do you have any clues on 
> what the issue may be this time, and what I could do about it? Again, my 
> goal so far is just to be able to start the task scheduler on a PostgreSQL 
> database....
>
> Thanks again,
>
> Sebastian
>
> On Friday, October 17, 2014 12:43:59 PM UTC-3, Niphlod wrote:
>>
>> if ou're using a DAL uri as "postgresql://blablabla" the only thing to do 
>> is to install psycopg2 on the system: if available, it takes precedence.
>>
>> On Thursday, October 16, 2014 11:13:41 PM UTC+2, Sebastian Echeverria 
>> wrote:
>>>
>>> Hello,
>>>
>>> Thanks for the reply! So in fact, the issue is the same one the other 
>>> poster was facing. Do you have any hints on how to use psycopg2 instead? 
>>> Where would I have to change that? Is there a configuration for that, or 
>>> would I have to make that change somewhere in the code?
>>>
>>> Thanks,
>>>
>>> Sebastian
>>>
>>> On Tuesday, October 14, 2014 9:26:07 AM UTC-3, Niphlod wrote:
>>>>
>>>> the problem comes from pg8000 not supporting the json type. Use 
>>>> psycopg2 instead.
>>>>
>>>> On Monday, October 13, 2014 9:56:38 PM UTC+2, Sebastian Echeverria 
>>>> wrote:
>>>>>
>>>>> Hello,
>>>>>
>>>>> I am having some trouble starting up web2py's scheduler. I am working 
>>>>> on a Ubuntu server, using web2py 2.9.9 deployed with nginx, and 
>>>>> PostgreSQL. 
>>>>> Everything works just right, but whenever I try to run the scheduler 
>>>>> (python web2py.py -K myapp), I get continous "*Error retrieving 
>>>>> status*" errors. The Scheduler object is being created in a model, 
>>>>> and all the appropriate scheduler tables have been automatically created, 
>>>>> so the issue does not seem to be there.
>>>>>
>>>>> If I modify scheduler.py to get some more info about the error, I see 
>>>>> that the exception that generates this error message is 
>>>>> "NotSupportedError: 
>>>>> type oid 114 not mapped to py type", thrown from here: 
>>>>> '..."web2py/gluon/scheduler.py", line 958, in send_heartbeat, 
>>>>> mybackedstatus = db(sw.worker_name == 
>>>>> self.worker_name).select().first()'. 
>>>>> I found a similar error here (
>>>>> https://groups.google.com/forum/#!topic/web2py/BfSIbUSPk38), but I 
>>>>> assumed in that case that the bug was on a custom table that person was 
>>>>> using. Here I am simply trying to start the scheduler with PostgreSQL. I 
>>>>> hope there is not a bug that prevents using the scheduler with 
>>>>> PostgreSQL...
>>>>>
>>>>> Is there anything that I am missing, or that I am doing wrong?
>>>>>
>>>>> Thanks in advance,
>>>>>
>>>>> Sebastian
>>>>>
>>>>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to