I believe it would be a good contribution. If it is triggered only for unsupported years, why not? ;-)
On 6/12/06, Max Ischenko <[EMAIL PROTECTED]> wrote: > > Hi, > > I'm using DateTimePicker widget and it fails to work with dates <= 1900. > > Traceback: > > File > "/home2/romanix/lib/python2.4/site-packages/TurboGears-0.9a6dev_r1341-py2 > .4.egg/turbogears/widgets/base.py", line 235, in display > params["value"] = to_unicode(self.adjust_value(value, **params)) > File > "/home2/romanix/lib/python2.4/site-packages/TurboGears-0.9a6dev_r1341-py2 > .4.egg/turbogears/widgets/forms.py", line 220, in adjust_value > value = self.validator.from_python(value) > File > "/home2/romanix/lib/python2.4/site-packages/FormEncode-0.5.1-py2.4.egg/fo > rmencode/api.py", line 353, in from_python > value = self._from_python(value, state) > File > "/home2/romanix/lib/python2.4/site-packages/TurboGears-0.9a6dev_r1341-py2 > .4.egg/turbogears/validators.py", line 105, in _from_python > return value.strftime(self.format) > ValueError: year=1450 is before 1900; the datetime strftime() methods require > ye > ar >= 1900 > > I wonder if we should add a work-around for this in TG core. > > See http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/306860 > > > > > -- Godoy. <[EMAIL PROTECTED]> --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "TurboGears Trunk" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/turbogears-trunk -~----------~----~----~----~------~----~------~--~---
