-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Closed
Labels
kind/questionUser questions (candidates for conversion to discussion)User questions (candidates for conversion to discussion)status/external-issueIssue is caused by external project (platform, dep, etc)Issue is caused by external project (platform, dep, etc)
Description
- Poetry version: Poetry (version 1.2.2)
- Python version: Python: 3.10.8
- OS version and name: MacOS 13.0.1
- pyproject.toml:
[tool.poetry.dependencies]
python = "^3.10"
apache-airflow-providers-google = { version = "==8.5.0rc1", allow-prereleases = true }
- I am on the latest stable Poetry version, installed using a recommended method.
- I have searched the issues of this repo and believe that this is not a duplicate.
- In version-constraints prefix-matching (with .*) is not respected after a pre-release version #6774 looks related but is a different error as that is installing incorrect packages
- I have consulted the FAQ and blog for any relevant entries or release notes.
- If an exception occurs when executing a command, I executed it again in debug mode (
-vvvoption) and have included the output below.
Issue
I am unable to run poetry lock with the above dependency.
Expected
Poetry locks correctly using apache-airflow-providers-common-sql==1.3.0rc1
Actual
Poetry returns the following error
poetry lock
Updating dependencies
Resolving dependencies... (1.5s)
Because apache-airflow-providers-google (8.5.0rc1) depends on apache-airflow-providers-common-sql (>=1.3.0) which doesn't match any versions, apache-airflow-providers-google is forbidden.
So, because poetry depends on apache-airflow-providers-google (==8.5.0rc1), version solving failed.
It looks like poetry has the following bug
Poetry is not supported to install airflow, and it has apparently a bug that it cannot properly handle the vaild >= .* requirement.
Note: the reproducibility of this example will stop once airflow publishes the final release of apache-airflow-providers-common-sql==1.3.0
Verifying that pypi has the expected requirement
API response
import json
import requests
package_name = 'apache-airflow-providers-google/8.5.0rc1'
url = 'https://pypi.python.org/pypi/' + str(package_name) + '/json'
data = requests.get(url).json()
print(data['info']['requires_dist'])for apache-airflow-provider-common-sql returns the following
apache-airflow-providers-common-sql (>=1.3.0.*)
Further Notes
pipenv & pip run without issue
Pipenv
Pipfile
[packages]
apache-airflow-providers-google = { version = "==8.5.0rc1", pre="true" }
CLI
mkdir test-pipenv && cd test-pipenv
pip install pipenv
pipenv lock
nano pipfile
pipenv lock
Locking [packages] dependencies...
Building requirements...
Resolving dependencies...
✔ Success!
Locking [dev-packages] dependencies...
Updated Pipfile.lock (43302be42e771518e472473549c7ab11902fd6f2e7eed04c64ffcd2d5f9be4e8)!
Locked Packages
...
"apache-airflow-providers-common-sql": {
"hashes": [
"sha256:9308d3ac4d1f888f1a1f91c18cfa493291e333635cf0a0f93565581a83b1f097",
"sha256:f5eb101f15a3535f879509873992d7194ef3e2a48316c984a0fc2a3a3af9001e"
],
"markers": "python_version ~= '3.7'",
"version": "==1.3.0rc1"
},
"apache-airflow-providers-google": {
"hashes": [
"sha256:a6d94a647c4dca9b2b75b4bf98c20c3809eb4ff8ccf4e7219f19df8fec3ea0de",
"sha256:db9105714472b9cf344b55a72172dd87d85b7de5c8c5755bd86007c23d3ec3cf"
],
"index": "pypi",
"version": "==8.5.0rc1"
},
...
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
kind/questionUser questions (candidates for conversion to discussion)User questions (candidates for conversion to discussion)status/external-issueIssue is caused by external project (platform, dep, etc)Issue is caused by external project (platform, dep, etc)