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

Always error message "Could not load conda plugin 'conda-libmamba-solver'" and "CondaSSLError: OpenSSL appears to be unavailable on this machine. OpenSSL is required to download and install packages." #388

Open
2 tasks done
big-boo1 opened this issue Nov 20, 2023 · 4 comments
Labels
type::bug describes erroneous operation, use severity::* to classify the type

Comments

@big-boo1
Copy link

Checklist

  • I added a descriptive title
  • I searched open reports and couldn't find a duplicate

What happened?

I'm very new to this so bear with me. I'm coding in the terminal shell, trying to do learn bioinformatics and doing RNAseq. Anaconda worked for me until a few hours ago. After trying to install packages, I get the errors:

Could not load conda plugin conda-libmamba-solver:

dlopen(/Users/me/miniconda3/lib/python3.11/site-packages/libmambapy/bindings.cpython-311-darwin.so, 2): Library not loaded: @rpath/libcrypto.3.dylib
Referenced from: /Users/me/miniconda3/lib/libmamba.2.0.0.dylib
Reason: no suitable image found. Did find:
/Users/me/miniconda3/lib/libcrypto.3.dylib: mach-o, but wrong architecture
/Users/me/miniconda3/lib/python3.11/site-packages/libmambapy/../../../libcrypto.3.dylib: mach-o, but wrong architecture
/Users/me/miniconda3/bin/../lib/libcrypto.3.dylib: mach-o, but wrong architecture
Collecting package metadata (current_repodata.json): failed

CondaSSLError: OpenSSL appears to be unavailable on this machine. OpenSSL is required to
download and install packages.

Exception: HTTPSConnectionPool(host='conda.anaconda.org', port=443): Max retries exceeded with url: /bioconda/osx-64/current_repodata.json (Caused by SSLError("Can't connect to HTTPS URL because the SSL module is not available."))

I'm unsure what caused this as I could install packages before, but now this issue keeps happening. I tried the following work arounds.

  set SSL_NO_VERIFY=1

Same error as above

 Copy and paste libcrypto.dll and libssl.3.dll from bin folder to dib folder

I don't have these files in my bin folder, however in lib folder I have libcrypto.dylib and libssl.3.dylib

   conda update --all

Same error as above

  pip install 'samtools'

WARNING: pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.
WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError("Can't connectto HTTPS URL because the SSL module is not available.")': /simple/samtools/
WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError("Can't connectto HTTPS URL because the SSL module is not available.")': /simple/samtools/
WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError("Can't connectto HTTPS URL because the SSL module is not available.")': /simple/samtools/
WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError("Can't connectto HTTPS URL because the SSL module is not available.")': /simple/samtools/
WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError("Can't connectto HTTPS URL because the SSL module is not available.")': /simple/samtools/
Could not fetch URL https://pypi.org/simple/samtools/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/samtools/ (Caused by SSLError("Can't connect to HTTPS URL because the SSL module is not available.")) - skipping
ERROR: Could not find a version that satisfies the requirement samtools (from versions: none)
ERROR: No matching distribution found for samtools

Any help you have would be much appreciated. Thank you.

Conda Info

Could not load conda plugin `conda-libmamba-solver`:

dlopen(/Users/me/miniconda3/lib/python3.11/site-packages/libmambapy/bindings.cpython-311-darwin.so, 2): Library not loaded: @rpath/libcrypto.3.dylib
  Referenced from: /Users/me/miniconda3/lib/libmamba.2.0.0.dylib
  Reason: no suitable image found.  Did find:
        /Users/me/miniconda3/lib/libcrypto.3.dylib: mach-o, but wrong architecture
        /Users/me/miniconda3/lib/python3.11/site-packages/libmambapy/../../../libcrypto.3.dylib: mach-o, but wrong architecture
        /Users/me/miniconda3/bin/../lib/libcrypto.3.dylib: mach-o, but wrong architecture

     active environment : base
    active env location : /Users/me/miniconda3
            shell level : 2
       user config file : /Users/me/.condarc
 populated config files : /Users/me/.condarc
          conda version : 23.5.2
    conda-build version : not installed
         python version : 3.11.4.final.0
       virtual packages : __archspec=1=arm64
                          __osx=11.0.1=0
                          __unix=0=0
       base environment : /Users/me/miniconda3  (writable)
      conda av data dir : /Users/me/miniconda3/etc/conda
  conda av metadata url : None
           channel URLs : https://conda.anaconda.org/conda-forge/osx-64
                          https://conda.anaconda.org/bioconda/osx-64
                          https://conda.anaconda.org/r/osx-64
                          https://repo.anaconda.com/pkgs/main/osx-64
                          https://repo.anaconda.com/pkgs/free/osx-64
                          https://repo.anaconda.com/pkgs/r/osx-64
          package cache : /Users/me/miniconda3/pkgs
                          /Users/me/.conda/pkgs
       envs directories : /Users/me/miniconda3/envs
                          /Users/me/.conda/envs
               platform : osx-arm64
             user-agent : conda/23.5.2 requests/2.29.0 CPython/3.11.4 Darwin/20.1.0 OSX/11.0.1
                UID:GID : 501:20
             netrc file : None
           offline mode : False

Conda Config

Could not load conda plugin `conda-libmamba-solver`:

dlopen(/Users/me/miniconda3/lib/python3.11/site-packages/libmambapy/bindings.cpython-311-darwin.so, 2): Library not loaded: @rpath/libcrypto.3.dylib
  Referenced from: /Users/me/miniconda3/lib/libmamba.2.0.0.dylib
  Reason: no suitable image found.  Did find:
        /Users/me/miniconda3/lib/libcrypto.3.dylib: mach-o, but wrong architecture
        /Users/me/miniconda3/lib/python3.11/site-packages/libmambapy/../../../libcrypto.3.dylib: mach-o, but wrong architecture
        /Users/me/miniconda3/bin/../lib/libcrypto.3.dylib: mach-o, but wrong architecture
==> /Users/me/.condarc <==
allow_conda_downgrades: True
subdirs:
  - osx-64
ssl_verify: False
channels:
  - conda-forge
  - bioconda
  - r
  - defaults
restore_free_channel: True

Conda list

Could not load conda plugin `conda-libmamba-solver`:

dlopen(/Users/me/miniconda3/lib/python3.11/site-packages/libmambapy/bindings.cpython-311-darwin.so, 2): Library not loaded: @rpath/libcrypto.3.dylib
  Referenced from: /Users/me/miniconda3/lib/libmamba.2.0.0.dylib
  Reason: no suitable image found.  Did find:
        /Users/me/miniconda3/lib/libcrypto.3.dylib: mach-o, but wrong architecture
        /Users/me/miniconda3/lib/python3.11/site-packages/libmambapy/../../../libcrypto.3.dylib: mach-o, but wrong architecture
        /Users/me/miniconda3/bin/../lib/libcrypto.3.dylib: mach-o, but wrong architecture
# packages in environment at /Users/me/miniconda3:
#
# Name                    Version                   Build  Channel
boltons                   23.0.0          py311hca03da5_0    defaults
brotlipy                  0.7.0           py311h80987f9_1002    defaults
bzip2                     1.0.8                h620ffc9_4    defaults
c-ares                    1.19.0               h80987f9_0    defaults
ca-certificates           2023.11.17           h8857fd0_0    conda-forge
certifi                   2023.7.22       py311hca03da5_0    anaconda
cffi                      1.15.1          py311h80987f9_3    defaults
charset-normalizer        2.0.4              pyhd3eb1b0_0    defaults
conda                     23.5.2          py311hca03da5_0    defaults
conda-content-trust       0.1.3           py311hca03da5_0    defaults
conda-libmamba-solver     23.5.0          py311hca03da5_0    defaults
conda-package-handling    2.1.0           py311hca03da5_0    defaults
conda-package-streaming   0.8.0           py311hca03da5_0    defaults
cryptography              39.0.1          py311h834c97f_2    defaults
fmt                       9.1.0                h48ca7d4_0    defaults
hisat2                    2.2.1                hb19a6fa_5    bioconda
icu                       68.1                 hc377ac9_0    defaults
idna                      3.4             py311hca03da5_0    defaults
jsonpatch                 1.32               pyhd3eb1b0_0    defaults
jsonpointer               2.1                pyhd3eb1b0_0    defaults
krb5                      1.20.1               hf3e1bf2_1    defaults
libarchive                3.6.2                h62fee54_2    defaults
libcurl                   8.1.1                h3e2b118_1    defaults
libcxx                    14.0.6               h848a8c0_0    defaults
libedit                   3.1.20221030         h80987f9_0    defaults
libev                     4.33                 h1a28f6b_1    defaults
libffi                    3.4.4                hca03da5_0    defaults
libiconv                  1.16                 h1a28f6b_2    defaults
libidn2                   2.3.4                h80987f9_0    anaconda
libmamba                  1.4.1                h1c5506f_1    defaults
libmambapy                1.4.1           py311h1c5506f_1    defaults
libnghttp2                1.52.0               h62f6fdd_1    defaults
libsolv                   0.7.22               h98b2900_0    defaults
libssh2                   1.10.0               h02f6b3c_2    defaults
libunistring              0.9.10               h1a28f6b_0    anaconda
libxml2                   2.10.3               h372ba2a_0    defaults
lz4-c                     1.9.4                h313beb8_0    defaults
ncurses                   6.4                  h313beb8_0    defaults
openssl                   3.1.4                hd75f5a5_0    conda-forge
packaging                 23.0            py311hca03da5_0    defaults
pcre2                     10.37                h37e8eca_1    defaults
perl                      5.32.1          4_h0dc2134_perl5    conda-forge
pip                       23.1.2          py311hca03da5_0    defaults
pluggy                    1.0.0           py311hca03da5_1    defaults
pybind11-abi              4                    hd3eb1b0_1    defaults
pycosat                   0.6.4           py311h80987f9_0    defaults
pycparser                 2.21               pyhd3eb1b0_0    defaults
pyopenssl                 23.0.0          py311hca03da5_0    defaults
pysocks                   1.7.1           py311hca03da5_0    defaults
python                    3.11.4               hb885b13_0    defaults
python.app                3               py311h80987f9_0    defaults
readline                  8.2                  h1a28f6b_0    defaults
reproc                    14.2.4               hc377ac9_1    defaults
reproc-cpp                14.2.4               hc377ac9_1    defaults
requests                  2.29.0          py311hca03da5_0    defaults
ruamel.yaml               0.17.21         py311h80987f9_0    defaults
setuptools                67.8.0          py311hca03da5_0    defaults
six                       1.16.0             pyhd3eb1b0_1    defaults
sqlite                    3.41.2               h80987f9_0    defaults
tk                        8.6.12               hb8d0fd4_0    defaults
toolz                     0.12.0          py311hca03da5_0    defaults
tqdm                      4.65.0          py311hb6e6a13_0    defaults
tzdata                    2023c                h04d1e81_0    defaults
urllib3                   1.26.16         py311hca03da5_0    defaults
wget                      1.21.4               h3e2b118_1    anaconda
wheel                     0.38.4          py311hca03da5_0    defaults
xz                        5.4.2                h80987f9_0    defaults
yaml-cpp                  0.7.0                hc377ac9_1    defaults
zlib                      1.2.13               h5a0b063_0    defaults
zstandard                 0.19.0          py311h80987f9_0    defaults
zstd                      1.5.5                hd90d995_0    defaults

Additional Context

I've installed a few packages such as hisat2, trying to install samtools.
Thanks

@big-boo1 big-boo1 added the type::bug describes erroneous operation, use severity::* to classify the type label Nov 20, 2023
@jaimergp
Copy link
Contributor

jaimergp commented Nov 20, 2023

Your openssl package is coming from conda-forge, while most of your environment is based on defaults. This is likely a cause for incompatibilities. Probably caused when you installed perl via hisat?

If your primary use is going to be bioinformatics via bioconda, I'd recommend you don't mix defaults. The best way to do this is to start with the Miniforge installer instead of Miniconda.

That said, we have some solutions available now that do not involve reinstalling everything.

  1. Grab conda-standalone for your platform from here. Even if you are on Apple Silicon the osx-64 should work ok as long as you have configured Rosetta on your system.
  2. Run conda-standalone install --override-channels -c defaults --solver=libmamba -p path/to/your/conda/installation openssl
  3. If this doesn't work (conflicts), we'll try the opposite: convert everything to conda-forge. conda-standalone update --all --override-channels -c bioconda -c conda-forge --solver=libmamba -p path/to/your/conda/installation
  4. If that doesn't work either, then please consider removing your Miniconda installation and starting with Miniforge instead.

Let me know how it goes!

@big-boo1
Copy link
Author

Your openssl package is coming from conda-forge, while most of your environment is based on defaults. This is likely a cause for incompatibilities. Probably caused when you installed perl via hisat?

If your primary use is going to be bioinformatics via bioconda, I'd recommend you don't mix defaults. The best way to do this is to start with the Miniforge installer instead of Miniconda.

That said, we have some solutions available now that do not involve reinstalling everything.

  1. Grab conda-standalone for your platform from here. Even if you are on Apple Silicon the osx-64 should work ok as long as you have configured Rosetta on your system.
  2. Run conda-standalone install --override-channels -c defaults --solver=libmamba -p path/to/your/conda/installation openssl
  3. If this doesn't work (conflicts), we'll try the opposite: convert everything to conda-forge. conda-standalone update --all --override-channels -c bioconda -c conda-forge --solver=libmamba -p path/to/your/conda/installation
  4. If that doesn't work either, then please consider removing your Miniconda installation and starting with Miniforge instead.

Let me know how it goes!

Hi, thanks for all the tips. So I tried the first 2, and ran into issues, and eventually decided it'd be easiest to uninstall anaconda3 and then I downloaded miniforge, and reinstalled anaconda using that. Now, I have samtools working and am not running into the errors. So all good for now.

Thank you again.

@big-boo1
Copy link
Author

Your openssl package is coming from conda-forge, while most of your environment is based on defaults. This is likely a cause for incompatibilities. Probably caused when you installed perl via hisat?
If your primary use is going to be bioinformatics via bioconda, I'd recommend you don't mix defaults. The best way to do this is to start with the Miniforge installer instead of Miniconda.
That said, we have some solutions available now that do not involve reinstalling everything.

  1. Grab conda-standalone for your platform from here. Even if you are on Apple Silicon the osx-64 should work ok as long as you have configured Rosetta on your system.
  2. Run conda-standalone install --override-channels -c defaults --solver=libmamba -p path/to/your/conda/installation openssl
  3. If this doesn't work (conflicts), we'll try the opposite: convert everything to conda-forge. conda-standalone update --all --override-channels -c bioconda -c conda-forge --solver=libmamba -p path/to/your/conda/installation
  4. If that doesn't work either, then please consider removing your Miniconda installation and starting with Miniforge instead.

Let me know how it goes!

Hi, thanks for all the tips. So I tried the first 2, and ran into issues, and eventually decided it'd be easiest to uninstall anaconda3 and then I downloaded miniforge, and reinstalled anaconda using that. Now, I have samtools working and am not running into the errors. So all good for now.

Thank you again.

Ok so now I try to install a new package, stringtie, but get the error.

environment variables:
CIO_TEST=
CONDA_DEFAULT_ENV=base
CONDA_EXE=/Users/me/miniforge3/bin/conda
CONDA_PREFIX=/Users/me/miniforge3
CONDA_PREFIX_1=/Users/me/miniforge3
CONDA_PREFIX_2=/Users/me/env
CONDA_PROMPT_MODIFIER=(base)
CONDA_PYTHON_EXE=/Users/me/miniforge3/bin/python
CONDA_ROOT=/Users/me/miniforge3
CONDA_SHLVL=3
CURL_CA_BUNDLE=
INFOPATH=/opt/homebrew/share/info:
LD_PRELOAD=
MANPATH=/opt/homebrew/share/man::
PATH=/Users/me/miniforge3/bin:/Users/me/miniforge3/condabin
:/opt/homebrew/bin:/opt/homebrew/sbin:/usr/local/bin:/usr/bin:/bin:/us
r/sbin:/sbin:/opt/X11/bin
REQUESTS_CA_BUNDLE=
SSL_CERT_FILE=

 active environment : base
active env location : /Users/me/miniforge3
        shell level : 3
   user config file : /Users/me/.condarc

populated config files : /Users/me/miniforge3/.condarc
/Users/me/.condarc
conda version : 23.3.1
conda-build version : not installed
python version : 3.10.12.final.0
virtual packages : __archspec=1=x86_64
__osx=11.0.1=0
__unix=0=0
base environment : /Users/me/miniforge3 (writable)
conda av data dir : /Users/me/miniforge3/etc/conda
conda av metadata url : None
channel URLs : https://conda.anaconda.org/bioconda/osx-64
https://conda.anaconda.org/bioconda/noarch
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
https://conda.anaconda.org/conda-forge/osx-64
https://conda.anaconda.org/conda-forge/noarch
package cache : /Users/me/miniforge3/pkgs
/Users/me/.conda/pkgs
envs directories : /Users/me/miniforge3/envs
/Users/me/.conda/envs
platform : osx-64
user-agent : conda/23.3.1 requests/2.31.0 CPython/3.10.12 Darwin/20.1.0 OSX/11.0.1
UID:GID : 501:20
netrc file : None
offline mode : False

An unexpected error has occurred. Conda has prepared the above report.

If submitted, this report will be used by core maintainers to improve
future releases of conda.

I'm not sure what's wrong with installing stringtie specifically, as the samtools install just before worked.

@jaimergp
Copy link
Contributor

Mixing anaconda and conda-forge in the base environment is going to lead to the same problems: a potentially broken conda installation. You should start with a fresh Miniforge and then install whatever you need for your project in a separate environment:

$ bash Miniforge-x.y.z.sh
$ conda create -n my-project-name -c bioconda samtools stringtie
$ conda activate my-project-name

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type::bug describes erroneous operation, use severity::* to classify the type
Projects
Status: 🆕 New
Development

No branches or pull requests

2 participants