IN 1240 - Replace pipenv check with pip-audit and maintenance #206
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.
Purpose and background context
This PR accomplishses a couple of tightly coupled things:
pipenv checkto usepip-audit, which is applied broadly across repos (Jira ticket)luigiresulting in installation of3.6.0, and some necessary type checking skipsluigihas been pinned to3.5.1for some time to avoid a barrage of type checking errors that3.5.2introduced. But with the move topip-audit, a vulnerability was found with3.5.1that version3.6.0(most recent) resolves. While the upgrade to python 3.12 was inconsequential, upgradingluigiresurfaced those mypy type checking errors.There is a good deal of commentary in the commit that unpins
luigi, but a short paraphrasing here:This project is largely a wrapper around
luigitasks. We define some custom classes that extendluigi.Taskandluigi.LocalTarget(the output of tasks). Each of our actual tasks is just an extension of these; 99% boilerplate with a sprinkling of business logic. This is what madeluigiappealing!However,
luigiis very poorly typed. Even the optionalluigi.mypymypy plugin does not seem to help (possibly an artifact of our extensions. Therefore it was decided to skip mypy type checking forhrqb.base.*andhrqb.task.*. In doing so, we:luigiwhich is important for vulnerability reasons, and keeping up-to-dateAs a big fan of type annotations and linting, the decision was not made lightly. But this allows us to keep this repository up-to-date dependency wise, and as the git commit mentions, there are some options if we'd like to layer on type checking again in the future.
How can a reviewer manually see the effects of these changes?
make test+make lintis about our best option at the moment, given the sensitivity of the data.Includes new or updated dependencies?
YES: bumps to python 3.12 and unpins
luigiresulting in installation of3.6.0Changes expectations for external applications?
NO
What are the relevant tickets?
Developer
Code Reviewer(s)