Thanks Dave. I’m thinking it must be something of that order too. Time to rebuild this project’s yank file.
Carl Hunter Roach Bisham Barn Owl Group Middle Thames Conservation Trust Runnymede Ringing Group Founder, Midnight 30 Ltd midnight30.com Makers of Great Careers ________________________________ From: [email protected] on behalf of Dave S <[email protected]> Sent: Tuesday, May 28, 2019 7:10 pm To: web2py-users Subject: [web2py] Re: GAE Task Queue no longer passes payload to web2py function On Tuesday, May 28, 2019 at 4:11:40 AM UTC-7, Carl Hunter Roach wrote: I installed R-2.15.4. You are right that I don't get any function parameters in the functions that handle my Google tasks. I am getting a weird error. In the function handling the Google task that historically worked) the value of `request.body` is: <open file '<fdopen>', mode 'w+b' at 0x2b31c3ed9930> That is weird. For the payload of the Google task I'm passing in some json data. I can't see where an fdopen value would be coming from. I'm afraid you've gone beyond my experience. I haven't used GAE. I know Massimo and some others of the core group have, but you may need to check that there isn't something in your YAML that GAE has obsoleted or has always considered wrong but tolerated until now. I know that GG code is tweaked fairly often, and given Google's continuous integration strategy, I'd expect GAE to be updated frequently as well. /dps On Friday, 24 May 2019 21:37:53 UTC+1, Dave S wrote: On Friday, May 24, 2019 at 3:43:26 AM UTC-7, Carl Hunter Roach wrote: This code has been working for a couple of years but, for an unknown reason to me, has stopped working. This function continues to create Tasks correctly. def send_task(): from google.appengine.api import taskqueue json_data = ... task = taskqueue.Task(url=..., countdown=2, payload=json_data) task.add() The handling url is passed to: in db.py openings_service = Service() in controller... @openings_service.json def opening_task_queue(): body_data = request.body.getvalue() For the last couple of years `body_data` was populated and processing continued. But last week, without change to my code, request.body was no longer present. I had been running with Web2py R-2.14.6 but an upgrade to R-2.15.0b2 broke how I needed to declare functions. Ooooh, yuck. 2.15.0b2 is not a good choice; I'm using 2.15.4, and the 2.18.x line is much, much better (pending upgrade, but I've been letting other people shake the low-hanging fruit off first) Where I had been using function headings with no parameters: @openings_service.json def submit_openings(): I now needed to declare: @openings_service.json def submit_openings(openings): Does anyone know why? And does that relate to the error I detail at the top of this post? That change should not be the case. Functions as URL targets should not have parameters, and none of my @auth_requires_login() or @request.restful() uses have had to add parameters after the annotation. /dps -- 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 a topic in the Google Groups "web2py-users" group. To unsubscribe from this topic, visit https://groups.google.com/d/topic/web2py/tAd7MgqZ9so/unsubscribe. To unsubscribe from this group and all its topics, send an email to [email protected]<mailto:[email protected]>. To view this discussion on the web visit https://groups.google.com/d/msgid/web2py/22ae6bd1-dbf8-4bfa-bd01-b2448577e509%40googlegroups.com<https://groups.google.com/d/msgid/web2py/22ae6bd1-dbf8-4bfa-bd01-b2448577e509%40googlegroups.com?utm_medium=email&utm_source=footer>. For more options, visit https://groups.google.com/d/optout. -- 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]. To view this discussion on the web visit https://groups.google.com/d/msgid/web2py/DB7PR03MB42981A6AEB3B72735369C85FA41E0%40DB7PR03MB4298.eurprd03.prod.outlook.com. For more options, visit https://groups.google.com/d/optout.

