question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Spike - Can we use `conda list` and `conda info` all the info we need to work with conda

See original GitHub issue

Can we stop using the environments.txt file?

Currently when we discover interpreter environments we walk through a list of locators. For conda we have CondaEnvService and CondaEnvFileService (in that order). CondaEnvService uses the conda command and CondaEnvFileService uses the .conda/environments.txt file. So this spike boils down to “can be get rid of CondaEnvFileService?”

Getting environments from mini conda does not work

  • This could be a bigger problem. (possible it fails with vanilla installs of latest version of Conda) TODO:
  • Need to test current extension on Windows, Mac and Linux.
    • Latest anaconda
    • Latest mini conda
    • Test discovery of conda environments (ensure they are listed in environment list)
  • Try to find a better way e.g. conda run (check upstream on Conda repo for recommendations)

See https://github.com/microsoft/vscode-python/issues/6802 & #6854 This is Conda related. TODO:

  • We need to identify a better (proper way) to get this working (adding paths, etc is a hack and we’re trying to get away from such hacks when dealing with Conda).

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:1
  • Comments:9 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
karthiknadigcommented, Nov 26, 2019

On linux, tested from latest to Anaconda3-5.3.1 which uses conda 4.4.10. I am able to access environment data using conda list. image

And via conda info: image

If the minimum version we are planning to support is conda 4.6* then I think we can safely get rid of CondaEnvFileService.

1reaction
brettcannoncommented, Nov 20, 2019

The real trick is the conda version which is updated independently of Anaconda releases. And we have been planning to support at least conda 4.6 and newer due to relying on conda run going forward.

Read more comments on GitHub >

github_iconTop Results From Across the Web

conda info — conda 22.11.1.post16+ce4e810c9 documentation
Display information about current conda install. ... List all known conda environments. ... Use once for info, twice for debug, three times for...
Read more >
CONDA CHEAT SHEET
Learn to use conda in 30 minutes at bit.ly/tryconda ... conda info conda update conda ... List all packages and versions installed in...
Read more >
Getting started with conda
Conda is a powerful package manager and environment manager that you use with command line commands at the Anaconda Prompt for Windows, or...
Read more >
conda list — conda 22.11.1.post16+ce4e810c9 documentation
List explicitly all installed conda packages with URL (output may be used by conda create ... Use once for info, twice for debug,...
Read more >
Managing packages - Conda
List the dependencies that a specific package requires to run: conda search ; Find your installation's package cache directory: conda info ; Now...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found