[Debian-pan-maintainers] Unifying jupyterlab and node-jupyterlab

Roland Mas lolando at debian.org
Fri Jun 7 16:53:20 BST 2024


Le 05/06/2024 à 15:24, Yadd a écrit :
> On 6/5/24 17:18, Roland Mas wrote:
>>
>> Le 02/06/2024 à 10:58, Yadd a écrit :
>>> On 6/2/24 12:53, Yadd wrote:
>>>> On 6/2/24 10:38, Yadd wrote:
>>>>> In my last commit, I added also a fix for #1060772:
>>>>>   - jupyter-lab uses yarnpkg by default
>>>>>   - in Debian build context, this can be overridden using
>>>>>     YARN_COMMAND=pkgjs-install-minimal
>>>>
>>>> Better hook with "YARN_COMMAND=pkgjs" which uses the adapted 
>>>> pkgjs-* command
>>>
>>> And this produces the final bundle without Internet access
>>>  => fixes #1060772 :-D
>>
>> …wow, you rock. Thanks for all that! I had started a WIP branch but 
>> was nowhere near completion like yours.
>>
>> I'll do some testing on my side and see if anything needs to be 
>> tweaked on the Python side.
>>
>> Thanks!
>
> Thank you, I think it's more easy to insert Python hooks into the node 
> package than the reverse ;-)
> Anyway I think we should publish starting from src:jupyterlab and not 
> from src:node-jupyterlab and publish binary:jupyterlab as proposed in 
> my branch.

Yeah, when it actually builds again I'll do the moving around. I tweaked 
yarn.js a bit following your tracks, ensuring it only calls pkgjs-$foo 
for values of $foo that exist, and renaming an environment variable 
following https://github.com/yarnpkg/berry/issues/5588; but I'm still 
stuck when building:

pbuilder at nevermir:/build/node-jupyterlab-4.0.11+ds1+~cs11.25.27$ export 
JUPYTERLAB_DIR=$(pwd)/debian/jupyterlab/usr/share/jupyter/lab
pbuilder at nevermir:/build/node-jupyterlab-4.0.11+ds1+~cs11.25.27$ export 
YARNCOMMAND=pkgjs
pbuilder at nevermir:/build/node-jupyterlab-4.0.11+ds1+~cs11.25.27$ export 
PYTHONPATH=$(pwd)/debian/jupyterlab/usr/lib/python3.11/dist-packages/
pbuilder at nevermir:/build/node-jupyterlab-4.0.11+ds1+~cs11.25.27$ node 
$(pwd)/debian/jupyterlab/usr/share/jupyter/lab/staging/yarn.js 
build:prod:minimize
Internal Error: @jupyterlab/repo-top at workspace:.: This package doesn't 
seem to be present in your lockfile; run "yarn install" to update the 
lockfile
     at mN.resolve 
(/usr/share/nodejs/@yarnpkg/cli/bundles/yarn.js:206:13156)
     at zy.resolve (/usr/share/nodejs/@yarnpkg/cli/bundles/yarn.js:141:1488)
     at /usr/share/nodejs/@yarnpkg/cli/bundles/yarn.js:211:7246
     at YC (/usr/share/nodejs/@yarnpkg/cli/bundles/yarn.js:140:52518)
     at le (/usr/share/nodejs/@yarnpkg/cli/bundles/yarn.js:211:7226)
     at /usr/share/nodejs/@yarnpkg/cli/bundles/yarn.js:211:7858

Running the install target with the same environment does invoke 
pkgjs-install-minimal, so I believe the dispatch logic in yarn.js is 
correct now. Any idea?

> So in resume:
>  * copy my debian/ directory (except d/changelog) into your
>    python-team/packages/jupyterlab,
>  * then move project (in Gitlab) from python-team/packages/jupyterlab to
>    debian/jupyterlab

Maybe debian-science/jupyterlab?

Roland.




More information about the Debian-pan-maintainers mailing list