-
Notifications
You must be signed in to change notification settings - Fork 27
Update dependencies #198
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update dependencies #198
Conversation
@eviljeff, would you have the bandwidth to look at this at some point? |
@KevinMind would be good for this, and has volunteered to take on the review, if you can give him the necessary reviewing permissions |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't see anything in particular that would stop me from approving. I did find a few areas where you could consider performance impact and there are some other quick wins you can add here to make the workflows more composable, concise or run faster in general.
@@ -0,0 +1,50 @@ | |||
name: CI |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems like there are many python versions in use across the different jobs. If this is intentionally, adding a comment specifying an issue link or reason why a particular version is required will make someone (maybe you) reviewing this yaml file in 6 years very appreciative :)
If otherwise you don't need different versions you could pin the version using an environment variable and specifying this across the different jobs. This is just a suggestion.
env:
- PYTHON_VERSION: "3.10"
jobs:
lint:
...
with:
python-version: ${{ env.PYTHON_VERSION }}
Even in a scenario where you need specific versions per purpose, using a variable can also help encapsulate that purpose.
env:
PYTHON_VERSION_ WITH_SPECIFIC_FEATURE: "3.6"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Much of that range is due to inheriting a spread from before. The 3.12 for lint
is just the current version and could probably be dropped to rely on the default provided by ubuntu-latest
; baseline
uses 3.6 because we still claim compatibility with that, and documentation
's 3.9 is slightly arbitrary, but I'm loathe to spend many cycles on it given the doc build's complexity.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You explained it excellently just now. I Just wonder if pulling that information out of this comment thread into the action definition would be helpful for someone like myself reading the code for the first time without context. Just a light suggestion to do with what you think is best.
- fluent.syntax==0.17.0 six | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-python@v4 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you use setup-python@v5 here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Dunno, didn't try. I intend to re-refactor this soon after landing this PR, by incrementing the minimum to around 3.9, which will let us get rid of this ubuntu-20.04
runner as well. The action versions will get updated at that time as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
with: | ||
python-version: 3.12 | ||
- run: python -m pip install -r dev-requirements.txt | ||
- run: python -m pip install ./fluent.syntax ./fluent.runtime |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess one consequence of merging the linting jobs on the GHA level is that if there is an error installing fluent.syntax you will not know if there would have also been an error in fluent.runtime.
Previously being in separate workflows would have revealed this as they could run separately and in parallel.
Does this have a performance impact on the CI run time as well? Have you considered a reusable action for setting up the environment that can then be shared across many jobs to allow centralizing configuration while still parallelizing execution?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Eh, sure, but at the cost of additional complexity and interdependency. I'm trying to keep these actions simple, and tbh I'm not too worried about one error potentially masking a later error, given that it'll be revealed after fixing the first one.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would be super peaved if I spent a bunch of time fixing one error only to reveal another that could have been known before, but I understand there are tradeoffs. Just wondering if you thought about it.
Maintentance-y updates to the tool configs and CI actions, adding top-level
dev-requirements.txt
andpyproject.toml
.After merging, I intend to push a couple of commits directly to
main
applyingisort
andblack
to the codebase; they're left out of here as that'll touch pretty much all files.The individual commits are intended to be relatively discrete steps.