Roundup Tracker - Issues

Issue 984604

classification
Handling date values in RDBMs
Type: Severity: normal
Components: Database Versions:
process
Status: closed fixed
:
: richard : richard, uzak
Priority: normal :

Created on 2004-07-03 13:35 by uzak, last changed 2004-07-04 09:08 by richard.

Files
File name Uploaded Description Edit Remove
date.patch uzak, 2004-07-03 14:22
Messages
msg1343 Author: [hidden] (uzak) Date: 2004-07-03 13:35
There is a bug in 0.7.5 in
roundup/backends/rdbms_common.py. On the line 1119 you
ask whether a value is instance of Date, if so, you
pass the value to the constructor of Date, which can't
do anything with it an raises an Exception. 

  File
"/usr/lib/python2.3/site-packages/roundup/cgi/templating.py",
line 868, in history
    d = date.Date(args[k]).local(timezone)
  File
"/usr/lib/python2.3/site-packages/roundup/date.py",
line 135, in __init__
    raise ValueError, 'Unknown spec %r'%spec
ValueError: Unknown spec <Date 2004-06-12.15:00:0.000000>

The real bug sits in roundup/date.py. There is a check
(line no. 125) for `tuple` attribute, which should be
`get_tuple` (or even better, isinstance(spec, Date).

I attach a patches for this bug.
msg1344 Author: [hidden] (richard) Date: 2004-07-04 09:08
Logged In: YES 
user_id=6405

 
History
Date User Action Args
2004-07-03 13:35:39uzakcreate