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

Release 1.7 planning #16341

Closed
2 tasks done
JukkaL opened this issue Oct 27, 2023 · 31 comments
Closed
2 tasks done

Release 1.7 planning #16341

JukkaL opened this issue Oct 27, 2023 · 31 comments
Assignees
Labels
meta Issues tracking a broad area of work

Comments

@JukkaL
Copy link
Collaborator

JukkaL commented Oct 27, 2023

I'm planning to make a 1.7 release around Nov 2 to Nov 6 (tentative timeline).

Please post here any issues you'd like to see fixed in the release, or PRs you'd like to have merged. I'll cut the release branch around Oct 30.

This release will be the first one where we create the release blog post in the repo (either in CHANGELOG.md or in a temporary file which we'll add to CHANGELOG.md at the time of the release).

Here are some other major changes I'm hoping to include:

  • Enable --new-type-inference by default (subject to no major known regressions).
  • Enable TypeVarTuple by default.
@JukkaL JukkaL added the meta Issues tracking a broad area of work label Oct 27, 2023
@JukkaL
Copy link
Collaborator Author

JukkaL commented Oct 27, 2023

@JukkaL JukkaL self-assigned this Oct 27, 2023
@KRRT7
Copy link

KRRT7 commented Oct 27, 2023

i'm not sure if this the right place to mention this but, you might need to add setuptools as a dependency for python 3.12+

@AlexWaygood
Copy link
Member

i'm not sure if this the right place to mention this but, you might need to add setuptools as a dependency for python 3.12+

Already done in ff7ac75

@wRAR

This comment was marked as resolved.

@ilevkivskyi
Copy link
Member

It would be great to have:

These are all fixes for dmypy inspect, they should be all low-risk, as they don't touch "regular" daemon logic.

@JukkaL
Copy link
Collaborator Author

JukkaL commented Oct 30, 2023

#15913 please

This was merged a while ago, so it will be included.

@JukkaL
Copy link
Collaborator Author

JukkaL commented Oct 30, 2023

I've now cut the release branch: https://github.com/python/mypy/tree/release-1.7

We can still cherry-pick important/low-risk fixes and documentation updates.

@ilevkivskyi
Copy link
Member

May be good to add #16381 (Unpack crash fix)

@JukkaL
Copy link
Collaborator Author

JukkaL commented Nov 1, 2023

Cherry-picked these PRs:

@hauntsaninja
Copy link
Collaborator

I wouldn't mind a cherry pick of #16407

@JukkaL
Copy link
Collaborator Author

JukkaL commented Nov 9, 2023

I wrote 1.7 release notes in the changelog, which will be copied to the release blog post: https://github.com/python/mypy/blob/master/CHANGELOG.md

Please review. I'll leave a comment here when I've copied it to the blog, after which we shouldn't make any major changes to the changelog.

The release will probably go out tomorrow, 10 Nov, if I don't get distracted.

@ilevkivskyi
Copy link
Member

@JukkaL Two comments on the blog post:

  • I think it is worth mentioning new --enable-incomplete-feature=PreciseTupleTypes. And maybe also in general mention that from now on we will try to use --enable-incomplete-feature as a more systematic way to try new features. Note there are some docs https://mypy.readthedocs.io/en/latest/command_line.html#enabling-incomplete-experimental-features, feel free to edit them if you want.
  • You refer to PEP 692 in description of TypedDict unpack. I think it may be worth mentioning that there are some intentional deviations from the PEP. The author of the PEP actually agrees it should be amended, but PEP is already accepted, so I don't know how they will sort it out. The summary is that unlike in the current edition of the PEP mypy always treats signatures with Unpack[SomeTypedDict] as equivalent to their expanded forms.

@ilevkivskyi
Copy link
Member

Another thing is that there are two crashes with TypeVarTuple (one came with a PR, I will merge it soon). Not sure what to do with this:

@ilevkivskyi
Copy link
Member

FWIW the fix for the second crash is very low risk: it is just an obvious typo that I forgot to test: #16428

@ilevkivskyi
Copy link
Member

Fix for the other crash looks also low-risk #16444

@JukkaL
Copy link
Collaborator Author

JukkaL commented Nov 10, 2023

Cherry-picked these PRs:

I will cherry-pick #16444 once it's merged.

@ilevkivskyi
Copy link
Member

Merged #16444

@JukkaL
Copy link
Collaborator Author

JukkaL commented Nov 10, 2023

Cherry-picked #16444.

@JukkaL
Copy link
Collaborator Author

JukkaL commented Nov 10, 2023

Changelog updates: #16446 (I will leave it open for a while but will merge it fairly soon)

@JukkaL
Copy link
Collaborator Author

JukkaL commented Nov 10, 2023

Mypy 1.7 is out: https://mypy-lang.blogspot.com/2023/11/mypy-17-released.html

@DanielNoord
Copy link

DanielNoord commented Nov 10, 2023

Congrats with the release guys!

Sadly, I think I found a regression: #16451. Let me know if I can provide more details.

@jessemyers-lettuce
Copy link

FYI, this release "regressed" pydantic usage. This snippet:

from pydantic import BaseModel

class Foo(BaseModel):
    pass

Now raises:

test.py:3: error: Explicit "Any" is not allowed  [misc]
    class Foo(BaseModel):
    ^~~~~~~~~~~~~~~~~~~~
test.py:3: error: Type of decorated function contains type "Any"
("Callable[[DefaultNamedArg(dict[str, Any] | None, '__pydantic_extra__'), DefaultNamedArg(set[str], '__pydantic_fields_set__'), DefaultNamedArg(dict[str, Any] | None, '__pydantic_private__')], None]")  [misc]
    class Foo(BaseModel):
    ^~~~~~~~~~~~~~~~~~~~
Found 2 errors in 1 file (checked 1 source file)

I'd guess that this behavior is correct... there is, in fact, an explicit Any in the BaseModel type definition, but it's going to mean a lot of code has to be updated to ignore this behavior.

@hauntsaninja
Copy link
Collaborator

@jessemyers-lettuce could you open a new issue with more details? I can't reproduce.

@jessemyers-lettuce
Copy link

@hauntsaninja Done. See #16454

@ilevkivskyi
Copy link
Member

Possible candidates for 1.7.1:

@ilevkivskyi
Copy link
Member

Two more potential candidates for 1.7.1:

@ilevkivskyi
Copy link
Member

Another candidate from me for 1.7.1:

@JukkaL
Copy link
Collaborator Author

JukkaL commented Nov 15, 2023

There may be a recent 1-2% perf regression, possibly related to some of the fixes that we are planning to include in 1.7.1. Perf data: https://github.com/mypyc/mypyc-benchmark-results/blob/master/reports/benchmarks/mypy_self_check.md

I'm planning to run some performance comparisons locally to get a better idea of whether there actually is a regression, since the automatically generated performance metrics are a bit noisy. The regression is small enough that even if it's real, we can probably proceed, but it seems worth it first check if there is some trivial fix.

@mr-c
Copy link
Contributor

mr-c commented Nov 16, 2023

I nominate #16484 for 1.7.1

@JukkaL
Copy link
Collaborator Author

JukkaL commented Nov 22, 2023

@JukkaL
Copy link
Collaborator Author

JukkaL commented Nov 23, 2023

1.7.1 is out now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
meta Issues tracking a broad area of work
Projects
None yet
Development

No branches or pull requests

9 participants