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

Subprocess exited with error on pip install -r requirements.txt #1

Open
dergigi opened this issue Jun 22, 2024 · 2 comments
Open

Subprocess exited with error on pip install -r requirements.txt #1

dergigi opened this issue Jun 22, 2024 · 2 comments

Comments

@dergigi
Copy link

dergigi commented Jun 22, 2024

  • OS X, m1
  • Python 3.12.4 (using pyenv)
  • pip 24.1

pip install -r requirements.txt

...fails on secp256k1

Collecting pycryptodome>=3.20.0 (from monstr->-r requirements.txt (line 2))
  Using cached pycryptodome-3.20.0-cp35-abi3-macosx_10_9_universal2.whl.metadata (3.4 kB)
Collecting secp256k1>=0.14.0 (from monstr->-r requirements.txt (line 2))
  Using cached secp256k1-0.14.0.tar.gz (2.4 MB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Installing backend dependencies ... done
  Preparing metadata (pyproject.toml) ... error
  error: subprocess-exited-with-error

  × Preparing metadata (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [53 lines of output]
      0.29.2
      Using bundled libsecp256k1
      running dist_info
      creating /private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-modern-metadata-3i12pwiq/secp256k1.egg-info
      writing /private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-modern-metadata-3i12pwiq/secp256k1.egg-info/PKG-INFO
      writing dependency_links to /private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-modern-metadata-3i12pwiq/secp256k1.egg-info/dependency_links.txt
      writing requirements to /private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-modern-metadata-3i12pwiq/secp256k1.egg-info/requires.txt
      writing top-level names to /private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-modern-metadata-3i12pwiq/secp256k1.egg-info/top_level.txt
      writing manifest file '/private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-modern-metadata-3i12pwiq/secp256k1.egg-info/SOURCES.txt'
      reading manifest file '/private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-modern-metadata-3i12pwiq/secp256k1.egg-info/SOURCES.txt'
      reading manifest template 'MANIFEST.in'
      writing manifest file '/private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-modern-metadata-3i12pwiq/secp256k1.egg-info/SOURCES.txt'
      creating '/private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-modern-metadata-3i12pwiq/secp256k1-0.14.0.dist-info'
      Traceback (most recent call last):
        File "/Users/RED/.pyenv/versions/3.12.4/lib/python3.12/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
          main()
        File "/Users/RED/.pyenv/versions/3.12.4/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 "/Users/RED/.pyenv/versions/3.12.4/lib/python3.12/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 149, in prepare_metadata_for_build_wheel
          return hook(metadata_directory, config_settings)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "/private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-build-env-xcqtlrbb/overlay/lib/python3.12/site-packages/setuptools/build_meta.py", line 368, in prepare_metadata_for_build_wheel
          self.run_setup()
        File "/private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-build-env-xcqtlrbb/overlay/lib/python3.12/site-packages/setuptools/build_meta.py", line 497, in run_setup
          super().run_setup(setup_script=setup_script)
        File "/private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-build-env-xcqtlrbb/overlay/lib/python3.12/site-packages/setuptools/build_meta.py", line 313, in run_setup
          exec(code, locals())
        File "<string>", line 265, in <module>
        File "/private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-build-env-xcqtlrbb/overlay/lib/python3.12/site-packages/setuptools/__init__.py", line 103, in setup
          return distutils.core.setup(**attrs)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "/private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-build-env-xcqtlrbb/overlay/lib/python3.12/site-packages/setuptools/_distutils/core.py", line 184, in setup
          return run_commands(dist)
                 ^^^^^^^^^^^^^^^^^^
        File "/private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-build-env-xcqtlrbb/overlay/lib/python3.12/site-packages/setuptools/_distutils/core.py", line 200, in run_commands
          dist.run_commands()
        File "/private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-build-env-xcqtlrbb/overlay/lib/python3.12/site-packages/setuptools/_distutils/dist.py", line 969, in run_commands
          self.run_command(cmd)
        File "/private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-build-env-xcqtlrbb/overlay/lib/python3.12/site-packages/setuptools/dist.py", line 976, in run_command
          super().run_command(command)
        File "/private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-build-env-xcqtlrbb/overlay/lib/python3.12/site-packages/setuptools/_distutils/dist.py", line 988, in run_command
          cmd_obj.run()
        File "/private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-build-env-xcqtlrbb/overlay/lib/python3.12/site-packages/setuptools/command/dist_info.py", line 97, in run
          bdist_wheel = self.get_finalized_command('bdist_wheel')
                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "/private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-build-env-xcqtlrbb/overlay/lib/python3.12/site-packages/setuptools/_distutils/cmd.py", line 302, in get_finalized_command
          cmd_obj = self.distribution.get_command_obj(command, create)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "/private/var/folders/hd/4yjqdk0x18jdcry20n_d33xc0000gn/T/pip-build-env-xcqtlrbb/overlay/lib/python3.12/site-packages/setuptools/_distutils/dist.py", line 862, in get_command_obj
          cmd_obj = self.command_obj[command] = klass(self)
                                                ^^^^^^^^^^^
      TypeError: 'NoneType' object is not callable
      [end of output]

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

× Encountered error while generating package metadata.
╰─> See above for output.

note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
@dergigi
Copy link
Author

dergigi commented Jun 22, 2024

None of the solutions proposed in ludbb/secp256k1-py#33 solved the issue for me.

@juergenhoetzel
Copy link

None of the solutions proposed in ludbb/secp256k1-py#33 solved the issue for me.

Hi ₿ @dergigi

Actually this is a secp256k1-py setuptools issue: setup.py: Fix invalid definition of bdist_wheel command

You can work around this problem by using my branch (not merged yet):

pip install  git+https://github.com/juergenhoetzel/secp256k1-py@pip24_bdist_wheel_fix
pip install -r requirements.txt 

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