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

build(deps): bump mypy from 0.920 to 0.930 #3573

Merged
merged 3 commits into from Dec 29, 2021

Conversation

PrettyWood
Copy link
Member

Change Summary

Related issue number

Checklist

  • Unit tests for the changes exist
  • Tests pass on CI and coverage remains at 100%
  • Documentation reflects the changes where applicable
  • changes/<pull request or issue id>-<github username>.md file added describing change
    (see changes/README.md for details)
  • My PR is ready to review, please add a comment including the phrase "please review" to assign reviewers

Due to python/mypy#11332, mypy would crash
because `__builtins__` is not part of `ctx.api` modules, `builtins` is
@samuelcolvin
Copy link
Member

Looks good, can we add a change description?

Seems sad up introduce all those "type ignores", is that our fault or mypy's fault?

Does this need to be noted in the docs and/or marked as a breaking change?

@christianbundy
Copy link
Contributor

Does this need to be noted in the docs and/or marked as a breaking change?

Yes, the latest pydantic release supports mypy 0.910 but this drops support for mypy < 0.930. I think this change should be released in pydantic 2.0.0.

@samuelcolvin
Copy link
Member

I think we just add a "breaking change" note in the changelog and go for it.

@christianbundy
Copy link
Contributor

I would expect zero breaking changes between v1.8.2 and v1.9.0 -- does pydantic use semver, or some other versioning scheme?

@samuelcolvin
Copy link
Member

Not strictly, see other releases.

I would expect zero breaking changes between v1.8.2 and v1.9.0

Unfortunately that's not realistic, in pydantic or any other software.

@christianbundy
Copy link
Contributor

christianbundy commented Dec 28, 2021

Maybe I should’ve said “zero intentional breaking changes”. :~)

Could you help me understand the downside to releasing a new major version? IMO putting a “breaking change” like in the changelog for a minor version should raise a parsing error.


Not strictly, see other releases.

EDIT: I looked at our changelogs and can see that Pydantic regularly includes breaking changes in minor releases. I have questions about this policy but they're unrelated to this specific PR -- we can table this, sorry for the noise.

@samuelcolvin
Copy link
Member

Maybe I should’ve said “zero intentional breaking changes”. :~)

Ye, I agree with you that this would be a better approach.

I want to get v2 (with big changes to how validation and validators work) out in the new year. After that, I think we should move to strict semvar and more regular major releases.

@samuelcolvin
Copy link
Member

I'm going to merge this and add a change description elsewhere.

@samuelcolvin samuelcolvin merged commit 8ef492b into pydantic:master Dec 29, 2021
samuelcolvin added a commit that referenced this pull request Dec 29, 2021
samuelcolvin added a commit that referenced this pull request Dec 30, 2021
* cleanup bumping mypy to 0.930, #3573

* add tests for old mypy

* tweak test-old-mypy job

* alter mypy plugin to work with older versions

* mypy.py compatibility with multiple versions

* fix mypy tests to allow for varied output

* toml parsing, fix #3579

* formatting :-(

* ignore missing types for toml package

* remove unused ignore_missing_imports

* undo removal of ignore_missing_imports for dotenv

* tweak coverage ignore

* fully uninstall mypy and toml/tomli
ntaylorwss pushed a commit to nicejobinc/pydantic that referenced this pull request Jun 24, 2022
* build(deps): bump mypy from 0.920 to 0.930

* fix: avoid mypy plugin crash

Due to python/mypy#11332, mypy would crash
because `__builtins__` is not part of `ctx.api` modules, `builtins` is

* fix tests
ntaylorwss pushed a commit to nicejobinc/pydantic that referenced this pull request Jun 24, 2022
* cleanup bumping mypy to 0.930, pydantic#3573

* add tests for old mypy

* tweak test-old-mypy job

* alter mypy plugin to work with older versions

* mypy.py compatibility with multiple versions

* fix mypy tests to allow for varied output

* toml parsing, fix pydantic#3579

* formatting :-(

* ignore missing types for toml package

* remove unused ignore_missing_imports

* undo removal of ignore_missing_imports for dotenv

* tweak coverage ignore

* fully uninstall mypy and toml/tomli
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.

None yet

3 participants