Hi,
I’m in the process of updating a seafile server from 7.0.5 to 7.1.5. With all its updates from python2 to python3. I’m running into the issue that when I try to access seafile with a browser I get " Page unavailable - Sorry, but the requested page is unavailable due to a server hiccup.". And /tmp/seahub.log says “ValueError: Missing staticfiles manifest entry for ‘frontend/js/app.js’”:
2021-11-18 13:14:16,033 [ERROR] django.request:132 handle_uncaught_exception Internal Server Error: /
Traceback (most recent call last):
File "/home/seafile/.local/lib/python3.9/site-packages/django/core/handlers/exception.py", line 41, in inner
response = get_response(request)
File "/home/seafile/.local/lib/python3.9/site-packages/django/core/handlers/base.py", line 249, in _legacy_get_response
response = self._get_response(request)
File "/home/seafile/.local/lib/python3.9/site-packages/django/core/handlers/base.py", line 187, in _get_response
response = self.process_exception_by_middleware(e, request)
File "/home/seafile/.local/lib/python3.9/site-packages/django/core/handlers/base.py", line 185, in _get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "/home/seafile/build/seafile-server/seahub/seahub/auth/decorators.py", line 27, in _wrapped_view
return view_func(request, *args, **kwargs)
File "/home/seafile/build/seafile-server/seahub/seahub/views/__init__.py", line 1171, in react_fake_view
return render(request, "react_app.html", {
File "/home/seafile/.local/lib/python3.9/site-packages/django/shortcuts.py", line 30, in render
content = loader.render_to_string(template_name, context, request, using=using)
File "/home/seafile/.local/lib/python3.9/site-packages/django/template/loader.py", line 68, in render_to_string
return template.render(context, request)
File "/home/seafile/.local/lib/python3.9/site-packages/django/template/backends/django.py", line 66, in render
return self.template.render(context)
File "/home/seafile/.local/lib/python3.9/site-packages/django/template/base.py", line 207, in render
return self._render(context)
File "/home/seafile/.local/lib/python3.9/site-packages/django/template/base.py", line 199, in _render
return self.nodelist.render(context)
File "/home/seafile/.local/lib/python3.9/site-packages/django/template/base.py", line 990, in render
bit = node.render_annotated(context)
File "/home/seafile/.local/lib/python3.9/site-packages/django/template/base.py", line 957, in render_annotated
return self.render(context)
File "/home/seafile/.local/lib/python3.9/site-packages/django/template/loader_tags.py", line 177, in render
return compiled_parent._render(context)
File "/home/seafile/.local/lib/python3.9/site-packages/django/template/base.py", line 199, in _render
return self.nodelist.render(context)
File "/home/seafile/.local/lib/python3.9/site-packages/django/template/base.py", line 990, in render
bit = node.render_annotated(context)
File "/home/seafile/.local/lib/python3.9/site-packages/django/template/base.py", line 957, in render_annotated
return self.render(context)
File "/home/seafile/.local/lib/python3.9/site-packages/django/template/loader_tags.py", line 72, in render
result = block.nodelist.render(context)
File "/home/seafile/.local/lib/python3.9/site-packages/django/template/base.py", line 990, in render
bit = node.render_annotated(context)
File "/home/seafile/.local/lib/python3.9/site-packages/django/template/base.py", line 957, in render_annotated
return self.render(context)
File "/home/seafile/.local/lib/python3.9/site-packages/django/template/library.py", line 203, in render
output = self.func(*resolved_args, **resolved_kwargs)
File "/home/seafile/.local/lib/python3.9/site-packages/webpack_loader/templatetags/webpack_loader.py", line 12, in render_bundle
tags = utils.get_as_tags(bundle_name, extension=extension, config=config, attrs=attrs)
File "/home/seafile/.local/lib/python3.9/site-packages/webpack_loader/utils.py", line 64, in get_as_tags
for chunk in bundle:
File "/home/seafile/.local/lib/python3.9/site-packages/webpack_loader/utils.py", line 34, in _filter_by_extension
for chunk in bundle:
File "/home/seafile/.local/lib/python3.9/site-packages/webpack_loader/loader.py", line 45, in filter_chunks
chunk['url'] = self.get_chunk_url(chunk)
File "/home/seafile/.local/lib/python3.9/site-packages/webpack_loader/loader.py", line 56, in get_chunk_url
return staticfiles_storage.url(relpath)
File "/home/seafile/.local/lib/python3.9/site-packages/django/contrib/staticfiles/storage.py", line 162, in url
return self._url(self.stored_name, name, force)
File "/home/seafile/.local/lib/python3.9/site-packages/django/contrib/staticfiles/storage.py", line 141, in _url
hashed_name = hashed_name_func(*args)
File "/home/seafile/.local/lib/python3.9/site-packages/django/contrib/staticfiles/storage.py", line 432, in stored_name
raise ValueError("Missing staticfiles manifest entry for '%s'" % clean_name)
ValueError: Missing staticfiles manifest entry for 'frontend/js/app.js'
pip3 list says:
seafile@seafile:~/build/seafile-server/seahub$ pip3 list
Package Version
---------------------- ---------
appdirs 1.4.4
borgbackup 1.1.16
captcha 0.3
certifi 2021.10.8
chardet 4.0.0
charset-normalizer 2.0.7
dbus-python 1.2.16
distlib 0.3.1
distro-info 1.0
Django 1.11.29
django-appconf 1.0.5
django-formtools 2.2
django-picklefield 2.1.1
django-ranged-response 0.2.0
django-simple-captcha 0.5.12
django-statici18n 2.0.0
django-webpack-loader 0.7.0
djangorestframework 3.11.1
et-xmlfile 1.1.0
filelock 3.0.12
future 0.18.2
gunicorn 20.1.0
idna 2.6
importlib-metadata 1.6.0
jdcal 1.4.1
jsonfield 2.0.2
jsonfield2 3.0.3
llfuse 1.3.8
lxml 4.6.4
more-itertools 4.2.0
msgpack 1.0.0
oauthlib 3.1.1
olefile 0.46
openpyxl 3.0.9
Pillow 8.4.0
pip 20.3.4
pycryptodome 3.11.0
PyGObject 3.38.0
PyJWT 2.1.0
PyMySQL 1.0.2
python-apt 2.2.1
python-dateutil 2.8.2
pytz 2021.3
qrcode 7.3.1
rcssmin 1.0.6
requests 2.26.0
requests-oauthlib 1.3.0
rjsmin 1.0.12
setuptools 52.0.0
six 1.16.0
unattended-upgrades 0.1
urllib3 1.22
wheel 0.34.2
zipp 1.0.0
seafile@seafile:~/build/seafile-server/seahub$ pip --version
pip 20.3.4 from /usr/lib/python3/dist-packages/pip (python 3.9)
seafile@seafile:~/build/seafile-server/seahub$ pip3 --version
pip 20.3.4 from /usr/lib/python3/dist-packages/pip (python 3.9)
seafile@seafile:~/build/seafile-server/seahub$ python --version
Python 3.9.2
/home/seafile/build/conf/seahub_settings.py says:
SECRET_KEY = '<my-secret-key>'
ENABLE_SETTINGS_VIA_WEB = False
ENABLE_ENCRYPTED_LIBRARY = False
FILE_SERVER_ROOT = 'https://<my-url>/seafhttp'
ENABLE_FOLDER_PERM = True
SERVE_STATIC = False
ACTIVATE_AFTER_REGISTRATION = True
LOGIN_BG_IMAGE_PATH = 'img/<custom-dir>/<custom-bg>.jpg'
ENABLE_SIGNUP = True
ENABLE_SHARE_TO_ALL_GROUPS = True
ENABLE_MAKE_GROUP_PUBLIC = True
SHOW_REPO_DOWNLOAD_BUTTON = True
ENABLE_WIKI = True
LOGO_PATH = 'img/<custom-dir>/<mylogo>.png'
LOGO_WIDTH = 256
LOGO_HEIGHT = 64
SITE_TITLE = 'My Title'
SITE_NAME = 'My Site Name'
THUMBNAIL_IMAGE_ORIGINAL_SIZE_LIMIT = 512
This is on Debian Bullseye, seafile-server/ccnet 7.1.5 and seahub on the latest 7.1 branch (88f856dae).
I tried deleting /tmp/seahub_cache/, but this made no difference. Anyone having seen this error before?
Edit:
I’m running gunicorn as follows:
seafile@seafile:~/build/seafile-server/seahub$ env PATH=/home/seafile/.local/bin:/home/seafile/install/bin:/usr/bin:/bin LD_LIBRARY_PATH=/home/seafile/install/lib/ CCNET_CONF_DIR=/home/seafile/build/ccnet SEAFILE_CONF_DIR=/home/seafile/seafile-data SEAFILE_CENTRAL_CONF_DIR=/home/seafile/build/conf PYTHONPATH=/home/seafile/install/lib/python3.9/site-packages/:/home/seafile/build/seafile-server/seahub/thirdpart /usr/bin/gunicorn seahub.wsgi:application -c /home/seafile/build/seafile-server/runtime/seahub.conf --log-level debug -b 0.0.0.0:8000
/home/seafile/build/seafile-server/runtime/seahub.conf looks like this:
import os
daemon = False
workers = 1
timeout = 60
# Logging
runtime_dir = os.path.dirname(__file__)
pidfile = os.path.join(runtime_dir, 'seahub.pid')
errorlog = os.path.join(runtime_dir, 'error.log')
accesslog = os.path.join(runtime_dir, 'access.log')
And I’m accessing gunicorn indirectly from an nginx reverse proxy.