Closed fflorent closed 1 month ago
LGTM, cheers also for the urljoin trick :+1:
@fflorent : note that I just reverted this PR as it's been breaking the CI for a few days now, in particular because now the tests on "install on subpath" scenario tries to access the app on domain.tld
instead of domain.tld/path
This seems related to this unexpected behavior of urljoin
:
>>> urljoin("https://foo.tld/path", "/")
'https://foo.tld/'
>>> urljoin("https://foo.tld/path", "")
'https://foo.tld/path'
@alexAubin Do you have an example of an app which fails, so I can reproduce locally? (if possible, one for which it is quick to run the CI).
For example https://github.com/YunoHost-Apps/243-game_ynh
Context
My Grist package is marked as broken since package_check has checked the assets.
By taking a closer look, I realized that it wasn't an issue of my package, nor of the upstream app, but of the checker.
Indeed, the browser resolves assets (scripts and stylesheets) paths either from the domain, but also if present using the
<base>
tag (mdn documentation).Proposed solution
https://{domain}/path/to/
or a absolute path without the domain like/path/to/
).