Bug 254558 - net-mgmt/seafile-server: File-related functionality is broken, always returning 404 when accessing files
Summary: net-mgmt/seafile-server: File-related functionality is broken, always returni...
Status: In Progress
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: amd64 Any
: --- Affects Only Me
Assignee: Richard Gallamore
Depends on:
Reported: 2021-03-25 19:21 UTC by ports
Modified: 2021-06-24 06:56 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (ultima)


Note You need to log in before you can comment on or make changes to this bug.
Description ports 2021-03-25 19:21:46 UTC
(for non-maintainers reading this: see workaround near the bottom)

It would appear that all /seafile links (i.e. any access to a file) result in 404 errors.

This happens on all my Seafile instances, and across all tested Seafile versions:
- 7.1.4 (previous "quarterly")
- 7.1.5 (current "quarterly")
- 8.0.3 (current "latest")

Examples of affected URLs (host & UUIDs omitted for privacy & security reasons):
- File downloads: https://$HOST/lib/$UUID/file/coy-ast.txt?dl=1
- Image downloads: https://$HOST/seafhttp/files/$UUID/browsers.jpg
- Any Seahub functionality that involved opening a file (preview, editing, ...)

Seahub is completely unaffected, other than functionality that depends on above URLs working. For example, login, directory viewing, and library creation all work fine --- but I cannot access any of the files.

The issue appears to be centered around the devel/oniguruma dependency (see below).

OS: FreeBSD 12.2-RELEASE-p3 GENERIC  amd64

I did manage to find the culprit, however: The devel/oniguruma dependency.

oniguruma-6.9.5.r1_1 works fine, but oniguruma-6.9.6 results in this problem.

I've frozen the port version to 6.9.5 for now, but a more permanent fix would be nice.
Comment 1 ports 2021-06-22 11:33:16 UTC
I'll put it in this bug, as it's a related problem (dependency version incompatibility):

Looks like django-webpack-loader breaks Seafile: https://stackoverflow.com/questions/67808608/django-webpack-loader-assets-keyerror

Need to use 0.7.0 and not 1.0.0 that's the latest in ports.
Comment 2 commit-hook freebsd_committer 2021-06-24 01:42:47 UTC
A commit in branch main references this bug:

URL: https://cgit.FreeBSD.org/ports/commit/?id=8219c84586becc6fab30d62c560cc517cff59039

commit 8219c84586becc6fab30d62c560cc517cff59039
Author:     Richard Gallamore <ultima@FreeBSD.org>
AuthorDate: 2021-06-24 01:36:42 +0000
Commit:     Richard Gallamore <ultima@FreeBSD.org>
CommitDate: 2021-06-24 01:36:42 +0000

    www/py-django-webpack-loader: Rollback to 0.7.0

    The most recent update to webpack-loader is not compatible
    with Seahub. Seahub is the only depend, therefore bumping epoch
    and rolling back.

    PR:     254558
    Reported by:    ports@stdran^

 www/py-django-webpack-loader/Makefile | 3 ++-
 www/py-django-webpack-loader/distinfo | 6 +++---
 2 files changed, 5 insertions(+), 4 deletions(-)
Comment 3 Richard Gallamore freebsd_committer 2021-06-24 01:44:55 UTC

Rolled back webpack-loader. Haven't had time to look at the other issue yet, but thanks for report. Adding it to my TODO.
Comment 4 Richard Gallamore freebsd_committer 2021-06-24 06:56:33 UTC

Tested the most recent version of devel/oniguruma and also reverted to version 6.9.6 and did not have any of the failures mentioned in the original bug description.

Can you please try and reproduce this and check the logs located here[1]. Let me know what kind of errors you see. Also, are you using a reverse proxy? The errors logged for this failure could be useful as well.

[1] /usr/local/www/haiwen/logs