New submission from Michael Zhang <mzhangthirt...@gmail.com>:

Discovered this while trying to use a function in `boto3`. Seems like when 
tzlocal() is passed with a 0 to datetime.datetime.fromtimestamp(), it throws an 
"[Errno 22] Invalid argument" error. Using 3.7.4 via Anaconda on Windows 10, 
and tzlocal().tznames's local timezone for me is EST/EDT.

Can replicate through this:
```
import datetime
from dateutil.tz import tzlocal

print(datetime.datetime.fromtimestamp(0, tzlocal()))
```

----------
messages: 355720
nosy: mzhang13
priority: normal
severity: normal
status: open
title: datetime.datetime.fromtimestamp(0, tzlocal()) throws error
type: crash
versions: Python 3.7

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue38645>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to