I am the reviewer for “python-furo - A clean customizable documentation theme for Sphinx”
(
https://bugzilla.redhat.com/show_bug.cgi?id=1910798). The Python part of the package is
clean and simple, and the submitter is responsive, competent, and helpful. I’d really like
to be able to approve the package. However, the review is hung up on the web assets it
includes.
Upstream uses gulp to compile/bundle and minify the JavaScript, and compile SASS to CSS,
in order to produce the PyPI source tarball. Based on
https://docs.fedoraproject.org/en-US/packaging-guidelines/JavaScript/#_co...,
https://docs.fedoraproject.org/en-US/packaging-guidelines/Web_Assets/#_css, and
https://docs.fedoraproject.org/en-US/packaging-guidelines/what-can-be-pac...,
it will be necessary to use the GitHub source tarball instead and do all of the additional
work in the RPM build.
For the Python part, in which the GitHub tarball is a PEP 517/518 format source tree
without a “legacy” setup.py, python3-flit can do the job of building a wheel, and
%py3_install_wheel can install it. No problem.
For the JavaScript part, bundling and minification can’t use uglify-js because ES6 “const”
is used, and it can’t use esbuild (golang-github-evanw-esbuild) as intended because
upstream does not use ES6 modules and imports. However, “bundling” by simple concatenation
with cat, optionally followed by minification with esbuild, should work fine. It would
break source maps, but at least the original sources would still be included in the RPM.
The problem is the SASS. Upstream uses gulp-sass with the JavaScript-transpiled version of
dart-sass, which seems to be the only SASS compiler that is not deprecated today. Trying
to compile with rubygem-sass or either frontend to libsass (sassc/rubygem-sassc) gives an
error like:
sassc -a src/furo/assets/styles/furo.sass
Error: Invalid CSS after "...ow-y: scroll; }": expected 1 selector or at-rule,
was "not(html):not(body)"
on line 20:24 of src/furo/assets/styles/_scaffold.sass
from line 5:1 of src/furo/assets/styles/furo.sass
> overflow-y: scroll; }
-----------------------^
with various other errors following if the offending section is commented out. I don’t
know SASS too well, but it doesn’t look too practical to patch our way out of this.
This is a call for help, then. Does anyone see a way forward for this package?
More details are in the review request Bugzilla issue, linked at the beginning of this
email.
Thanks,
Ben Beasley