conda commands die with "archive_read_open_filename_w symbol not found"

Created on 4 Jul 2019  路  50Comments  路  Source: conda/conda

Current Behavior


When I try to do anything with conda, it now gives me the following traceback:

$ conda update conda
Traceback (most recent call last):
  File "/Users/adam/anaconda/envs/astropy36mpl2/bin/conda", line 13, in <module>
    sys.exit(main())
  File "/Users/adam/anaconda/lib/python2.7/site-packages/conda/cli/main.py", line 150, in main
    return conda_exception_handler(_main, *args, **kwargs)
  File "/Users/adam/anaconda/lib/python2.7/site-packages/conda/exceptions.py", line 1335, in conda_exception_handler
    return_value = exception_handler(func, *args, **kwargs)
  File "/Users/adam/anaconda/lib/python2.7/site-packages/conda/exceptions.py", line 1046, in __call__
    return self.handle_exception(exc_val, exc_tb)
  File "/Users/adam/anaconda/lib/python2.7/site-packages/conda/exceptions.py", line 1090, in handle_exception
    return self.handle_unexpected_exception(exc_val, exc_tb)
  File "/Users/adam/anaconda/lib/python2.7/site-packages/conda/exceptions.py", line 1101, in handle_unexpected_exception
    self.print_unexpected_error_report(error_report)
  File "/Users/adam/anaconda/lib/python2.7/site-packages/conda/exceptions.py", line 1171, in print_unexpected_error_report
    from .cli.main_info import get_env_vars_str, get_main_info_str
  File "/Users/adam/anaconda/lib/python2.7/site-packages/conda/cli/main_info.py", line 19, in <module>
    from ..core.index import _supplement_index_with_system
  File "/Users/adam/anaconda/lib/python2.7/site-packages/conda/core/index.py", line 9, in <module>
    from .package_cache_data import PackageCacheData
  File "/Users/adam/anaconda/lib/python2.7/site-packages/conda/core/package_cache_data.py", line 15, in <module>
    from conda_package_handling.api import InvalidArchiveError
  File "/Users/adam/anaconda/lib/python2.7/site-packages/conda_package_handling/api.py", line 3, in <module>
    from libarchive.exception import ArchiveError as _LibarchiveArchiveError
  File "/Users/adam/anaconda/lib/python2.7/site-packages/libarchive/__init__.py", line 1, in <module>
    from .entry import ArchiveEntry
  File "/Users/adam/anaconda/lib/python2.7/site-packages/libarchive/entry.py", line 6, in <module>
    from . import ffi
  File "/Users/adam/anaconda/lib/python2.7/site-packages/libarchive/ffi.py", line 184, in <module>
    c_int, check_int)
  File "/Users/adam/anaconda/lib/python2.7/site-packages/libarchive/ffi.py", line 95, in ffi
    f = getattr(libarchive, 'archive_'+name)
  File "/Users/adam/anaconda/lib/python2.7/ctypes/__init__.py", line 378, in __getattr__
    func = self.__getitem__(name)
  File "/Users/adam/anaconda/lib/python2.7/ctypes/__init__.py", line 383, in __getitem__
    func = self._FuncPtr((name_or_ordinal, self))
AttributeError: dlsym(0x100645af0, archive_read_open_filename_w): symbol not found

This happened after I ran conda update conda:

## Package Plan ##

  environment location: /Users/adam/anaconda

  added / updated specs:
    - conda


The following packages will be downloaded:

    package                    |            build
    ---------------------------|-----------------
    conda-4.7.5                |           py27_0         3.0 MB
    conda-package-handling-1.3.10|           py27_0         259 KB
    tqdm-4.32.1                |             py_0          48 KB
    ------------------------------------------------------------
                                           Total:         3.3 MB

The following NEW packages will be INSTALLED:

  conda-package-han~ pkgs/main/osx-64::conda-package-handling-1.3.10-py27_0
  python-libarchive~ pkgs/main/osx-64::python-libarchive-c-2.8-py27_6
  tqdm               pkgs/main/noarch::tqdm-4.32.1-py_0

The following packages will be UPDATED:

  conda                                       4.6.14-py27_0 --> 4.7.5-py27_0



Downloading and Extracting Packages
tqdm-4.32.1          | 48 KB     | ############################################################################################################################################################################################# | 100%
conda-4.7.5          | 3.0 MB    | #############################################################################################################################################7                                                |  75%
conda-package-handli | 259 KB    | ############################################################################################################################################################################################# | 100%

CondaMultiError: [Errno 2] No such file or directory: '/Users/adam/anaconda/pkgs/conda-4.7.5-py27_0.tar.bz2'

Environment Information

conda info



Same traceback as above

conda config --show-sources


$ conda config --show-sources
==> /Users/adam/.condarc <==
channels:
  - http://ssb.stsci.edu/astroconda
  - openastronomy
  - astropy
  - astropy-ci-extras
  - defaults
changeps1: False
always_yes: True

conda list --show-channel-urls


same traceback as above

So, is there any way I can recover a functioning conda environment? It's beyond time I replace the py2.7 conda with a py3 version, but I don't know how to do that given conda in its current state.

type-bug

Most helpful comment

I had the same issue after updating. Running brew install libarchive then updating the LIBARCHIVE environment variable resolved this error for me.

https://github.com/Changaco/python-libarchive-c

All 50 comments

I had the same issue after updating. Running brew install libarchive then updating the LIBARCHIVE environment variable resolved this error for me.

https://github.com/Changaco/python-libarchive-c

You should never need to use a package manager outside of conda to provide things that conda has. I'm glad your solution worked, @eelretep but there's a bug on our side that we need to fix.

@keflavich I believe you have an older build of libarchive that is not compatible. Because of how conda works, we can't specify a minimum required build; only minimum required version.

You should be able to fix things by downloading https://repo.anaconda.com/pkgs/main/osx-64/libarchive-3.3.3-h786848e_5.tar.bz2 and extract it into your miniconda or anaconda install folder. This is a hack, but it should allow conda to function well enough to get you running again, and conda will just overwrite these files next time you update libarchive.

Thanks @msarahan, that's a huge help. However, it looks like that's the version I already had. At least, doing as you suggested, i.e.:

cd ~/anaconda/
tar -xjvf ~/Downloads/libarchive-3.3.3-h786848e_5.tar.bz2

and I get the same error, which isn't surprising now that I see that the version is the same.

I also tried extracting another version on my system, pkgs/libarchive-3.3.2-h2f80186_5.tar.bz2, but no luck there either.

afaict, I'm extracting in the right place; otool -L lib/libarchive.dylib shows the version changing when I extract from the different versions. Any other ideas? Is it maybe some dependency of libarchive that's causing the problems?

Certainly could be another dependency. Our preview miniconda installers are at https://repo.anaconda.com/pkgs/misc/previews/miniconda/4.7.5/

It may be easier to install that somewhere, and then use a tool like "Beyond Compare" to diff the folders. Or just install that, and hopefully it works, and you can move on. It would be nice to understand this problem so we can address it in the future, though.

Alright, I'll investigate a little further, thanks. In case you know more than I do (which is almost a guarantee), I'm following this:

$ otool -L lib/libarchive.13.dylib
lib/libarchive.13.dylib:
    @rpath/libarchive.13.dylib (compatibility version 17.0.0, current version 17.3.0)
    @rpath/liblzo2.2.dylib (compatibility version 2.0.0, current version 2.0.0)
    @rpath/libzstd.1.3.7.dylib (compatibility version 1.3.7, current version 0.0.0)
    @rpath/liblz4.1.dylib (compatibility version 1.0.0, current version 1.8.1)
    @rpath/libbz2.dylib (compatibility version 0.0.0, current version 0.0.0)
    @rpath/libxml2.2.dylib (compatibility version 12.0.0, current version 12.8.0)
    /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1197.1.1)
    @rpath/libz.1.dylib (compatibility version 1.0.0, current version 1.2.11)
    @rpath/liblzma.5.dylib (compatibility version 8.0.0, current version 8.4.0)
    @rpath/libiconv.2.dylib (compatibility version 9.0.0, current version 9.0.0)

to look for problems in the dependencies...

zstd stands out there. Try downloading that one manually and doing what you did with libarchive.

Unfortunately, it again looks like that's the one I had. Based on my report up top, I'm trying to install older versions of python-libarchive, but so far no luck

Yeah... I'd just start with a clean miniconda to another path as a sanity check.

I installed miniconda2 and immediately hit:

$ ~/miniconda2/bin/conda update conda
Traceback (most recent call last):
  File "/Users/adam/miniconda2/bin/conda", line 13, in <module>
    sys.exit(main())
  File "/Users/adam/miniconda2/lib/python2.7/site-packages/conda/cli/main.py", line 150, in main
    return conda_exception_handler(_main, *args, **kwargs)
  File "/Users/adam/miniconda2/lib/python2.7/site-packages/conda/exceptions.py", line 1335, in conda_exception_handler
    return_value = exception_handler(func, *args, **kwargs)
  File "/Users/adam/miniconda2/lib/python2.7/site-packages/conda/exceptions.py", line 1046, in __call__
    return self.handle_exception(exc_val, exc_tb)
  File "/Users/adam/miniconda2/lib/python2.7/site-packages/conda/exceptions.py", line 1090, in handle_exception
    return self.handle_unexpected_exception(exc_val, exc_tb)
  File "/Users/adam/miniconda2/lib/python2.7/site-packages/conda/exceptions.py", line 1101, in handle_unexpected_exception
    self.print_unexpected_error_report(error_report)
  File "/Users/adam/miniconda2/lib/python2.7/site-packages/conda/exceptions.py", line 1171, in print_unexpected_error_report
    from .cli.main_info import get_env_vars_str, get_main_info_str
  File "/Users/adam/miniconda2/lib/python2.7/site-packages/conda/cli/main_info.py", line 19, in <module>
    from ..core.index import _supplement_index_with_system
  File "/Users/adam/miniconda2/lib/python2.7/site-packages/conda/core/index.py", line 9, in <module>
    from .package_cache_data import PackageCacheData
  File "/Users/adam/miniconda2/lib/python2.7/site-packages/conda/core/package_cache_data.py", line 15, in <module>
    from conda_package_handling.api import InvalidArchiveError
  File "/Users/adam/miniconda2/lib/python2.7/site-packages/conda_package_handling/api.py", line 3, in <module>
    from libarchive.exception import ArchiveError as _LibarchiveArchiveError
  File "/Users/adam/miniconda2/lib/python2.7/site-packages/libarchive/__init__.py", line 1, in <module>
    from .entry import ArchiveEntry
  File "/Users/adam/miniconda2/lib/python2.7/site-packages/libarchive/entry.py", line 6, in <module>
    from . import ffi
  File "/Users/adam/miniconda2/lib/python2.7/site-packages/libarchive/ffi.py", line 27, in <module>
    libarchive = ctypes.cdll.LoadLibrary(libarchive_path)
  File "/Users/adam/miniconda2/lib/python2.7/ctypes/__init__.py", line 444, in LoadLibrary
    return self._dlltype(name)
  File "/Users/adam/miniconda2/lib/python2.7/ctypes/__init__.py", line 366, in __init__
    self._handle = _dlopen(self._name, mode)
OSError: dlopen(/Users/adam/miniconda2/bin/../lib/libarchive.dylib, 6): Library not loaded: @rpath/libxml2.2.dylib
  Referenced from: /Users/adam/miniconda2/lib/libarchive.13.dylib
  Reason: Incompatible library version: libarchive.dylib requires version 12.0.0 or later, but libxml2.2.dylib provides version 10.0.0

so now I suspect there's some global environmental variable screwing with my library paths.

alright, cleaning out my environment fixed miniconda but not conda. At least, though, it changed the behavior of conda.

This works:

LD_LIBRARY_PATH="" DYLD_LIBRARY_PATH="" DYLD_FALLBACK_LIBRARY_PATH="" ~/miniconda2/bin/concda update conda

This now gives me a different error:

LD_LIBRARY_PATH="" DYLD_LIBRARY_PATH="" DYLD_FALLBACK_LIBRARY_PATH="" ~/anaconda/bin/conda update conda

->

AttributeError: dlsym(RTLD_DEFAULT, archive_read_open_filename_w): symbol not found

I tried copying over the files from miniconda2 and think I ran over a bug in libarchive:

$ LD_LIBRARY_PATH="" DYLD_LIBRARY_PATH="" DYLD_FALLBACK_LIBRARY_PATH="" ~/anaconda/bin/conda update conda
Traceback (most recent call last):
... cut ...
  File "/Users/adam/anaconda/lib/python2.7/site-packages/libarchive/entry.py", line 6, in <module>
    from . import ffi
  File "/Users/adam/anaconda/lib/python2.7/site-packages/libarchive/ffi.py", line 36, in <module>
    os.environ['PATH'] = os.pathsep.join((new_path, backup_PATH))
NameError: name 'new_path' is not defined

which is caused by this:

 29 if not libarchive_path:
 30     if sys.platform == 'win32' and not libarchive_path:
 31         new_path = os.path.join(sys.prefix, 'Library', 'bin')
 32     elif sys.platform == 'darwin':
 33         libarchive_path = os.path.join(sys.prefix, 'lib')
 34     elif sys.platform.startswith('linux'):
 35         new_path_path = os.path.join(sys.prefix, 'lib')
 36     os.environ['PATH'] = os.pathsep.join((new_path, backup_PATH))

which fails because libarchive_path should probably be new_path on line 33? But I can't find the source code for this package to submit a PR... it wasn't the obvious google hits.

EDIT: correcting that apparent error returned me to

AttributeError: dlsym(RTLD_DEFAULT, archive_read_open_filename_w): symbol not found

I gave up and overwrote everything in ~/anaconda from ~/miniconda2, and that solved the problem, though I still have to clean my environment before running conda commands, which was not true prior to the update at the top of this issue. Unfortunately, I may have hidden the underlying problem in this process, but at least I've hacked my way back to a functional system. Thanks.

EDIT: nope, that broke some paths, so I'm probably in a worse place than before...

OK, when fixing that, note that line 35 above should probably be new_path instead of new_path_path too

What does "that broke some paths" look like? Is that worth exploring?

whenever I do things with conda (besides update conda), it defaults to the miniconda path:

$ LD_LIBRARY_PATH="" DYLD_LIBRARY_PATH="" DYLD_FALLBACK_LIBRARY_PATH="" ~/anaconda/bin/conda install -n astropy36mpl2 osmapi

EnvironmentLocationNotFound: Not a conda environment: /Users/adam/miniconda2/envs/astropy36mpl2

That's the shell function stuff. If you re-run conda init, it should get fixed.

That doesn't solve it, unfortunately. I'm just going to make a clean environment at this point, I think.

Also, conda init has started writing to my .bash_profile instead of my .bashrc, which it did previously. Since .bash_profile didn't exist and supercedes .bashrc, apparently, that had a lot of unintended consequences, including wiping my bash history... that's unrelated to this, but I'm now very afraid of using conda init.

Yikes. Sorry about that. I'm not sure if there are issues that capture that - if you don't mind, please file a separate issue. conda init is more global than I would like, but I'm also not sure how to do what it does in a more isolated way.

The fixed build of python-libarchive-c is up (build 9)

same issue, do we have a fix for it?

If you have any of these variables set, that's probably the problem. By setting these, you are interfering with the programs in your conda environment and how they find their libraries.

LD_LIBRARY_PATH
DYLD_LIBRARY_PATH
DYLD_FALLBACK_LIBRARY_PATH

nope, none of them are set for me.

We need more info about your installation. You probably can't run conda info right now, but can you post otool results, as demonstrated by @keflavich?

otool -L lib/libarchive.13.dylib

I had the same dependencies as @keflavich and tried updating the versions for libarchive but with no success.
Now i am going for a fresh install of miniconda!

P.S. also tried updating the libarchive as mentioned by @eelretep. That didnt help either and i started getting this error:


Vendor:  continuum
Product: anaconda
Message: trial mode expires in 28 days
/Users/shubham/softwares/anaconda/lib/python2.7/site-packages/cryptography/hazmat/primitives/constant_time.py:26: CryptographyDeprecationWarning: Support for your Python version is deprecated. The next version of cryptography will remove support. Please upgrade to a release (2.7.7+) that supports hmac.compare_digest as soon as possible.
  utils.PersistentlyDeprecated2018,
WARNING conda.base.context:use_only_tar_bz2(632): Conda is constrained to only using the old .tar.bz2 file format because you have conda-build installed, and it is <3.18.3.  Update or remove conda-build to get smaller downloads and faster extractions.
Collecting package metadata (repodata.json): done
Solving environment: failed

PackagesNotFoundError: The following packages are not available from current channels:

  - pkgs/free/osx-64::libxslt==1.1.28=2 -> libxml2==2.9.0
  - pkgs/free/osx-64::lxml==3.6.4=py27_0 -> libxslt==1.1.28

Current channels:

  - https://repo.anaconda.com/pkgs/main/osx-64
  - https://repo.anaconda.com/pkgs/main/noarch
  - https://repo.anaconda.com/pkgs/r/osx-64
  - https://repo.anaconda.com/pkgs/r/noarch

To search for alternate channels that may provide the conda package you're
looking for, navigate to

    https://anaconda.org

and use the search bar at the top of the page.

Actually, updating libarchive did help - that is a new, different error. Please see https://www.anaconda.com/why-we-removed-the-free-channel-in-conda-4-7/

I'm having this same error. This thread is helpful...

facing a similar issue. every time I use conda update or conda install it raises following error:

AttributeError: dlsym(0x7fe5b8f12cf0, archive_read_open_filename_w): symbol not found

Same issue here:
AttributeError: dlsym(0x10055e1d0, archive_read_open_filename_w): symbol not found

The only thing I can could is conda --version, which is conda 4.7.5

I cannot figure this out yet. I tried many things to reproduce the error and came up blank. Sorry for anyone having trouble. The following works fine for me:

curl -SLO https://repo.anaconda.com/miniconda/Miniconda2-latest-MacOSX-x86_64.sh
bash ./Miniconda2-latest-MacOSX-x86_64.sh -bfp /tmp/mc2
. /tmp/mc2/bin/activate 
conda update conda
conda --version

I have the same issue. If I try condal list I get

AttributeError: dlsym(0x7f8595c66540, archive_read_open_filename_w): symbol not found

Following earlier posts, I also ran:

otool -L lib/libarchive.13.dylib
lib/libarchive.13.dylib:
    @rpath/libarchive.13.dylib (compatibility version 17.0.0, current version 17.3.0)
    @rpath/liblzo2.2.dylib (compatibility version 2.0.0, current version 2.0.0)
    @rpath/libzstd.1.3.7.dylib (compatibility version 1.3.7, current version 0.0.0)
    @rpath/liblz4.1.dylib (compatibility version 1.0.0, current version 1.8.1)
    @rpath/libbz2.dylib (compatibility version 0.0.0, current version 0.0.0)
    @rpath/libxml2.2.dylib (compatibility version 12.0.0, current version 12.8.0)
    /usr/lib/libSystem.B.dylib (compatibility version 1.0.0, current version 1197.1.1)
    @rpath/libz.1.dylib (compatibility version 1.0.0, current version 1.2.11)
    @rpath/liblzma.5.dylib (compatibility version 8.0.0, current version 8.4.0)
    @rpath/libiconv.2.dylib (compatibility version 9.0.0, current version 9.0.0)

Any help would be appreciated. Thanks.

Same issue here:
AttributeError: dlsym(0x10055e1d0, archive_read_open_filename_w): symbol not found

The only thing I can could is conda --version, which is conda 4.7.5

Some details that might help:
30 min before everything broke down:

  • I did conda install biopython, and succeeded.
  • I accidentally tried to open a .py script with Xcode, which failed, as usual, as I never update Xcode.
    Versions:
    macOS Mojave Version: 10.14.5 (18F132)
    Xcode Version: 8.3.3 (12175.1)

30 min after:

  • Typed conda list and got AttributeError.

I am not sure whether it is a coincidence, but I found another person running into the same conda issue after installing biopython.

Same problem. Started happening after I ran conda update -n base conda

conda --version gives 4.7.5.

@alanasweinstein or anyone else running into this issue, could you attach a copy of the conda-meta/history files from the root of the conda install? Even the last ~100 lines or so would be extremely helpful in debugging this issue.

@jjhelmus Apologies, I already deleted everything (rm -rf anaconda/) and did a clean reinstall. That did fix it, though! I suppose I'll just avoid running conda update for a while. Thanks for your response, hope someone else can provide that info.

@jjhelmus conda-meta/history is pasted here.

@jjhelmus I'm having the same issue. AttributeError: /usr/lib64/libarchive.so.2: undefined symbol: archive_read_open_filename_w.

Here is the last few chunks of my conda-meta/history:

https://pastebin.com/raw/cSd41JwY

@OXPHOS and @elsherbini Thanks for the history files, they were very useful.

I think I've nailed this down to an issue with the python-libarchive-c package. This wrapper will try to use libarchive from the system rather than the one included in the libarchive package and the system library may not be built with the required features enabled. The wrapped has been patched to prefer copy of the library provided in the conda package, see AnacondaRecipes/python-libarchive-c#2. New packages with this patch are available with a build number of 11. Conda will prefer this build to other builds so updates or install will get this change.

The more difficult part is updating to this build if the environment has the older broken build installed. Luckily the wrapper will use the library pointed to be the LIBARCHIVE environment variable which can be used to select the conda provided library.

On linux the following can be used to update python-libarchive-c:

LIBARCHIVE=${CONDA_PREFIX}/lib/libarchive.so conda update python-libarchive-c

On macOS:

LIBARCHIVE=${CONDA_PREFIX}/lib/libarchive.dylib conda update python-libarchive-c

@elsherbini The libarchive build that is installed may also cause issues. You may need to used the following if the above does not work:

CONDA_USE_ONLY_TAR_BZ2=1 LIBARCHIVE=${CONDA_PREFIX}/lib/libarchive.so conda update python-libarchive-c libarchive

Thanks! I'm running into another error:

OSError: libbz2.so.1.0: cannot open shared object file: No such file or directory

I'm doing this on an HPC environment that has some truly ancient versions installed of some things, so my case might be exceptional.

Is libbz2.so.1.0 in the lib directory of the conda environment?

No, but there is a libbz2.a in there.

You'll need libbz2.so.1.0 which is provide by the conda bzip2 package. Not sure how that got installed without the shared library.

Some of the bzip2 packages in the free channel only contain the static library, libbz2.a. If conda choose to install one of these packages it may be the cause of the issue. Downloading a bzip2 package from https://repo.anaconda.com/pkgs/main/linux-64/ and manually unpacking it into the conda environment should give you a working environment. You will want to update the bzip2 package in that environment.

Well, I ran into another issue when running LIBARCHIVE=path/to/anaconda/lib/libarchive.dylib conda update python-libarchive-c:

Executing transaction: - ERROR conda.core.link:_execute_post_link_actions(720): An error occurred while installing package 'defaults::qt-5.9.7-h468cd18_1'. LinkError: post-link script failed for package defaults::qt-5.9.7-h468cd18_1

(And 3 other failed installs)

And when I tried to get more feedback by adding -v as suggested, I found python is completely broken:

$ LIBARCHIVE=path/to/anaconda/lib/libarchive.dylib conda update python-libarchive-c -v
Traceback (most recent call last):
  File "/Users/zora/anaconda/bin/conda", line 13, in <module>
    sys.exit(main())
  File "/Users/zora/anaconda/lib/python2.7/site-packages/conda/cli/main.py", line 149, in main
    from ..exceptions import conda_exception_handler
  File "/Users/zora/anaconda/lib/python2.7/site-packages/conda/exceptions.py", line 19, in <module>
    from ._vendor.auxlib.entity import EntityEncoder
  File "/Users/zora/anaconda/lib/python2.7/site-packages/conda/_vendor/auxlib/entity.py", line 249, in <module>
    from enum import Enum
ImportError: No module named enum

Another example:

$ source activate envpy3.6
Traceback (most recent call last):
  File "/Users/zora/anaconda/bin/conda", line 13, in <module>
    sys.exit(main())
  File "/Users/zora/anaconda/lib/python2.7/site-packages/conda/cli/main.py", line 145, in main
    init_loggers()
  File "/Users/zora/anaconda/lib/python2.7/site-packages/conda/cli/main.py", line 56, in init_loggers
    from ..gateways.logging import initialize_logging, set_verbosity
  File "/Users/zora/anaconda/lib/python2.7/site-packages/conda/gateways/logging.py", line 14, in <module>
    from ..common.io import attach_stderr_handler
  File "/Users/zora/anaconda/lib/python2.7/site-packages/conda/common/io.py", line 7, in <module>
    from concurrent.futures import ProcessPoolExecutor, ThreadPoolExecutor, Executor, Future, _base, as_completed  # NOQA
ImportError: No module named concurrent.futures

Any thoughts on this? Thanks!

I unpacked the bzip2 package, and got a new error (full paste here: https://pastebin.com/raw/LmpNC2ae)

>LIBARCHIVE=/home/josephe/miniconda3/lib/libarchive.so conda update python-libarchive-c
...
UnsatisfiableError: The following specifications were found to be incompatible with each other:

  - r-crayon
  - r-dbi
  - r-dplyr -> r-dbi[version='>=0.4.1']
  - r-essentials -> r-dbi[version='>=1.0.0']
  - r-essentials -> r-dplyr[version='>=0.7.6'] -> r-tibble[version='>=2.0.0'] -> r-crayon[version='>=1.3.4']
  - r-gistr -> r-dplyr -> r-dbi[version='>=0.4.1']
  - r-irkernel -> r-crayon
  - r-plotly -> r-dplyr -> r-dbi[version='>=0.4.1']
  - r-purrr -> r-dplyr[version='>=0.4.3'] -> r-dbi[version='>=0.4.1']
  - r-rbokeh -> r-gistr -> r-dplyr -> r-dbi[version='>=0.4.1']

@elsherbini It may be easier to start from a fresh install of Miniconda/Anaconda and recreate you environment rather than trying to fix the existing one. This is not ideal but it may be quicker.

Another option is to install Miniconda in a different location and use conda install -p path_to_current_install libarchive to try to fix the issue. You can also download the libarchive package directly from repo.anaconda.com and pass the local path to conda install .... This bypasses the solver so if you choose an incompatible package you can end up breaking your environment further.

Just a note on @eelretep 's solution. It works for me, and he provides a link. But the key part of the link is the command export LIBARCHIVE=/usr/local/Cellar/libarchive/3.3.3/lib/libarchive.13.dylib which you should do after you do brew install libarchive. The part i want to point out is that make sure you check what version of libarchive actually exists on your system after your brew install. My brew install gave me 3.4.0, not 3.3.3, so if you just copy/paste the command directly, it won't work and will tell you the file doesn't exist. So just make sure to swap it out with the right version.

I cannot figure this out yet. I tried many things to reproduce the error and came up blank. Sorry for anyone having trouble. The following works fine for me:

curl -SLO https://repo.anaconda.com/miniconda/Miniconda2-latest-MacOSX-x86_64.sh
bash ./Miniconda2-latest-MacOSX-x86_64.sh -bfp /tmp/mc2
. /tmp/mc2/bin/activate 
conda update conda
conda --version

@mingwandroid this worked for me, thanks! I was having this issue today with conda 4.7.10. None of the brew suggestions worked for me.

Was this page helpful?
0 / 5 - 0 ratings