If you are still running Python 2 and using OctoPrint 1.7.0 or later, you will start to see warnings like this:
You need to upgrade your OctoPrint install to use Python 3, as Python 2 is end-of-life and a future OctoPrint version will no longer support running using Python 2. In addition, there's at least 25 plugins that already don't support Python 2 and more will follow, that you won't be able to take advantage of. You should upgrade as soon as possible.
The process is slightly different depending on how you are running OctoPrint. Select how you have OctoPrint running below to find out how to upgrade:
OctoPi 0.18, released January 2021 runs OctoPrint using Python 3 by default.
To install OctoPi 0.18 on your Raspberry Pi:
Take a backup using OctoPrint's built-in Backup and restore plugin and download it
Download & Setup OctoPi 0.18
Restore your backup on the new install
Note: You will need to update OctoPrint before you can reinstall your backup, otherwise there is a version mismatch.
If you do not want to install OctoPi 0.18, but are using OctoPi 0.17 then you can upgrade your install to Python 3 manually.
Please follow the instructions on the Upgrade to Python 3 script's homepage to get your OctoPi 0.17 install upgraded to use Python 3.
Manual installs on Linux can be upgraded to Python 3 by using the Upgrade Script. You still need Python 3.6 or newer to be installed as
python3, for more details please see how to use the script on it's homepage.
On both Windows and MacOS there is no automated script, you will have to reinstall the virtual environment yourself.
Refer back to the OS-specific install guides for how to setup the virtual environment and install OctoPrint. All settings and configuration would be saved, but you will have to reinstall plugins.
If your system is not supported, for example you cannot install Python 3 on the system, then you should look at upgrades that will enable you to do so. Python 2 was end-of-life at the start of 2020, you should be using Python 3.
Any other installs will need to be upgraded manually.
Need help upgrading to Python 3?
Please open a new topic on the forums, rather than commenting here