title: CondaEnvException: Pip failed. I am getting a pip subprocess error when trying to create an environment in conda using a .yml file
body: <p>I am trying to create an environment in conda using a .yml file. Here are the commands i have run,</p>
  <pre><code>git clone https://github.com/fastai/fastai
  cd fastai
  conda env create -f environment.yml
  </code></pre>
  <p>The last command gives me the error. Everything works fine until a certain point and then all of a sudden  I get this :</p>
  <pre><code>Pip subprocess error:
    ERROR: Command errored out with exit status 1:
     command: 'C:\Users\me\Anaconda3\envs\fastai\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '&quot;'&quot;'C:\\Users\\Admin\\AppData\\Local\\Temp\\pip-install-f93i4zuc\\scikit-misc\\setup.py'&quot;'&quot;'; __file__='&quot;'&quot;'C:\\Users\\Admin\\AppData\\Local\\Temp\\pip-install-f93i4zuc\\scikit-misc\\setup.py'&quot;'&quot;';f=getattr(tokenize, '&quot;'&quot;'open'&quot;'&quot;', open)(__file__);code=f.read().replace('&quot;'&quot;'\r\n'&quot;'&quot;', '&quot;'&quot;'\n'&quot;'&quot;');f.close();exec(compile(code, __file__, '&quot;'&quot;'exec'&quot;'&quot;'))' bdist_wheel -d 'C:\Users\Admin\AppData\Local\Temp\pip-wheel-0yqpfbub'
         cwd: C:\Users\Admin\AppData\Local\Temp\pip-install-f93i4zuc\scikit-misc\
    Complete output (123 lines):
    blas_opt_info:
    blas_mkl_info:
    No module named 'numpy.distutils._msvccompiler' in numpy.distutils; trying from distutils
    customize MSVCCompiler
      libraries mkl_rt not found in ['C:/Users/me/Anaconda3/envs/fastai\\Library\\lib']
      NOT AVAILABLE
  
    blis_info:
      libraries blis not found in ['C:\\Users\\me\\Anaconda3\\envs\\fastai\\lib', 'C:\\', 'C:\\Users\\me\\Anaconda3\\envs\\fastai\\libs']
      NOT AVAILABLE
  
    openblas_info:
      libraries openblas not found in ['C:\\Users\\me\\Anaconda3\\envs\\fastai\\lib', 'C:\\', 'C:\\Users\\me\\Anaconda3\\envs\\fastai\\libs']
    get_default_fcompiler: matching types: '['gnu', 'intelv', 'absoft', 'compaqv', 'intelev', 'gnu95', 'g95', 'intelvem', 'intelem', 'flang']'
    customize GnuFCompiler
    Could not locate executable g77
    Could not locate executable f77
    customize IntelVisualFCompiler
    Could not locate executable ifort
    Could not locate executable ifl
    customize AbsoftFCompiler
    Could not locate executable f90
    customize CompaqVisualFCompiler
    Could not locate executable DF
    customize IntelItaniumVisualFCompiler
    Could not locate executable efl
    customize Gnu95FCompiler
    Could not locate executable gfortran
    Could not locate executable f95
    customize G95FCompiler
    Could not locate executable g95
    customize IntelEM64VisualFCompiler
    customize IntelEM64TFCompiler
    Could not locate executable efort
    Could not locate executable efc
    customize PGroupFlangCompiler
    Could not locate executable flang
    don't know how to compile Fortran code on platform 'nt'
      NOT AVAILABLE
  
    atlas_3_10_blas_threads_info:
    Setting PTATLAS=ATLAS
      libraries tatlas not found in ['C:\\Users\\me\\Anaconda3\\envs\\fastai\\lib', 'C:\\', 'C:\\Users\\me\\Anaconda3\\envs\\fastai\\libs']
      NOT AVAILABLE
  
    atlas_3_10_blas_info:
      libraries satlas not found in ['C:\\Users\\me\\Anaconda3\\envs\\fastai\\lib', 'C:\\', 'C:\\Users\\me\\Anaconda3\\envs\\fastai\\libs']
      NOT AVAILABLE
  
    atlas_blas_threads_info:
    Setting PTATLAS=ATLAS
      libraries ptf77blas,ptcblas,atlas not found in ['C:\\Users\\me\\Anaconda3\\envs\\fastai\\lib', 'C:\\', 'C:\\Users\\me\\Anaconda3\\envs\\fastai\\libs']
      NOT AVAILABLE
  
    atlas_blas_info:
      libraries f77blas,cblas,atlas not found in ['C:\\Users\\me\\Anaconda3\\envs\\fastai\\lib', 'C:\\', 'C:\\Users\\me\\Anaconda3\\envs\\fastai\\libs']
      NOT AVAILABLE
  
    accelerate_info:
      NOT AVAILABLE
  
    C:\Users\me\Anaconda3\envs\fastai\lib\site-packages\numpy\distutils\system_info.py:1896: UserWarning:
        Optimized (vendor) Blas libraries are not found.
        Falls back to netlib Blas library which has worse performance.
        A better performance should be easily gained by switching
        Blas library.
      if self._calc_info(blas):
    blas_info:
      libraries blas not found in ['C:\\Users\\me\\Anaconda3\\envs\\fastai\\lib', 'C:\\', 'C:\\Users\\me\\Anaconda3\\envs\\fastai\\libs']
      NOT AVAILABLE
  
    C:\Users\me\Anaconda3\envs\fastai\lib\site-packages\numpy\distutils\system_info.py:1896: UserWarning:
        Blas (http://www.netlib.org/blas/) libraries not found.
        Directories to search for the libraries can be specified in the
        numpy/distutils/site.cfg file (section [blas]) or by setting
        the BLAS environment variable.
      if self._calc_info(blas):
    blas_src_info:
      NOT AVAILABLE
  
    C:\Users\me\Anaconda3\envs\fastai\lib\site-packages\numpy\distutils\system_info.py:1896: UserWarning:
        Blas (http://www.netlib.org/blas/) sources not found.
        Directories to search for the sources can be specified in the
        numpy/distutils/site.cfg file (section [blas_src]) or by setting
        the BLAS_SRC environment variable.
      if self._calc_info(blas):
      NOT AVAILABLE
  
    running bdist_wheel
    running build
    running config_cc
    unifing config_cc, config, build_clib, build_ext, build commands --compiler options
    running config_fc
    unifing config_fc, config, build_clib, build_ext, build commands --fcompiler options
    running build_src
    build_src
    building py_modules sources
    building library &quot;floess&quot; sources
    building extension &quot;skmisc.loess._loess&quot; sources
    building data_files sources
    build_src: building npy-pkg config files
    running build_py
    creating build\lib.win-amd64-3.6
    creating build\lib.win-amd64-3.6\skmisc
    copying skmisc\setup.py -&gt; build\lib.win-amd64-3.6\skmisc
    copying skmisc\_version.py -&gt; build\lib.win-amd64-3.6\skmisc
    copying skmisc\__config__.py -&gt; build\lib.win-amd64-3.6\skmisc
    copying skmisc\__init__.py -&gt; build\lib.win-amd64-3.6\skmisc
    copying build\src.win-amd64-3.6\skmisc\__config__.py -&gt; build\lib.win-amd64-3.6\skmisc
    creating build\lib.win-amd64-3.6\skmisc\loess
    copying skmisc\loess\setup.py -&gt; build\lib.win-amd64-3.6\skmisc\loess
    copying skmisc\loess\__init__.py -&gt; build\lib.win-amd64-3.6\skmisc\loess
    creating build\lib.win-amd64-3.6\skmisc\loess\tests
    copying skmisc\loess\tests\test_loess.py -&gt; build\lib.win-amd64-3.6\skmisc\loess\tests
    copying skmisc\loess\tests\__init__.py -&gt; build\lib.win-amd64-3.6\skmisc\loess\tests
    UPDATING build\lib.win-amd64-3.6\skmisc/_version.py
    set build\lib.win-amd64-3.6\skmisc/_version.py to '0.1.3'
    running build_clib
    No module named 'numpy.distutils._msvccompiler' in numpy.distutils; trying from distutils
    customize MSVCCompiler
    customize MSVCCompiler using build_clib
    building 'floess' library
    error: library floess has Fortran sources but no Fortran compiler found
    ----------------------------------------
    ERROR: Failed building wheel for scikit-misc
      ERROR: Command errored out with exit status 1:
       command: 'C:\Users\me\Anaconda3\envs\fastai\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '&quot;'&quot;'C:\\Users\\Admin\\AppData\\Local\\Temp\\pip-install-f93i4zuc\\scikit-misc\\setup.py'&quot;'&quot;'; __file__='&quot;'&quot;'C:\\Users\\Admin\\AppData\\Local\\Temp\\pip-install-f93i4zuc\\scikit-misc\\setup.py'&quot;'&quot;';f=getattr(tokenize, '&quot;'&quot;'open'&quot;'&quot;', open)(__file__);code=f.read().replace('&quot;'&quot;'\r\n'&quot;'&quot;', '&quot;'&quot;'\n'&quot;'&quot;');f.close();exec(compile(code, __file__, '&quot;'&quot;'exec'&quot;'&quot;'))' install --record 'C:\Users\Admin\AppData\Local\Temp\pip-record-l2a968qs\install-record.txt' --single-version-externally-managed --compile --install-headers 'C:\Users\me\Anaconda3\envs\fastai\Include\scikit-misc'
           cwd: C:\Users\Admin\AppData\Local\Temp\pip-install-f93i4zuc\scikit-misc\
      Complete output (123 lines):
      blas_opt_info:
      blas_mkl_info:
      No module named 'numpy.distutils._msvccompiler' in numpy.distutils; trying from distutils
      customize MSVCCompiler
        libraries mkl_rt not found in ['C:/Users/me/Anaconda3/envs/fastai\\Library\\lib']
        NOT AVAILABLE
  
      blis_info:
        libraries blis not found in ['C:\\Users\\me\\Anaconda3\\envs\\fastai\\lib', 'C:\\', 'C:\\Users\\me\\Anaconda3\\envs\\fastai\\libs']
        NOT AVAILABLE
  
      openblas_info:
        libraries openblas not found in ['C:\\Users\\me\\Anaconda3\\envs\\fastai\\lib', 'C:\\', 'C:\\Users\\me\\Anaconda3\\envs\\fastai\\libs']
      get_default_fcompiler: matching types: '['gnu', 'intelv', 'absoft', 'compaqv', 'intelev', 'gnu95', 'g95', 'intelvem', 'intelem', 'flang']'
      customize GnuFCompiler
      Could not locate executable g77
      Could not locate executable f77
      customize IntelVisualFCompiler
      Could not locate executable ifort
      Could not locate executable ifl
      customize AbsoftFCompiler
      Could not locate executable f90
      customize CompaqVisualFCompiler
      Could not locate executable DF
      customize IntelItaniumVisualFCompiler
      Could not locate executable efl
      customize Gnu95FCompiler
      Could not locate executable gfortran
      Could not locate executable f95
      customize G95FCompiler
      Could not locate executable g95
      customize IntelEM64VisualFCompiler
      customize IntelEM64TFCompiler
      Could not locate executable efort
      Could not locate executable efc
      customize PGroupFlangCompiler
      Could not locate executable flang
      don't know how to compile Fortran code on platform 'nt'
        NOT AVAILABLE
  
      atlas_3_10_blas_threads_info:
      Setting PTATLAS=ATLAS
        libraries tatlas not found in ['C:\\Users\\me\\Anaconda3\\envs\\fastai\\lib', 'C:\\', 'C:\\Users\\me\\Anaconda3\\envs\\fastai\\libs']
        NOT AVAILABLE
  
      atlas_3_10_blas_info:
        libraries satlas not found in ['C:\\Users\\me\\Anaconda3\\envs\\fastai\\lib', 'C:\\', 'C:\\Users\\me\\Anaconda3\\envs\\fastai\\libs']
        NOT AVAILABLE
  
      atlas_blas_threads_info:
      Setting PTATLAS=ATLAS
        libraries ptf77blas,ptcblas,atlas not found in ['C:\\Users\\me\\Anaconda3\\envs\\fastai\\lib', 'C:\\', 'C:\\Users\\me\\Anaconda3\\envs\\fastai\\libs']
        NOT AVAILABLE
  
      atlas_blas_info:
        libraries f77blas,cblas,atlas not found in ['C:\\Users\\me\\Anaconda3\\envs\\fastai\\lib', 'C:\\', 'C:\\Users\\me\\Anaconda3\\envs\\fastai\\libs']
        NOT AVAILABLE
  
      accelerate_info:
        NOT AVAILABLE
  
      C:\Users\me\Anaconda3\envs\fastai\lib\site-packages\numpy\distutils\system_info.py:1896: UserWarning:
          Optimized (vendor) Blas libraries are not found.
          Falls back to netlib Blas library which has worse performance.
          A better performance should be easily gained by switching
          Blas library.
        if self._calc_info(blas):
      blas_info:
        libraries blas not found in ['C:\\Users\\me\\Anaconda3\\envs\\fastai\\lib', 'C:\\', 'C:\\Users\\me\\Anaconda3\\envs\\fastai\\libs']
        NOT AVAILABLE
  
      C:\Users\me\Anaconda3\envs\fastai\lib\site-packages\numpy\distutils\system_info.py:1896: UserWarning:
          Blas (http://www.netlib.org/blas/) libraries not found.
          Directories to search for the libraries can be specified in the
          numpy/distutils/site.cfg file (section [blas]) or by setting
          the BLAS environment variable.
        if self._calc_info(blas):
      blas_src_info:
        NOT AVAILABLE
  
      C:\Users\me\Anaconda3\envs\fastai\lib\site-packages\numpy\distutils\system_info.py:1896: UserWarning:
          Blas (http://www.netlib.org/blas/) sources not found.
          Directories to search for the sources can be specified in the
          numpy/distutils/site.cfg file (section [blas_src]) or by setting
          the BLAS_SRC environment variable.
        if self._calc_info(blas):
        NOT AVAILABLE
  
      running install
      running build
      running config_cc
      unifing config_cc, config, build_clib, build_ext, build commands --compiler options
      running config_fc
      unifing config_fc, config, build_clib, build_ext, build commands --fcompiler options
      running build_src
      build_src
      building py_modules sources
      building library &quot;floess&quot; sources
      building extension &quot;skmisc.loess._loess&quot; sources
      building data_files sources
      build_src: building npy-pkg config files
      running build_py
      creating build\lib.win-amd64-3.6
      creating build\lib.win-amd64-3.6\skmisc
      copying skmisc\setup.py -&gt; build\lib.win-amd64-3.6\skmisc
      copying skmisc\_version.py -&gt; build\lib.win-amd64-3.6\skmisc
      copying skmisc\__config__.py -&gt; build\lib.win-amd64-3.6\skmisc
      copying skmisc\__init__.py -&gt; build\lib.win-amd64-3.6\skmisc
      copying build\src.win-amd64-3.6\skmisc\__config__.py -&gt; build\lib.win-amd64-3.6\skmisc
      creating build\lib.win-amd64-3.6\skmisc\loess
      copying skmisc\loess\setup.py -&gt; build\lib.win-amd64-3.6\skmisc\loess
      copying skmisc\loess\__init__.py -&gt; build\lib.win-amd64-3.6\skmisc\loess
      creating build\lib.win-amd64-3.6\skmisc\loess\tests
      copying skmisc\loess\tests\test_loess.py -&gt; build\lib.win-amd64-3.6\skmisc\loess\tests
      copying skmisc\loess\tests\__init__.py -&gt; build\lib.win-amd64-3.6\skmisc\loess\tests
      UPDATING build\lib.win-amd64-3.6\skmisc/_version.py
      set build\lib.win-amd64-3.6\skmisc/_version.py to '0.1.3'
      running build_clib
      No module named 'numpy.distutils._msvccompiler' in numpy.distutils; trying from distutils
      customize MSVCCompiler
      customize MSVCCompiler using build_clib
      building 'floess' library
      error: library floess has Fortran sources but no Fortran compiler found
      ----------------------------------------
  ERROR: Command errored out with exit status 1: 'C:\Users\me\Anaconda3\envs\fastai\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '&quot;'&quot;'C:\\Users\\Admin\\AppData\\Local\\Temp\\pip-install-f93i4zuc\\scikit-misc\\setup.py'&quot;'&quot;'; __file__='&quot;'&quot;'C:\\Users\\Admin\\AppData\\Local\\Temp\\pip-install-f93i4zuc\\scikit-misc\\setup.py'&quot;'&quot;';f=getattr(tokenize, '&quot;'&quot;'open'&quot;'&quot;', open)(__file__);code=f.read().replace('&quot;'&quot;'\r\n'&quot;'&quot;', '&quot;'&quot;'\n'&quot;'&quot;');f.close();exec(compile(code, __file__, '&quot;'&quot;'exec'&quot;'&quot;'))' install --record 'C:\Users\Admin\AppData\Local\Temp\pip-record-l2a968qs\install-record.txt' --single-version-externally-managed --compile --install-headers 'C:\Users\me\Anaconda3\envs\fastai\Include\scikit-misc' Check the logs for full command output.
  
  
  CondaEnvException: Pip failed
  </code></pre>
  <p>Here is the .yml file</p>
  <pre><code>name: fastai
  channels:
  - fastai
  - pytorch
  - defaults
  - peterjc123
  dependencies:
  - scipy
  - cuda90
  - cudnn
  - numpy
  - pillow
  - jpeg
  - spacy
  - zlib
  - freetype
  - libtiff
  - bleach
  - certifi
  - cffi
  - cycler
  - decorator
  - entrypoints
  - expat
  - html5lib
  - icu
  - ipykernel
  - ipython
  - ipython_genutils
  - ipywidgets
  - jedi
  - jinja2
  - jsonschema
  - jupyter
  - jupyter_client
  - jupyter_console
  - jupyter_core
  #- conda-forge::jupyter_contrib_nbextensions
  - libiconv
  - libpng
  - libsodium
  - libxml2
  - markupsafe
  - matplotlib=2.2.3
  - mistune
  - mkl
  - nbformat
  - notebook
  - numpy
  - olefile
  - openssl
  - pandas
  - pandocfilters
  - path.py
  - patsy
  - pcre
  - pexpect
  - pickleshare
  - pillow
  - pip
  - prompt_toolkit
  - pycparser
  - pygments
  - pyparsing
  - pyqt
  - python&gt;=3.6.0
  - python-dateutil
  - pytz
  - pyzmq
  - qt
  - qtconsole
  - scipy
  - seaborn
  - setuptools
  - simplegeneric
  - sip
  - six
  - sqlite
  - statsmodels
  - testfixtures
  - testpath&gt;=0.4.2
  - tk
  - tornado&lt;5
  - tqdm
  - traitlets
  - wcwidth
  - wheel
  - widgetsnbextension
  - xz
  - zeromq
  - pytorch&lt;0.4
  - bcolz
  - prompt_toolkit
  #- pytest
  - cython
  - graphviz
  - pip:
    - torchvision==0.1.9
    - opencv-python
    - isoweek
    - pandas_summary==0.0.5
    - torchtext==0.2.3
    - graphviz
    - sklearn_pandas
    - feather-format
    - plotnine
    - kaggle-cli
    - ipywidgets
    - nbconvert
    - PyHamcrest
    - pdpbox==0.1.0
    - scikit-misc
  </code></pre>
  <p>I have tried the following things and continue to get the error mentioned above:</p>
  <ul>
  <li>Uninstall the environment and try again</li>
  <li>Update pip to the current version in all environments</li>
  <li>Run the Anaconda Powershell prompt as admin and try again</li>
  </ul>
  <p>Can someone help in resolving this problem. I have no idea why this is happening so and explanation is also appreciated.</p>