The pending update to ubuntu - 22.04 - upgrades python to 3.10. As the current version (non-beta) of OpenLP doesn't work with this version of python it might be advisable not to upgrade your ubuntu system if you are using OpenLP in your church. I had to switch back to ubuntu 21.10 when arch upgraded its python.
Comments
Would it not make sense to build Flatpak or Snap packages so you have more control over the Python version used and that way provide stability? Or is that a useless endeavour considering the integration with Open/LibreOffice and other components?
We're not far off releasing OpenLP 3.0, which works fine on Python 3.10. So trying to produce a Flatpak or Snap would just take more of our already limited time and delay the release even more.
I see Raoul, when I find the time, I could give it a try, making a flatpak or appimage. But only to hand over the recipe or yml, since only you the authors should make and distribute such packages.
But then probably for the 3.0 or the last 2.x version just to check how it all works.
@hyperl0gic that would be awesome!
If anyone still interested, I was able to manage to run OpenLP 2.4.6 under Ubuntu 22.04.
In a nutshell, you need python version less than 3.10. For this, I used 'pyenv' to work with different version of python.
Here is the instruction.
-----
Step 1: Build dependencies for 'pyenv'
$ sudo apt install -y make build-essential libssl-dev zlib1g-dev libbz2-dev libreadline-dev libsqlite3-dev wget curl llvm libncurses5-dev libncursesw5-dev xz-utils tk-dev libffi-dev liblzma-dev python3-openssl
-----
Step 2: Install 'pyenv'
$ curl https://pyenv.run | bash
-----
Step 3: Follow warning message at the end of Step 2 by adding some variables in .bash_rc file. And restart your terminal.
-----
Step 4: Install python 3.9 using 'pyenv'
$ pyenv install 3.9
-----
Step 5: Check available python versions
$ pyenv versions
-----
Step 6: Switch to different python versions
$ pyenv local 3.9
Step 7: Install python modules required by OpenLP
$ pip install alembic beautifulsoup4 chardet lxml PyQt5 PyQtWebKit sqlalchemy
-----
Step 8: Locate target version of python
$ which python
-----
Step 9: Run OpenLP from the terminal using the output from Step 8.
$ /home/$USER/.pyenv/shims/python /usr/bin/openlp
-----
Step 10: Check if it really works. :P
-----
Step 11: Make sure to switch back to default python version
$ pyenv local system
-----
When everything works as expected you can run following commands from now on.
$ pyenv local 3.9
$ /home/$USER/.pyenv/shims/python /usr/bin/openlp
$ pyenv local system
Or put above 3 lines into a script.
Thanks for those instructions @calvinkim !
The next version of Ubuntu (kinetic) should have a working version of OpenLP (currently 2.9.5).