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

Build error with incremental installed #212

Open
dschepler opened this issue Jul 29, 2024 · 0 comments
Open

Build error with incremental installed #212

dschepler opened this issue Jul 29, 2024 · 0 comments

Comments

@dschepler
Copy link

On my system (Linux x86_64), when I try to build python-dbusmock (version 0.32.1) from source, I get errors:

python3 -m pip wheel /home/unfrobbed-dev/pkgs/python-dbusmock/python-dbusmock-0.32.1 -w /home/unfrobbed-dev/pkgs/python-dbusmock/python-dbusmock-0.32.1/debian/obj-amd64 --no-build-isolation --no-index --no-deps
Processing /home/unfrobbed-dev/pkgs/python-dbusmock/python-dbusmock-0.32.1
  Preparing metadata (pyproject.toml) ... error
  error: subprocess-exited-with-error
  
  × Preparing metadata (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [35 lines of output]
      Traceback (most recent call last):
        File "/usr/lib/python3.12/site-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
          main()
        File "/usr/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 "/usr/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 "/usr/lib/python3.12/site-packages/setuptools/build_meta.py", line 368, in prepare_metadata_for_build_wheel
          self.run_setup()
        File "/usr/lib/python3.12/site-packages/setuptools/build_meta.py", line 313, in run_setup
          exec(code, locals())
        File "<string>", line 7, in <module>
        File "/usr/lib/python3.12/site-packages/setuptools/__init__.py", line 108, in setup
          return distutils.core.setup(**attrs)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "/usr/lib/python3.12/site-packages/setuptools/_distutils/core.py", line 146, in setup
          _setup_distribution = dist = klass(attrs)
                                       ^^^^^^^^^^^^
        File "/usr/lib/python3.12/site-packages/setuptools/dist.py", line 278, in __init__
          _Distribution.__init__(self, dist_attrs)
        File "/usr/lib/python3.12/site-packages/setuptools/_distutils/dist.py", line 286, in __init__
          self.finalize_options()
        File "/usr/lib/python3.12/site-packages/setuptools/dist.py", line 630, in finalize_options
          ep(self)
        File "/usr/lib/python3.12/site-packages/incremental/__init__.py", line 402, in _get_setuptools_version
          config = _load_pyproject_toml("./pyproject.toml")
                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "/usr/lib/python3.12/site-packages/incremental/__init__.py", line 518, in _load_pyproject_toml
          path=_findPath(os.path.dirname(toml_path), package),
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
        File "/usr/lib/python3.12/site-packages/incremental/__init__.py", line 370, in _findPath
          raise ValueError(
      ValueError: Can't find the directory of package python-dbusmock: I looked in ./src/python-dbusmock and ./python-dbusmock
      [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.

If I temporarily remove the incremental package, or if I create a symbolic link from python-dbusmock to dbusmock, either one seems to work around the issue. My guess (which could very well be wrong) is that if incremental is installed, then the dynamic = ["version"] line in pyproject.toml activates it.

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