ContinuumIO / anaconda-issues

Anaconda issue tracking
648 stars 224 forks source link

AttributeError: 'bytes' object has no attribute 'get' -- immediatly on macOSX-arm64 anaconda navigator install #13395

Open strongpc54 opened 5 months ago

strongpc54 commented 5 months ago

Checklist

What happened?

image

Conda info

strongpc@Mac-mini ~ % conda info

# >>>>>>>>>>>>>>>>>>>>>> ERROR REPORT <<<<<<<<<<<<<<<<<<<<<<

    Traceback (most recent call last):
      File "/opt/anaconda3/lib/python3.11/site-packages/conda/exception_handler.py", line 17, in __call__
        return func(*args, **kwargs)
               ^^^^^^^^^^^^^^^^^^^^^
      File "/opt/anaconda3/lib/python3.11/site-packages/conda/cli/main.py", line 66, in main_subshell
        context.__init__(argparse_args=pre_args)
      File "/opt/anaconda3/lib/python3.11/site-packages/conda/base/context.py", line 472, in __init__
        self._set_search_path(
      File "/opt/anaconda3/lib/python3.11/site-packages/conda/common/configuration.py", line 1416, in _set_search_path
        self._search_path = IndexedSet(self._expand_search_path(search_path, **kwargs))
                            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      File "/opt/anaconda3/lib/python3.11/site-packages/boltons/setutils.py", line 125, in __init__
        self.update(other)
      File "/opt/anaconda3/lib/python3.11/site-packages/boltons/setutils.py", line 355, in update
        for o in other:
      File "/opt/anaconda3/lib/python3.11/site-packages/conda/common/configuration.py", line 1389, in _expand_search_path
        if path.is_file() and (
           ^^^^^^^^^^^^^^
      File "/opt/anaconda3/lib/python3.11/pathlib.py", line 1267, in is_file
        return S_ISREG(self.stat().st_mode)
                       ^^^^^^^^^^^
      File "/opt/anaconda3/lib/python3.11/pathlib.py", line 1013, in stat
        return os.stat(self, follow_symlinks=follow_symlinks)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    PermissionError: [Errno 13] Permission denied: '/Users/strongpc/.config/conda/.condarc'

`$ /opt/anaconda3/bin/conda info`

An unexpected error has occurred. Conda has prepared the above report.
If you suspect this error is being caused by a malfunctioning plugin,
consider using the --no-plugins option to turn off plugins.

Example: conda --no-plugins install <package>

Alternatively, you can set the CONDA_NO_PLUGINS environment variable on
the command line to run the command without plugins enabled.

Example: CONDA_NO_PLUGINS=true conda install <package>

If submitted, this report will be used by core maintainers to improve
future releases of conda.
Would you like conda to send this report to the core maintainers? [y/N]: N

No report sent. To permanently opt-out, use

    $ conda config --set report_errors false

strongpc@Mac-mini ~ %

Conda config

Same error message

Conda list

Same error message

Additional Context

This started happening after upgrade to from Python 3.10 -> Python 3.11.3. I tried to delete & reinstall anaconda navigator several times, eventually reinstalled macOSX Sonoma 14.5 and restored by files from time machine backup, and can't fix this problem. It gets my PyCharm environment stuck in a loop trying to reload everything. Very painful.

Sopwith commented 4 months ago

Getting this exact same error, exact same traceback issues, on Windows 11. This is for the default python install from Anaconda.

saundramonroe commented 4 months ago

The error message you are encountering is a PermissionError, which indicates that the conda command is unable to access a configuration file due to insufficient permissions. Specifically, the error is occurring because the conda process does not have permission to read the file located at /Users/strongpc/.config/conda/.condarc. PermissionError [Errno 13] Permission denied: '/Users/strongpc/.config/conda/.condarc'. Do you have any additional permissions you need to set?