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

DeprecatedInstaller on Python3.12 + Ubuntu 24.04 #268

Open
ripaul opened this issue Sep 16, 2024 · 3 comments
Open

DeprecatedInstaller on Python3.12 + Ubuntu 24.04 #268

ripaul opened this issue Sep 16, 2024 · 3 comments

Comments

@ripaul
Copy link

ripaul commented Sep 16, 2024

Hi,

I recently got force to switch to Ubuntu 24.04 which comes with Python 3.12. Since then I get the following error when trying to install cyipopt via pip:

$ pip install cyipopt
Collecting cyipopt
  Using cached cyipopt-1.5.0.tar.gz (68 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... error
  error: subprocess-exited-with-error
  
  × Getting requirements to build wheel did not run successfully.
  │ exit code: 1
  ╰─> [34 lines of output]
      <string>:32: _DeprecatedInstaller: setuptools.installer and fetch_build_eggs are deprecated.
      !!
      
              ********************************************************************************
              Requirements should be satisfied by a PEP 517 installer.
              If you are using pip, you can try `pip install --use-pep517`.
              ********************************************************************************
      
      !!
      Package ipopt was not found in the pkg-config search path.
      Perhaps you should add the directory containing `ipopt.pc'
      to the PKG_CONFIG_PATH environment variable
      Package 'ipopt', required by 'virtual:world', not found
      Using Ipopt found with pkg-config.
      Traceback (most recent call last):
        File "/mnt/gpu_public/r.paul/proj/bayesopt-mcmc/experiments/venv/lib/python3.12/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
          main()
        File "/mnt/gpu_public/r.paul/proj/bayesopt-mcmc/experiments/venv/lib/python3.12/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
          json_out['return_val'] = hook(**hook_input['kwargs'])
                                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "/mnt/gpu_public/r.paul/proj/bayesopt-mcmc/experiments/venv/lib/python3.12/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 118, in get_requires_for_build_wheel
          return hook(config_settings)
                 ^^^^^^^^^^^^^^^^^^^^^
        File "/tmp/pip-build-env-ax2h20_q/overlay/lib/python3.12/site-packages/setuptools/build_meta.py", line 332, in get_requires_for_build_wheel
          return self._get_build_requires(config_settings, requirements=[])
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "/tmp/pip-build-env-ax2h20_q/overlay/lib/python3.12/site-packages/setuptools/build_meta.py", line 302, in _get_build_requires
          self.run_setup()
        File "/tmp/pip-build-env-ax2h20_q/overlay/lib/python3.12/site-packages/setuptools/build_meta.py", line 318, in run_setup
          exec(code, locals())
        File "<string>", line 203, in <module>
        File "<string>", line 174, in handle_ext_modules_general_os
        File "<string>", line 108, in pkgconfig
      OSError: pkg-config was not able to find any of the requested packages ['ipopt'] on your system. Make sure pkg-config can discover the .pc files associated with the installed packages.
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.

Using the recommended --use-pep517 option gives the exact same result. Any ideas, recommendations, fixes?

@moorepants
Copy link
Collaborator

The reasons your package isn't building is because it can't find an ipopt executable:

OSError: pkg-config was not able to find any of the requested packages ['ipopt'] on your system. Make sure pkg-config can discover the .pc files associated with the installed packages.
      [end of output]

@ripaul
Copy link
Author

ripaul commented Sep 16, 2024

Oh, I see. Let me try that out. Though maybe that's something to emphasize a bit more in the documentation, at least in the PyPI description text?

@moorepants
Copy link
Collaborator

We have an entire page on installation here: https://cyipopt.readthedocs.io/en/stable/install.html

You are welcome to contribute improvements to that if something is unclear or missing.

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

2 participants