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

cyipopt fails to compile with Python 3.13 #285

Open
moorepants opened this issue Jan 9, 2025 · 2 comments
Open

cyipopt fails to compile with Python 3.13 #285

moorepants opened this issue Jan 9, 2025 · 2 comments

Comments

@moorepants
Copy link
Collaborator

This works:

$ conda create -n cyipopt-pip numpy setuptools cython ipopt pkg-config pip python=3.12  # install all build and run deps
$ conda activate cyipopt-pip
$ python -m pip install --no-deps --no-build-isolation cyipopt

but this fails:

$ conda create -n cyipopt-pip numpy setuptools cython ipopt pkg-config pip python=3.13  # install all build and run deps
$ conda activate cyipopt-pip
$ python -m pip install --no-deps --no-build-isolation cyipopt

Error in compilation seems to be:

cyipopt/cython/ipopt_wrapper.c:26966:69: error: unknown type name ‘__pyx_vectorcallfunc’; did you mean ‘vectorcallfunc’?

See the full log in #284 (comment)

@moorepants
Copy link
Collaborator Author

Same error seen here: scipy/scipy#21275 which seems to indicate a numpy version mistmatch being downloaded.

@moorepants
Copy link
Collaborator Author

I just tried it again with Python 3.13 and it worked. Not sure why:

moorepants@nandi:cyipopt(master)$ conda create -n cyipopt-pip numpy setuptools cython ipopt pkg-config pip python=3.13
Channels:
 - conda-forge
Platform: linux-64
Collecting package metadata (repodata.json): done
Solving environment: done

## Package Plan ##

  environment location: /home/moorepants/miniconda/envs/cyipopt-pip

  added / updated specs:
    - cython
    - ipopt
    - numpy
    - pip
    - pkg-config
    - python=3.13
    - setuptools


The following NEW packages will be INSTALLED:

  _libgcc_mutex      conda-forge/linux-64::_libgcc_mutex-0.1-conda_forge 
  _openmp_mutex      conda-forge/linux-64::_openmp_mutex-4.5-2_gnu 
  ampl-asl           conda-forge/linux-64::ampl-asl-1.0.0-h5888daf_2 
  bzip2              conda-forge/linux-64::bzip2-1.0.8-h4bc722e_7 
  ca-certificates    conda-forge/linux-64::ca-certificates-2024.12.14-hbcca054_0 
  cython             conda-forge/linux-64::cython-3.0.11-py313hc66aa0d_3 
  ipopt              conda-forge/linux-64::ipopt-3.14.17-h59d4785_0 
  ld_impl_linux-64   conda-forge/linux-64::ld_impl_linux-64-2.43-h712a8e2_2 
  libblas            conda-forge/linux-64::libblas-3.9.0-26_linux64_openblas 
  libcblas           conda-forge/linux-64::libcblas-3.9.0-26_linux64_openblas 
  libexpat           conda-forge/linux-64::libexpat-2.6.4-h5888daf_0 
  libffi             conda-forge/linux-64::libffi-3.4.2-h7f98852_5 
  libgcc             conda-forge/linux-64::libgcc-14.2.0-h77fa898_1 
  libgcc-ng          conda-forge/linux-64::libgcc-ng-14.2.0-h69a702a_1 
  libgfortran        conda-forge/linux-64::libgfortran-14.2.0-h69a702a_1 
  libgfortran-ng     conda-forge/linux-64::libgfortran-ng-14.2.0-h69a702a_1 
  libgfortran5       conda-forge/linux-64::libgfortran5-14.2.0-hd5240d6_1 
  libgomp            conda-forge/linux-64::libgomp-14.2.0-h77fa898_1 
  libhwloc           conda-forge/linux-64::libhwloc-2.11.2-default_h0d58e46_1001 
  libiconv           conda-forge/linux-64::libiconv-1.17-hd590300_2 
  liblapack          conda-forge/linux-64::liblapack-3.9.0-26_linux64_openblas 
  liblzma            conda-forge/linux-64::liblzma-5.6.3-hb9d3cd8_1 
  liblzma-devel      conda-forge/linux-64::liblzma-devel-5.6.3-hb9d3cd8_1 
  libmpdec           conda-forge/linux-64::libmpdec-4.0.0-h4bc722e_0 
  libopenblas        conda-forge/linux-64::libopenblas-0.3.28-pthreads_h94d23a6_1 
  libscotch          conda-forge/linux-64::libscotch-7.0.4-h2fe6a88_5 
  libspral           conda-forge/linux-64::libspral-2024.05.08-h2b245be_4 
  libsqlite          conda-forge/linux-64::libsqlite-3.47.2-hee588c1_0 
  libstdcxx          conda-forge/linux-64::libstdcxx-14.2.0-hc0a3c3a_1 
  libuuid            conda-forge/linux-64::libuuid-2.38.1-h0b41bf4_0 
  libxml2            conda-forge/linux-64::libxml2-2.13.5-h0d44e9d_1 
  libzlib            conda-forge/linux-64::libzlib-1.3.1-hb9d3cd8_2 
  metis              conda-forge/linux-64::metis-5.1.0-hd0bcaf9_1007 
  mumps-include      conda-forge/linux-64::mumps-include-5.7.3-ha770c72_6 
  mumps-seq          conda-forge/linux-64::mumps-seq-5.7.3-h27a6a8b_0 
  ncurses            conda-forge/linux-64::ncurses-6.5-he02047a_1 
  numpy              conda-forge/linux-64::numpy-2.2.1-py313hb30382a_0 
  openssl            conda-forge/linux-64::openssl-3.4.0-h7b32b05_1 
  pip                conda-forge/noarch::pip-24.3.1-pyh145f28c_2 
  pkg-config         conda-forge/linux-64::pkg-config-0.29.2-h4bc722e_1009 
  python             conda-forge/linux-64::python-3.13.1-ha99a958_104_cp313 
  python_abi         conda-forge/linux-64::python_abi-3.13-5_cp313 
  readline           conda-forge/linux-64::readline-8.2-h8228510_1 
  setuptools         conda-forge/noarch::setuptools-75.6.0-pyhff2d567_1 
  tk                 conda-forge/linux-64::tk-8.6.13-noxft_h4845f30_101 
  tzdata             conda-forge/noarch::tzdata-2024b-hc8b5060_0 
  xz                 conda-forge/linux-64::xz-5.6.3-hbcc6ac9_1 
  xz-gpl-tools       conda-forge/linux-64::xz-gpl-tools-5.6.3-hbcc6ac9_1 
  xz-tools           conda-forge/linux-64::xz-tools-5.6.3-hb9d3cd8_1 
  zlib               conda-forge/linux-64::zlib-1.3.1-hb9d3cd8_2 



Downloading and Extracting Packages:

Preparing transaction: done
Verifying transaction: done
Executing transaction: done
#
# To activate this environment, use
#
#     $ conda activate cyipopt-pip
#
# To deactivate an active environment, use
#
#     $ conda deactivate

moorepants@nandi:cyipopt(master)$ act cyipopt-pip 
(cyipopt-pip) moorepants@nandi:cyipopt(master)$ python -m pip install --no-deps --no-build-isolation --no-cache-dir cyipopt
Collecting cyipopt
  Downloading cyipopt-1.5.0.tar.gz (68 kB)
  Preparing metadata (pyproject.toml) ... done
Building wheels for collected packages: cyipopt
  Building wheel for cyipopt (pyproject.toml) ... done
  Created wheel for cyipopt: filename=cyipopt-1.5.0-cp313-cp313-linux_x86_64.whl size=188983 sha256=64ac8d0fd9bf0eb648ebca3d8f28c344c866fcc695012b673c241610e7ef340d
  Stored in directory: /tmp/pip-ephem-wheel-cache-xm7sglv8/wheels/c9/32/95/657ae24f2a5b1c7f720f3a204b3c1983cd39be1dddd071bbf3
Successfully built cyipopt
Installing collected packages: cyipopt
Successfully installed cyipopt-1.5.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant