Skip to content

Windows error: "conda activate" fails because shell is not initialized #3371

Closed
@nicoddemus

Description

Hi,

After updating to conda 4.6.1, I'm getting this error when I try to build a recipe:

CommandNotFoundError: Your shell has not been properly configured to use 'conda activate'.
If using 'conda activate' from a batch script, change your
invocation to 'CALL conda.bat activate'.

To initialize your shell, run

    $ conda init <SHELL_NAME>

Currently supported shells are:
  - bash
  - cmd.exe
  - fish
  - tcsh
  - xonsh
  - zsh
  - powershell

See 'conda init --help' for more information and options.

I still get this error even after executing conda init cmd.exe and restarting the shell. I've also executed conda init cmd.exe with base environment active, but obtain the same results.

Using the same conda and conda-build combinations work on Linux.

Relevant conda info:

     active environment : base
    active env location : W:\Miniconda3
            shell level : 1
       user config file : C:\Users\bruno\.condarc
 populated config files : W:\Miniconda3\.condarc
          conda version : 4.6.1
    conda-build version : 3.16.3
         python version : 3.7.1.final.0
       base environment : W:\Miniconda3  (writable)
           channel URLs : https://<mirrorurl>/conda-channel/esss/win-64
                          https://<mirrorurl>/conda-channel/esss/noarch
                          https://<mirrorurl>/conda-channel/mirror-main/win-64
                          https://<mirrorurl>/conda-channel/mirror-main/noarch
                          https://<mirrorurl>/conda-channel/mirror-conda-forge/win-64
                          https://<mirrorurl>/conda-channel/mirror-conda-forge/noarch
          package cache : W:\Miniconda3\pkgs
                          C:\Users\bruno\.conda\pkgs
                          C:\Users\bruno\AppData\Local\conda\conda\pkgs
       envs directories : W:\Miniconda3\envs
                          C:\Users\bruno\.conda\envs
                          C:\Users\bruno\AppData\Local\conda\conda\envs
               platform : win-64
             user-agent : conda/4.6.1 requests/2.21.0 CPython/3.7.1 Windows/10 Windows/10.0.17134
          administrator : True
             netrc file : None
           offline mode : False

Any advice appreciated. 👍

cc @prusse-martin

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    locked[bot] locked due to inactivity

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions