question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

defauls packages are always installed regardless of the channels option

See original GitHub issue

I tipically use setup-miniconda to install packages from two or three channels, conda-forge, robotology or robostack. I never need/want to install packages from defaults. I tought that by using the channels options as shown in https://github.com/conda-incubator/setup-miniconda#example-4-conda-options the defaults channels should have low priority by default, but even in that case, if i try to install the compilers meta-package, packages from defaults are installed:

See https://github.com/traversaro/setup-miniconda-always-uses-default-mre/runs/3199430212 (related job: https://github.com/traversaro/setup-miniconda-always-uses-default-mre/blob/main/.github/workflows/install-compilers-only-conda-forge-based-on-ex4.yml) for an example of this:

2021-07-30T06:55:37.1491185Z   + _libgcc_mutex                      0.1  conda_forge    conda-forge/linux-64       3 KB
2021-07-30T06:55:37.1492319Z   + _openmp_mutex                      4.5  1_gnu          conda-forge/linux-64      22 KB
2021-07-30T06:55:37.1499003Z   + binutils                        2.36.1  hdd6e379_2     conda-forge/linux-64      27 KB
2021-07-30T06:55:37.1500414Z   + binutils_impl_linux-64          2.36.1  h193b22a_2     conda-forge/linux-64      10 MB
2021-07-30T06:55:37.1501953Z   + binutils_linux-64                 2.36  hf3e587d_33    conda-forge/linux-64      22 KB
2021-07-30T06:55:37.1503097Z   + bzip2                            1.0.8  h7f98852_4     conda-forge/linux-64     Cached
2021-07-30T06:55:37.1504025Z   + c-ares                          1.17.1  h7f98852_1     conda-forge/linux-64     Cached
2021-07-30T06:55:37.1505036Z   + c-compiler                       1.2.0  h7f98852_0     conda-forge/linux-64       6 KB
2021-07-30T06:55:37.1506366Z   + ca-certificates              2021.5.30  ha878542_0     conda-forge/linux-64     Cached
2021-07-30T06:55:37.1507325Z   + cmake                           3.21.1  h8897547_0     conda-forge/linux-64      15 MB
2021-07-30T06:55:37.1508214Z   + compilers                        1.2.0  ha770c72_0     conda-forge/linux-64       5 KB
2021-07-30T06:55:37.1509182Z   + cxx-compiler                     1.2.0  h4bd325d_0     conda-forge/linux-64       6 KB
2021-07-30T06:55:37.1510125Z   + expat                            2.4.1  h9c3ff4c_0     conda-forge/linux-64     182 KB
2021-07-30T06:55:37.1512088Z   + fortran-compiler                 1.2.0  h1990efc_0     conda-forge/linux-64       6 KB
2021-07-30T06:55:37.1513160Z   + gcc_impl_linux-64                9.3.0  h6df7d76_17    pkgs/main/linux-64        45 MB
2021-07-30T06:55:37.1514070Z   + gcc_linux-64                     9.3.0  hf25ea35_33    conda-forge/linux-64      23 KB
2021-07-30T06:55:37.1515034Z   + gfortran_impl_linux-64           9.3.0  hc4a2995_19    conda-forge/linux-64      10 MB
2021-07-30T06:55:37.1516018Z   + gfortran_linux-64                9.3.0  hdc58fab_33    conda-forge/linux-64      23 KB
2021-07-30T06:55:37.1516956Z   + gxx_impl_linux-64                9.3.0  hbdd7822_17    pkgs/main/linux-64         9 MB
2021-07-30T06:55:37.1518070Z   + gxx_linux-64                     9.3.0  h3fbe746_33    conda-forge/linux-64      23 KB
2021-07-30T06:55:37.1519332Z   + kernel-headers_linux-64         2.6.32  he073ed8_14    conda-forge/noarch       708 KB
2021-07-30T06:55:37.1520397Z   + krb5                            1.19.2  hcc1bbae_0     conda-forge/linux-64     Cached
2021-07-30T06:55:37.1521329Z   + ld_impl_linux-64                2.36.1  hea4e1c9_2     conda-forge/linux-64     667 KB
2021-07-30T06:55:37.1522274Z   + libcurl                         7.78.0  h2574ce0_0     conda-forge/linux-64     Cached
2021-07-30T06:55:37.1523413Z   + libedit                   3.1.20191231  he28a2e2_2     conda-forge/linux-64     Cached
2021-07-30T06:55:37.1524337Z   + libev                             4.33  h516909a_1     conda-forge/linux-64     Cached
2021-07-30T06:55:37.1525294Z   + libgcc-devel_linux-64            9.3.0  hb95220a_17    pkgs/main/linux-64         3 MB
2021-07-30T06:55:37.1526240Z   + libgcc-ng                       11.1.0  hc902ee8_4     conda-forge/linux-64     909 KB
2021-07-30T06:55:37.1527208Z   + libgfortran-ng                   9.4.0  h69a702a_4     conda-forge/linux-64      18 KB
2021-07-30T06:55:37.1528163Z   + libgfortran5                     9.4.0  h62347ff_4     conda-forge/linux-64       2 MB
2021-07-30T06:55:37.1529096Z   + libgomp                         11.1.0  hc902ee8_4     conda-forge/linux-64     428 KB
2021-07-30T06:55:37.1530039Z   + libnghttp2                      1.43.0  h812cca2_0     conda-forge/linux-64     Cached
2021-07-30T06:55:37.1530981Z   + libssh2                          1.9.0  ha56f1ee_6     conda-forge/linux-64     Cached
2021-07-30T06:55:37.1531966Z   + libstdcxx-devel_linux-64         9.3.0  hf0c5c8d_17    pkgs/main/linux-64        11 MB
2021-07-30T06:55:37.1533138Z   + libstdcxx-ng                    11.1.0  h56837e0_4     conda-forge/linux-64       4 MB
2021-07-30T06:55:37.1534059Z   + libuv                           1.42.0  h7f98852_0     conda-forge/linux-64       1 MB
2021-07-30T06:55:37.1534951Z   + lz4-c                            1.9.3  h9c3ff4c_0     conda-forge/linux-64     Cached
2021-07-30T06:55:37.1535858Z   + make                               4.3  hd18ef5c_1     conda-forge/linux-64     507 KB
2021-07-30T06:55:37.1536747Z   + ncurses                            6.2  h58526e2_4     conda-forge/linux-64     985 KB
2021-07-30T06:55:37.1537621Z   + ninja                           1.10.2  h4bd325d_0     conda-forge/linux-64       2 MB
2021-07-30T06:55:37.1538525Z   + openssl                         1.1.1k  h7f98852_0     conda-forge/linux-64     Cached
2021-07-30T06:55:37.1539449Z   + pkg-config                      0.29.2  h36c2ea0_1008  conda-forge/linux-64     120 KB
2021-07-30T06:55:37.1540355Z   + rhash                            1.4.1  h7f98852_0     conda-forge/linux-64     192 KB
2021-07-30T06:55:37.1541271Z   + sysroot_linux-64                  2.12  he073ed8_14    conda-forge/noarch        32 MB
2021-07-30T06:55:37.1542147Z   + tk                              8.6.10  h21135ba_1     conda-forge/linux-64       3 MB
2021-07-30T06:55:37.1542999Z   + xz                               5.2.5  h516909a_1     conda-forge/linux-64     343 KB
2021-07-30T06:55:37.1543834Z   + zlib                            1.2.11  h516909a_1010  conda-forge/linux-64     106 KB
2021-07-30T06:55:37.1544716Z   + zstd                             1.5.0  ha95c52a_0     conda-forge/linux-64     Cached

The workaround that I am using know is to directly remove the defaults in the CI script, adding:

conda config --remove channels defaults

See for example https://github.com/dic-iit/kindyn-vio/blob/eb6617cbac34bb19526a01d5e43efc5654174d7c/.github/workflows/conda-ci.yml#L40 .

Issue Analytics

  • State:open
  • Created 2 years ago
  • Comments:10 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
jaimergpcommented, Jul 30, 2021

The action is using conda config --add channels, so I guess that should put conda-forge above in priority, but it’s obviously not happening. We might need to add a clear-preconfigured-channels option or similar to work around this.

Other things we can try in the meantime:

  • Have you tried using an environment file with some channels specified in the file itself? This might hit another code path in conda.
  • You can also provide a custom .condarc with the exact configuration you need.
1reaction
jaimergpcommented, Jul 30, 2021

Thanks for the report! I’ll look into this.

In the meantime, you might want to try channel-priority: strict too. Sorry, just saw you are indeed using it already.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to avoid using conda-forge packages unless necessary?
Specify that a particular package should come from a given channel with conda install conda-forge::somepackage · Explicitly list channel ...
Read more >
Anaconda is bloated — Set up a lean, robust data science ...
Run the command conda list which will return the name, version, build number, and channel for each package currently installed. This is a...
Read more >
Manual :: Installing packages
This guide shows people new to the PEAR command line installer how to get started. Normal installation procedure. The general command to install...
Read more >
REINSTALLMODE property - Win32 apps - Microsoft Learn
Options are case-insensitive and order-independent. This property should normally always be used in conjunction with the REINSTALL property.
Read more >
Chapter 4. Installing Applications: Packages and Ports
By default, pkg uses the binary packages from the FreeBSD package mirrors (the repository). For information about building a custom package ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found