Skip to content

Jupyter interaction with ROOT #106

@tomeichlersmith

Description

@tomeichlersmith

Describe the bug
If a person attempts to open Jupyter from within an ldmx image (dev or pro), they are prevented because the directories we add to specific jupyter environment variables are not write-able.

Error:

OSError: [Errno 30] Read-only filesystem: '/usr/local/etc/notebook:'

Location where this is set:

https://github.com/LDMX-Software/docker/blob/1c729e21b606ac9400e2e29c184a645e14c39338/Dockerfile#L226-L227

To Reproduce
Steps to reproduce the behavior:

  1. denv init ldmx/dev:latest
  2. denv python3 -m pip install jupyterlab
  3. denv jupyter lab
  4. See error

Expected behavior
We can avoid this error by not setting these environment variables.
A workaround is to edit the file at <denv workspace>/.profile to unset these variables.

denv true # make sure profile is copied over
cat >> .profile <<PROF
# unset errorneously set variables that should not be used since ROOT
# is installed in a read-only location
unset JUPYTER_CONFIG_DIR
unset JUPYTER_PATH
PROF

What tag of the container are you using? What application are you using to run the container?
Both of these are answered by denv config print.

denv_workspace="/export/scratch/users/eichl008"
denv_name="eichl008"
denv_image="ldmx/pro:v4.0.1"
denv_mounts=""
denv_shell="/bin/bash -i"
denv_network="true"
apptainer version 1.3.5-1.el8

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions