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

Error installing dspy from git due to setup.py {VERSION_PLACEHOLDER} #1199

Closed
vikrantrathore opened this issue Jun 24, 2024 · 1 comment
Closed
Assignees

Comments

@vikrantrathore
Copy link

When installing dspy from git it gives an error due to setup.py line containing name="{{PACKAGE_NAME_PLACEHOLDER}}", and version="{{VERSION_PLACEHOLDER}}",. The version in pypi is 2.4.10 and package_name_placeholder value is dspy-ai. Is there a difference between git vs the published pypi package?

 Package operations: 1 install, 0 updates, 0 removals

  - Installing dspy (2.0.8 01e5066): Failed

  ChefBuildError

  Backend subprocess exited when trying to invoke get_requires_for_build_wheel

  Traceback (most recent call last):
    File "/Users/dummyuser/Library/Application Support/pypoetry/venv/lib/python3.12/site-packages/pyproject_hooks/_in_process/_in_process.py", line 373, in <module>
      main()
    File "/Users/dummyuser/Library/Application Support/pypoetry/venv/lib/python3.12/site-packages/pyproject_hooks/_in_process/_in_process.py", line 357, in main
      json_out["return_val"] = hook(**hook_input["kwargs"])
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/Users/dummyuser/Library/Application Support/pypoetry/venv/lib/python3.12/site-packages/pyproject_hooks/_in_process/_in_process.py", line 134, in get_requires_for_build_wheel
      return hook(config_settings)
             ^^^^^^^^^^^^^^^^^^^^^
    File "/var/folders/d_/nhqt8l112d13r8fs1n188dc00000gn/T/tmpejd8us47/.venv/lib/python3.12/site-packages/setuptools/build_meta.py", line 327, in get_requires_for_build_wheel
      return self._get_build_requires(config_settings, requirements=[])
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/var/folders/d_/nhqt8l112d13r8fs1n188dc00000gn/T/tmpejd8us47/.venv/lib/python3.12/site-packages/setuptools/build_meta.py", line 297, in _get_build_requires
      self.run_setup()
    File "/var/folders/d_/nhqt8l112d13r8fs1n188dc00000gn/T/tmpejd8us47/.venv/lib/python3.12/site-packages/setuptools/build_meta.py", line 313, in run_setup
      exec(code, locals())
    File "<string>", line 11, in <module>
    File "/var/folders/d_/nhqt8l112d13r8fs1n188dc00000gn/T/tmpejd8us47/.venv/lib/python3.12/site-packages/setuptools/__init__.py", line 103, in setup
      return distutils.core.setup(**attrs)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/var/folders/d_/nhqt8l112d13r8fs1n188dc00000gn/T/tmpejd8us47/.venv/lib/python3.12/site-packages/setuptools/_distutils/core.py", line 146, in setup
      _setup_distribution = dist = klass(attrs)
                                   ^^^^^^^^^^^^
    File "/var/folders/d_/nhqt8l112d13r8fs1n188dc00000gn/T/tmpejd8us47/.venv/lib/python3.12/site-packages/setuptools/dist.py", line 320, in __init__
      self.metadata.version = self._normalize_version(self.metadata.version)
                              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    File "/var/folders/d_/nhqt8l112d13r8fs1n188dc00000gn/T/tmpejd8us47/.venv/lib/python3.12/site-packages/setuptools/dist.py", line 356, in _normalize_version
      normalized = str(Version(version))
                       ^^^^^^^^^^^^^^^^
    File "/var/folders/d_/nhqt8l112d13r8fs1n188dc00000gn/T/tmpejd8us47/.venv/lib/python3.12/site-packages/setuptools/_vendor/packaging/version.py", line 200, in __init__
      raise InvalidVersion(f"Invalid version: '{version}'")
  setuptools.extern.packaging.version.InvalidVersion: Invalid version: '{{VERSION_PLACEHOLDER}}'


  at ~/Library/Application Support/pypoetry/venv/lib/python3.12/site-packages/poetry/installation/chef.py:164 in _prepare
      160│
      161│                 error = ChefBuildError("\n\n".join(message_parts))
      162│
      163│             if error is not None:
    → 164│                 raise error from None
      165│
      166│             return path
      167│
      168│     def _prepare_sdist(self, archive: Path, destination: Path | None = None) -> Path:

@hmoazam hmoazam self-assigned this Jun 25, 2024
@hmoazam
Copy link
Collaborator

hmoazam commented Jun 25, 2024

We've fixed this in #1205
There's no difference between the git repo and pypi packages except the pypi ones are versioned releases whereas git will have all the latest changes.

@hmoazam hmoazam closed this as completed Jun 25, 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

2 participants