geekscape / aiko_engine_mp

microPython event based engine supporting network messages (MQTT), times and various hardware drivers
Other
22 stars 24 forks source link

Syntax error in examples/buttons_slider.py #22

Closed PaulSchulz closed 3 years ago

PaulSchulz commented 3 years ago

paul@silver:~/Documents/git/aiko_engine_mp/examples$ ./install.sh File "buttons_sliders.py", line 85 print("Touch: " + str(slider_left), end=" \r") ^ SyntaxError: invalid syntax

geekscape commented 3 years ago

Very likely that you are using Python2 on your host system, e.g laptop. microPython is effective Python3 version 3.4.0. All of the microPython application / framework source code will be using Python 3 syntax, etc.

On your SwagBadge, you can try ...

>>> import sys
>>> sys.version
'3.4.0'

These days, it is best to be moving on from Python 2 and use Python 3. However, take care not to upgrade your system Python ... especially on Mac OS X ! Always best to use a Python virtual environment for your development efforts and tools like pyenv to manage your Python versions.

marcmerlin commented 3 years ago

Sorry about that @PaulSchulz , fixed and thanks for your report. https://github.com/geekscape/aiko_engine_mp/pull/25