-
Notifications
You must be signed in to change notification settings - Fork 2
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
Feature/check package versions #22
Conversation
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.
Our code is gold! :)
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've suggest a naming change and some minor typing, but that's it.
What you write in the PR description seems to make sense to me. I guess we need to see if this works with our repositories or whether we have any repositories that break the implemented rule.
If we ever need a different rule for whatever reason we can still discuss it as it comes up and possibly modify this versioning rule here.
@pchorus In our daily I understood that we will forbid |
Yes, we decided that there is also no need for |
What about
Changing this to So I wonder if we really should remove |
Argh, stupid Poetry slow resolution :( Maybe we can allow ">" as a hack to make sure that this was added manually? |
One could also add boto3 as an explicit exception to the checker. |
6a01589
to
307e122
Compare
9aa816e
to
95be261
Compare
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.
Did not test, but LGTM in general. I still need to talk to you guys about the "*" stuff.
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 like the idea. Thank you for implementing this! However, I agree with @marns93 regarding pinning the problematic boto3
versions. There is also another problem with poetry: it downloads all boto3
versions to resolve dependencies if you use *
which takes hours every time one run poetry update
. We should either exclude boto3
from check or allow >=
.
0926fd8
to
363e678
Compare
I added a |
363e678
to
29b9ed9
Compare
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.
👍
invalid_package_versions/tests/test_get_invalid_package_versions.py
Outdated
Show resolved
Hide resolved
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.
Thanks for adding the tests.
LGTM. :)
75b7cd6
to
807a7f9
Compare
As discussed @zyv and I created a GitHub Action to check package versions configured in
pyproject.toml
.We want to avoid pinned versions and also lax configuration like using
^
or>=
.All we want to allow is
*
as general solution which is always the preferred version config.If we need to pin version, we should use
~
which allows updates to minor or patch versions (depending on the version number that follows the~
), but never updates major versions which can contain breaking changes.We have tested this action in
django-insurance-api-v2
by using the feature branch of this repository here.I run it with current
pyproject.toml
(https://github.com/moneymeets/django-insurance-api-v2/actions/runs/8632210966/job/23664358558) containing some errors and also with a fixedpyproject.toml
(https://github.com/moneymeets/django-insurance-api-v2/actions/runs/8632335916/job/23662773927).Please share your thoughts.
Is this what we are aiming for?