1

I am setting up GitHub Codespaces for my project.

I have my .devcontainer configuration with a following Dockerfile:

FROM condaforge/mambaforge:latest
RUN apt-get update && apt-get install sudo gcc --yes && apt-get clean
RUN mamba install -c conda-forge \
  "conda-build == 3.25.0" "boa == 0.15.1" "conda-verify == 3.1.1" "jupyter-lab"

Relevant section of the .decontainer.json:

    "build": { "dockerfile": "Dockerfile" },

    "privileged": true,

    "forwardPorts": [8000, 9000],

    "portsAttributes": {
        "8000": {
            "label": "HTTP",
            "protocol": "http",
            "onAutoForward": "notify",
            "elevateIfNeeded": true
        },
        "9000": {
            "label": "HTTPS",
            "protocol": "https",
            "onAutoForward": "notify",
            "elevateIfNeeded": true
        }
    },

I start the codespace and then in the terminal I run jupyter-lab --port 8000 --allow-root and the server starts; I open it it another browser tab, paste the authentication token and Jupyter Lab initiates. However, whenever I try to work in a notebook I am stuck on "Connecting to the IPython kernel" stage. Do I need to specify some more options for the codespace? Or maybe for the Jupyter server?

1 Answer 1

0

Try conda install nb_conda_kernels. This should make any conda envs visible as eligible notebook kernels.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.