conda-forge / cppyy-feedstock

A conda-smithy repository for cppyy.
BSD 3-Clause "New" or "Revised" License
3 stars 4 forks source link

"cppyy" and "root" should be labeled as mutually incompatible #60

Closed jpivarski closed 2 years ago

jpivarski commented 2 years ago

Solution to issue cannot be found in the documentation.

Issue

Currently, it's possible to install the conda-forge packages cppyy and root in the same environment. However, their Python packages overshadow each other:

import cppyy

may try to load the Python library from the cppyy package or from the root package. (Which one wins depends on the order of sys.path.)

Is there some way to label these conda-forge packages as mutually incompatible at installation-time? They're mutually incompatible at runtime.

I'll also include the root-feedstock maintainers here: @chrisburr, @eguiraud, @henryiii.

Installed packages

Attempting to install in an empty environment (see Environment info, below), with only one channel, conda-forge (installed via Miniforge).

The problem is that it would allow this:

% mamba install cppyy root

Looking for: ['cppyy', 'root']

conda-forge/noarch                                 @   3.5MB/s  2.6s
conda-forge/linux-64                                22.1MB @   4.0MB/s  5.8s
Transaction

  Prefix: /home/jpivarski/mambaforge/envs/test-cppyy-root

  Updating specs:

   - cppyy
   - root

  Package                                      Version  Build                Channel                    Size
──────────────────────────────────────────────────────────────────────────────────────────────────────────────
  Install:
──────────────────────────────────────────────────────────────────────────────────────────────────────────────

  + _libgcc_mutex                                  0.1  conda_forge          conda-forge/linux-64     Cached
  + _openmp_mutex                                  4.5  1_gnu                conda-forge/linux-64     Cached
  + _sysroot_linux-64_curr_repodata_hack             3  h5bd9786_13          conda-forge/noarch         15kB
  + afterimage                                    1.21  ha9998ff_1003        conda-forge/linux-64      736kB
  + argon2-cffi                                 21.3.0  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + argon2-cffi-bindings                        21.2.0  py310h6acc77f_1      conda-forge/linux-64     Cached
  + asttokens                                    2.0.5  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + atk-1.0                                     2.36.0  h3371d22_4           conda-forge/linux-64     Cached
  + attrs                                       21.4.0  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + backcall                                     0.2.0  pyh9f0ad1d_0         conda-forge/noarch       Cached
  + backports                                      1.0  py_2                 conda-forge/noarch       Cached
  + backports.functools_lru_cache                1.6.4  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + beautifulsoup4                              4.11.0  pyha770c72_0         conda-forge/noarch         60kB
  + binutils                                    2.36.1  hdd6e379_2           conda-forge/linux-64       27kB
  + binutils_impl_linux-64                      2.36.1  h193b22a_2           conda-forge/linux-64     Cached
  + binutils_linux-64                             2.36  hf3e587d_9           conda-forge/linux-64     Cached
  + bleach                                       5.0.0  pyhd8ed1ab_0         conda-forge/noarch        126kB
  + bzip2                                        1.0.8  h7f98852_4           conda-forge/linux-64     Cached
  + c-ares                                      1.18.1  h7f98852_0           conda-forge/linux-64     Cached
  + c-compiler                                   1.4.1  h166bdaf_0           conda-forge/linux-64        5kB
  + ca-certificates                          2021.10.8  ha878542_0           conda-forge/linux-64     Cached
  + cairo                                       1.16.0  ha61ee94_1011        conda-forge/linux-64        2MB
  + cffi                                        1.15.0  py310h0fdd8cc_0      conda-forge/linux-64     Cached
  + cfitsio                                      4.0.0  h9a35b8e_0           conda-forge/linux-64        1MB
  + colorama                                     0.4.4  pyh9f0ad1d_0         conda-forge/noarch         18kB
  + compilers                                    1.4.1  ha770c72_0           conda-forge/linux-64        5kB
  + cppyy                                        2.3.0  py310h8a6ca7b_0      conda-forge/linux-64     Cached
  + cppyy-backend                               1.14.8  py310hbf28c38_0      conda-forge/linux-64     Cached
  + cppyy-cling                                 6.25.3  py310hd64a29c_0      conda-forge/linux-64     Cached
  + cpycppyy                                    1.12.9  py310hbf28c38_0      conda-forge/linux-64     Cached
  + cxx-compiler                                 1.4.1  h924138e_0           conda-forge/linux-64        5kB
  + davix                                        0.8.1  h2122014_0           conda-forge/linux-64        2MB
  + debugpy                                      1.5.1  py310h122e73d_0      conda-forge/linux-64     Cached
  + decorator                                    5.1.1  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + defusedxml                                   0.7.1  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + entrypoints                                    0.4  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + executing                                    0.8.3  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + expat                                        2.4.8  h27087fc_0           conda-forge/linux-64     Cached
  + fftw                                        3.3.10  nompi_h77c792f_102   conda-forge/linux-64        7MB
  + flit-core                                    3.7.1  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + font-ttf-dejavu-sans-mono                     2.37  hab24e00_0           conda-forge/noarch       Cached
  + font-ttf-inconsolata                         3.000  h77eed37_0           conda-forge/noarch       Cached
  + font-ttf-source-code-pro                     2.038  h77eed37_0           conda-forge/noarch       Cached
  + font-ttf-ubuntu                               0.83  hab24e00_0           conda-forge/noarch       Cached
  + fontconfig                                  2.14.0  h8e229c2_0           conda-forge/linux-64     Cached
  + fonts-conda-ecosystem                            1  0                    conda-forge/noarch       Cached
  + fonts-conda-forge                                1  0                    conda-forge/noarch       Cached
  + fortran-compiler                             1.4.1  h2a4ca65_0           conda-forge/linux-64        5kB
  + freetype                                    2.10.4  h0708190_1           conda-forge/linux-64     Cached
  + fribidi                                     1.0.10  h36c2ea0_0           conda-forge/linux-64     Cached
  + ftgl                                         2.4.0  hbcb1f35_0           conda-forge/linux-64      115kB
  + gcc                                         10.3.0  he2824d0_9           conda-forge/linux-64     Cached
  + gcc_impl_linux-64                           10.3.0  hf2f2afa_15          conda-forge/linux-64       49MB
  + gcc_linux-64                                10.3.0  hc39de41_9           conda-forge/linux-64     Cached
  + gdk-pixbuf                                  2.42.8  hff1cb4f_0           conda-forge/linux-64     Cached
  + gettext                                   0.19.8.1  h73d1719_1008        conda-forge/linux-64     Cached
  + gfortran                                    10.3.0  h18518b4_9           conda-forge/linux-64       24kB
  + gfortran_impl_linux-64                      10.3.0  h73f4979_15          conda-forge/linux-64       15MB
  + gfortran_linux-64                           10.3.0  hb09a455_9           conda-forge/linux-64     Cached
  + giflib                                       5.2.1  h36c2ea0_2           conda-forge/linux-64     Cached
  + gl2ps                                        1.4.2  h0708190_0           conda-forge/linux-64      150kB
  + glew                                         2.1.0  h9c3ff4c_2           conda-forge/linux-64      663kB
  + graphite2                                   1.3.13  h58526e2_1001        conda-forge/linux-64     Cached
  + graphviz                                    2.50.0  h8e749b2_2           conda-forge/linux-64        3MB
  + gsl                                            2.7  he838d99_0           conda-forge/linux-64        3MB
  + gsoap                                      2.8.119  h90a1d37_0           conda-forge/linux-64        2MB
  + gtk2                                       2.24.33  h90689f9_2           conda-forge/linux-64     Cached
  + gts                                          0.7.6  h64030ff_2           conda-forge/linux-64     Cached
  + gxx                                         10.3.0  he2824d0_9           conda-forge/linux-64     Cached
  + gxx_impl_linux-64                           10.3.0  hf2f2afa_15          conda-forge/linux-64       12MB
  + gxx_linux-64                                10.3.0  h2593f52_9           conda-forge/linux-64     Cached
  + harfbuzz                                     4.2.0  hf9f4e7c_1           conda-forge/linux-64        2MB
  + icu                                           70.1  h27087fc_0           conda-forge/linux-64       14MB
  + importlib-metadata                          4.11.3  py310hff52083_1      conda-forge/linux-64       34kB
  + importlib_resources                          5.6.0  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + ipykernel                                   6.12.1  py310hfdc917e_0      conda-forge/linux-64      191kB
  + ipyparallel                                  8.2.1  pyhd8ed1ab_0         conda-forge/noarch        212kB
  + ipython                                      8.2.0  py310hff52083_0      conda-forge/linux-64        1MB
  + ipython_genutils                             0.2.0  py_1                 conda-forge/noarch       Cached
  + jbig                                           2.1  h7f98852_2003        conda-forge/linux-64     Cached
  + jedi                                        0.18.1  py310hff52083_1      conda-forge/linux-64        1MB
  + jinja2                                       3.1.1  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + jpeg                                            9e  h7f98852_0           conda-forge/linux-64     Cached
  + jsonschema                                   4.4.0  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + jupyter_client                               7.2.2  pyhd8ed1ab_1         conda-forge/noarch       Cached
  + jupyter_core                                 4.9.2  py310hff52083_0      conda-forge/linux-64     Cached
  + jupyterlab_pygments                          0.2.0  pyhd8ed1ab_0         conda-forge/noarch         17kB
  + kernel-headers_linux-64                     3.10.0  h4a8ded7_13          conda-forge/noarch       Cached
  + keyutils                                     1.6.1  h166bdaf_0           conda-forge/linux-64     Cached
  + krb5                                        1.19.3  h3790be6_0           conda-forge/linux-64     Cached
  + ld_impl_linux-64                            2.36.1  hea4e1c9_2           conda-forge/linux-64     Cached
  + lerc                                           3.0  h9c3ff4c_0           conda-forge/linux-64     Cached
  + libblas                                      3.9.0  14_linux64_openblas  conda-forge/linux-64     Cached
  + libcblas                                     3.9.0  14_linux64_openblas  conda-forge/linux-64     Cached
  + libcurl                                     7.82.0  h7bff187_0           conda-forge/linux-64     Cached
  + libcxx                                      12.0.1  h4bd325d_1           conda-forge/linux-64        1MB
  + libcxxabi                                   12.0.1  ha770c72_1           conda-forge/linux-64      185kB
  + libdeflate                                    1.10  h7f98852_0           conda-forge/linux-64     Cached
  + libedit                               3.1.20191231  he28a2e2_2           conda-forge/linux-64     Cached
  + libev                                         4.33  h516909a_1           conda-forge/linux-64     Cached
  + libffi                                       3.4.2  h7f98852_5           conda-forge/linux-64     Cached
  + libgcc-devel_linux-64                       10.3.0  he6cfe16_15          conda-forge/linux-64        4MB
  + libgcc-ng                                   11.2.0  h1d223b6_15          conda-forge/linux-64      932kB
  + libgd                                        2.3.3  h18fbbfe_3           conda-forge/linux-64      272kB
  + libgfortran-ng                              11.2.0  h69a702a_15          conda-forge/linux-64       23kB
  + libgfortran5                                11.2.0  h5c6108e_15          conda-forge/linux-64        2MB
  + libglib                                     2.70.2  h174f98d_4           conda-forge/linux-64     Cached
  + libglu                                       9.0.0  he1b5a44_1001        conda-forge/linux-64      423kB
  + libgomp                                     11.2.0  h1d223b6_15          conda-forge/linux-64      443kB
  + libiconv                                      1.16  h516909a_0           conda-forge/linux-64     Cached
  + liblapack                                    3.9.0  14_linux64_openblas  conda-forge/linux-64     Cached
  + libllvm11                                   11.1.0  hf817b99_3           conda-forge/linux-64     Cached
  + libllvm9                                     9.0.1  default_hc23dcda_7   conda-forge/linux-64     Cached
  + libnghttp2                                  1.47.0  h727a467_0           conda-forge/linux-64     Cached
  + libnsl                                       2.0.0  h7f98852_0           conda-forge/linux-64     Cached
  + libopenblas                                 0.3.20  pthreads_h78a6416_0  conda-forge/linux-64     Cached
  + libpng                                      1.6.37  h21135ba_2           conda-forge/linux-64     Cached
  + librsvg                                     2.52.5  h0a9e6e8_3           conda-forge/linux-64     Cached
  + libsanitizer                                10.3.0  h26c7422_15          conda-forge/linux-64        6MB
  + libsodium                                   1.0.18  h36c2ea0_1           conda-forge/linux-64     Cached
  + libssh2                                     1.10.0  ha56f1ee_2           conda-forge/linux-64     Cached
  + libstdcxx-devel_linux-64                    10.3.0  he6cfe16_15          conda-forge/linux-64       10MB
  + libstdcxx-ng                                11.2.0  he4da1e4_15          conda-forge/linux-64        4MB
  + libtiff                                      4.3.0  h542a066_3           conda-forge/linux-64     Cached
  + libtool                                      2.4.6  h9c3ff4c_1008        conda-forge/linux-64     Cached
  + libuuid                                     2.32.1  h7f98852_1000        conda-forge/linux-64     Cached
  + libwebp                                      1.2.2  h3452ae3_0           conda-forge/linux-64     Cached
  + libwebp-base                                 1.2.2  h7f98852_1           conda-forge/linux-64     Cached
  + libxcb                                        1.13  h7f98852_1004        conda-forge/linux-64     Cached
  + libxml2                                     2.9.12  h22db469_2           conda-forge/linux-64      791kB
  + libzlib                                     1.2.11  h166bdaf_1014        conda-forge/linux-64     Cached
  + llvmlite                                    0.38.0  py310h58363a5_1      conda-forge/linux-64        2MB
  + lz4-c                                        1.9.3  h9c3ff4c_1           conda-forge/linux-64     Cached
  + markupsafe                                   2.1.1  py310h5764c6d_1      conda-forge/linux-64       23kB
  + matplotlib-inline                            0.1.3  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + metakernel                                  0.29.0  pyhd8ed1ab_0         conda-forge/noarch        190kB
  + mistune                                      0.8.4  py310h6acc77f_1005   conda-forge/linux-64     Cached
  + nbclient                                    0.5.13  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + nbconvert                                    6.4.5  pyhd8ed1ab_2         conda-forge/noarch          6kB
  + nbconvert-core                               6.4.5  pyhd8ed1ab_2         conda-forge/noarch        458kB
  + nbconvert-pandoc                             6.4.5  pyhd8ed1ab_2         conda-forge/noarch          5kB
  + nbformat                                     5.3.0  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + ncurses                                        6.3  h27087fc_1           conda-forge/linux-64     Cached
  + nest-asyncio                                 1.5.5  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + nlohmann_json                               3.10.5  h9c3ff4c_0           conda-forge/linux-64      105kB
  + notebook                                    6.4.10  pyha770c72_0         conda-forge/noarch       Cached
  + numba                                       0.55.1  py310hc55943c_0      conda-forge/linux-64     Cached
  + numpy                                       1.21.5  py310h647a097_0      conda-forge/linux-64     Cached
  + openssl                                     1.1.1n  h166bdaf_0           conda-forge/linux-64     Cached
  + packaging                                     21.3  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + pandoc                                    2.17.1.1  ha770c72_0           conda-forge/linux-64     Cached
  + pandocfilters                                1.5.0  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + pango                                       1.50.6  hbd2fdc8_0           conda-forge/linux-64     Cached
  + parso                                        0.8.3  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + pcre                                          8.45  h9c3ff4c_0           conda-forge/linux-64     Cached
  + pexpect                                      4.8.0  pyh9f0ad1d_2         conda-forge/noarch       Cached
  + pickleshare                                  0.7.5  py_1003              conda-forge/noarch       Cached
  + pip                                         22.0.4  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + pixman                                      0.40.0  h36c2ea0_0           conda-forge/linux-64     Cached
  + portalocker                                  2.4.0  py310hff52083_0      conda-forge/linux-64       29kB
  + prometheus_client                           0.14.0  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + prompt-toolkit                              3.0.29  pyha770c72_0         conda-forge/noarch       Cached
  + psutil                                       5.9.0  py310h5764c6d_1      conda-forge/linux-64      358kB
  + pthread-stubs                                  0.4  h36c2ea0_1001        conda-forge/linux-64     Cached
  + ptyprocess                                   0.7.0  pyhd3deb0d_0         conda-forge/noarch       Cached
  + pure_eval                                    0.2.2  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + pycparser                                     2.21  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + pygments                                    2.11.2  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + pyparsing                                    3.0.7  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + pyrsistent                                  0.18.1  py310h5764c6d_1      conda-forge/linux-64       95kB
  + pythia8                                        8.8  py310h122e73d_0      conda-forge/linux-64       30MB
  + python                                      3.10.4  h9a8a25e_0_cpython   conda-forge/linux-64     Cached
  + python-dateutil                              2.8.2  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + python-fastjsonschema                       2.15.3  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + python_abi                                    3.10  2_cp310              conda-forge/linux-64        4kB
  + pyzmq                                       22.3.0  py310h330234f_2      conda-forge/linux-64      524kB
  + readline                                       8.1  h46c0cb4_0           conda-forge/linux-64     Cached
  + root                                        6.26.0  py310h769672d_0      conda-forge/linux-64       29kB
  + root_base                                   6.26.0  py310hfaa99c0_0      conda-forge/linux-64      261MB
  + scitokens-cpp                                0.6.3  h00015f2_2           conda-forge/linux-64     Cached
  + send2trash                                   1.8.0  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + setuptools                                  62.0.0  py310hff52083_0      conda-forge/linux-64     Cached
  + six                                         1.16.0  pyh6c4a22f_0         conda-forge/noarch       Cached
  + soupsieve                                    2.3.1  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + sqlite                                      3.37.1  h4ff8645_0           conda-forge/linux-64     Cached
  + stack_data                                   0.2.0  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + sysroot_linux-64                              2.17  h4a8ded7_13          conda-forge/noarch       Cached
  + tbb                                       2021.5.0  h924138e_1           conda-forge/linux-64        2MB
  + terminado                                   0.13.3  py310hff52083_1      conda-forge/linux-64       28kB
  + testpath                                     0.6.0  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + tk                                          8.6.12  h27826a3_0           conda-forge/linux-64     Cached
  + tornado                                        6.1  py310h5764c6d_3      conda-forge/linux-64      673kB
  + tqdm                                        4.64.0  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + traitlets                                    5.1.1  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + tzdata                                       2022a  h191b570_0           conda-forge/noarch       Cached
  + vdt                                          0.4.3  h9c3ff4c_0           conda-forge/linux-64       30kB
  + vector-classes                               1.4.2  h4bd325d_1           conda-forge/linux-64      275kB
  + wcwidth                                      0.2.5  pyh9f0ad1d_2         conda-forge/noarch       Cached
  + webencodings                                 0.5.1  py_1                 conda-forge/noarch       Cached
  + wheel                                       0.37.1  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + xorg-fixesproto                                5.0  h7f98852_1002        conda-forge/linux-64        9kB
  + xorg-kbproto                                 1.0.7  h7f98852_1002        conda-forge/linux-64     Cached
  + xorg-libice                                 1.0.10  h7f98852_0           conda-forge/linux-64     Cached
  + xorg-libsm                                   1.2.3  hd9c2040_1000        conda-forge/linux-64     Cached
  + xorg-libx11                                 1.6.12  h36c2ea0_0           conda-forge/linux-64      941kB
  + xorg-libxau                                  1.0.9  h7f98852_0           conda-forge/linux-64     Cached
  + xorg-libxcursor                              1.2.0  h516909a_0           conda-forge/linux-64       31kB
  + xorg-libxdmcp                                1.1.3  h7f98852_0           conda-forge/linux-64     Cached
  + xorg-libxext                                 1.3.4  h516909a_0           conda-forge/linux-64       53kB
  + xorg-libxfixes                               5.0.3  h516909a_1004        conda-forge/linux-64       17kB
  + xorg-libxft                                  2.3.4  hc534e41_1           conda-forge/linux-64       55kB
  + xorg-libxpm                                 3.5.13  h516909a_0           conda-forge/linux-64       65kB
  + xorg-libxrender                             0.9.10  h516909a_1002        conda-forge/linux-64       32kB
  + xorg-libxt                                   1.1.5  h516909a_1003        conda-forge/linux-64      376kB
  + xorg-renderproto                            0.11.1  h7f98852_1002        conda-forge/linux-64     Cached
  + xorg-xextproto                               7.3.0  h7f98852_1002        conda-forge/linux-64     Cached
  + xorg-xproto                                 7.0.31  h7f98852_1007        conda-forge/linux-64     Cached
  + xrootd                                       5.4.1  py310hf716355_0      conda-forge/linux-64     Cached
  + xxhash                                       0.8.0  h7f98852_3           conda-forge/linux-64     Cached
  + xz                                           5.2.5  h516909a_1           conda-forge/linux-64     Cached
  + zeromq                                       4.3.4  h9c3ff4c_1           conda-forge/linux-64     Cached
  + zipp                                         3.8.0  pyhd8ed1ab_0         conda-forge/noarch       Cached
  + zlib                                        1.2.11  h166bdaf_1014        conda-forge/linux-64     Cached
  + zstd                                         1.5.2  ha95c52a_0           conda-forge/linux-64     Cached

  Summary:

  Install: 224 packages

  Total download: 447MB

──────────────────────────────────────────────────────────────────────────────────────────────────────────────

Confirm changes: [Y/n] 

Although I expect bad things to happen in theory, I decided to actually try it, too. Here's what happens after installation:

% python
Python 3.10.4 | packaged by conda-forge | (main, Mar 24 2022, 17:38:57) [GCC 10.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import cppyy
Fatal in <TROOT::InitInterpreter>: cannot load library /home/jpivarski/irishep/root-install/lib/libRIO.so: undefined symbol: _ZN7TThread3RunEPv

% python
Python 3.10.4 | packaged by conda-forge | (main, Mar 24 2022, 17:38:57) [GCC 10.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import ROOT
Fatal in <TROOT::InitInterpreter>: cannot load library /home/jpivarski/irishep/root-install/lib/libRIO.so: undefined symbol: _ZN7TThread3RunEPv

Environment info

Brand new environment:

% conda create -n test-cppyy-root
Collecting package metadata (current_repodata.json): done
Solving environment: done

## Package Plan ##

  environment location: /home/jpivarski/mambaforge/envs/test-cppyy-root

Proceed ([y]/n)? y

Preparing transaction: done
Verifying transaction: done
Executing transaction: done
#
# To activate this environment, use
#
#     $ conda activate test-cppyy-root
#
# To deactivate an active environment, use
#
#     $ conda deactivate

% conda activate test-cppyy-root
% conda list
# packages in environment at /home/jpivarski/mambaforge/envs/test-cppyy-root:
#
# Name                    Version                   Build  Channel
jpivarski commented 2 years ago

Oh, I should also mention the motivation: I was hunting down a performance issue, thinking that I was running cppyy from conda-forge, only to find out that I was actually running cppyy from a self-compiled copy of ROOT (not through conda-forge). That's my own problem—self-compiled software can always conflict with software installed through conda-forge—but it got me thinking about what would happen if someone installed both the cppyy and root packages from conda-forge, thinking they are independent and compatible because conda lets them do it.

saraedum commented 2 years ago

Maybe I misunderstand what you wrote above, but I think the real problem in your example is that it's picking up a root library from somewhere else, outside of the conda prefixes.

For me, import ROOT works fine. However, import cppyy complains with:

>>> import cppyy
(Re-)building pre-compiled headers (options: -O2); this may take a minute ...
In file included from input_line_10:9:
In file included from ./etc/dictpch/allHeaders.h:315:
./include/ROOT/TReentrantRWLock.hxx:28:19: error: use of undeclared identifier 'TVirtualRWMutex'
   using Hint_t = TVirtualRWMutex::Hint_t;

However, cppyy seems to be functional even though this error happpens.

saraedum commented 2 years ago

Can this be closed @jpivarski ?

If not, we would need to mark these packages as incompatible in the meta.yaml here and also patch the existing metadata.

jpivarski commented 2 years ago

You're right! I had intended to create a clean reproducer, but I see in the error output that it's getting ROOT from /home/jpivarski/irishep/root-install and that's causing an error. (My test environment wasn't clean enough.)

If you can't reproduce it in a clean environment, I guess it's fine. ROOT users very often install ROOT in several different ways, but the "conda way" is for everything to be installed from conda and that works here.

saraedum commented 2 years ago

Ok. I'll close this then. :)