Seahub fails to run initial start with ModuleNotFoundError

1.7k Views Asked by At

I'm currently trying to install seafile 7.1.4 on a Raspberry Pi 4 following the official guide (https://download.seafile.com/published/seafile-manual/deploy/using_mysql.md). The setup went smoothly, but when I try to start the seahub (./seahub start) for the first time I get the following error:

Traceback (most recent call last):
  File "check_init_admin.py", line 351, in <module>
    rpc = RPC()
  File "check_init_admin.py", line 284, in __init__
    import ccnet
ModuleNotFoundError: No module named 'ccnet'

I've been on google for the past two hours, but can't find a solution to this problem. What am I doing wrong?

1

There are 1 best solutions below

0
mtgstuber On

I ran into the same issue. There's a bug in the 7.1.4 package. Seafile uses some local site packages. They (apparently) used to be under ${INSTALLPATH}/seafile/lib/python3.6/site-packages, now the are under ${INSTALLPATH}/seafile/lib/python3.7/site-packages

To fix: open seahub.sh in the editor of your choice.
find the line that says:

export PYTHONPATH=${INSTALLPATH}/seafile/lib/python3.6/site-packages:${INSTALLPATH}/seafile/lib64/python3.6/site-packages:${INSTALLPATH}/seahub:${INSTALLPATH}/seahub/thirdpart:$PYTHONPATH

change it to read:

export PYTHONPATH=${INSTALLPATH}/seafile/lib/python3.7/site-packages:${INSTALLPATH}/seafile/lib64/python3.7/site-packages:${INSTALLPATH}/seahub:${INSTALLPATH}/seahub/thirdpart:$PYTHONPATH