GNU bug report logs - #52139
jupyter trying to modify /gnu/store

Previous Next

Package: guix;

Reported by: Alexander Asteroth <alexander.asteroth <at> h-brs.de>

Date: Sat, 27 Nov 2021 10:21:01 UTC

Severity: normal

Merged with 52159

Done: Lars-Dominik Braun <lars <at> 6xq.net>

Bug is archived. No further changes may be made.

Full log


Message #42 received at 52139 <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: Lars-Dominik Braun <lars <at> 6xq.net>
Cc: Alexander Asteroth <alexander.asteroth <at> h-brs.de>, 52139 <at> debbugs.gnu.org
Subject: Re: bug#52139: jupyter trying to modify /gnu/store
Date: Tue, 14 Dec 2021 16:06:58 +0100
Hi Lars,

Lars-Dominik Braun <lars <at> 6xq.net> skribis:

>> But precisely: as Alexander wrote, when JUPYTER_CONFIG_DIR points to the
>> store, jupyterlab cannot drop a config file there.  Or am I missing
>> something?
> sorry, my message was unclear here. The config file is written at
> build time.

Oh I see.

>> BTW, if JUPYTER_CONFIG_DIR is meant to contain a directory name, as
>> opposed to a colon-separated search path, we should make this change:
> Looking at the documentation[1] again this is correct, but I feel we
> should use JUPYTER_CONFIG_PATH instead, because it supports
> colon-delimited entries, see attached patch. However that does not get
> rid of error messages like these, when trying to use Settings→JupyterLab
> Theme for example:
>
> [W 08:10:14.476 LabApp] 500 PUT /lab/api/workspaces/lab?1639383014500 (127.0.0.1): [Errno 30] Read-only file system: '/gnu/store/8q7wdpdddfqh46plbbsa3rwci5092n5y-profile/etc/jupyter/lab'
>
> So it seems that JUPYTER_CONFIG_PATH overrides the default
> JUPYTER_CONFIG_DIR, when the latter is not set. Or maybe guix-science’s
> jupyterlab is simply too old – not sure right now.

OK.

> +++ b/gnu/packages/python-xyz.scm
> @@ -8478,7 +8478,7 @@ (define-public python-jupyter-core
>      ;; search paths.
>      (native-search-paths
>       (list (search-path-specification
> -            (variable "JUPYTER_CONFIG_DIR")
> +            (variable "JUPYTER_CONFIG_PATH")
>              (files '("etc/jupyter")))
>             (search-path-specification
>              (variable "JUPYTER_PATH")
> @@ -12145,8 +12145,6 @@ (define-public python-nbconvert
>               (when tests?
>                 ;; Some tests invoke the installed nbconvert binary.
>                 (add-installed-pythonpath inputs outputs)
> -               ;; Tries to write to this path.
> -               (unsetenv "JUPYTER_CONFIG_DIR")
>                 ;; Tests depend on templates installed to output.
>                 (setenv "JUPYTER_PATH"
>                         (string-append
> @@ -12254,6 +12252,8 @@ (define-public python-notebook
>                 ;; Some tests do not expect all files to be installed in the
>                 ;; same directory, but JUPYTER_PATH contains multiple entries.
>                 (unsetenv "JUPYTER_PATH")
> +               ;; Interferes with tests that check paths.
> +               (unsetenv "JUPYTER_CONFIG_PATH")
>                 ;; Some tests need HOME
>                 (setenv "HOME" "/tmp")
>                 (with-directory-excursion "/tmp"

If that works for you, go for it.

Thanks,
Ludo’.




This bug report was last modified 3 years and 151 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.