forked from micropython/micropython
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Closed
Labels
Description
Hello, according to the documentation here, there is supposed to be a time.time() function like normal python. However, when I try to use this function it doesn't exist. It is probably just a documentation oversight. My output from the error and REPL is shown below:
code.py output:
Traceback (most recent call last):
File "code.py", line 37, in <module>
File "code.py", line 17, in __init__
AttributeError: 'module' object has no attribute 'time'
Press any key to enter the REPL. Use CTRL-D to reload.
Adafruit CircuitPython 5.2.0 on 2020-04-09; Adafruit Trinket M0 with samd21e18
>>> import time
>>> time.time()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AttributeError: 'module' object has no attribute 'time'
>>> dir(time)
['__name__', 'monotonic', 'sleep', 'struct_time']
>>>
I am using a Trinket M0 and circuitpython 5.2.0.