conda-forge / pulp-feedstock

A conda-smithy repository for pulp.
BSD 3-Clause "New" or "Revised" License
2 stars 9 forks source link

Missing osx-arm64 binaries #40

Open peterjc opened 3 months ago

peterjc commented 3 months ago

Solution to issue cannot be found in the documentation.

Issue

Snakemake installed on osx-arm64 using bioconda and conda-forge is failing https://github.com/snakemake/snakemake/issues/3007 with the following with:

OSError: [Errno 86] Bad CPU type in executable: '/Users/peterjc/miniforge3/envs/snakemake-testing/lib/python3.12/site-packages/pulp/solverdir/cbc/osx/64/cbc'

The problem seems two fold, why is it not looking for an ARM binary, and why isn't there an ARM binary. This can be confirmed in an environment with just pulp:

$ ls -1  /home/pjacock/miniforge3/envs/pulp/lib/python3.12/site-packages/pulp/solverdir/cbc/*
/home/pjacock/miniforge3/envs/pulp/lib/python3.12/site-packages/pulp/solverdir/cbc/linux:
32
64
arm64

/home/pjacock/miniforge3/envs/pulp/lib/python3.12/site-packages/pulp/solverdir/cbc/osx:
64

/home/pjacock/miniforge3/envs/pulp/lib/python3.12/site-packages/pulp/solverdir/cbc/win:
32
64

Installed packages

$ conda list
# packages in environment at /home/pjacock/miniforge3/envs/pulp:
#
# Name                    Version                   Build  Channel
_libgcc_mutex             0.1                 conda_forge    conda-forge
_openmp_mutex             4.5                       2_gnu    conda-forge
amply                     0.1.6              pyhd8ed1ab_0    conda-forge
bzip2                     1.0.8                h4bc722e_7    conda-forge
ca-certificates           2024.7.4             hbcca054_0    conda-forge
coin-or-cbc               2.10.11              h56f689f_0    conda-forge
coin-or-cgl               0.60.7               h516709c_0    conda-forge
coin-or-clp               1.17.8               h1ee7a9c_0    conda-forge
coin-or-osi               0.108.10             haf5fa05_0    conda-forge
coin-or-utils             2.11.11              h8c65801_1    conda-forge
coincbc                   2.10.11           0_metapackage    conda-forge
docutils                  0.21.2             pyhd8ed1ab_0    conda-forge
ld_impl_linux-64          2.40                 hf3520f5_7    conda-forge
libblas                   3.9.0           23_linux64_openblas    conda-forge
libcblas                  3.9.0           23_linux64_openblas    conda-forge
libexpat                  2.6.2                h59595ed_0    conda-forge
libffi                    3.4.2                h7f98852_5    conda-forge
libgcc-ng                 14.1.0               h77fa898_0    conda-forge
libgfortran-ng            14.1.0               h69a702a_0    conda-forge
libgfortran5              14.1.0               hc5f4f2c_0    conda-forge
libgomp                   14.1.0               h77fa898_0    conda-forge
liblapack                 3.9.0           23_linux64_openblas    conda-forge
liblapacke                3.9.0           23_linux64_openblas    conda-forge
libnsl                    2.0.1                hd590300_0    conda-forge
libopenblas               0.3.27          pthreads_hac2b453_1    conda-forge
libsqlite                 3.46.0               hde9e2c9_0    conda-forge
libstdcxx-ng              14.1.0               hc0a3c3a_0    conda-forge
libuuid                   2.38.1               h0b41bf4_0    conda-forge
libxcrypt                 4.4.36               hd590300_1    conda-forge
libzlib                   1.3.1                h4ab18f5_1    conda-forge
ncurses                   6.5                  h59595ed_0    conda-forge
openssl                   3.3.1                h4bc722e_2    conda-forge
pip                       24.2               pyhd8ed1ab_0    conda-forge
pulp                      2.8.0           py312h7900ff3_0    conda-forge
pyparsing                 3.1.2              pyhd8ed1ab_0    conda-forge
python                    3.12.5          h2ad013b_0_cpython    conda-forge
python_abi                3.12                    4_cp312    conda-forge
readline                  8.2                  h8228510_1    conda-forge
setuptools                72.1.0             pyhd8ed1ab_0    conda-forge
tk                        8.6.13          noxft_h4845f30_101    conda-forge
tzdata                    2024a                h0c530f3_0    conda-forge
wheel                     0.44.0             pyhd8ed1ab_0    conda-forge
xz                        5.2.6                h166bdaf_0    conda-forge

Environment info

$ conda info

     active environment : pulp
    active env location : /home/pjacock/miniforge3/envs/pulp
            shell level : 2
       user config file : /home/pjacock/.condarc
 populated config files : /home/pjacock/miniforge3/.condarc
                          /home/pjacock/.condarc
          conda version : 24.7.1
    conda-build version : not installed
         python version : 3.10.14.final.0
                 solver : libmamba (default)
       virtual packages : __archspec=1=cascadelake
                          __conda=24.7.1=0
                          __glibc=2.28=0
                          __linux=4.18.0=0
                          __unix=0=0
       base environment : /home/pjacock/miniforge3  (writable)
      conda av data dir : /home/pjacock/miniforge3/etc/conda
  conda av metadata url : None
           channel URLs : https://conda.anaconda.org/conda-forge/linux-64
                          https://conda.anaconda.org/conda-forge/noarch
                          https://conda.anaconda.org/bioconda/linux-64
                          https://conda.anaconda.org/bioconda/noarch
          package cache : /home/pjacock/miniforge3/pkgs
                          /home/pjacock/.conda/pkgs
       envs directories : /home/pjacock/miniforge3/envs
                          /home/pjacock/.conda/envs
               platform : linux-64
             user-agent : conda/24.7.1 requests/2.31.0 CPython/3.10.14 Linux/4.18.0-477.13.1.el8_8.x86_64 almalinux/8.10 glibc/2.28 solver/libmamba conda-libmamba-solver/24.1.0 libmambapy/1.5.8
                UID:GID : 1001:1002
             netrc file : None
           offline mode : False
peterjc commented 3 months ago

This appears to be an upstream issue in that https://github.com/conda-forge/pulp-feedstock/blob/main/recipe/ does not attempt to compile the solvers, and therefore must just be taking the binaries provided.

See e.g. https://github.com/coin-or/pulp/tree/v2.1/pulp/solverdir/cbc

peterjc commented 3 months ago

It looks like Linux ARM binaries were added after v2.1, so hopefully they can add macOS ARM binaries too (https://github.com/coin-or/pulp/issues/765), and make a new release.

Then updating the conda-package should resolve this.