python-lazy-object-proxy: Can't install lazy-object-proxy via Pip on macOS

$ pip --version
pip 22.2.2 from /opt/homebrew/lib/python3.10/site-packages/pip (python 3.10)
$ pip install lazy-object-proxy==1.7.1
Collecting lazy-object-proxy==1.7.1
  Using cached lazy_object_proxy-0.0.0-cp310-cp310-macosx_12_0_arm64.whl
Discarding https://files.pythonhosted.org/packages/75/93/3fc1cc28f71dd10b87a53b9d809602d7730e84cc4705a062def286232a9c/lazy-object-proxy-1.7.1.tar.gz (from https://pypi.org/simple/lazy-object-proxy/) (requires-python:>=3.6): Requested lazy-object-proxy==1.7.1 from file:///Users/p/Library/Caches/pip/wheels/af/2c/f1/847bc504949237f8e24257cc51a27d9b48f5114576a1345420/lazy_object_proxy-0.0.0-cp310-cp310-macosx_12_0_arm64.whl has inconsistent version: filename has '1.7.1', but metadata has '0.0.0'
ERROR: Could not find a version that satisfies the requirement lazy-object-proxy==1.7.1 (from versions: 0.1.0, 1.0.0, 1.0.1, 1.0.2, 1.1.0, 1.2.0, 1.2.1, 1.2.2, 1.3.0, 1.3.1, 1.4.0, 1.4.1, 1.4.2, 1.4.3, 1.5.0, 1.5.1, 1.5.2, 1.6.0, 1.7.0, 1.7.1)
ERROR: No matching distribution found for lazy-object-proxy==1.7.1

The last version that works for me is 1.4.1, and I think the problem is that 1.4.2 introduced a pyproject.toml file that doesn’t specify a version number. So maybe the fix is to include a version number in pyproject.toml (and add a corresponding entry to .bumpversion.cfg).

About this issue

  • Original URL
  • State: closed
  • Created 2 years ago
  • Reactions: 4
  • Comments: 18 (7 by maintainers)

Commits related to this issue

Most upvoted comments

@phst I found a fix that helped, for me at least. I had to install setuptools-scm using pip. Apparently that was a dependency for lazy-object-proxy that I did not have. Once I ran pip install lazy-object-proxy after getting setuptools-scm, it worked like a charm.

Screenshot 2022-11-25 at 3 59 50 PM

Doing a clean install on a new mac, had the same issue with 1.9.0. Manual install of setuptools-scm fixed the issue.

Any details on what build env you had?

This happens on all macOS versions I tried, including Ventura, and also with the new pip 22.3.

This must have been built from source and you see that bad build ended up in your cache.

This doesn’t seem to be related to caching, as it also happens with the cache disabled:

$ pip --no-cache-dir install lazy-object-proxy==1.7.1
Collecting lazy-object-proxy==1.7.1
  Downloading lazy-object-proxy-1.7.1.tar.gz (41 kB)
     ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 42.0/42.0 kB 2.0 MB/s eta 0:00:00
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Installing backend dependencies ... done
  Preparing metadata (pyproject.toml) ... done
  WARNING: Requested lazy-object-proxy==1.7.1 from https://files.pythonhosted.org/packages/75/93/3fc1cc28f71dd10b87a53b9d809602d7730e84cc4705a062def286232a9c/lazy-object-proxy-1.7.1.tar.gz, but installing version 0.0.0
Discarding https://files.pythonhosted.org/packages/75/93/3fc1cc28f71dd10b87a53b9d809602d7730e84cc4705a062def286232a9c/lazy-object-proxy-1.7.1.tar.gz (from https://pypi.org/simple/lazy-object-proxy/) (requires-python:>=3.6): Requested lazy-object-proxy==1.7.1 from https://files.pythonhosted.org/packages/75/93/3fc1cc28f71dd10b87a53b9d809602d7730e84cc4705a062def286232a9c/lazy-object-proxy-1.7.1.tar.gz has inconsistent version: expected '1.7.1', but metadata has '0.0.0'
ERROR: Could not find a version that satisfies the requirement lazy-object-proxy==1.7.1 (from versions: 0.1.0, 1.0.0, 1.0.1, 1.0.2, 1.1.0, 1.2.0, 1.2.1, 1.2.2, 1.3.0, 1.3.1, 1.4.0, 1.4.1, 1.4.2, 1.4.3, 1.5.0, 1.5.1, 1.5.2, 1.6.0, 1.7.0, 1.7.1, 1.8.0)
ERROR: No matching distribution found for lazy-object-proxy==1.7.1

Version 1.8.0 doesn’t work either.