danielrichman / strict-rfc3339

Strict, simple, lightweight RFC3339 functions
GNU General Public License v3.0
31 stars 13 forks source link

Validate_rfc3339 accepts dates with trailing text #1

Closed danielnelson closed 9 years ago

danielnelson commented 9 years ago

The strict_rfc3339.validate_rfc3339 function allows arbitrary text after the time.

I expected this to return False:

In [10]: strict_rfc3339.validate_rfc3339("2013-03-25T12:42:31+00:37howdy")
Out[10]: True
danielrichman commented 9 years ago

wow, this is quite embarassingly bad. Fixed, pushing to pypi now.