I put together a little test app, but can't reproduce the problem. However, it researching, I've tracked down the error to the following:
Traceback 1. 2. 3. 4. 5. 6. 7. 8. 9. 10. 11. 12. 13. 14. 15. 16. 17. 18. 19. 20. 21. 22. 23. 24. 25. 26. 27. 28. Traceback (most recent call last): File "C:\prod\web2py2.10.2\gluon\restricted.py", line 227, in restricted exec ccode in environment File "C:/prod/web2py2.10.2/applications/connect/controllers/contacts.py" <http://127.0.0.1:8000/admin/default/edit/connect/controllers/contacts.py>, line 727, in <module> File "C:\prod\web2py2.10.2\gluon\globals.py", line 393, in <lambda> self._caller = lambda f: f() File "C:\prod\web2py2.10.2\gluon\tools.py", line 3440, in f return action(*a, **b) File "C:/prod/web2py2.10.2/applications/connect/controllers/contacts.py" <http://127.0.0.1:8000/admin/default/edit/connect/controllers/contacts.py>, line 231, in index paginate=15, maxtextlength=45, formstyle=my_formstyle, ui=grid_ui) File "C:\prod\web2py2.10.2\gluon\sqlhtml.py", line 2272, in grid next=referrer) File "C:\prod\web2py2.10.2\gluon\html.py", line 2301, in process self.validate(**kwargs) File "C:\prod\web2py2.10.2\gluon\html.py", line 2238, in validate if self.accepts(**kwargs): File "C:\prod\web2py2.10.2\gluon\sqlhtml.py", line 1677, in accepts self.id_field_name]).update(**fields) File "C:\prod\web2py2.10.2\gluon\packages\dal\pydal\objects.py", line 2112, in update if any(f(self,update_fields) for f in table._before_update): File "C:\prod\web2py2.10.2\gluon\packages\dal\pydal\objects.py", line 2112, in <genexpr> if any(f(self,update_fields) for f in table._before_update): File "C:\prod\web2py2.10.2\gluon\packages\dal\pydal\objects.py", line 423, in <lambda> archive_record(qset, fs, db[an], cn)) File "C:\prod\web2py2.10.2\gluon\packages\dal\pydal\helpers\methods.py", line 91, in archive_record if fields[k] != v: KeyError: 'id' Please ignore the web2py2.10.2 in the directory naming, it truly is 2.10.3. I'm able to reproduce this with my app on Linux or Windows, with rocket, nginx or Apache. Going to mess around with it more today... -Jim On Wednesday, April 8, 2015 at 9:27:25 AM UTC-5, Jim S wrote: > > Using MySQL. I'll put something together to see if I can reproduce the > issue. > > -Jim > > On Wednesday, April 8, 2015 at 8:24:02 AM UTC-5, Paolo Valleri wrote: >> >> Hi Jim, >> Which back-engine are you using? Have you tried with a different one? >> Can you pack a simple app that reproduce the issue? >> >> Paolo >> >> On Tuesday, April 7, 2015 at 9:40:29 PM UTC+2, Jim S wrote: >>> >>> Just wondering if this is posted in the right place. Should I be >>> reporting this issue elsewhere? >>> >>> -Jim >>> >>> On Monday, April 6, 2015 at 9:53:46 AM UTC-5, Jim S wrote: >>>> >>>> Upgraded to >>>> >>>> 2.10.3-stable+timestamp.2015.04.02.21.42.07 >>>> (Running on nginx/1.4.6, Python 2.7.6) >>>> >>>> ...still having the same problem with record versioning. >>>> >>>> -Jim >>>> >>>> On Thursday, April 2, 2015 at 4:37:03 PM UTC-5, Jim S wrote: >>>>> >>>>> Version 2.10.1-stable+timestamp.2015.04.01.03.27.40 >>>>> >>>>> I have one table with record versioning turned on. I get the >>>>> following in my nginx setup... >>>>> >>>>> nginx 502 Bad Gateway >>>>> >>>>> Looking in the nginx log I see: >>>>> >>>>> 2015/04/02 15:37:13 [error] 1040#0: *67 upstream prematurely closed >>>>> connection while reading response header from upstream, client: >>>>> 10.10.2.126, server: ss15, request: "POST >>>>> /contacts/index/edit/contact/5221?district_id=0&search_text=steil&tag_id=0&_signature=81d4b0ab8a5bf5f05de6ed17c6203596d5883f76 >>>>> >>>>> HTTP/1.1", upstream: "uwsgi://unix:///tmp/web2py.socket:", host: "ss15", >>>>> referrer: " >>>>> https://ss15/contacts/index/edit/contact/5221?district_id=0&search_text=steil&tag_id=0&_signature=81d4b0ab8a5bf5f05de6ed17c6203596d5883f76 >>>>> " >>>>> >>>>> If I comment out this line: >>>>> >>>>> db.contact._enable_record_versioning() >>>>> >>>>> Then it works fine. >>>>> >>>>> It works fine on my production server running Version >>>>> 2.9.5-stable+timestamp.2014.03.16.02.35.39 >>>>> >>>>> nginx 1.4.6 on both systems >>>>> uwsgi version 2.0.6 on the system that works >>>>> uwsgi version 2.0.10 on the system exhibiting the problem >>>>> >>>>> If I run with the built-in rocket server, I see the same behavior. >>>>> >>>>> Here is the traceback when running on rocket: >>>>> >>>>> ERROR:Rocket.Errors.Thread-2:Traceback (most recent call last): >>>>> File "C:\prod\web2py\gluon\rocket.py", line 1337, in run >>>>> self.run_app(conn) >>>>> File "C:\prod\web2py\gluon\rocket.py", line 1838, in run_app >>>>> output = self.app(environ, self.start_response) >>>>> File "C:\prod\web2py\gluon\main.py", line 652, in app_with_logging >>>>> ret[0] = wsgiapp(environ, responder2) >>>>> File "C:\prod\web2py\gluon\main.py", line 563, in wsgibase >>>>> return wsgibase(new_environ, responder) >>>>> File "C:\prod\web2py\gluon\main.py", line 533, in wsgibase >>>>> if request.body: >>>>> File "C:\prod\web2py\gluon\globals.py", line 268, in body >>>>> self._body = copystream_progress(self) >>>>> File "C:\prod\web2py\gluon\globals.py", line 125, in >>>>> copystream_progress >>>>> copystream(source, dest, size, chunk_size) >>>>> File "C:\prod\web2py\gluon\fileutils.py", line 426, in copystream >>>>> data = src.read(size) >>>>> >>>>> ValueError: I/O operation on closed file >>>>> >>>>> Please let me know if you need more information to help with this >>>>> issue. >>>>> >>>>> -Jim >>>>> >>>>> >>>>> On Wednesday, April 1, 2015 at 11:03:20 AM UTC-5, Massimo Di Pierro >>>>> wrote: >>>>>> >>>>>> Please report here upgrading issues to web2py 2.10.2 >>>>>> >>>>>> from which version? >>>>>> which os? >>>>>> which python version? >>>>>> what is the problem? complete traceback >>>>>> >>>>> -- 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 web2py+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.