小编Mar*_*ulz的帖子

heroku python datetime不包括fromisoformat

我使用控制台在Heroku上运行以下代码:

~ $ python
Python 3.6.6 (default, Aug  1 2018, 21:10:15)
[GCC 7.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import datetime
>>> datetime.datetime.fromisoformat("2015-06-06T17:23:54+10:00")
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
AttributeError: type object 'datetime.datetime' has no attribute 'fromisoformat'
>>>
Run Code Online (Sandbox Code Playgroud)

这在我的Mac上的Python 3.7.0上运行良好。

如何访问在Heroku下运行的“ fromisoformat”?

heroku python-3.x python-datetime

5
推荐指数
1
解决办法
1129
查看次数

标签 统计

heroku ×1

python-3.x ×1

python-datetime ×1