Hi, I need some help tracking the cause of this error. I have been looking at Python off and on for the last year or so. I write ASP classic and VB6 as my day job (yeah, I know.., it pays the bills). So some of this may be me have to think differently. I have tried the web.py group with no answer. I am probably not asking the right question or they think it is a SQLlite error.
Here is the complete traceback Traceback (most recent call last): File "/usr/local/lib/python2.7/dist-packages/web.py-0.37-py2.7.egg/web/application.py", line 239, in process return self.handle() File "/usr/local/lib/python2.7/dist-packages/web.py-0.37-py2.7.egg/web/application.py", line 230, in handle return self._delegate(fn, self.fvars, args) File "/usr/local/lib/python2.7/dist-packages/web.py-0.37-py2.7.egg/web/application.py", line 420, in _delegate return handle_class(cls) File "/usr/local/lib/python2.7/dist-packages/web.py-0.37-py2.7.egg/web/application.py", line 396, in handle_class return tocall(*args) File "Code.py", line 24, in GET todos = db.select('todo') File "/usr/local/lib/python2.7/dist-packages/web.py-0.37-py2.7.egg/web/db.py", line 682, in select return self.query(qout, processed=True) File "/usr/local/lib/python2.7/dist-packages/web.py-0.37-py2.7.egg/web/db.py", line 1030, in query out = DB.query(self, *a, **kw) File "/usr/local/lib/python2.7/dist-packages/web.py-0.37-py2.7.egg/web/db.py", line 644, in query self._db_execute(db_cursor, sql_query) File "/usr/local/lib/python2.7/dist-packages/web.py-0.37-py2.7.egg/web/db.py", line 587, in _db_execute out = cur.execute(query, params) File "/usr/lib/python2.7/sqlite3/dbapi2.py", line 63, in convert_date return datetime.date(*map(int, val.split("-"))) ValueError: invalid literal for int() with base 10: '21 01:47:43' 127.0.0.1:59850 - - [04/Dec/2012 22:47:35] "HTTP/1.1 GET /" - 500 Internal Server Error I understand the error, there is no way '21 01:47:43' can become an int. What I can not figure out is the correlation between the last two lines in the traceback. What is actually calling the last command 'datetime.date'? Here is another kicker, I have tesed this on 4 computers, all with Python 2.7 and the lastest web.py egg. One of the computers works without an error. I did some additional testing by hijacking db.py and adding text to line 587 that would normally cause a meltdown. I can say that on the working computer the function datetime.date is not being called. Why on one computer and not the others. I know the code is the same becuse the files are synced via DropBox on all 4 machines. I have also written a test script that calls the SQLite lib directly and opens a connection and recordset. This works on all 4 machines. All of my code for this is here on this shared dropbox folder. Code.py is the stater file for web.py https://www.dropbox.com/sh/1zqjgtj86q033r8/LBgzPx-kLq Thanks, Erik Martinson
_______________________________________________ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor