Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use python-dateutil instead of python-aniso8601 #89

Open
ajblum opened this issue Aug 7, 2015 · 0 comments
Open

Use python-dateutil instead of python-aniso8601 #89

ajblum opened this issue Aug 7, 2015 · 0 comments

Comments

@ajblum
Copy link

ajblum commented Aug 7, 2015

I see that python-aniso8601 is being used so its installation is required. I would ask, can dateutil.parser (python-dateutil) be used instead ?

I've run a quick test after this change to conversions/iso8601.py and it looks as though timestamps for statements are posted to the LRS in utc:

[root@localhost conversions]# diff iso8601-old.py iso8601-new.py 
24c24,25
< import aniso8601

---
> #import aniso8601
> import dateutil.parser
204c205,206
<             return aniso8601.parse_datetime(value)

---
>             #return aniso8601.parse_datetime(value)
>       return dateutil.parser.parse(value)

My selfish reason for wanting this is that dateutil is available with RHEL's python without adding in extra software via pip (beyond TinCanPython). I also see that there is some community input on this - http://stackoverflow.com/questions/127803/how-to-parse-an-iso-8601-formatted-date-in-python.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant