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

datetime: support a formatter function in addition to the existing dateformat string #17

Open
rtdean opened this issue Jul 14, 2019 · 1 comment
Assignees
Labels
enhancement New feature or request

Comments

@rtdean
Copy link

rtdean commented Jul 14, 2019

While the existing datetime support is nice, some additional flexibility would be nice. When reading date strings, for example, the ability to use a well known parser such as dateutil.parser or, the ability to manipulate the datetime object as it's created (such as making sure the conversion to UTC happens correctly, if needed), or even to instantiate a datetime from a non-human format, such as a unix timestamp.

To that end, in addition to the dateformat metadata that exists today, maybe some sort of datefactory or dateformatter metadata, which would be a callable, passing in the value, and returning a well-formed datetime object would be useful.

@dfurtado
Copy link
Owner

Hello @rtdean !!

Sorry for the late reply. Yeah, I agree it would be very parsing dates the right way. Is that something that you would be interested in implementing?

@dfurtado dfurtado self-assigned this Jul 27, 2020
@dfurtado dfurtado added the enhancement New feature or request label Jul 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants