M5stack core2 error : ImportError: cannot import name

hello, I’m on m5stack core2 and when I want to send or even compile my project, I have this error:
ImportError: cannot import name ‘Serial’ from ‘serial’ (C:\Users\Home.platformio\penv\lib\site-packages\serial_init _.py):
File “C:\Users\Home.platformio\penv\lib\site-packages\platformio\builder[main.py](http://main.py/)”, line 97:
env = DefaultEnvironment(**DEFAULT_ENV_OPTIONS)
default_env = SCons.Environment.Environment(*args, **kw)

File “frozen importlib._bootstrap_external”, line 529:

File “frozen importlib._bootstrap_external”, line 1029:

File “frozen importlib._bootstrap_external”, line 854:

File “frozen importlib._bootstrap”, line 274:

File “frozen importlib._bootstrap”, line 711:

File “frozen importlib._bootstrap”, line 680:

File “frozen importlib._bootstrap_external”, line 850:

File “frozen importlib._bootstrap”, line 228:

File “C:\Users\Home.platformio\penv\lib\site-packages\platformio\builder\tools[pioupload.py](http://pioupload.py/)”, line 26:
from serial import Serial, SerialException

Everything was working fine until i installed atom on my computer

Try remove this folders:
C:\Users\Home.platformio\penv
C:\Users\Home.platformio\ .cache

1 Like

besides, I can no longer create a project either, when I do, I have the error that I showed you.
i am on windows 10

thank you it worked!

1 Like