Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conda broken after update #10575

Open
LarsWigger opened this issue Mar 29, 2021 · 7 comments
Open

Conda broken after update #10575

LarsWigger opened this issue Mar 29, 2021 · 7 comments
Labels
pending::feedback indicates we are waiting on feedback from the user source::community catch-all for issues filed by community members stale::recovered [bot] recovered after being marked as stale type::support neither a bug nor feature, is really just a user having questions or difficulty somewhere

Comments

@LarsWigger
Copy link

LarsWigger commented Mar 29, 2021

Current Behavior

After trying to update the base environment, I get an error message at various points, even a basic conda activate. This is the first the time it happened, the error message is at the bottom:

Error
# conda remove tensorboard
Collecting package metadata (repodata.json): done
Solving environment: /
Warning: 2 possible package resolutions (only showing differing packages):
  - defaults/linux-64::jedi-0.17.2-py37h06a4308_1, defaults/noarch::parso-0.7.0-py_0
  - defaults/linux-64::jedi-0.17.0-py37_0, defaults/noarch::parso-0.8.1-pyhd3eb1b0done

## Package Plan ##

  environment location: /opt/anaconda3

  removed specs:
    - tensorboard


The following packages will be REMOVED:

  _tflow_select-2.1.0-gpu
  absl-py-0.12.0-py37h06a4308_0
  aiohttp-3.7.4-py37h27cfd23_1
  astunparse-1.6.3-py_0
  async-timeout-3.0.1-py37h06a4308_0
  blas-1.0-mkl
  c-ares-1.17.1-h27cfd23_0
  cachetools-4.2.1-pyhd3eb1b0_0
  coverage-5.5-py37h27cfd23_2
  cudatoolkit-10.1.243-h6bb024c_0
  cudnn-7.6.5-cuda10.1_0
  cupti-10.1.168-0
  cython-0.29.22-py37h2531618_0
  gast-0.3.3-py_0
  google-auth-1.28.0-pyhd3eb1b0_0
  google-auth-oauthlib-0.4.3-pyhd3eb1b0_0
  google-pasta-0.2.0-py_0
  grpcio-1.36.1-py37h2157cd5_1
  h5py-2.10.0-py37hd6299e0_1
  hdf5-1.10.6-hb1b8bf9_0
  intel-openmp-2020.2-254
  keras-preprocessing-1.1.2-pyhd3eb1b0_0
  libgfortran-ng-7.3.0-hdf63c60_0
  libprotobuf-3.14.0-h8c45485_0
  markdown-3.3.4-py37h06a4308_0
  mkl-2020.2-256
  mkl-service-2.3.0-py37he8ac12f_0
  mkl_fft-1.3.0-py37h54f3939_0
  mkl_random-1.1.1-py37h0573a6f_0
  multidict-5.1.0-py37h27cfd23_2
  numpy-1.19.2-py37h54aff64_0
  numpy-base-1.19.2-py37hfa32c7d_0
  opt_einsum-3.1.0-py_0
  protobuf-3.14.0-py37h2531618_1
  pyasn1-0.4.8-py_0
  pyasn1-modules-0.2.8-py_0
  requests-oauthlib-1.3.0-py_0
  rsa-4.7.2-pyhd3eb1b0_1
  scipy-1.6.2-py37h91f5cce_0
  tensorboard-2.4.0-pyhc547734_0
  tensorboard-plugin-wit-1.6.0-py_0
  tensorflow-2.2.0-gpu_py37h1a511ff_0
  tensorflow-base-2.2.0-gpu_py37h8a81be8_0
  tensorflow-estimator-2.2.0-pyh208ff02_0
  tensorflow-gpu-2.2.0-h0d30ee6_0
  termcolor-1.1.0-py37h06a4308_1
  typing-extensions-3.7.4.3-hd3eb1b0_0
  werkzeug-1.0.1-pyhd3eb1b0_0
  wrapt-1.12.1-py37h7b6447c_1
  yarl-1.6.3-py37h27cfd23_0

The following packages will be UPDATED:

  chardet                           3.0.4-py37h06a4308_1003 --> 4.0.0-py37h06a4308_1003
  jedi                                        0.17.0-py37_0 --> 0.17.2-py37h06a4308_1

The following packages will be DOWNGRADED:

  parso                                  0.8.1-pyhd3eb1b0_0 --> 0.7.0-py_0
  typing_extensions                    3.7.4.3-pyh06a4308_0 --> 3.7.4.3-pyha847dfd_0


Proceed ([y]/n)? y

Preparing transaction: done
Verifying transaction: done
Executing transaction: done
Error processing line 1 of /opt/anaconda3/lib/python3.7/site-packages/google_auth-1.21.1-py3.8-nspkg.pth:

  Traceback (most recent call last):
    File "/opt/anaconda3/lib/python3.7/site.py", line 168, in addpackage
      exec(line)
    File "<string>", line 1, in <module>
    File "<frozen importlib._bootstrap>", line 580, in module_from_spec
  AttributeError: 'NoneType' object has no attribute 'loader'

Remainder of file ignored

I am also really buffled by the choices made by the package manager, like uninstalling numpy when I want to remove tensorboard or trying to update everything, including jupyterhub, when I told it to update only one package (conda itself). This does not make any sense to me, but this may be intentional.

Steps to Reproduce

I suspect this cannot be reproduced. I submit this issue in case someone can make sense of this, either to prevent this issue in the future or to tell me how to fix this.

Environment Information

conda info
Error processing line 1 of /opt/anaconda3/lib/python3.7/site-packages/google_auth-1.21.1-py3.8-nspkg.pth:

  Traceback (most recent call last):
    File "/opt/anaconda3/lib/python3.7/site.py", line 168, in addpackage
      exec(line)
    File "<string>", line 1, in <module>
    File "<frozen importlib._bootstrap>", line 580, in module_from_spec
  AttributeError: 'NoneType' object has no attribute 'loader'

Remainder of file ignored

     active environment : base
    active env location : /opt/anaconda3
            shell level : 1
       user config file : /root/.condarc
 populated config files : /root/.condarc
          conda version : 4.9.2
    conda-build version : 3.21.4
         python version : 3.7.10.final.0
       virtual packages : __cuda=11.2=0
                          __glibc=2.27=0
                          __unix=0=0
                          __archspec=1=x86_64
       base environment : /opt/anaconda3  (writable)
           channel URLs : https://repo.anaconda.com/pkgs/main/linux-64
                          https://repo.anaconda.com/pkgs/main/noarch
                          https://repo.anaconda.com/pkgs/r/linux-64
                          https://repo.anaconda.com/pkgs/r/noarch
                          https://conda.anaconda.org/conda-forge/linux-64
                          https://conda.anaconda.org/conda-forge/noarch
          package cache : /opt/anaconda3/pkgs
                          /root/.conda/pkgs
       envs directories : /opt/anaconda3/envs
                          /root/.conda/envs
               platform : linux-64
             user-agent : conda/4.9.2 requests/2.25.1 CPython/3.7.10 Linux/5.0.0-050000-generic ubuntu/18.04.5 glibc/2.27
                UID:GID : 0:0
             netrc file : None
           offline mode : False

conda config --show-sources
# conda config --show-sources
Error processing line 1 of /opt/anaconda3/lib/python3.7/site-packages/google_auth-1.21.1-py3.8-nspkg.pth:

  Traceback (most recent call last):
    File "/opt/anaconda3/lib/python3.7/site.py", line 168, in addpackage
      exec(line)
    File "<string>", line 1, in <module>
    File "<frozen importlib._bootstrap>", line 580, in module_from_spec
  AttributeError: 'NoneType' object has no attribute 'loader'

Remainder of file ignored
==> /root/.condarc <==
auto_activate_base: False
channels:
  - defaults
  - conda-forge

conda list --show-channel-urls
# conda list --show-channel-urls
Error processing line 1 of /opt/anaconda3/lib/python3.7/site-packages/google_auth-1.21.1-py3.8-nspkg.pth:

  Traceback (most recent call last):
    File "/opt/anaconda3/lib/python3.7/site.py", line 168, in addpackage
      exec(line)
    File "<string>", line 1, in <module>
    File "<frozen importlib._bootstrap>", line 580, in module_from_spec
  AttributeError: 'NoneType' object has no attribute 'loader'

Remainder of file ignored
# packages in environment at /opt/anaconda3:
#
# Name                    Version                   Build  Channel
_libgcc_mutex             0.1                        main    defaults
absl-py                   0.10.0                   pypi_0    pypi
anaconda-client           1.7.2                    py37_0    defaults
anaconda-navigator        1.10.0                   py37_0    defaults
argon2-cffi               20.1.0           py37h27cfd23_1    defaults
async_generator           1.10             py37h28b3542_0    defaults
attrs                     20.3.0             pyhd3eb1b0_0    defaults
backcall                  0.2.0              pyhd3eb1b0_0    defaults
backports                 1.0                pyhd3eb1b0_2    defaults
backports.functools_lru_cache 1.6.1              pyhd3eb1b0_0    defaults
backports.tempfile        1.0                pyhd3eb1b0_1    defaults
backports.weakref         1.0.post1                  py_1    defaults
beautifulsoup4            4.9.3              pyha847dfd_0    defaults
bleach                    3.3.0              pyhd3eb1b0_0    defaults
brotlipy                  0.7.0           py37h27cfd23_1003    defaults
bzip2                     1.0.8                h7b6447c_0    defaults
ca-certificates           2021.1.19            h06a4308_1    defaults
certifi                   2020.12.5        py37h06a4308_0    defaults
cffi                      1.14.5           py37h261ae71_0    defaults
chardet                   4.0.0           py37h06a4308_1003    defaults
click                     7.1.2              pyhd3eb1b0_0    defaults
clyent                    1.2.2                    py37_1    defaults
conda                     4.9.2            py37h06a4308_0    defaults
conda-build               3.21.4           py37h06a4308_0    defaults
conda-env                 2.6.0                         1    defaults
conda-package-handling    1.7.2            py37h03888b9_0    defaults
conda-verify              3.4.2                      py_1    defaults
cryptography              3.4.7            py37hd23ed53_0    defaults
dbus                      1.13.18              hb2f20db_0    defaults
decorator                 4.4.2              pyhd3eb1b0_0    defaults
defusedxml                0.7.1              pyhd3eb1b0_0    defaults
entrypoints               0.3                      py37_0    defaults
expat                     2.3.0                h2531618_2    defaults
filelock                  3.0.12             pyhd3eb1b0_1    defaults
fontconfig                2.13.1               h6c09931_0    defaults
freetype                  2.10.4               h5ab3b9f_0    defaults
future                    0.18.2                   py37_1    defaults
glib                      2.68.0               h36276a3_0    defaults
glob2                     0.7                pyhd3eb1b0_0    defaults
google-auth               1.21.1                   pypi_0    pypi
gst-plugins-base          1.14.0               h8213a91_2    defaults
gstreamer                 1.14.0               h28cd5cc_2    defaults
icu                       58.2                 he6710b0_3    defaults
idna                      2.10               pyhd3eb1b0_0    defaults
importlib-metadata        3.7.3            py37h06a4308_1    defaults
importlib_metadata        3.7.3                hd3eb1b0_1    defaults
ipykernel                 5.3.4            py37h5ca1d4c_0    defaults
ipython                   7.21.0           py37hb070fc8_0    defaults
ipython_genutils          0.2.0              pyhd3eb1b0_1    defaults
jedi                      0.17.2           py37h06a4308_1    defaults
jinja2                    2.11.3             pyhd3eb1b0_0    defaults
jpeg                      9b                   h024ee3a_2    defaults
jsonschema                3.2.0                      py_2    defaults
jupyter_client            6.1.7                      py_0    defaults
jupyter_core              4.7.1            py37h06a4308_0    defaults
jupyterlab_pygments       0.1.2                      py_0    defaults
lcms2                     2.11                 h396b838_0    defaults
ld_impl_linux-64          2.33.1               h53a641e_7    defaults
libarchive                3.4.2                h62408e4_0    defaults
libffi                    3.3                  he6710b0_2    defaults
libgcc-ng                 9.1.0                hdf63c60_0    defaults
liblief                   0.10.1               he6710b0_0    defaults
libpng                    1.6.37               hbc83047_0    defaults
libsodium                 1.0.18               h7b6447c_0    defaults
libstdcxx-ng              9.1.0                hdf63c60_0    defaults
libtiff                   4.2.0                h85742a9_0    defaults
libuuid                   1.0.3                h1bed415_2    defaults
libwebp-base              1.2.0                h27cfd23_0    defaults
libxcb                    1.14                 h7b6447c_0    defaults
libxml2                   2.9.10               hb55368b_3    defaults
lz4-c                     1.9.3                h2531618_0    defaults
markupsafe                1.1.1            py37h14c3975_1    defaults
mistune                   0.8.4           py37h14c3975_1001    defaults
navigator-updater         0.2.1                    py37_0    defaults
nbclient                  0.5.3              pyhd3eb1b0_0    defaults
nbconvert                 6.0.7                    py37_0    defaults
nbformat                  5.1.2              pyhd3eb1b0_1    defaults
ncurses                   6.2                  he6710b0_1    defaults
nest-asyncio              1.5.1              pyhd3eb1b0_0    defaults
notebook                  6.3.0            py37h06a4308_0    defaults
olefile                   0.46                     py37_0    defaults
openssl                   1.1.1k               h27cfd23_0    defaults
opt-einsum                3.3.0                    pypi_0    pypi
packaging                 20.9               pyhd3eb1b0_0    defaults
pandoc                    2.12                 h06a4308_0    defaults
pandocfilters             1.4.3            py37h06a4308_1    defaults
parso                     0.7.0                      py_0    defaults
patchelf                  0.12                 h2531618_1    defaults
pcre                      8.44                 he6710b0_0    defaults
pexpect                   4.8.0              pyhd3eb1b0_3    defaults
pickleshare               0.7.5           pyhd3eb1b0_1003    defaults
pillow                    8.1.2            py37he98fc37_0    defaults
pip                       21.0.1           py37h06a4308_0    defaults
pkginfo                   1.7.0            py37h06a4308_0    defaults
prometheus_client         0.9.0              pyhd3eb1b0_0    defaults
prompt-toolkit            3.0.17             pyh06a4308_0    defaults
protobuf                  3.13.0                   pypi_0    pypi
psutil                    5.8.0            py37h27cfd23_1    defaults
ptyprocess                0.7.0              pyhd3eb1b0_2    defaults
py-lief                   0.10.1           py37h403a769_0    defaults
pyasn1-modules            0.2.8                    pypi_0    pypi
pycosat                   0.6.3            py37h27cfd23_0    defaults
pycparser                 2.20                       py_2    defaults
pygments                  2.8.1              pyhd3eb1b0_0    defaults
pyopenssl                 20.0.1             pyhd3eb1b0_1    defaults
pyparsing                 2.4.7              pyhd3eb1b0_0    defaults
pyqt                      5.9.2            py37h05f1152_2    defaults
pyrsistent                0.17.3           py37h7b6447c_0    defaults
pysocks                   1.7.1                    py37_1    defaults
python                    3.7.10               hdb3f193_0    defaults
python-dateutil           2.8.1              pyhd3eb1b0_0    defaults
python-libarchive-c       2.9                pyhd3eb1b0_0    defaults
pytz                      2021.1             pyhd3eb1b0_0    defaults
pyyaml                    5.4.1            py37h27cfd23_1    defaults
pyzmq                     20.0.0           py37h2531618_1    defaults
qt                        5.9.7                h5867ecd_1    defaults
qtpy                      1.9.0                      py_0    defaults
readline                  8.1                  h27cfd23_0    defaults
requests                  2.25.1             pyhd3eb1b0_0    defaults
ripgrep                   12.1.1                        0    defaults
ruamel_yaml               0.15.100         py37h27cfd23_0    defaults
scipy                     1.4.1                    pypi_0    pypi
send2trash                1.5.0              pyhd3eb1b0_1    defaults
setuptools                52.0.0           py37h06a4308_0    defaults
sip                       4.19.8           py37hf484d3e_0    defaults
six                       1.15.0           py37h06a4308_0    defaults
soupsieve                 2.2.1              pyhd3eb1b0_0    defaults
sqlite                    3.35.2               hdfb4753_0    defaults
tensorboard               2.3.0                    pypi_0    pypi
tensorboard-plugin-wit    1.7.0                    pypi_0    pypi
tensorflow-estimator      2.3.0                    pypi_0    pypi
tensorflow-gpu            2.3.0                    pypi_0    pypi
termcolor                 1.1.0                    pypi_0    pypi
terminado                 0.9.3            py37h06a4308_0    defaults
testpath                  0.4.4              pyhd3eb1b0_0    defaults
tk                        8.6.10               hbc83047_0    defaults
tornado                   6.1              py37h27cfd23_0    defaults
tqdm                      4.59.0             pyhd3eb1b0_1    defaults
traitlets                 5.0.5              pyhd3eb1b0_0    defaults
typing_extensions         3.7.4.3            pyha847dfd_0    defaults
urllib3                   1.26.4             pyhd3eb1b0_0    defaults
wcwidth                   0.2.5                      py_0    defaults
webencodings              0.5.1                    py37_1    defaults
wheel                     0.36.2             pyhd3eb1b0_0    defaults
xmltodict                 0.12.0                     py_0    defaults
xz                        5.2.5                h7b6447c_0    defaults
yaml                      0.2.5                h7b6447c_0    defaults
zeromq                    4.3.4                h2531618_0    defaults
zipp                      3.4.1              pyhd3eb1b0_0    defaults
zlib                      1.2.11               h7b6447c_3    defaults
zstd                      1.4.5                h9ceee32_0    defaults
@mcclearyj
Copy link

Let me know if you find a solution -- I am having this same problem. It began when I followed what appears to be the following bad advice here: https://stackoverflow.com/a/62269476/11929138

Did you do something similar?

@Connor-Ecocentric
Copy link

yup same issue with me, man i am sick of conda being so flaky all the time! hopefully this gets fixed, will update if i find a solution

@Ali786H
Copy link

Ali786H commented Nov 15, 2022

Same issue after update

@kenodegard
Copy link
Contributor

@LarsWigger It looks like something is wrong with the google-auth package that is installed into your base environment. Since this package is listed as a PyPI/pip package I suggest uninstalling it and reinstalling from conda:

pip uninstall google-auth
conda install google-auth

Two good rules of thumb to follow in conda:

  1. Create separate (non-base) environments for your work (e.g., conda create -n scratch). Since conda lives in your base environment, it's risky to install all of the packages you wish to use in that same environment. This results in EVERYTHING being considered for an update when you update conda. It's also much easier to recover from a broken non-base environment than from a broken base environment.

  2. While conda has some understanding of how PyPI/pip works, PyPI/pip has no idea how conda works. So it's always risky to mix conda and PyPI/pip in the same environment (especially in the base environment). We expect mixed environments to break eventually. For this reason, the above point of leaving the base environment "pure" is especially true.


@mcclearyj @Connor-Ecocentric @Ali786H please open new issues with the error messages you are encountering if the above doesn't work for you.

@kenodegard kenodegard added type::support neither a bug nor feature, is really just a user having questions or difficulty somewhere source::community catch-all for issues filed by community members pending::feedback indicates we are waiting on feedback from the user labels Nov 15, 2022
@Ali786H
Copy link

Ali786H commented Nov 15, 2022

Thanks Dear

@github-actions
Copy link

github-actions bot commented Dec 7, 2022

Hi there, thank you for your contribution!

This issue has been automatically marked as stale because it has not had recent activity. It will be closed automatically if no further activity occurs.

If you would like this issue to remain open please:

  1. Verify that you can still reproduce the issue at hand
  2. Comment that the issue is still reproducible and include:
    - What OS and version you reproduced the issue on
    - What steps you followed to reproduce the issue

NOTE: If this issue was closed prematurely, please leave a comment.

Thanks!

@github-actions github-actions bot added the stale [bot] marked as stale due to inactivity label Dec 7, 2022
@mcclearyj
Copy link

While conda has some understanding of how PyPI/pip works, PyPI/pip has no idea how conda works. So it's always risky to mix conda and PyPI/pip in the same environment (especially in the base environment). We expect mixed environments to break eventually. For this reason, the above point of leaving the base environment "pure" is especially true.

@kenodegard, yes, after a miserable few days I came to this realization. One should use either pip or conda to manage packages, not both, and maintain a minimal base environment.

For extra confusion, pip installs packages in a .local directory, and depending on how PYTHONPATH is set up, even a complete reinstallation of conda may not resolve the conflicts.

@github-actions github-actions bot added stale::recovered [bot] recovered after being marked as stale and removed stale [bot] marked as stale due to inactivity labels Dec 8, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pending::feedback indicates we are waiting on feedback from the user source::community catch-all for issues filed by community members stale::recovered [bot] recovered after being marked as stale type::support neither a bug nor feature, is really just a user having questions or difficulty somewhere
Projects
Status: No status
Development

No branches or pull requests

5 participants