Skip to content
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

SCons: Update mypy #85192

Merged
merged 1 commit into from
Dec 11, 2023
Merged

SCons: Update mypy #85192

merged 1 commit into from
Dec 11, 2023

Conversation

Repiteo
Copy link
Contributor

@Repiteo Repiteo commented Nov 21, 2023

Implements a handful of minor adjustments all revolving around mypy

  • Added a new section to the .gitignore to explicitly handle the mypy cache after running the mypy test script (or mypy in general)
  • Added a new value to the mypy config: no_implicit_optional = True. This is because mypy made this their default value in later versions1, so adding a rule one way or the other clears up ambiguity for mypy installed from other sources (eg: vscode extension)
  • Fixes two files that weren't conforming to no_implicit_optional = True. While they could've been left alone if the value was changed to false, all cases of changed arguments were right beside another argument that was already using an explicit optional wrapper; as such, the changes were sensible in-context & just so happened to be the only offending areas in the entire repo to begin with

Footnotes

  1. https://github.com/hauntsaninja/no_implicit_optional#whats-going-on

@Repiteo Repiteo requested a review from a team as a code owner November 21, 2023 21:47
@akien-mga akien-mga added this to the 4.3 milestone Nov 22, 2023
@Repiteo Repiteo changed the title SCons: mypy updates [SCons] Update mypy Dec 1, 2023
@Repiteo Repiteo changed the title [SCons] Update mypy SCons: Update mypy Dec 1, 2023
@akien-mga akien-mga merged commit 2df8c3c into godotengine:master Dec 11, 2023
15 checks passed
@akien-mga
Copy link
Member

Thanks!

@Repiteo Repiteo deleted the scons-mypy-update branch December 12, 2023 02:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants