Description
I’m attempting to run pip download
in order to bundle wheels into a zip file to upload to a service without internet access. I need to download all of my dependencies from PyPI and then upload them to the service for the service to run.
While running pip download I hit this error which makes very little sense to me due to the constraint message exactly matching on the version. Particularly since the constraint uses ==
.
Here’s the constraint file used
Error
<code> python -m pip download -r requirements/requirements.txt -d plugins
Looking in links: /usr/local/airflow/plugins
WARNING: Location '/usr/local/airflow/plugins' is ignored: it is either a non-existing path or lacks a specific scheme.
ERROR: Cannot install apache-airflow-providers-amazon==8.16.0 because these package versions have conflicting dependencies.
The conflict is caused by:
The user requested apache-airflow-providers-amazon==8.16.0
The user requested (constraint) apache-airflow-providers-amazon==8.16.0
To fix this you could try to:
1. loosen the range of package versions you've specified
2. remove package versions to allow pip attempt to solve the dependency conflict
</code>
<code> python -m pip download -r requirements/requirements.txt -d plugins
Looking in links: /usr/local/airflow/plugins
WARNING: Location '/usr/local/airflow/plugins' is ignored: it is either a non-existing path or lacks a specific scheme.
ERROR: Cannot install apache-airflow-providers-amazon==8.16.0 because these package versions have conflicting dependencies.
The conflict is caused by:
The user requested apache-airflow-providers-amazon==8.16.0
The user requested (constraint) apache-airflow-providers-amazon==8.16.0
To fix this you could try to:
1. loosen the range of package versions you've specified
2. remove package versions to allow pip attempt to solve the dependency conflict
</code>
python -m pip download -r requirements/requirements.txt -d plugins
Looking in links: /usr/local/airflow/plugins
WARNING: Location '/usr/local/airflow/plugins' is ignored: it is either a non-existing path or lacks a specific scheme.
ERROR: Cannot install apache-airflow-providers-amazon==8.16.0 because these package versions have conflicting dependencies.
The conflict is caused by:
The user requested apache-airflow-providers-amazon==8.16.0
The user requested (constraint) apache-airflow-providers-amazon==8.16.0
To fix this you could try to:
1. loosen the range of package versions you've specified
2. remove package versions to allow pip attempt to solve the dependency conflict
requirements.txt
<code>--constraint "https://raw.githubusercontent.com/apache/airflow/constraints-2.8.1/constraints-3.11.txt"
apache-airflow-providers-amazon==8.16.0
apache-airflow-providers-postgres==5.10.0
# https://seasensor.atlassian.net/browse/SP-4980
--find-links /usr/local/airflow/plugins --no-index
# TODO: Remove these dependencies when we've moved to remote operators. These
# are all Task Code Requirements and not Airflow Requirements
# NOTE: Any requirement found both in https://github.com/iocurrents/data-pipeline/blob/main/scripts/requirements.txt
# and in the constraints file automatically default to the constrains file
# version.
botocore==1.34.67
iniconfig==2.0.0
jmespath==1.0.1
jsonschema==4.21.1
jsonschema-specifications==2023.12.1
markdown-it-py==3.0.0
mdurl==0.1.2
numpy==1.24.4 # Downgraded from 1.24.4
packaging==24.0
pandas==2.1.4 # Downgraded from 2.2.1
pluggy==1.3.0 # Downgrade from 1.4.0
psycopg2==2.9.9
pygments==2.17.2
pytest==7.4.4 # Downgraded from 8.1.1
python-dateutil==2.8.2 # Downgraded from 2.9.0.post0
pytz==2023.3.1.1 # Downgraded from 2024.1
referencing==0.32.1 # Downgraded from 0.34.0
rich==13.7.0 # Downgraded from 13.7.1
rpds-py==0.17.1 # Downgraded from 0.18.0
s3transfer==0.8.2 # Downgraded from 0.10.1
six==1.16.0
tzdata==2023.4 # Downgraded from 2024.1
urllib3==2.0.7 # Upgraded from 1.25.4
</code>
<code>--constraint "https://raw.githubusercontent.com/apache/airflow/constraints-2.8.1/constraints-3.11.txt"
apache-airflow-providers-amazon==8.16.0
apache-airflow-providers-postgres==5.10.0
# https://seasensor.atlassian.net/browse/SP-4980
--find-links /usr/local/airflow/plugins --no-index
# TODO: Remove these dependencies when we've moved to remote operators. These
# are all Task Code Requirements and not Airflow Requirements
# NOTE: Any requirement found both in https://github.com/iocurrents/data-pipeline/blob/main/scripts/requirements.txt
# and in the constraints file automatically default to the constrains file
# version.
botocore==1.34.67
iniconfig==2.0.0
jmespath==1.0.1
jsonschema==4.21.1
jsonschema-specifications==2023.12.1
markdown-it-py==3.0.0
mdurl==0.1.2
numpy==1.24.4 # Downgraded from 1.24.4
packaging==24.0
pandas==2.1.4 # Downgraded from 2.2.1
pluggy==1.3.0 # Downgrade from 1.4.0
psycopg2==2.9.9
pygments==2.17.2
pytest==7.4.4 # Downgraded from 8.1.1
python-dateutil==2.8.2 # Downgraded from 2.9.0.post0
pytz==2023.3.1.1 # Downgraded from 2024.1
referencing==0.32.1 # Downgraded from 0.34.0
rich==13.7.0 # Downgraded from 13.7.1
rpds-py==0.17.1 # Downgraded from 0.18.0
s3transfer==0.8.2 # Downgraded from 0.10.1
six==1.16.0
tzdata==2023.4 # Downgraded from 2024.1
urllib3==2.0.7 # Upgraded from 1.25.4
</code>
--constraint "https://raw.githubusercontent.com/apache/airflow/constraints-2.8.1/constraints-3.11.txt"
apache-airflow-providers-amazon==8.16.0
apache-airflow-providers-postgres==5.10.0
# https://seasensor.atlassian.net/browse/SP-4980
--find-links /usr/local/airflow/plugins --no-index
# TODO: Remove these dependencies when we've moved to remote operators. These
# are all Task Code Requirements and not Airflow Requirements
# NOTE: Any requirement found both in https://github.com/iocurrents/data-pipeline/blob/main/scripts/requirements.txt
# and in the constraints file automatically default to the constrains file
# version.
botocore==1.34.67
iniconfig==2.0.0
jmespath==1.0.1
jsonschema==4.21.1
jsonschema-specifications==2023.12.1
markdown-it-py==3.0.0
mdurl==0.1.2
numpy==1.24.4 # Downgraded from 1.24.4
packaging==24.0
pandas==2.1.4 # Downgraded from 2.2.1
pluggy==1.3.0 # Downgrade from 1.4.0
psycopg2==2.9.9
pygments==2.17.2
pytest==7.4.4 # Downgraded from 8.1.1
python-dateutil==2.8.2 # Downgraded from 2.9.0.post0
pytz==2023.3.1.1 # Downgraded from 2024.1
referencing==0.32.1 # Downgraded from 0.34.0
rich==13.7.0 # Downgraded from 13.7.1
rpds-py==0.17.1 # Downgraded from 0.18.0
s3transfer==0.8.2 # Downgraded from 0.10.1
six==1.16.0
tzdata==2023.4 # Downgraded from 2024.1
urllib3==2.0.7 # Upgraded from 1.25.4
Environment Information
<code>python --version
Python 3.11.9
</code>
<code>python --version
Python 3.11.9
</code>
python --version
Python 3.11.9