conda Verified current stable Not installed? Package Management

Conda / View Specific Environment By Path

View Specific Environment By Path

Diagnoses health and configuration status of a specific conda environment.

$
Terminal
conda doctor -p <path/to/environment>

When To Use

During troubleshooting of environment issues.

Pro Tip

Add the `--json` flag to receive output in JSON format for easier parsing in scripts.

Terminal Output

Expected runtime feedback

Simulated preview
>
Output
# conda doctor -p path/to/environment

Checking environment validity...

Environment location: path/to/environment

Packages:
              Name                           Version         Build       Channel 
             ------------------------------------------
             numpy                          1.21.0       py37h6f1e8f2_0  defaults 
             pandas                         1.3.0        py37h06a2f20_0  defaults

No issues found. Your environment is healthy!

Anatomy of Output

Understanding the result

[WARNING] Environment not found: /path/to/environment Warning

Indicates that the specified environment path does not exist.

[INFO] Environment packages: numpy, pandas Installed Packages

Lists packages installed in the specified environment.

[ERROR] Environment is missing crucial dependencies. Dependency Error

Signifies potential issues that may affect application functionality.

Power User Variants

Optimized versions

conda doctor --json -p /path/to/environment

Output environment health in JSON format for script processing.

conda doctor -p /path/to/another-env

Check health of another specific environment.

Troubleshooting

Common pitfalls

CondaEnvNotFound: Environment '/path/to/environment' does not exist.

Solution: Ensure the path is correct or create the environment.

CondaError: Unable to access environment at '/path/to/environment'.

Solution: Check permissions or path validity.

EnvironmentError: Failed due to an unknown error.

Solution: Run with `-v` for verbose output.

Command Breakdown

What each part is doing

conda
Base Command
The executable that performs this operation. Here it runs Conda before the shell applies any redirect operators.
-p
p| prefix
The value supplied for p| prefix.
<path/to/environment>
path to environment
The value supplied for path to environment.
-p
Command Option
Tool-specific option used by this command invocation.

How To Run

Execution path

  1. Step 1

    Run the command: `conda doctor -p path/to/environment` to check the environment.

  2. Step 2

    Verify the output to ensure all packages are listed and no issues are reported.

Alternative Approaches

Comparable commands in other tools

Alternative package management tools for the same job.