Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

conda-unpack overwrites kernel.json incorrectly (on Windows 10) #385

Open
2 tasks done
rra88 opened this issue Jan 3, 2025 · 0 comments
Open
2 tasks done

conda-unpack overwrites kernel.json incorrectly (on Windows 10) #385

rra88 opened this issue Jan 3, 2025 · 0 comments
Labels
type::bug describes erroneous operation, use severity::* to classify the type

Comments

@rra88
Copy link

rra88 commented Jan 3, 2025

Checklist

  • I added a descriptive title
  • I searched open reports and couldn't find a duplicate

What happened?

What I did:

  1. on a Windows 10 machine with anaconda3 running conda 23.7.4, I created a test environment "test_env" using conda create -n test_env python=3.12.
  2. I then activated the environment (conda activate test_env) and installed ipykernel with conda install ipykernel
  3. Following the section "Commandline Usage" of https://conda.github.io/conda-pack/, I then moved the environment to another (offline) Windows 10 computer with miniconda3 running conda 24.9.2
  4. On that computer I inspected the file kernel.json (located at "C:\Users<my_user>\AppData\Local\anaconda3\envs\test_env\share\jupyter\kernels\python3" on the first computer, and at "C:\Users<my_user>\AppData\Local\miniconda3\envs\test_env\share\jupyter\kernels\python3" on the second computer), and could see that the first "argv" entry had been changed from "C:/Users/<my_user>/AppData/Local/anaconda3/envs/test_env\python.exe" (see the uploaded kernel.json file) to something very different and obviously wrong.
  5. Activating the environment and running conda-unpack, I saw that the same path was changed to ""//?/C:/Users/<my_user>/AppData/Local/miniconda3/envs/test_env\python.exe", which is as I expected, except for the "//?/" prefix.

Is this a bug, or have I done something incorrectly?

Note that manually removing the prefix in the kernel.json file caused the desired behaviour (jupyter notebook was able to find and use the environment). Also note that in step 5 above, I activated the environment using conda activate test_env instead of source my_env/bin/activate which was described in https://conda.github.io/conda-pack/, as that command did not work.

Additional Context

kernel.json

@rra88 rra88 added the type::bug describes erroneous operation, use severity::* to classify the type label Jan 3, 2025
@github-project-automation github-project-automation bot moved this to 🆕 New in 🧭 Planning Jan 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type::bug describes erroneous operation, use severity::* to classify the type
Projects
Status: 🆕 New
Development

No branches or pull requests

1 participant