← Back to issue list

build(deps): update dependency mypy to ~=1.18.2 (main)

View original Github issue

Metadata

Project
rockcraft
Number
#990
Type
pull request
State
merged
Author
renovate[bot]
Labels
PR: Dependencies
Created
Updated
Closed

Current evaluation

Merged PR #990 via commit db194f40, updating mypy from ~=1.17.1 to ~=1.18.2.

Resolution: closed resolved

Reason: The approved Renovate dependency update was merged into main as commit db194f40, with all reported CI checks passing.

Evaluated by: mr-cal-bot

No scores available.

Issue body

This PR contains the following updates: | Package | Change | Age | Confidence | |---|---|---|---| | [mypy](https://redirect.github.com/python/mypy) ([changelog](https://mypy.readthedocs.io/en/latest/changelog.html)) | `~=1.17.1` -> `~=1.18.2` | [![age](https://developer.mend.io/api/mc/badges/age/pypi/mypy/1.18.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://developer.mend.io/api/mc/badges/confidence/pypi/mypy/1.17.1/1.18.2?slim=true)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes <details> <summary>python/mypy (mypy)</summary> ### [`v1.18.2`](https://redirect.github.com/python/mypy/blob/HEAD/CHANGELOG.md#Mypy-1182) [Compare Source](https://redirect.github.com/python/mypy/compare/v1.18.1...v1.18.2) - Fix crash on recursive alias (Ivan Levkivskyi, PR [19845](https://redirect.github.com/python/mypy/pull/19845)) - Add additional guidance for stubtest errors when runtime is `object.__init__` (Stephen Morton, PR [19733](https://redirect.github.com/python/mypy/pull/19733)) - Fix handling of None values in f-string expressions in mypyc (BobTheBuidler, PR [19846](https://redirect.github.com/python/mypy/pull/19846)) ### [`v1.18.1`](https://redirect.github.com/python/mypy/blob/HEAD/CHANGELOG.md#Mypy-1181) [Compare Source](https://redirect.github.com/python/mypy/compare/v1.17.1...v1.18.1) We’ve just uploaded mypy 1.18.1 to the Python Package Index ([PyPI](https://pypi.org/project/mypy/)). Mypy is a static type checker for Python. This release includes new features, performance improvements and bug fixes. 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). ##### Mypy Performance Improvements Mypy 1.18.1 includes numerous performance improvements, resulting in about 40% speedup compared to 1.17 when type checking mypy itself. In extreme cases, the improvement can be 10x or higher. The list below is an overview of the various mypy optimizations. Many mypyc improvements (discussed in a separate section below) also improve performance. Type caching optimizations have a small risk of causing regressions. When reporting issues with unexpected inferred types, please also check if `--disable-expression-cache` will work around the issue, as it turns off some of these optimizations. - Improve self check performance by 1.8% (Jukka Lehtosalo, PR [19768](https://redirect.github.com/python/mypy/pull/19768), [19769](https://redirect.github.com/python/mypy/pull/19769), [19770](https://redirect.github.com/python/mypy/pull/19770)) - Optimize fixed-format deserialization (Ivan Levkivskyi, PR [19765](https://redirect.github.com/python/mypy/pull/19765)) - Use macros to optimize fixed-format deserialization (Ivan Levkivskyi, PR [19757](https://redirect.github.com/python/mypy/pull/19757)) - Two additional micro‑optimizations (Ivan Levkivskyi, PR [19627](https://redirect.github.com/python/mypy/pull/19627)) - Another set of micro‑optimizations (Ivan Levkivskyi, PR [19633](https://redirect.github.com/python/mypy/pull/19633)) - Cache common types (Ivan Levkivskyi, PR [19621](https://redirect.github.com/python/mypy/pull/19621)) - Skip more method bodies in third‑party libraries for speed (Ivan Levkivskyi, PR [19586](https://redirect.github.com/python/mypy/pull/19586)) - Simplify the representation of callable types (Ivan Levkivskyi, PR [19580](https://redirect.github.com/python/mypy/pull/19580)) - Add cache for types of some expressions (Ivan Levkivskyi, PR [19505](https://redirect.github.com/python/mypy/pull/19505)) - Use cache for dictionary expressions (Ivan Levkivskyi, PR [19536](https://redirect.github.com/python/mypy/pull/19536)) - Use cache for binary operations (Ivan Levkivskyi, PR [19523](https://redirect.github.com/python/mypy/pull/19523)) - Cache types of type objects (Ivan Levkivskyi, PR [19514](https://redirect.github.com/python/mypy/pull/19514)) - Avoid duplicate work when checking boolean operations (Ivan Levkivskyi, PR [19515](https://redirect.github.com/python/mypy/pull/19515)) - Optimize generic inference passes (Ivan Levkivskyi, PR [19501](https://redirect.github.com/python/mypy/pull/19501)) - Speed up the default plugin (Jukka Lehtosalo, PRs [19385](https://redirect.github.com/python/mypy/pull/19385) and [19462](https://redirect.github.com/python/mypy/pull/19462)) - Remove nested imports from the default plugin (Ivan Levkivskyi, PR [19388](https://redirect.github.com/python/mypy/pull/19388)) - Micro‑optimize type expansion (Jukka Lehtosalo, PR [19461](https://redirect.github.com/python/mypy/pull/19461)) - Micro‑optimize type indirection (Jukka Lehtosalo, PR [19460](https://redirect.github.com/python/mypy/pull/19460)) - Micro‑optimize the plugin framework (Jukka Lehtosalo, PR [19464](https://redirect.github.com/python/mypy/pull/19464)) - Avoid temporary set creation in subtype checking (Jukka Lehtosalo, PR [19463](https://redirect.github.com/python/mypy/pull/19463)) - Subtype checking micro‑optimization (Jukka Lehtosalo, PR [19384](https://redirect.github.com/python/mypy/pull/19384)) - Return early where possible in subtype check (Stanislav Terliakov, PR [19400](https://redirect.github.com/python/mypy/pull/19400)) - Deduplicate some types before joining (Stanislav Terliakov, PR [19409](https://redirect.github.com/python/mypy/pull/19409)) - Speed up type checking by caching argument inference context (Jukka Lehtosalo, PR [19323](https://redirect.github.com/python/mypy/pull/19323)) - Optimize binding method self argument type and deprecation checks (Ivan Levkivskyi, PR [19556](https://redirect.github.com/python/mypy/pull/19556)) - Keep trivial instance types/aliases during expansion (Ivan Levkivskyi, PR [19543](https://redirect.github.com/python/mypy/pull/19543)) ##### Fixed‑Format Cache (Experimental) Mypy now supports a new cache format used for faster incremental builds. It makes incremental builds up to twice as fast. The feature is experimental and currently only supported when using a compiled version of mypy. Use `--fixed-format-cache` to enable the new format, or `fixed_format_cache = True` in a configuration file. We plan to enable this by default in a future mypy release, and we'll eventually deprecate and remove support for the original JSON-based format. Unlike the JSON-based cache format, the new binary format is currently not easy to parse and inspect by mypy users. We are planning to provide a tool to convert fixed-format cache files to JSON, but details of the output JSON may be different from the current JSON format. If you rely on being able to inspect mypy cache files, we recommend creating a GitHub issue and explaining your use case, so that we can more likely provide support for it. (Using `MypyFile.read(binary_data)` to inspect cache data may be sufficient to support some use cases.) This feature was contributed by Ivan Levkivskyi (PR [19668](https://redirect.github.com/python/mypy/pull/19668), [19735](https://redirect.github.com/python/mypy/pull/19735), [19750](https://redirect.github.com/python/mypy/pull/19750), [19681](https://redirect.github.com/python/mypy/pull/19681), [19752](https://redirect.github.com/python/mypy/pull/19752), [19815](https://redirect.github.com/python/mypy/pull/19815)). ##### Flexible Variable Definitions: Update Mypy 1.16.0 introduced `--allow-redefinition-new`, which allows redefining variables with different types, and inferring union types for variables from multiple assignments. The feature is now documented in the `--help` output, but the feature is still experimental. We are planning to enable this by default in mypy 2.0, and we will also deprecate the older `--allow-redefinition` flag. Since the new behavior differs significantly from the older flag, we encourage users of `--allow-redefinition` to experiment with `--allow-redefinition-new` and create a GitHub issue if the new functionality doesn't support some important use cases. This feature was contributed by Jukka Lehtosalo. ##### Inferred Type for Bare ClassVar A ClassVar without an explicit type annotation now causes the type of the variable to be inferred from the initializer: ```python from typing import ClassVar class Item: ### Type of 'next_id' is now 'int' (it was 'Any') next_id: ClassVar = 1 ... ``` This feature was contributed by Ivan Levkivskyi (PR [19573](https://redirect.github.com/python/mypy/pull/19573)). ##### Disjoint Base Classes (@&#8203;disjoint\_base, PEP 800) Mypy now understands disjoint bases (PEP 800): it recognizes the `@disjoint_base` decorator, and rejects class definitions that combine mutually incompatible base classes, and takes advantage of the fact that such classes cannot exist in reachability and narrowing logic. This class definition will now generate an error: ```python ``` </details> --- ### Configuration 📅 **Schedule**: Branch creation - "every weekend" in timezone Etc/UTC, Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/canonical/rockcraft). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0MS4xMzEuOSIsInVwZGF0ZWRJblZlciI6IjQxLjE3My4xIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJQUjogRGVwZW5kZW5jaWVzIl19-->

Evaluation history

Date Model Scores Action Summary
stealth/space-bunny-alpha — closed resolved Merged PR #990 via commit db194f40, updating mypy from ~=1.17.1 to ~=1.18.2.
stealth/space-bunny-alpha — closed resolved Merged PR #990 via commit db194f40, upgrading mypy from ~=1.17.1 to ~=1.18.2.
stealth/space-bunny-alpha — closed resolved Merged PR #990 via commit db194f40, upgrading mypy from ~=1.17.1 to ~=1.18.2 after approval and passing CI checks.
stealth/space-bunny-alpha — closed resolved Renovate PR merged via commit db194f40, bumping mypy from ~=1.17.1 to ~=1.18.2 in pyproject.toml/uv.lock; CI passed with 2 approvals. Later bumped to ~=1.19.0 (#1054) and mypy was dropped entirely in #1207 in favour of ty.
stealth/space-bunny-alpha — closed resolved Renovate PR #990 merged as commit db194f40, bumping mypy from ~=1.17.1 to ~=1.18.2 in pyproject.toml/uv.lock; all CI checks passed and it was approved by 2 reviewers.
stealth/space-bunny-alpha — closed resolved Merged PR #990 via commit db194f40, upgrading mypy from ~=1.17.1 to ~=1.18.2.
stealth/space-bunny-alpha — closed resolved Merged into main via #990 (db194f40), updating mypy from ~=1.17.1 to ~=1.18.2.
qwen/qwen3.6-35b-a3b — — Merged automated dependency update upgrading mypy from 1.17.1 to 1.18.2. Approved by two reviewers with all CI checks passing. Two files were modified to update the static type checker to the latest stable release.
qwen3.6-35b-a3b-mtp-q6 — — Merged automated dependency update raising mypy from 1.17.1 to 1.18.2 on the main branch. Applied via Renovate bot without manual review.

Update history

No update history recorded yet.

Related issues

Issue Project State Summary Similarity
#5787 build(deps): update dependency mypy to ~=1.18.2 (main) snapcraft merged Merged into main via commit 2f1cc3677, updating mypy from ~=1.17.1 to ~=1.18.2.
97%
#1054 build(deps): update dependency mypy to ~=1.19.0 (main) rockcraft merged Merged PR #1054 updated mypy from ~=1.18.2 to ~=1.19.0 in commit f7c1bf3e.
96%
#211 build(deps): update dependency mypy to ~=1.18.2 imagecraft merged Merged mypy dependency update from ~=1.17.1 to ~=1.18.2 via PR #211 in commit 308b369.
96%
#190 build(deps): update dependency mypy to ~=1.17.1 imagecraft merged Merged PR #190 into main via commit 71b7e56, upgrading mypy from ~=1.16.0 to ~=1.17.1.
96%
#243 build(deps): update dependency mypy to ~=1.19.1 (main) imagecraft merged Renovate PR #243 was merged in commit e5d1bd0, updating mypy from ~=1.18.2 to ~=1.19.1.
94%
#176 build(deps): update dependency mypy to ~=1.20.0 craft-grammar merged Merged into main via commit 340a07a, updating mypy to ~=1.20.0 and replacing #174.
94%
#343 build(deps): update dependency mypy to ~=1.20.2 (main) imagecraft merged Renovate PR #343 merged into main, updating mypy from ~=1.19.1 to ~=1.20.2 in commit 5b27f1a.
94%
#386 build(deps): update dependency mypy to v1.18.2 craft-cli merged Renovate dependency bump of mypy from ==1.12.0 to ==1.18.2 merged into main via PR #386 (commit 822838d); 2 files changed (+46/-26), all CI and2 approvals passed.
93%
#90 build(deps): update dependency mypy to ~=1.15.0 imagecraft merged Merged PR #90 via commit 4b7ba84, updating mypy from ~=1.13.0 to ~=1.15.0.
93%
#11 build(deps): update dependency mypy to ~=1.14.1 craft-artifacts merged Merged PR #11 updated mypy from ~=1.13.0 to ~=1.14.1 in commit 40172fc.
92%