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

[BUG] Cannot install the package using poetry 1.4.X #175

Closed
integrajerome opened this issue Mar 2, 2023 · 9 comments
Closed

[BUG] Cannot install the package using poetry 1.4.X #175

integrajerome opened this issue Mar 2, 2023 · 9 comments
Labels
bug Something isn't working

Comments

@integrajerome
Copy link

integrajerome commented Mar 2, 2023

Error installing the package using poetry 1.4.0.

To reproduce: install or upgrade to poetry 4 and try to install latest fastapi-restful.

image

@integrajerome integrajerome added the bug Something isn't working label Mar 2, 2023
@integrajerome integrajerome changed the title [BUG] There is no item named .../WHEEL in the archive, poetry 4 [BUG] Cannot install the package using poetry 4 Mar 2, 2023
@Abashinos
Copy link

same here

@jgentil
Copy link

jgentil commented Mar 9, 2023

it looks like it's case sensitive. The file inflates as fastapi_restful-0.4.3.dist-info/WHEEL but it's looking for FastApi_RESTful-0.4.3.dist-info/WHEEL

This is probably because the .whl filename on pypi is named FastApi_RESTful-0.4.3-py3-none-any.whl and Poetry is matching the exact case of the whl file to the expected dist-info.

This is a regression in Poetry 1.4.0 and I've submitted a bug here: python-poetry/poetry#7572

However, as a workaround, you can download the .whl file from PyPI itself here, rename it to the proper lower-case name, and then use poetry add to install it.

wget https://files.pythonhosted.org/packages/3d/f8/f152c23d669efab0c78ccbc9cb0500c3c1c2a07ab492cf9fac2ac91ffd74/FastApi_RESTful-0.4.3-py3-none-any.whl
mv FastApi_RESTful-0.4.3-py3-none-any.whl fastapi_restful-0.4.3-py3-none-any.whl
poetry add ./fastapi_restful-0.4.3-py3-none-any.whl

@yuval9313 if you could change the case of the project in pyproject.toml and rename the source directory, that would fix this issue.

@Abashinos
Copy link

it looks like it's case sensitive. The file inflates as fastapi_restful-0.4.3.dist-info/WHEEL but it's looking for FastApi_RESTful-0.4.3.dist-info/WHEEL

This is probably because the .whl filename on pypi is named FastApi_RESTful-0.4.3-py3-none-any.whl and Poetry is matching the exact case of the whl file to the expected dist-info.

This is a regression in Poetry 1.4.0 and I've submitted a bug here: python-poetry/poetry#7572

However, as a workaround, you can download the .whl file from PyPI itself here, rename it to the proper lower-case name, and then use poetry add to install it.

wget https://files.pythonhosted.org/packages/3d/f8/f152c23d669efab0c78ccbc9cb0500c3c1c2a07ab492cf9fac2ac91ffd74/FastApi_RESTful-0.4.3-py3-none-any.whl
mv FastApi_RESTful-0.4.3-py3-none-any.whl fastapi_restful-0.4.3-py3-none-any.whl
poetry add ./fastapi_restful-0.4.3-py3-none-any.whl

@yuval9313 if you could change the case of the project in pyproject.toml and rename the source directory, that would fix this issue.

Thank you for the breakdown!
I've opted to downgrade poetry until they get to the fix, but, judging from the thread you linked, they won't be in much of a hurry.
Another suggestion mentioned there is to exclusively disable the new installer with poetry config installer.modern-installation false, but remembering to enable it back once the issue is fixed would be a challenge in itself.

@yuval9313
Copy link
Owner

it looks like it's case sensitive. The file inflates as fastapi_restful-0.4.3.dist-info/WHEEL but it's looking for FastApi_RESTful-0.4.3.dist-info/WHEEL

This is probably because the .whl filename on pypi is named FastApi_RESTful-0.4.3-py3-none-any.whl and Poetry is matching the exact case of the whl file to the expected dist-info.

This is a regression in Poetry 1.4.0 and I've submitted a bug here: python-poetry/poetry#7572

However, as a workaround, you can download the .whl file from PyPI itself here, rename it to the proper lower-case name, and then use poetry add to install it.

wget https://files.pythonhosted.org/packages/3d/f8/f152c23d669efab0c78ccbc9cb0500c3c1c2a07ab492cf9fac2ac91ffd74/FastApi_RESTful-0.4.3-py3-none-any.whl
mv FastApi_RESTful-0.4.3-py3-none-any.whl fastapi_restful-0.4.3-py3-none-any.whl
poetry add ./fastapi_restful-0.4.3-py3-none-any.whl

@yuval9313 if you could change the case of the project in pyproject.toml and rename the source directory, that would fix this issue.

I assume you are right, I will do it but I must check with pypi to prevent 2 packages with the same name, one lower case and one like it is now

@integrajerome integrajerome changed the title [BUG] Cannot install the package using poetry 4 [BUG] Cannot install the package using poetry 1.4.X Mar 23, 2023
@integrajerome
Copy link
Author

it looks like it's case sensitive. The file inflates as fastapi_restful-0.4.3.dist-info/WHEEL but it's looking for FastApi_RESTful-0.4.3.dist-info/WHEEL

This is probably because the .whl filename on pypi is named FastApi_RESTful-0.4.3-py3-none-any.whl and Poetry is matching the exact case of the whl file to the expected dist-info.

This is a regression in Poetry 1.4.0 and I've submitted a bug here: python-poetry/poetry#7572

However, as a workaround, you can download the .whl file from PyPI itself here, rename it to the proper lower-case name, and then use poetry add to install it.

wget https://files.pythonhosted.org/packages/3d/f8/f152c23d669efab0c78ccbc9cb0500c3c1c2a07ab492cf9fac2ac91ffd74/FastApi_RESTful-0.4.3-py3-none-any.whl
mv FastApi_RESTful-0.4.3-py3-none-any.whl fastapi_restful-0.4.3-py3-none-any.whl
poetry add ./fastapi_restful-0.4.3-py3-none-any.whl

@yuval9313 if you could change the case of the project in pyproject.toml and rename the source directory, that would fix this issue.

@yuval9313 Could you please make the change for us to easy upgrade.

@yuval9313
Copy link
Owner

I wonder, is it possible to create both version with the original weird case and lower case one as well? I has some issues with pypi last time I tried to post the .whl file and hadn't gotten to it since

@integrajerome
Copy link
Author

integrajerome commented May 4, 2023

I wonder, is it possible to create both version with the original weird case and lower case one as well? I has some issues with pypi last time I tried to post the .whl file and hadn't gotten to it since

I depend on your code a lot and need to upgrade :s :)
What about creating a new version to change whl case?

@yuval9313
Copy link
Owner

image

And in the second I will pass tests on master I will release a version for only-lowercase packages so pypi itself stop having issues with this package (leaving unresolved until then)

@yuval9313
Copy link
Owner

Works as of 0.4.5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants