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

New setuptools release prevents install of python core library #202

Closed
melvin806 opened this issue Jul 29, 2024 · 13 comments
Closed

New setuptools release prevents install of python core library #202

melvin806 opened this issue Jul 29, 2024 · 13 comments

Comments

@melvin806
Copy link

Hi

I followed the instructions to upgrade the package
python -m pip install --upgrade ibm-cloud-sdk-core

i am running on wsl,
i am running on python 3.9 inside wsl
my setuptools-72.0.0

But i am getting this error, may i know what i am missing?
× Getting requirements to build wheel did not run successfully.
│ exit code: 1
╰─> [18 lines of output]

    File "/tmp/pip-build-env-nz566fgr/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 327, in get_requires_for_build_wheel
      return self._get_build_requires(config_settings, requirements=[])
    File "/tmp/pip-build-env-nz566fgr/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 297, in _get_build_requires
      self.run_setup()
    File "/tmp/pip-build-env-nz566fgr/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 497, in run_setup
      super().run_setup(setup_script=setup_script)
    File "/tmp/pip-build-env-nz566fgr/overlay/lib/python3.9/site-packages/setuptools/build_meta.py", line 313, in run_setup
      exec(code, locals())
    File "<string>", line 20, in <module>
  ModuleNotFoundError: No module named 'setuptools.command.test'
  [end of output]
@vinothsubramanian
Copy link

I confirm that the same issue occurs using uv.

uv pip install -r .\requirements.txt
⠴ ibm-cloud-sdk-core==3.20.3                                                                                                                                                            
error: Failed to download and build 'ibm-cloud-sdk-core==3.20.3'
  Caused by: Failed to build: 'ibm-cloud-sdk-core==3.20.3'
  Caused by: Build backend failed to determine extra requires with 'build_wheel()' with exit code: 1
stdout:

--- stderr:
<string>:18: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html
Traceback (most recent call last):
  File "<string>", line 14, in <module>
  File "C:\Users\myuserid\AppData\Local\uv\cache\builds-v0\.tmp8oeKOV\Lib\site-packages\setuptools\build_meta.py", line 327, in get_requires_for_build_wheel
    return self._get_build_requires(config_settings, requirements=[])
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\myuserid\AppData\Local\uv\cache\builds-v0\.tmp8oeKOV\Lib\site-packages\setuptools\build_meta.py", line 297, in _get_build_requires
    self.run_setup()
  File "C:\Users\myuserid\AppData\Local\uv\cache\builds-v0\.tmp8oeKOV\Lib\site-packages\setuptools\build_meta.py", line 497, in run_setup
    super().run_setup(setup_script=setup_script)
  File "C:\Users\myuserid\AppData\Local\uv\cache\builds-v0\.tmp8oeKOV\Lib\site-packages\setuptools\build_meta.py", line 313, in run_setup
    exec(code, locals())
  File "<string>", line 20, in <module>
ModuleNotFoundError: No module named 'setuptools.command.test'
---

@vinothsubramanian
Copy link

solved by installing with --no-build-isolation

Seems to be the workaround for now

@willwade
Copy link

willwade commented Jul 29, 2024

+1 from me. this is stopping ci builds on 3.12,3.11

@suresh-at-straker
Copy link

similar issue for me.

Getting requirements to build wheel: started
Getting requirements to build wheel: finished with status 'error'
...
...
Getting requirements to build wheel did not run successfully.
exit code: 1

@willwade
Copy link

I'm intrigued. why has this started overnight? Whats changed? (the workarounds arent working for me sadly)

@vinothsubramanian
Copy link

@willwade There is an release to setuptools published today. That seems to be the root cause of the issue.

@melvin806
Copy link
Author

solved by installing with --no-build-isolation

Seems to be the workaround for now

but how did you apply the workaround onto the cicd pipeline? i cant build any new build images

@willwade
Copy link

solved by installing with --no-build-isolation

Seems to be the workaround for now

but how did you apply the workaround onto the cicd pipeline? i cant build any new build images

pypa/setuptools#4519 (comment)

@pyrooka
Copy link
Member

pyrooka commented Jul 29, 2024

Hi everyone! Thanks for all the feedback we are working on the fix. One thing that we can do is removing the test references from the setup.py file because - if I am correct - it's not used anymore. That should solve this issue. Give us a little time, we'll back soon!

@pyrooka
Copy link
Member

pyrooka commented Jul 29, 2024

FYI, the latest setuptools release which caused this issue has been yanked, so all builds should run fine without any changes. I still think we should remove the references to the deprecated code.
I leave this issue open for a while to make sure everything works fine, so feel free to leave a feedback here.

@bradhvr
Copy link

bradhvr commented Jul 29, 2024

@pyrooka Thanks for the quick responses on this!

@padamstx padamstx changed the title Not able to upgrade to the latest. New setuptools release prevents install of python core library Jul 29, 2024
@pyrooka
Copy link
Member

pyrooka commented Jul 29, 2024

@bradhvr Of course! We are trying to support our users as much as possible. :)

@pyrooka
Copy link
Member

pyrooka commented Jul 29, 2024

A new release - which removes the deprecated code from the project - was published not too long ago: https://pypi.org/project/ibm-cloud-sdk-core/3.20.4/

I'm closing this issue now, but feel free to re-open it if needed!

@pyrooka pyrooka closed this as completed Jul 29, 2024
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

6 participants