Closed jakob-keller closed 1 year ago
Hello! Thank you for the feature request.
Sure, good idea!
Here's how pyproject.toml
would need to look like to make this work.
[tool.poetry.dependencies]
botocore = { version = "1.31.64", optional = true }
python = "^3.7"
types-awscrt = "*"
typing-extensions = { version = ">=4.1.0", python = "<3.9" }
[tool.poetry.extras]
botocore = [
"botocore",
]
The actual botocore version would need to be bumped through publish_on_update.yml
:
poetry add --optional botocore==${STUBS_VERSION}
@vemel I think the CI issues are due to the fact that the PR was slightly stale. This should fix the issues:
poetry add --optional botocore==1.31.73
@jakob-keller thanks for letting me know. I optional botocore
it to 1.31.73
. Thanks for updating publish CI job as well!
This request is inspired by the optional
boto3
extra offered byboto3-stubs
. Selecting the extra sets a hard pin on the versions ofboto3
andbotocore
, effectively providing convenient synchronisation of those packages' installed versions:pip install boto3==1.28.60 boto3-stubs[boto3]
will install version 1.28.60 of both boto3 and boto3-stubs. Despite there being available a more recent version of boto3-stubs.Such a simple mechanism might also be offered by
botocore-stubs
: A new extra namedbotocore
would set a hard pin to the respective version ofbotocore
.