Hi
I'm running Mint20 and am presently trying to follow a specific procedure that, I think, uses python 2 or python3 but is detecting some error in my python installation.
It could be possible as I previoulsy ran sudo apt install python-is-python3 /or made some modification to try something working some time ago...(making some alaises or simlink)
Here is the entire error I get that makes me thinking there are some python2/3 messed up :
"~/SBMS_update/electrodacus-esp32$ platformio run Processing serial (platform: https://github.com/platformio/platform-espressif32.git; board: nodemcu-32s; framework: arduino, espidf) Verbose mode can be enabled via -v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/...u-32s.html
PLATFORM: Espressif 32 (2.1.0+sha.a58a358) > NodeMCU-32S
HARDWARE: ESP32 240MHz, 320KB RAM, 4MB Flash
DEBUG: Current (esp-prog) External (esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa)
PACKAGES:
framework-arduinoespressif32 0.0.0+sha.d011dd7
framework-espidf 3.40001.200521 (4.0.1)
tool-cmake 3.16.4
tool-esptoolpy 1.30000.201119 (3.0.0)
tool-ninja 1.7.1
tool-openocd-esp32 2.1000.20201202 (10.0)
toolchain-esp32ulp 1.22851.191205 (2.28.51)
toolchain-xtensa32 2.80200.200827 (8.2.0)
Traceback (most recent call last):
File "genVersion.py", line 1, in
import subprocess
File "/usr/lib/python3.8/subprocess.py", line 49, in
import signal
File "/usr/lib/python3.8/signal.py", line 3, in
from functools import wraps as _wraps
File "/usr/lib/python3.8/functools.py", line 18, in
from collections import namedtuple
File "/usr/lib/python3.8/collections/init.py", line 27, in
from reprlib import recursive_repr as _recursive_repr
File "/home/harold/.local/lib/python2.7/site-packages/reprlib/init.py", line 7, in
raise ImportError('This package should not be accessible on Python 3. '
ImportError: This package should not be accessible on Python 3. Either you are trying to run from the python-future src folder or your installation of python-future is corrupted.
Error in sys.excepthook:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 53, in apport_excepthook
if not enabled():
File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 24, in enabled
import re
File "/usr/lib/python3.8/re.py", line 127, in
import functools
File "/usr/lib/python3.8/functools.py", line 18, in
from collections import namedtuple
File "/usr/lib/python3.8/collections/init.py", line 27, in
from reprlib import recursive_repr as _recursive_repr
File "/home/harold/.local/lib/python2.7/site-packages/reprlib/init.py", line 7, in
raise ImportError('This package should not be accessible on Python 3. '
ImportError: This package should not be accessible on Python 3. Either you are trying to run from the python-future src folder or your installation of python-future is corrupted.
Original exception was:
Traceback (most recent call last):
File "genVersion.py", line 1, in
import subprocess
File "/usr/lib/python3.8/subprocess.py", line 49, in
import signal
File "/usr/lib/python3.8/signal.py", line 3, in
from functools import wraps as _wraps
File "/usr/lib/python3.8/functools.py", line 18, in
from collections import namedtuple
File "/usr/lib/python3.8/collections/init.py", line 27, in
from reprlib import recursive_repr as _recursive_repr
File "/home/harold/.local/lib/python2.7/site-packages/reprlib/init.py", line 7, in
raise ImportError('This package should not be accessible on Python 3. '
ImportError: This package should not be accessible on Python 3. Either you are trying to run from the python-future src folder or your installation of python-future is corrupted.
OSError: 'python genVersion.py' exited 1:
File "/home/harold/.local/lib/python2.7/site-packages/platformio/builder/main.py", line 170:
env.SConscript("$BUILD_SCRIPT")
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Script/SConscript.py", line 541:
return _SConscript(self.fs, *files, **subst_kw)
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Script/SConscript.py", line 250:
exec file in call_stack[-1].globals
File "/home/harold/.platformio/platforms/espressif32/builder/main.py", line 224:
target_elf = env.BuildProgram()
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Environment.py", line 224:
return self.method(*nargs, **kwargs)
File "/home/harold/.local/lib/python2.7/site-packages/platformio/builder/tools/platformio.py", line 61:
env.ProcessProgramDeps()
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Environment.py", line 224:
return self.method(*nargs, **kwargs)
File "/home/harold/.local/lib/python2.7/site-packages/platformio/builder/tools/platformio.py", line 124:
env.ProcessFlags(env.get("BUILD_FLAGS"))
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Environment.py", line 224:
return self.method(*nargs, **kwargs)
File "/home/harold/.local/lib/python2.7/site-packages/platformio/builder/tools/platformio.py", line 222:
env.Append(**env.ParseFlagsExtended(flags))
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Environment.py", line 224:
return self.method(*nargs, **kwargs)
File "/home/harold/.local/lib/python2.7/site-packages/platformio/builder/tools/platformio.py", line 185:
for key, value in env.ParseFlags(str(raw)).items():
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Environment.py", line 810:
do_parse(arg)
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Environment.py", line 676:
arg = self.backtick(arg[1:])
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Environment.py", line 594:
raise OSError("'%s' exited %d" % (command, status))
========================================== [FAILED] Took 0.37 seconds ==========================================
Environment Status Duration
serial FAILED 00:00:00.368
==================================== 1 failed, 0 succeeded in 00:00:00.368 ===================================="
My quetsion is : How could I fix to a proper installation of both python2 and python3 ?
I'm running Mint20 and am presently trying to follow a specific procedure that, I think, uses python 2 or python3 but is detecting some error in my python installation.
It could be possible as I previoulsy ran sudo apt install python-is-python3 /or made some modification to try something working some time ago...(making some alaises or simlink)
Here is the entire error I get that makes me thinking there are some python2/3 messed up :
"~/SBMS_update/electrodacus-esp32$ platformio run Processing serial (platform: https://github.com/platformio/platform-espressif32.git; board: nodemcu-32s; framework: arduino, espidf) Verbose mode can be enabled via -v, --verbose` option
CONFIGURATION: https://docs.platformio.org/page/boards/...u-32s.html
PLATFORM: Espressif 32 (2.1.0+sha.a58a358) > NodeMCU-32S
HARDWARE: ESP32 240MHz, 320KB RAM, 4MB Flash
DEBUG: Current (esp-prog) External (esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa)
PACKAGES:
framework-arduinoespressif32 0.0.0+sha.d011dd7
framework-espidf 3.40001.200521 (4.0.1)
tool-cmake 3.16.4
tool-esptoolpy 1.30000.201119 (3.0.0)
tool-ninja 1.7.1
tool-openocd-esp32 2.1000.20201202 (10.0)
toolchain-esp32ulp 1.22851.191205 (2.28.51)
toolchain-xtensa32 2.80200.200827 (8.2.0)
Traceback (most recent call last):
File "genVersion.py", line 1, in
import subprocess
File "/usr/lib/python3.8/subprocess.py", line 49, in
import signal
File "/usr/lib/python3.8/signal.py", line 3, in
from functools import wraps as _wraps
File "/usr/lib/python3.8/functools.py", line 18, in
from collections import namedtuple
File "/usr/lib/python3.8/collections/init.py", line 27, in
from reprlib import recursive_repr as _recursive_repr
File "/home/harold/.local/lib/python2.7/site-packages/reprlib/init.py", line 7, in
raise ImportError('This package should not be accessible on Python 3. '
ImportError: This package should not be accessible on Python 3. Either you are trying to run from the python-future src folder or your installation of python-future is corrupted.
Error in sys.excepthook:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 53, in apport_excepthook
if not enabled():
File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 24, in enabled
import re
File "/usr/lib/python3.8/re.py", line 127, in
import functools
File "/usr/lib/python3.8/functools.py", line 18, in
from collections import namedtuple
File "/usr/lib/python3.8/collections/init.py", line 27, in
from reprlib import recursive_repr as _recursive_repr
File "/home/harold/.local/lib/python2.7/site-packages/reprlib/init.py", line 7, in
raise ImportError('This package should not be accessible on Python 3. '
ImportError: This package should not be accessible on Python 3. Either you are trying to run from the python-future src folder or your installation of python-future is corrupted.
Original exception was:
Traceback (most recent call last):
File "genVersion.py", line 1, in
import subprocess
File "/usr/lib/python3.8/subprocess.py", line 49, in
import signal
File "/usr/lib/python3.8/signal.py", line 3, in
from functools import wraps as _wraps
File "/usr/lib/python3.8/functools.py", line 18, in
from collections import namedtuple
File "/usr/lib/python3.8/collections/init.py", line 27, in
from reprlib import recursive_repr as _recursive_repr
File "/home/harold/.local/lib/python2.7/site-packages/reprlib/init.py", line 7, in
raise ImportError('This package should not be accessible on Python 3. '
ImportError: This package should not be accessible on Python 3. Either you are trying to run from the python-future src folder or your installation of python-future is corrupted.
OSError: 'python genVersion.py' exited 1:
File "/home/harold/.local/lib/python2.7/site-packages/platformio/builder/main.py", line 170:
env.SConscript("$BUILD_SCRIPT")
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Script/SConscript.py", line 541:
return _SConscript(self.fs, *files, **subst_kw)
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Script/SConscript.py", line 250:
exec file in call_stack[-1].globals
File "/home/harold/.platformio/platforms/espressif32/builder/main.py", line 224:
target_elf = env.BuildProgram()
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Environment.py", line 224:
return self.method(*nargs, **kwargs)
File "/home/harold/.local/lib/python2.7/site-packages/platformio/builder/tools/platformio.py", line 61:
env.ProcessProgramDeps()
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Environment.py", line 224:
return self.method(*nargs, **kwargs)
File "/home/harold/.local/lib/python2.7/site-packages/platformio/builder/tools/platformio.py", line 124:
env.ProcessFlags(env.get("BUILD_FLAGS"))
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Environment.py", line 224:
return self.method(*nargs, **kwargs)
File "/home/harold/.local/lib/python2.7/site-packages/platformio/builder/tools/platformio.py", line 222:
env.Append(**env.ParseFlagsExtended(flags))
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Environment.py", line 224:
return self.method(*nargs, **kwargs)
File "/home/harold/.local/lib/python2.7/site-packages/platformio/builder/tools/platformio.py", line 185:
for key, value in env.ParseFlags(str(raw)).items():
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Environment.py", line 810:
do_parse(arg)
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Environment.py", line 676:
arg = self.backtick(arg[1:])
File "/home/harold/.platformio/packages/tool-scons/script/../engine/SCons/Environment.py", line 594:
raise OSError("'%s' exited %d" % (command, status))
========================================== [FAILED] Took 0.37 seconds ==========================================
Environment Status Duration
serial FAILED 00:00:00.368
==================================== 1 failed, 0 succeeded in 00:00:00.368 ===================================="
My quetsion is : How could I fix to a proper installation of both python2 and python3 ?