On Saturday, February 15 2020, Inaki Malerba wrote: > Hi everyone! Hey Inaki, > I'm looking for some advice on how to fix some problems on 2 different > packages I've been trying to update with no luck so far. > > # python-icecream. [0][1] > > The new release includes a dependency to a very small repository [2] > that's not packaged. > > My first thought was to open an ITP and try to package it, but it turns > out to be a single python script and I'm not sure if it's reasonable to > create a whole package for that. > > Should I package the new dependency? The README[3] even suggests that > it's ok to copy that single file. Would it be OK if I patch it into my > package? It's not uncommon to see small Python packages out there, often with only a single file, like this one. IMO, you should go ahead and package it properly. Other packages might depend on it, and it seems like an easy package to make anyway. > # doit [4][5] > > The latest release of this package contains a huge change on the > documentation, which breaks the linting. It contains a lot of external > javascripts and stuff. > > As python-icecream, doit made a change to depend on a custom sphinx > theme that's not packaged but I managed to fix that patching it to use > the default theme[6]. > > Having changed the theme and fixed one of lintian suggestions (the > node-html5shiv one), there are still a lot of problems with the docs > package[7]. I even thought of removing the python-doit-doc package. This one is more complicated... Apparently upstream decided to write an index.html documentation page full of minified, non-Free JS: https://github.com/pydoit/doit/commit/e7717d705d60731f750f1e27e0f633c3d0502678 If you look at index.html's header, you'll see references to things under the _static/vendor directory, or links to fonts.googleapis.com. Both are problematic: https://github.com/pydoit/doit/blob/master/doc/index.html#L10-L26 We have almost everything packaged in Debian that is needed to replace these. You will have to remove the files from the tarball (using d/copyright's Files-Excluded, plus using +dfsg in the package's version). These are the replacements that already exist in Debian: libjs-bootstrap (for bootstrap.min.js) fonts-font-awesome (for font-awesome.min.css) fonts-roboto (for the googleapis.com Roboto font) We're missing packages for "bootstrap-select.min.css" and "owl.carousel". The good thing about "owl.carousel" is that python-doit ships the non-minified JS version, which means that you can minify it during build time. The problematic part is the "bootstrap-select.min.css" file, which is only shipped in its minified version. The ideal scenario would be to package bootstrap-select and then depend on it, but I don't think it's fair to make you go through this (the package seems a bit complicated, and packaging JS is not easy sometimes). Another "good enough" approach (IMO) would be to copy a version of "bootstrap-select.js" (non-minified) into python-doit's code (using a patch under d/patch, of course), and then minify it during the build. This is not very elegant, but solves the problem (it's similar to what you proposed above, for python-icecream). All in all, it will demand a bit of work, unfortunately. Thanks, -- Sergio GPG key ID: 237A 54B1 0287 28BF 00EF 31F4 D0EB 7628 65FC 5E36 Please send encrypted e-mail if possible http://sergiodj.net/
Attachment:
signature.asc
Description: PGP signature