Skip to content

time.struct_time(...) does not follow CPython #2326

@ghost

Description

CircuitPython throws an error for time.struct_time(time.localtime(946688698)):

>>> import time
>>> time.struct_time(time.localtime(946688698))
Traceback (most recent call last):
  File "<stdin>", line 2, in <module>
TypeError: time.struct_time() takes a 9-sequence


CPython is happy:

>>> import time
>>> time.struct_time(time.localtime(946688698))
time.struct_time(tm_year=1999, tm_mon=12, tm_mday=31, tm_hour=17, tm_min=4, tm_sec=58, tm_wday=4, tm_yday=365, tm_isdst=0)

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions