. Trying to switch the Python interpreter for the Scalyr Agent.
. Searching for python in PATH "/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin":
+ command python [2.7.17] is found and matches the minimum required version - Success!
+ The Scalyr Agent will use the default system python binary (/usr/bin/env python).
Traceback (most recent call last):
File "/usr/share/scalyr-agent-2/bin/scalyr-agent-2", line 101, in <module>
from scalyr_agent.monitors_manager import MonitorsManager
File "/usr/share/scalyr-agent-2/py/scalyr_agent/monitors_manager.py", line 20, in <module>
from scalyr_agent.builtin_monitors.thread_pool import ThreadPoolExecutorFactory
File "/usr/share/scalyr-agent-2/py/scalyr_agent/builtin_monitors/thread_pool.py", line 20, in <module>
from concurrent.futures import ThreadPoolExecutor
ImportError: No module named concurrent.futures
Traceback (most recent call last):
File "/usr/sbin/scalyr-agent-2", line 101, in <module>
from scalyr_agent.monitors_manager import MonitorsManager
File "/usr/share/scalyr-agent-2/py/scalyr_agent/monitors_manager.py", line 20, in <module>
from scalyr_agent.builtin_monitors.thread_pool import ThreadPoolExecutorFactory
File "/usr/share/scalyr-agent-2/py/scalyr_agent/builtin_monitors/thread_pool.py", line 20, in <module>
from concurrent.futures import ThreadPoolExecutor
ImportError: No module named concurrent.futures
596cab27 introduced two imports for ThreadPoolExecutor from concurrent.futures, which was introduced in python 3.2.
agent_build_refactored/managed_packages/non-aio/install-scriptlets/check-python.sh can set the python interpreter to python 2.7 if it's installed on the system, which causes the package install to fail: