8000 chore: update yardstick to python 3.11 and refactor to satisfy mypy and black by spiffcs · Pull Request #295 · anchore/yardstick · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

chore: update yardstick to python 3.11 and refactor to satisfy mypy and black #295

New issue
8000

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

Merged
merged 9 commits into from
May 3, 2024

Conversation

spiffcs
Copy link
Contributor
@spiffcs spiffcs commented May 2, 2024

Summary

Yardstick can now use a newer python version.

This PR moves us to using 3.11. It also updates an old issue in ScanConfiguration where a python dictionary was being serialized as a str

This has been restored to dict where the type is correctly reflected as:

dict[str, str | dict]

Other refactors that came with bumping to python 3.11 were performed.

Most notably this is removing return types from instances of staticmethod that tried to return class types before the class was initialized, and updating instances of Optional[foo] too foo | None

Signed-off-by: Christopher Phillips <christopher.phillips@anchore.com>
@spiffcs spiffcs changed the title chore: change type to correct data type chore: change sub dict type to correct data type May 2, 2024
spiffcs added 6 commits May 2, 2024 16:27
Signed-off-by: Christopher Phillips <christopher.phillips@anchore.com>
Signed-off-by: Christopher Phillips <christopher.phillips@anchore.com>
Signed-off-by: Christopher Phillips <christopher.phillips@anchore.com>
Signed-off-by: Christopher Phillips <christopher.phillips@anchore.com>
Signed-off-by: Christopher Phillips <christopher.phillips@anchore.com>
Signed-off-by: Christopher Phillips <christopher.phillips@anchore.com>
@spiffcs spiffcs changed the title chore: change sub dict type to correct data type chore: update yardstick to python 3.11 and refactor to satisfy mypy and black May 3, 2024
spiffcs added 2 commits May 3, 2024 16:39
Signed-off-by: Christopher Phillips <christopher.phillips@anchore.com>
Signed-off-by: Christopher Phillips <christopher.phillips@anchore.com>
@spiffcs spiffcs marked this pull request as ready for review May 3, 2024 21:05
Copy link
Contributor
@wagoodman wagoodman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉

@spiffcs spiffcs merged commit 14514c0 into main May 3, 2024
3 checks passed
@spiffcs spiffcs deleted the scan-config-detail branch May 3, 2024 21:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0