fix(deps): Remove absolute requirements #331
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary of Changes
This removes absolute requirements from the requirements.txt file.
Motivation
The specific requirement which has been causing me problems is
attrs==18.1.0
. I have been working on a Looker integration, but thelooker_sdk
library users a feature ofattrs
only available in>=19
. When I install both libraries at the same time, pip installsattrs==18.1.0
due to amundsendatabuilder's restriction, and thenlooker_sdk
fails.It is worth noting that Looker ought to update their own setup.py to include
attrs>=19.0.0
or something like that, but all that would do is make this problem happen at pip install time instead of runtime.In general, pinning dependencies in libraries is liable to cause this kind of problem. I also noticed that a lot of the pinned dependencies were transitive dependencies not actually required by amundsendatabuilder itself. My feeling is that unless there's a specific reason to pin them due to e.g. a bug or issue, pip can sort these out itself.
Thus, I have removed all transitive dependencies in
requirements.txt
, and changed remaining dependencies from==
to>=
.I have also incremented the version number to 3.1.0 so that this change can be picked up immediately.
This is a fairly significant change so I understand if it needs some work - please let me know if there's anything else I need to do.
Tests
No new tests needed. Hopefully this will just pass in CI.
Documentation
N/A
CheckList
Make sure you have checked all steps below to ensure a timely review.
make test