Funkwhale upgrade debian 11 issue

My YunoHost server

Hardware: Personnal server
YunoHost version:
yunohost:
repo: stable
version: 11.0.9.14
yunohost-admin:
repo: stable
version: 11.0.10
moulinette:
repo: stable
version: 11.0.9
ssowat:
repo: stable
version: 11.0.9

I have access to my server : Through SSH | through the webadmin | direct access via keyboard / screen
Are you in a special context or did you perform some particular tweaking on your YunoHost instance ? : no / yes idk
If yes, please explain:

Description of my issue

After upgrade to bullseye funwhale not start anymore
1/ do the upgrade
2/ go to vhost and get 502 bad gateway
3/ Tryin

sudo yunohost app upgrade -F funkwhale

4/ Reboot she server
5/ Tryin again

sudo yunohost app upgrade -F funkwhale

No luck here the log we see error when services start
https://paste.yunohost.org/raw/gejehudeje

ModuleNotFoundError: No module named '\''gunicorn'\''
ModuleNotFoundError: No module named '\''celeri'\''

seems another error with no impact idk : Synapse update 1.46.0~ynh1 -> 1.65.0~ynh1 failed - #4 by cjinh

Tryin to recreate virtuelenv to test

sudo -u funkwhale python3 -m venv virtualenv
source virtualenv/bin/activate
sudo -u funkwhale pip install --upgrade pip
sudo -u funkwhale pip install --upgrade setuptools
sudo -u funkwhale pip install -r api/requirements.txt

grep pyOpenSSL api/requirements/base.txt
pyOpenSSL~=21.0.0
sudo systemctl start funkwhale.target 
supervision@yuno:/var/www/funkwhale$ sudo systemctl status  funkwhale.target 
● funkwhale.target - Funkwhale (funkwhale)
     Loaded: loaded (/etc/systemd/system/funkwhale.target; static)
     Active: active since Wed 2022-09-14 08:59:40 CEST; 4s ago

sept. 14 08:59:40 yuno.domaine.fr systemd[1]: Reached target Funkwhale (funkwhale).


sudo systemctl status  funkwhale-beat.service 
● funkwhale-beat.service - funkwhale celery beat process
     Loaded: loaded (/etc/systemd/system/funkwhale-beat.service; enabled; vendor preset: enabled)
     Active: failed (Result: exit-code) since Wed 2022-09-14 08:59:40 CEST; 17s ago
    Process: 657900 ExecStart=/var/www/funkwhale/virtualenv/bin/celery -A funkwhale_api.taskapp beat -l INFO (code=exited, status=203/EXEC)
   Main PID: 657900 (code=exited, status=203/EXEC)
        CPU: 2ms

sept. 14 08:59:40 yuno.domaine.fr systemd[1]: Started funkwhale celery beat process.
sept. 14 08:59:40 yuno.domaine.fr systemd[657900]: funkwhale-beat.service: Failed to locate executable /var/www/funkwhale/virtualenv/bin/celery: No such file or directory
sept. 14 08:59:40 yuno.domaine.fr systemd[657900]: funkwhale-beat.service: Failed at step EXEC spawning /var/www/funkwhale/virtualenv/bin/celery: No such file or directory
sept. 14 08:59:40 yuno.domaine.fr systemd[1]: funkwhale-beat.service: Main process exited, code=exited, status=203/EXEC
sept. 14 08:59:40 yuno.domaine.fr systemd[1]: funkwhale-beat.service: Failed with result 'exit-code'.
sudo cp /var/www/funkwhale/virtualenv.old/bin/celery /var/www/funkwhale/virtualenv/bin/
sudo chown funkwhale: /var/www/funkwhale/virtualenv/bin/celery 
sudo systemctl status funkwhale-beat.service 
● funkwhale-beat.service - funkwhale celery beat process
     Loaded: loaded (/etc/systemd/system/funkwhale-beat.service; enabled; vendor preset: enabled)
     Active: failed (Result: exit-code) since Wed 2022-09-14 09:01:41 CEST; 5s ago
    Process: 660220 ExecStart=/var/www/funkwhale/virtualenv/bin/celery -A funkwhale_api.taskapp beat -l INFO (code=exited, status=1/FAILURE)
   Main PID: 660220 (code=exited, status=1/FAILURE)
        CPU: 75ms

sept. 14 09:01:41 yuno.domaine.fr systemd[1]: Started funkwhale celery beat process.
sept. 14 09:01:41 yuno.domaine.fr celery[660220]: Traceback (most recent call last):
sept. 14 09:01:41 yuno.domaine.fr celery[660220]:   File "/var/www/funkwhale/virtualenv/bin/celery", line 5, in <module>
sept. 14 09:01:41 yuno.domaine.fr celery[660220]:     from celery.__main__ import main
sept. 14 09:01:41 yuno.domaine.fr celery[660220]: ModuleNotFoundError: No module named 'celery'
sept. 14 09:01:41 yuno.domaine.fr systemd[1]: funkwhale-beat.service: Main process exited, code=exited, status=1/FAILURE
sept. 14 09:01:41 yuno.domaine.fr systemd[1]: funkwhale-beat.service: Failed with result 'exit-code'.
/var/www/funkwhale/virtualenv$ source bin/activate

/var/www/funkwhale/virtualenv$ sudo -u funkwhale pip show celery
Name: celery
Version: 5.1.2
Summary: Distributed Task Queue.
Home-page: http://celeryproject.org
Author: Ask Solem
Author-email: auvipy@gmail.com
License: BSD
Location: /var/www/funkwhale/.local/lib/python3.9/site-packages
Requires: billiard, click, click-didyoumean, click-plugins, click-repl, kombu, pytz, setuptools, vine
Required-by: 

I remember similar issue some times ago when upgrade to debian 10

Have a nice day

just see this

I give a try

EDIT :
Not working
Maybe it’s a pip version issue
I’m still on pip 20.3.4 after upgrade pip to 22.2.2

(virtualenv) user@yuno:/var/www/funkwhale$ sudo -u funkwhale pip install --upgrade pip
Requirement already satisfied: pip in /usr/lib/python3/dist-packages (20.3.4)
Collecting pip
  Downloading pip-22.2.2-py3-none-any.whl (2.0 MB)
     |████████████████████████████████| 2.0 MB 3.2 MB/s 
Installing collected packages: pip
  WARNING: The scripts pip, pip3 and pip3.9 are installed in '/var/www/funkwhale/.local/bin' which is not on PATH.
  Consider adding this directory to PATH or, if you prefer to suppress this warning, use --no-warn-script-location.
Successfully installed pip-22.2.2

python --version
Python 3.9.2

pip3 --version
pip 20.3.4 from /var/www/funkwhale/virtualenv/lib/python3.9/site-packages/pip (python 3.9)

pip --version
pip 20.3.4 from /var/www/funkwhale/virtualenv/lib/python3.9/site-packages/pip (python 3.9)

ls virtualenv/lib
python3.9



sudo -u funkwhale -H -E python3 -m pip update /var/www/funkwhale/virtualenv
ERROR: unknown command "update"

So I think, I don’t need to update virtualenv because I recreated it
I’m a bit lost if someone got any idea

Hi @cjinh,

I think this is a problem with cryptography. Yunohost currently ships Funkwhale 1.2.7 which uses cryptography>=3.3.2, but there is a compatibility issue between cryptography 38 and pyopenssl 20. Looking at your trace, I can see the following:

AttributeError: module 'lib' has no attribute 'SSL_CTX_set_ecdh_auto'

This indicates the problem is with the pyopenssl package.

We shipped a fix for this in Funkwhale 1.2.8 where we pinned down the cryptography version to avoid this issue, but Yunohost hasn’t been updated to this new version yet. I’ll take a look at pushing an update for it soon.

PS: it looks like they’re working on a solution to prevent this kind of incompatibility in future :tada:

2 Likes

Thanks you :+1:
I’ll be waiting the 1.2.8

Just did the upgrade 1.2.8 and it’s work again
Thanks you guys :green_heart: :orange_heart: :heartbeat:

1 Like

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.