What is the problem?
I updated Octoprint to version 1.7.3, then I updated my raspberry pi. Now Octoprint is not starting anymore.
What did you already try to solve it?
Connected to the Raspberry via ssh, then:
sudo service octoprint stop
source ~/oprint/bin/activate
octoprint serve --debug --host 127.0.0.1
Traceback (most recent call last):
File "/home/pi/oprint/bin/octoprint", line 6, in <module>
from pkg_resources import load_entry_point
File "/home/pi/oprint/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3019, in <module>
@_call_aside
File "/home/pi/oprint/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3003, in _call_aside
f(*args, **kwargs)
File "/home/pi/oprint/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3032, in _initialize_master_working_set
working_set = WorkingSet._build_master()
File "/home/pi/oprint/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 657, in _build_master
return cls._build_from_requirements(__requires__)
File "/home/pi/oprint/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 670, in _build_from_requirements
dists = ws.resolve(reqs, Environment())
File "/home/pi/oprint/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 849, in resolve
raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'urllib3>=1.25.7; python_version <= "3.4"' distribution was not found and is required by sentry-sdk
Then I tried to update my sentry-sdk via pip install --upgrade sentry-sdk
Collecting sentry-sdk
Downloading https://files.pythonhosted.org/packages/24/dc/f1d34d1fc0e272003be75a3b4d54517ade4a14960c4ebbe7fe4f58c3d39b/sentry_sdk-1.19.1-py2.py3-none-any.whl (199kB)
100% |ββββββββββββββββββββββββββββββββ| 204kB 1.1MB/s
Collecting urllib3>=1.25.7; python_version <= "3.4" (from sentry-sdk)
Using cached https://files.pythonhosted.org/packages/7b/f5/890a0baca17a61c1f92f72b81d3c31523c99bec609e60c292ea55b387ae8/urllib3-1.26.15-py2.py3-none-any.whl
Collecting certifi (from sentry-sdk)
Downloading https://files.pythonhosted.org/packages/37/45/946c02767aabb873146011e665728b680884cd8fe70dde973c640e45b775/certifi-2021.10.8-py2.py3-none-any.whl (149kB)
100% |ββββββββββββββββββββββββββββββββ| 153kB 1.4MB/s
Installing collected packages: urllib3, certifi, sentry-sdk
Successfully installed certifi-2021.10.8 sentry-sdk-1.19.1 urllib3-1.26.15
Then I checked my Python version:
pi@octopi:~ $ python3 --version
Python 3.5.3
Then I removed Python 3.5 from the system by sudo apt-get remove python3.5, then sudo apt-get purge python3.5 and then sudo apt remove python3.5-minimal
Now I get:
pi@octopi:~ $ python3 --version
-bash: /usr/bin/python3: No such file or directory
and
pi@octopi:~ $ python --version
Python 2.7.13
Result is still the same. No change on the output of octoprint serve --debug --host 127.0.0.1
Have you tried running in safe mode?
Yes, no change. Same error message
Systeminfo Bundle
Cannot get Systeminfo because:
(oprint) pi@octopi:~ $ octoprint systeminfo .
Traceback (most recent call last):
File "/home/pi/oprint/bin/octoprint", line 6, in <module>
from pkg_resources import load_entry_point
File "/home/pi/oprint/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3019, in <module>
@_call_aside
File "/home/pi/oprint/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3003, in _call_aside
f(*args, **kwargs)
File "/home/pi/oprint/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 3032, in _initialize_master_working_set
working_set = WorkingSet._build_master()
File "/home/pi/oprint/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 657, in _build_master
return cls._build_from_requirements(__requires__)
File "/home/pi/oprint/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 670, in _build_from_requirements
dists = ws.resolve(reqs, Environment())
File "/home/pi/oprint/local/lib/python2.7/site-packages/pkg_resources/__init__.py", line 849, in resolve
raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'urllib3>=1.25.7; python_version <= "3.4"' distribution was not found and is required by sentry-sdk
Additional information about your setup
``` Linux octopi 4.19.66-v7+ #1253 SMP Thu Aug 15 11:49:46 BST 2019 armv7l ------------------------------------------------------------------------------ OctoPrint version : 1.7.3 OctoPi version : 0.16.0 ------------------------------------------------------------------------------</small>