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

Getting requirements to build wheel did not run successfully. #734

Open
Galvo87 opened this issue Sep 11, 2023 · 1 comment
Open

Getting requirements to build wheel did not run successfully. #734

Galvo87 opened this issue Sep 11, 2023 · 1 comment
Labels
waiting response/feedback Blocked while waiting information/feeback from the issue/PR/discussion author.

Comments

@Galvo87
Copy link

Galvo87 commented Sep 11, 2023

Description of your problem

Please provide a minimal, self-contained, and reproducible example.

putup proj
cd proj
pip install -e .
from lingua import Language, LanguageDetectorBuilder
import spacy
pip install .

Please provide the full traceback using the --very-verbose flag.

Defaulting to user installation because normal site-packages is not writeable
Processing /home/developer/Documents/doflamingo
  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
  ╰─> [50 lines of output]
      running egg_info
      writing src/doflamingo.egg-info/PKG-INFO
      writing dependency_links to src/doflamingo.egg-info/dependency_links.txt
      
      
      An error occurred while building the project, please ensure you have the most updated version of setuptools, setuptools_scm and wheel with:
         pip install -U setuptools setuptools_scm wheel
      
      
      Traceback (most recent call last):
        File "/usr/local/lib/python3.10/dist-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 353, in <module>
          main()
        File "/usr/local/lib/python3.10/dist-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py", line 335, in main
          json_out['return_val'] = hook(**hook_input['kwargs'])
        File "/usr/local/lib/python3.10/dist-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-_enlb72z/overlay/local/lib/python3.10/dist-packages/setuptools/build_meta.py", line 355, in get_requires_for_build_wheel
          return self._get_build_requires(config_settings, requirements=['wheel'])
        File "/tmp/pip-build-env-_enlb72z/overlay/local/lib/python3.10/dist-packages/setuptools/build_meta.py", line 325, in _get_build_requires
          self.run_setup()
        File "/tmp/pip-build-env-_enlb72z/overlay/local/lib/python3.10/dist-packages/setuptools/build_meta.py", line 341, in run_setup
          exec(code, locals())
        File "<string>", line 13, in <module>
        File "/tmp/pip-build-env-_enlb72z/overlay/local/lib/python3.10/dist-packages/setuptools/__init__.py", line 103, in setup
          return distutils.core.setup(**attrs)
        File "/tmp/pip-build-env-_enlb72z/overlay/local/lib/python3.10/dist-packages/setuptools/_distutils/core.py", line 185, in setup
          return run_commands(dist)
        File "/tmp/pip-build-env-_enlb72z/overlay/local/lib/python3.10/dist-packages/setuptools/_distutils/core.py", line 201, in run_commands
          dist.run_commands()
        File "/tmp/pip-build-env-_enlb72z/overlay/local/lib/python3.10/dist-packages/setuptools/_distutils/dist.py", line 969, in run_commands
          self.run_command(cmd)
        File "/tmp/pip-build-env-_enlb72z/overlay/local/lib/python3.10/dist-packages/setuptools/dist.py", line 1001, in run_command
          super().run_command(command)
        File "/tmp/pip-build-env-_enlb72z/overlay/local/lib/python3.10/dist-packages/setuptools/_distutils/dist.py", line 988, in run_command
          cmd_obj.run()
        File "/tmp/pip-build-env-_enlb72z/overlay/local/lib/python3.10/dist-packages/setuptools/command/egg_info.py", line 311, in run
          writer(self, ep.name, os.path.join(self.egg_info, ep.name))
        File "/tmp/pip-build-env-_enlb72z/overlay/local/lib/python3.10/dist-packages/setuptools/command/egg_info.py", line 719, in write_entries
          eps = _entry_points.load(cmd.distribution.entry_points)
        File "/usr/lib/python3.10/functools.py", line 889, in wrapper
          return dispatch(args[0].__class__)(*args, **kw)
        File "/tmp/pip-build-env-_enlb72z/overlay/local/lib/python3.10/dist-packages/setuptools/_entry_points.py", line 59, in load
          return validate(metadata.EntryPoints(groups))
        File "/usr/lib/python3.10/importlib/metadata/__init__.py", line 389, in <genexpr>
          return (
        File "/usr/lib/python3.10/importlib/metadata/__init__.py", line 103, in <genexpr>
          section._replace(value=Pair.parse(section.value))
        File "/usr/lib/python3.10/importlib/metadata/_collections.py", line 30, in parse
          return cls(*map(str.strip, text.split("=", 1)))
      TypeError: Pair.__new__() missing 1 required positional argument: 'value'
      [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.

Please provide any additional information below.
The error occurs only when adding Spacy and lingua-language-detector libraries to the project.

Versions and main components

  • PyScaffold Version: 4.5
  • Python Version: Python 3.10.12
  • Operating system: Ubuntu 22.04.2 LTS
  • How did you install PyScaffold: (conda/pip) Pip
@abravalheri
Copy link
Collaborator

Hi @Galvo87, I am having trouble to reproduce your problem.

In the example below, I tried to create a reproducer script filling the gaps in your example to my best knowledge:

> docker run --rm -it python:3.11-bullseye /bin/bash
git config --global user.email "[email protected]"
git config --global user.name "Your Name"
cd /tmp
python3 -m pip install -U pip
python3 -m pip install -U pyscaffold
putup proj
cd proj
pip install -e .
echo 'from lingua import Language, LanguageDetectorBuilder' >> src/proj/__init__.py
echo 'import spacy' >> src/proj/__init__.py
python3 -m pip install lingua-language-detector spacy
pip install .

The example above runs successfully and prints Successfully installed proj-0.0.post1.dev1+g9a6935f.d20230911.

Could you please give us a bit more information on how to reproduce the problem. Ideally a minimal reproducible example would be the best for proceeding with the investigation. You can also modify my example above until it results in the error you are seeing.


By the looks of your traceback, I recommend double checking your configuration for entry_points:

 File "/tmp/pip-build-env-_enlb72z/overlay/local/lib/python3.10/dist-packages/setuptools/_entry_points.py", line 59, in load
          return validate(metadata.EntryPoints(groups))
        File "/usr/lib/python3.10/importlib/metadata/__init__.py", line 389, in <genexpr>
          return (
        File "/usr/lib/python3.10/importlib/metadata/__init__.py", line 103, in <genexpr>
          section._replace(value=Pair.parse(section.value))
        File "/usr/lib/python3.10/importlib/metadata/_collections.py", line 30, in parse
          return cls(*map(str.strip, text.split("=", 1)))
      TypeError: Pair.__new__() missing 1 required positional argument: 'value'

The error above looks characteristic of a "mal-formed" entry-point configuration... (This might not necessarily be in your code, but maybe in one other dependency?)

@abravalheri abravalheri added the waiting response/feedback Blocked while waiting information/feeback from the issue/PR/discussion author. label Sep 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
waiting response/feedback Blocked while waiting information/feeback from the issue/PR/discussion author.
Projects
None yet
Development

No branches or pull requests

2 participants