-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
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
Changelog for 1.13 #18000
Changelog for 1.13 #18000
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,6 +2,49 @@ | |
|
||
## Next release | ||
|
||
## Mypy 1.13 | ||
|
||
We’ve just uploaded mypy 1.13 to the Python Package Index ([PyPI](https://pypi.org/project/mypy/)). | ||
Mypy is a static type checker for Python. You can install it as follows: | ||
|
||
python3 -m pip install -U mypy | ||
|
||
You can read the full documentation for this release on [Read the Docs](http://mypy.readthedocs.io). | ||
|
||
Note that unlike typical releases, Mypy 1.13 does not have any changes to type checking semantics | ||
from 1.12.1. | ||
|
||
### Improved performance | ||
|
||
Mypy 1.13 contains several performance improvements. Users can expect mypy to be 5-20% faster. | ||
In environments with long search paths (such as environments using many editable installs), mypy | ||
can be significantly faster, e.g. 2.2x faster in the use case targeted by these improvements. | ||
|
||
Mypy 1.13 allows use of the `orjson` library for handling the cache instead of the stdlib `json`, | ||
for improved performance. You can ensure the presence of `orjson` using the `faster-cache` extra: | ||
|
||
python3 -m pip install -U mypy[faster-cache] | ||
|
||
Mypy may depend on `orjson` by default in the future. | ||
|
||
These improvements were contributed by Shantanu. | ||
|
||
List of changes: | ||
* Significantly speed up file handling error paths (Shantanu, PR [17920](https://github.com/python/mypy/pull/17920)) | ||
* Use fast path in modulefinder more often (Shantanu, PR [17950](https://github.com/python/mypy/pull/17950)) | ||
* Let mypyc optimise os.path.join (Shantanu, PR [17949](https://github.com/python/mypy/pull/17949)) | ||
* Make is_sub_path faster (Shantanu, PR [17962](https://github.com/python/mypy/pull/17962)) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Minor: don't mention There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'll keep the mention... I think all of these changes are basically internal implementation details (it would be worrisome if they were not ;-) ) The specific |
||
* Speed up stubs suggestions (Shantanu, PR [17965](https://github.com/python/mypy/pull/17965)) | ||
* Use sha1 for hashing (Shantanu, PR [17953](https://github.com/python/mypy/pull/17953)) | ||
* Use orjson instead of json, when available (Shantanu, PR [17955](https://github.com/python/mypy/pull/17955)) | ||
* Add faster-cache extra, test in CI (Shantanu, PR [17978](https://github.com/python/mypy/pull/17978)) | ||
|
||
### Acknowledgements | ||
Thanks to all mypy contributors who contributed to this release: | ||
|
||
- Shantanu Jain | ||
- Jukka Lehtosalo | ||
|
||
## Mypy 1.12 | ||
|
||
We’ve just uploaded mypy 1.12 to the Python Package Index ([PyPI](https://pypi.org/project/mypy/)). Mypy is a static type | ||
|
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.
are there any stats for this? Any downsides? What's the comparison with sqlite?
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.
Depends on your workload and whether incremental or not, Jukka measured 10-15% in #17955 (comment) , I've seen the lower end of that
It composes with sqlite, since mypy's sqlite thing just dumps json into sqlite. I think sqlite cache is mainly a way to workaround filesystem performance. I haven't benchmarked (or really used) the sqlite option. Jukka mentions he'd like to make it the default in the future though: #17955 (comment)