QIIME2 2022.8 installation issue

I have tried to install the newest version of QIIME2 22.8 and got failed in environment creation. I tried several times and it kept failing:

(base) jinbingbai@Jinbings-iMac ~ % conda env create -n qiime2-2022.8 --file qiime2-2022.8-py38-osx-conda.yml
Solving environment: failed

ResolvePackageNotFound:

  • ipython=8.5.0
  • __osx
  • ipython=8.5.0
  • __linux
  • ipython=8.5.0
  • __win

Do you know what the problem is?

Recently, I am not sure what has happened, I generally activate my qiime2 using the following code:

source opt/miniconda3/bin/activate
source activate qiime2-2020.2

Please guide me how to update conda and install the newer version QIIME 2.

Thanks.

Hi @Bing,

Thanks for reaching out!

It looks like you're using OS X as your operating system - do you know if your Mac has an M1 or intel chip? Most folks with M1 Macs require slightly different install instructions compared to our standard conda install instructions for OS X.

If this is the case, please use the following commands to install QIIME 2 2022.8 on your machine:

wget https://data.qiime2.org/distro/core/qiime2-2022.8-py38-osx-conda.yml
CONDA_SUBDIR=osx-64 conda env create -n qiime2-2022.8 --file qiime2-2022.8-py38-osx-conda.yml
conda activate qiime2-2022.8
conda config --env --set subdir osx-64

If this is not the case, please try running the following command:

conda clean --all

This will remove your index cache, lock files, unused cache packages, and tarballs - but will leave all existing environments as-is.

Hope this helps! Cheers :lizard:

1 Like

@lizgehret I tried the codes and still not work. Here is my complete codes, could you check whether I did anything wrong at the beginning.

Last login: Fri Oct 14 01:15:47 on ttys000
jinbingbai@Jinbings-iMac ~ % source miniconda3/bin/activate
(base) jinbingbai@Jinbings-iMac ~ % conda update conda
Solving environment: done


==> WARNING: A newer version of conda exists. <==
  current version: 4.5.11
  latest version: 22.9.0

Please update conda by running

    $ conda update -n base -c defaults conda



# All requested packages already installed.

(base) jinbingbai@Jinbings-iMac ~ % conda install wget
Solving environment: done


==> WARNING: A newer version of conda exists. <==
  current version: 4.5.11
  latest version: 22.9.0

Please update conda by running

    $ conda update -n base -c defaults conda



# All requested packages already installed.

(base) jinbingbai@Jinbings-iMac ~ % wget https://data.qiime2.org/distro/core/qiime2-2022.8-py38-osx-conda.yml
--2022-10-14 01:23:57--  https://data.qiime2.org/distro/core/qiime2-2022.8-py38-osx-conda.yml
Resolving data.qiime2.org... 54.200.1.12
Connecting to data.qiime2.org|54.200.1.12|:443... connected.
HTTP request sent, awaiting response... 302 FOUND
Location: https://raw.githubusercontent.com/qiime2/environment-files/master/2022.8/release/qiime2-2022.8-py38-osx-conda.yml [following]
--2022-10-14 01:23:57--  https://raw.githubusercontent.com/qiime2/environment-files/master/2022.8/release/qiime2-2022.8-py38-osx-conda.yml
Resolving raw.githubusercontent.com... 2606:50c0:8003::154, 2606:50c0:8000::154, 2606:50c0:8001::154, ...
Connecting to raw.githubusercontent.com|2606:50c0:8003::154|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 8573 (8.4K) [text/plain]
Saving to: 'qiime2-2022.8-py38-osx-conda.yml.4'

qiime2-2022.8-py38- 100%[===================>]   8.37K  --.-KB/s    in 0s      

2022-10-14 01:23:57 (26.0 MB/s) - 'qiime2-2022.8-py38-osx-conda.yml.4' saved [8573/8573]

(base) jinbingbai@Jinbings-iMac ~ % CONDA_SUBDIR=osx-64 conda env create -n qiime2-2022.8 --file qiime2-2022.8-py38-osx-conda.yml
Solving environment: failed

ResolvePackageNotFound: 
  - ipython=8.5.0
  - __linux
  - ipython=8.5.0
  - __osx
  - ipython=8.5.0
  - __win

(base) jinbingbai@Jinbings-iMac ~ % conda env create -n qiime2-2022.8 --file qiime2-2022.8-py38-osx-conda.yml
Solving environment: failed

ResolvePackageNotFound: 
  - ipython=8.5.0
  - __osx
  - ipython=8.5.0
  - __linux
  - ipython=8.5.0
  - __win

(base) jinbingbai@Jinbings-iMac ~ % 

I also attached the folder of my previous QIIME 2 versions and not sure whether it has anything to do with these folder issues.

Thanks,
Bing

Hi @Bing,

Apologies for the delay in response! Thanks for providing these details/screenshots - it looks like your version of conda is pretty out of date - let's try updating that first and see if that resolves the issue. Please run the following command before re-running conda env create for QIIME 2 2022.8:

conda update conda

If that doesn't resolve the issue, we'll keep digging! :nerd_face:

1 Like

The issue seems the package directory, please see below. Please let me know how to set up the package directory before I run the conda update conda

Here are the errors when I run the codes:

jinbingbai@Jinbings-iMac ~ % conda list --name base conda

packages in environment at /Users/jinbingbai/opt/miniconda3:

Name Version Build Channel

conda 22.9.0 py37hecd8cb5_0
conda-package-handling 1.9.0 py37hca72f7f_0

jinbingbai@Jinbings-iMac ~ % conda update conda
Collecting package metadata (current_repodata.json): failed
WARNING conda.exceptions:print_unexpected_error_report(1251): KeyError('pkgs_dirs')
Traceback (most recent call last):
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/exceptions.py", line 1129, in call
return func(*args, **kwargs)
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/cli/main.py", line 86, in main_subshell
exit_code = do_call(args, p)
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/cli/conda_argparse.py", line 93, in do_call
return getattr(module, func_name)(args, parser)
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/notices/core.py", line 72, in wrapper
return_value = func(*args, **kwargs)
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/cli/main_update.py", line 22, in execute
install(args, parser, 'update')
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/cli/install.py", line 265, in install
should_retry_solve=(_should_retry_unfrozen or repodata_fn != repodata_fns[-1]),
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/core/solve.py", line 159, in solve_for_transaction
should_retry_solve)
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/core/solve.py", line 200, in solve_for_diff
force_remove, should_retry_solve)
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/core/solve.py", line 304, in solve_final_state
ssc = self._collect_all_metadata(ssc)
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/common/io.py", line 86, in decorated
return f(*args, **kwds)
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/core/solve.py", line 439, in _collect_all_metadata
_supplement_index_with_system(virtual_pkg_index)
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/core/index.py", line 172, in _supplement_index_with_system
cuda_version = context.cuda_version
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/auxlib/decorators.py", line 276, in new_fget
cache[inner_attname] = func(self)
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/common/decorators.py", line 24, in wrapper
return func(*args, **kwargs)
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/base/context.py", line 935, in cuda_version
return cuda_detect()
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/common/cuda.py", line 38, in cuda_detect
import ctypes
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/ctypes/init.py", line 7, in
from _ctypes import Union, Structure, Array
ImportError: dlopen(/Users/jinbingbai/opt/miniconda3/lib/python3.7/lib-dynload/_ctypes.cpython-37m-darwin.so, 2): Library not loaded: @rpath/libffi.6.dylib
Referenced from: /Users/jinbingbai/opt/miniconda3/lib/python3.7/lib-dynload/_ctypes.cpython-37m-darwin.so
Reason: image not found

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/exceptions.py", line 1249, in print_unexpected_error_report
message_builder.append(get_main_info_str(error_report['conda_info']))
File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/cli/main_info.py", line 237, in get_main_info_str
info_dict['_' + key] = ('\n' + 26 * ' ').join(info_dict[key])
KeyError: 'pkgs_dirs'

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

Traceback (most recent call last):
  File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/exceptions.py", line 1129, in __call__
    return func(*args, **kwargs)
  File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/cli/main.py", line 86, in main_subshell
    exit_code = do_call(args, p)
  File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/cli/conda_argparse.py", line 93, in do_call
    return getattr(module, func_name)(args, parser)
  File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/notices/core.py", line 72, in wrapper
    return_value = func(*args, **kwargs)
  File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/cli/main_update.py", line 22, in execute
    install(args, parser, 'update')
  File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/cli/install.py", line 265, in install
    should_retry_solve=(_should_retry_unfrozen or repodata_fn != repodata_fns[-1]),
  File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/core/solve.py", line 159, in solve_for_transaction
    should_retry_solve)
  File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/core/solve.py", line 200, in solve_for_diff
    force_remove, should_retry_solve)
  File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/core/solve.py", line 304, in solve_final_state
    ssc = self._collect_all_metadata(ssc)
  File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/common/io.py", line 86, in decorated
    return f(*args, **kwds)
  File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/core/solve.py", line 439, in _collect_all_metadata
    _supplement_index_with_system(virtual_pkg_index)
  File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/core/index.py", line 172, in _supplement_index_with_system
    cuda_version = context.cuda_version
  File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/auxlib/decorators.py", line 276, in new_fget
    cache[inner_attname] = func(self)
  File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/common/decorators.py", line 24, in wrapper
    return func(*args, **kwargs)
  File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/base/context.py", line 935, in cuda_version
    return cuda_detect()
  File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/site-packages/conda/common/cuda.py", line 38, in cuda_detect
    import ctypes
  File "/Users/jinbingbai/opt/miniconda3/lib/python3.7/ctypes/__init__.py", line 7, in <module>
    from _ctypes import Union, Structure, Array
ImportError: dlopen(/Users/jinbingbai/opt/miniconda3/lib/python3.7/lib-dynload/_ctypes.cpython-37m-darwin.so, 2): Library not loaded: @rpath/libffi.6.dylib
  Referenced from: /Users/jinbingbai/opt/miniconda3/lib/python3.7/lib-dynload/_ctypes.cpython-37m-darwin.so
  Reason: image not found

$ /Users/jinbingbai/opt/miniconda3/bin/conda update conda

environment variables:
conda info could not be constructed.
KeyError('pkgs_dirs')

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.
Would you like conda to send this report to the core maintainers? [y/N]:
Timeout reached. No report sent.

Hi @Bing,

Apologies for the delay!

This is interesting - let's try a couple of things.

Run the following:
conda clean --all

If that doesn't work, I would completely uninstall and re-install conda with the latest version. You can just use the install instructions on our docs page for this. Once that's completed, try installing QIIME 2 once more - this should hopefully resolve the issue!

Cheers :lizard:

1 Like

This is really helpful, I suggest put it on the Qiime 2 installation webpage since a lot of people are using Mac M1/M2 chip now.

Thanks @lizgehret. I ended up reinstalling everything. It works now.

This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.