Open cwfoo opened 1 year ago
I suggested @cwfoo open this bug report, but after investigating this issue a little further, it does seem like an odd timezone parameter...
I have a patch for undertime in here that tries to workaround that issue:
https://gitlab.com/anarcat/undertime/-/merge_requests/22
I'm not sure what the right way to go here. The best would be for dateparser to accept actual tzinfo objects instead of having to pass them as a string in the environment.
but after investigating this issue a little further, it does seem like an odd timezone parameter...
Indeed.
The best would be for dateparser to accept actual tzinfo objects instead of having to pass them as a string in the environment.
Sounds like a valid enhancement.
Maybe you could edit the title and description of the issue to be about this enhancement. Or close this issue and open a new one about the enhancement.
These UTC offsets behave as expected:
However, if the UTC offset timezone omits both "UTC" and the minutes offset, there will be an error. Example:
Dateparser should support two-digit UTC offsets because Python standard libraries sometimes return such offsets. For example:
Please fix dateparser so that the
TIMEZONE
setting is able to handle two-digit UTC offsets such as'+08'
.