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-build --channel CHANNEL --override-channels always includes the "default" channel #5338

Closed
2 tasks done
truemerrill opened this issue May 13, 2024 · 1 comment
Closed
2 tasks done
Labels
duplicate indicate issues/PRs that are duplicates of another type::bug describes erroneous operation, use severity::* to classify the type

Comments

@truemerrill
Copy link

Checklist

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

What happened?

Issue

conda-build --help provides the following description of the --override-channels flag:

--override-channels   Do not search default or .condarc channels. Requires --channel.

But in fact the default channel is always searched. This is an issue for air-gapped machines where the default channel is unreachable but a local mirror is available. In such cases, conda-build will timeout while trying to fetch the index of http://repo.anaconda.org.

Why "default" always added

  • The conda-build main function eventually calls conda_build.environ.get_install_actions.
  • At line 861, get_install_actions calls conda_build.index.get_build_index without providing the omit_defaults keyword argument. The default value of omit_defaults is False.
  • Because omit_defaults is always set to the default value False, there is no possible command-line flag or .condarc setting that can ever make omit_defaults equal to True.
  • The effect of omit_defaults = False is that conda.core.index.calculate_channel_urls is called with the argument prepend = True. This adds the default channel to the list of channel URLs.
  • This contradicts the description of the --override-channels flag, since the default channel is always present.

Conda Info

libmamba version : 1.5.8
     micromamba version : 1.5.8
           curl version : libcurl/8.4.0 (SecureTransport) LibreSSL/3.3.6 zlib/1.2.12 nghttp2/1.58.0
     libarchive version : libarchive 3.5.3 zlib/1.2.12 liblzma/5.4.3 bz2lib/1.0.8
       envs directories : /Users/jmerrill3/.micromamba/envs
          package cache : /Users/jmerrill3/.micromamba/pkgs
                          /Users/jmerrill3/.mamba/pkgs
            environment : analysis (active)
           env location : /Users/jmerrill3/.micromamba/envs/analysis
      user config files : /Users/jmerrill3/.mambarc
 populated config files : /Users/jmerrill3/.condarc
       virtual packages : __unix=0=0
                          __osx=14.4.1=0
                          __archspec=1=arm64
               channels : https://repo.anaconda.com/pkgs/main/osx-arm64
                          https://repo.anaconda.com/pkgs/main/noarch
                          https://repo.anaconda.com/pkgs/r/osx-arm64
                          https://repo.anaconda.com/pkgs/r/noarch
                          https://conda.anaconda.org/conda-forge/osx-arm64
                          https://conda.anaconda.org/conda-forge/noarch
       base environment : /Users/jmerrill3/.micromamba
               platform : osx-arm64

Conda Config

Configuration files (by precedence order):
~/.condarc

Conda list

List of packages in environment: "/Users/jmerrill3/.micromamba/envs/analysis"

  Name                           Version     Build               Channel    
──────────────────────────────────────────────────────────────────────────────
  alabaster                      0.7.12      pyhd3eb1b0_0                   
  attrs                          23.1.0      py39hca03da5_0                 
  babel                          2.11.0      py39hca03da5_0                 
  beautifulsoup4                 4.12.2      py39hca03da5_0                 
  black                          24.3.0      py39hca03da5_0                 
  blas                           1.0         openblas                       
  boltons                        23.0.0      py39hca03da5_0                 
  bottleneck                     1.3.7       py39hbda83bc_0                 
  brotli                         1.0.9       h80987f9_8                     
  brotli-bin                     1.0.9       h80987f9_8                     
  brotli-python                  1.0.9       py39h313beb8_8                 
  bzip2                          1.0.8       h80987f9_6                     
  ca-certificates                2024.3.11   hca03da5_0                     
  cctools                        949.0.1     hc179dcd_25                    
  cctools_osx-arm64              949.0.1     h332cad3_25                    
  certifi                        2024.2.2    py39hca03da5_0                 
  cffi                           1.16.0      py39h80987f9_1                 
  chardet                        4.0.0       py39hca03da5_1003              
  charset-normalizer             2.0.4       pyhd3eb1b0_0                   
  click                          8.1.7       py39hca03da5_0                 
  colorama                       0.4.6       py39hca03da5_0                 
  conda                          23.7.4      py39hca03da5_0                 
  conda-build                    24.3.0      py39hca03da5_0                 
  conda-index                    0.4.0       pyhd3eb1b0_0                   
  conda-package-handling         2.0.2       py_0                conda      
  conda-package-streaming        0.9.0       py_0                conda      
  contourpy                      1.2.0       py39h48ca7d4_0                 
  cryptography                   42.0.5      py39hd4332d6_1                 
  cycler                         0.11.0      pyhd3eb1b0_0                   
  docutils                       0.18.1      py39hca03da5_3                 
  exceptiongroup                 1.2.0       py39hca03da5_0                 
  filelock                       3.13.1      py39hca03da5_0                 
  flake8                         7.0.0       py39hca03da5_0                 
  fonttools                      4.51.0      py39h80987f9_0                 
  freetype                       2.12.1      h1192e45_0                     
  icu                            73.1        h313beb8_0                     
  idna                           3.7         py39hca03da5_0                 
  imagesize                      1.4.1       py39hca03da5_0                 
  importlib-metadata             7.0.1       py39hca03da5_0                 
  importlib_resources            6.1.1       py39hca03da5_1                 
  iniconfig                      1.1.1       pyhd3eb1b0_0                   
  isort                          5.9.3       pyhd3eb1b0_0                   
  jinja2                         3.1.3       py39hca03da5_0                 
  jpeg                           9e          h80987f9_1                     
  jsonpatch                      1.33        py39hca03da5_1                 
  jsonpointer                    2.1         pyhd3eb1b0_0                   
  jsonschema                     4.19.2      py39hca03da5_0                 
  jsonschema-specifications      2023.7.1    py39hca03da5_0                 
  kiwisolver                     1.4.4       py39h313beb8_0                 
  lcms2                          2.12        hba8e193_0                     
  ld64                           530         hb29bf3f_25                    
  ld64_osx-arm64                 530         h001ce53_25                    
  ldid                           2.1.5       h20b2a84_3                     
  lerc                           3.0         hc377ac9_0                     
  libarchive                     3.6.2       h62fee54_3                     
  libbrotlicommon                1.0.9       h80987f9_8                     
  libbrotlidec                   1.0.9       h80987f9_8                     
  libbrotlienc                   1.0.9       h80987f9_8                     
  libcxx                         14.0.6      h848a8c0_0                     
  libdeflate                     1.17        h80987f9_1                     
  libffi                         3.4.4       hca03da5_1                     
  libgfortran                    5.0.0       11_3_0_hca03da5_28             
  libgfortran5                   11.3.0      h009349e_28                    
  libiconv                       1.16        h80987f9_3                     
  liblief                        0.12.3      h313beb8_0                     
  libllvm14                      14.0.6      h7ec7a93_3                     
  libopenblas                    0.3.21      h269037a_0                     
  libpng                         1.6.39      h80987f9_0                     
  libtiff                        4.5.1       h313beb8_0                     
  libwebp-base                   1.3.2       h80987f9_0                     
  libxml2                        2.10.4      h0b34f26_2                     
  llvm-openmp                    14.0.6      hc6e5704_0                     
  lz4-c                          1.9.4       h313beb8_1                     
  markupsafe                     2.1.3       py39h80987f9_0                 
  matplotlib                     3.8.4       py39hca03da5_0                 
  matplotlib-base                3.8.4       py39h46d7db6_0                 
  mccabe                         0.7.0       pyhd3eb1b0_0                   
  menuinst                       2.0.2       py39hca03da5_1                 
  more-itertools                 10.1.0      py39hca03da5_0                 
  mypy                           1.8.0       py39h80987f9_0                 
  mypy_extensions                1.0.0       py39hca03da5_0                 
  ncurses                        6.4         h313beb8_0                     
  numexpr                        2.8.7       py39hecc3335_0                 
  numpy                          1.26.4      py39h3b2db8e_0                 
  numpy-base                     1.26.4      py39ha9811e2_0                 
  openjpeg                       2.3.0       h7a6adac_2                     
  openssl                        3.0.13      h1a28f6b_1                     
  packaging                      23.2        py39hca03da5_0                 
  pandas                         2.2.1       py39h313beb8_0                 
  patch                          2.7.6       hca03da5_1001                  
  pathspec                       0.10.3      py39hca03da5_0                 
  patsy                          0.5.3       py39hca03da5_0                 
  pillow                         10.3.0      py39h80987f9_0                 
  pip                            24.0        py39hca03da5_0                 
  pkginfo                        1.9.6       py39hca03da5_0                 
  platformdirs                   3.10.0      py39hca03da5_0                 
  pluggy                         1.0.0       py39hca03da5_1                 
  psutil                         5.9.0       py39h1a28f6b_0                 
  py-lief                        0.12.3      py39h313beb8_0                 
  pybind11-abi                   4           hd3eb1b0_1                     
  pycodestyle                    2.11.1      py39hca03da5_0                 
  pycosat                        0.6.6       py39h80987f9_1                 
  pycparser                      2.21        pyhd3eb1b0_0                   
  pyflakes                       3.2.0       py39hca03da5_0                 
  pygments                       2.15.1      py39hca03da5_1                 
  pyopenssl                      24.0.0      py39hca03da5_0                 
  pyparsing                      3.0.9       py39hca03da5_0                 
  pysocks                        1.7.1       py39hca03da5_0                 
  pytest                         7.4.0       py39hca03da5_0                 
  python                         3.9.19      hb885b13_1                     
  python-dateutil                2.9.0post0  py39hca03da5_0                 
  python-libarchive-c            2.9         pyhd3eb1b0_1                   
  python-tzdata                  2023.3      pyhd3eb1b0_0                   
  pytz                           2024.1      py39hca03da5_0                 
  pyyaml                         6.0.1       py39h80987f9_0                 
  readline                       8.2         h1a28f6b_0                     
  referencing                    0.30.2      py39hca03da5_0                 
  requests                       2.31.0      py39hca03da5_1                 
  rpds-py                        0.10.6      py39hf0e4da2_0                 
  ruamel.yaml                    0.17.21     py39h1a28f6b_0                 
  ruamel.yaml.clib               0.2.6       py39h1a28f6b_1                 
  scipy                          1.13.0      py39h20cbe94_0                 
  seaborn                        0.13.2      hd8ed1ab_2          conda-forge
  seaborn-base                   0.13.2      pyhd8ed1ab_2        conda-forge
  setuptools                     69.5.1      py39hca03da5_0                 
  six                            1.16.0      pyhd3eb1b0_1                   
  snowballstemmer                2.2.0       pyhd3eb1b0_0                   
  soupsieve                      2.5         py39hca03da5_0                 
  sphinx                         5.0.2       py39hca03da5_0                 
  sphinxcontrib-applehelp        1.0.2       pyhd3eb1b0_0                   
  sphinxcontrib-devhelp          1.0.2       pyhd3eb1b0_0                   
  sphinxcontrib-htmlhelp         2.0.0       pyhd3eb1b0_0                   
  sphinxcontrib-jsmath           1.0.1       pyhd3eb1b0_0                   
  sphinxcontrib-qthelp           1.0.3       pyhd3eb1b0_0                   
  sphinxcontrib-serializinghtml  1.1.5       pyhd3eb1b0_0                   
  sqlite                         3.45.3      h80987f9_0                     
  statsmodels                    0.14.0      py39hbda83bc_0                 
  tapi                           1100.0.11   h8754e6a_1                     
  tk                             8.6.14      h6ba3021_0                     
  tomli                          2.0.1       py39hca03da5_0                 
  toolz                          0.12.0      py39hca03da5_0                 
  tornado                        6.3.3       py39h80987f9_0                 
  tqdm                           4.66.2      py39h33ce5c2_0                 
  typing-extensions              4.11.0      py39hca03da5_0                 
  typing_extensions              4.11.0      py39hca03da5_0                 
  tzdata                         2024a       h04d1e81_0                     
  unicodedata2                   15.1.0      py39h80987f9_0                 
  urllib3                        2.1.0       py39hca03da5_1                 
  wheel                          0.43.0      py39hca03da5_0                 
  xz                             5.4.6       h80987f9_1                     
  yaml                           0.2.5       h1230e6a_0                     
  zipp                           3.17.0      py39hca03da5_0                 
  zlib                           1.2.13      h18a0788_1                     
  zstandard                      0.22.0      py39h1a4646a_0                 
  zstd                           1.5.5       hd90d995_2

Additional Context

No response

@truemerrill truemerrill added the type::bug describes erroneous operation, use severity::* to classify the type label May 13, 2024
@kenodegard kenodegard added the duplicate indicate issues/PRs that are duplicates of another label May 14, 2024
@kenodegard
Copy link
Contributor

This was previously reported in #3693 and the fix is included in the conda-build 24.5.0 release from earlier today!

@kenodegard kenodegard closed this as not planned Won't fix, can't repro, duplicate, stale May 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate indicate issues/PRs that are duplicates of another type::bug describes erroneous operation, use severity::* to classify the type
Projects
Status: 🏁 Done
Development

No branches or pull requests

2 participants