Pin botocore dependency to a minor version range (like boto3) rather than an exact patch version #5563
Labels
closed-for-staleness
feature-request
A feature should be added or improved.
installation
p3
This is a minor priority issue
response-requested
Waiting on additional info and feedback. Will move to "closing-soon" in 7 days.
Is your feature request related to a problem? Please describe.
awscli
pins itsbotocore
dependency to an exact patch version. For example,awscli==1.18.143
requiresbotocore==1.18.2
. However,boto3
handles itsbotocore
dependency in a different (and, seemingly, better) way, by pinning it to a range representing the current patch version up to the next minor version. For example,boto3==1.15.2
requiresbotocore>=1.18.2,<1.19.0
. The effect that this ends up having is that for projects which depend on bothawscli
andboto3
,awscli
must always be updated beforeboto3
can be updated, for what seems like no necessary technical reason, in order for dependency resolution using common tools likepipenv
(21k stars) to succeed.And while this can be somewhat worked around in certain projects (by explicitly pinning versions of
awscli
andboto3
, and making sure to updateawscli
before updatingboto3
), it becomes much more arduous if your project also relies on a 3rd party dependency which does not explicitly pin a version ofboto3
. For example, the latest version of the popular (4k stars) librarymoto==1.3.16
requiresboto3>=1.9.201
, which causes the transitiveboto3
dependency identified by a tool likepipenv
to always be the latest version ofboto3
. As we've established, attempting to resolve dependencies using a newer version ofboto3
thanawscli
will always fail, so the end result of this is that anytime a new release ofboto3
/awscli
is released (which is nearly every day), if using a 3rd party which has an unpinned transitive dependency onboto3
, all dependency resolution using a tool likepipenv
begins failing, even for completely unrelated dependencies, untilawscli
has been updated.For example, here is the dependency resolution error we began receiving from
pipenv
yesterday upon the release of newboto3
/awscli
versions:And, for clarity, here is what our dependencies looked like in our
Pipfile
yesterday:And while manually updating our dependency pin to
awscli==1.18.143
resolved the issue for the day, it will return when1.18.144
is released, presumably, later today.Describe the solution you'd like
For
awscli
to pin itsbotocore
dependency the same wayboto3
does - to a range including all future patch versions of the same minor version. This will at least limit this occurrence from happening nearly every day, to only happening when a new minor release ofbotocore
is created.So instead of:
awscli==1.18.143
requiringbotocore==1.18.2
awscli==1.18.143
should requirebotocore>=1.18.2,<1.19.0
(which is the samebotocore
requirement that the correspondingboto3==1.15.2
release has)Describe alternatives you've considered
As mentioned, in the case outlined, the alternative is to manually update
awscli
every time there is a new patch release (which is almost every day) before being able to successfully resolve dependencies via common dependency resolution tools such aspipenv
.The text was updated successfully, but these errors were encountered: