conda `detect_env` does not work on remote ssh
I use zed to dev on a remote server,
I have anaconda env and here is my pyrightconfig.json
{
"venv": "opencv",
"venvPath": "/Users/chuongnguyen/miniconda3/envs"
}
it works in my local machine but not on the remote server. do i miss anything?
Originally posted by @Chuong98CC in #7646
actually, I found that setting the project setting will make it partially work
- cmd-shift-p --> open command pallete and then search for
zed: open project setting. This will create a folder./zed/setting.jsonin your project root. - add your python path explicitly
{
"lsp": {
"pyright": {
"settings": {
"python": {
"pythonPath": "/path/to/conda/env/bin/python"
}
}
}
},
"terminal": {
"detect_venv": {
"on": {
// Default directories to search for virtual environments, relative
// to the current working directory. We recommend overriding this
// in your project's settings, rather than globally.
"directories": ["/path/to/conda/env"],
// Can also be `csh`, `fish`, and `nushell`
"activate_script": "default"
}
}
}
}
but the detect_env still does not work. create new terminal just use the base env
Just double checking, you are using the same user name on both remote and local dev correct? I.e. /Users/chuongnguyen/miniconda3/envs is a valid path on both the local machine and the remote? (or are they the same computer?)
hi @probably-neb ,
i am able to use the miniconda using the scripts from this issue https://github.com/zed-industries/zed/discussions/19702.
My problem is when I start a new terminal, it does not auto-change into the conda env as in VSCode, but we still have to do in manuanlly, like conda activate env_name
thanks.
with https://github.com/zed-industries/zed/pull/37627 this should hopefully be solved