Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: python/mypy
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: master@{1day}
Choose a base ref
...
head repository: python/mypy
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: master
Choose a head ref
  • 5 commits
  • 9 files changed
  • 2 contributors

Commits on Jun 13, 2025

  1. Configuration menu
    Copy the full SHA
    6c3c4a7 View commit details
    Browse the repository at this point in the history
  2. Preserve literals when joining Literal and Instance with matching las…

    …t_known_value (#19279)
    
    Discovered in #19225.
    sterliakov authored Jun 13, 2025
    Configuration menu
    Copy the full SHA
    2996c91 View commit details
    Browse the repository at this point in the history
  3. Use union of current context and left side for right side narrowing o…

    …f binary ops (#19249)
    
    Fixes #12001. Fixes #6898. Fixes #15368. Improves #17790 and #11508.
    
    When encountering `a {and,or} b`, we used to use `a` as primary context
    for `b` inference. This results in weird errors when `a` and `b` are
    completely unrelated, and in many cases return type/assignment type
    context can do much better. Inferring to union should be harmless in
    most cases, so use union of `a` and current context instead.
    sterliakov authored Jun 13, 2025
    Configuration menu
    Copy the full SHA
    2ba79cb View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    4373e05 View commit details
    Browse the repository at this point in the history
  5. Handle corner case: protocol vs classvar vs descriptor (#19277)

    Ref #19274
    
    This is a bit ugly. But I propose to have this "hot-fix" until we have a
    proper overhaul of instance vs class variables. To be clear: attribute
    access already works correctly (on both `P` and `Type[P]`), but
    subtyping returns false because of
    ```python
                    elif (IS_CLASSVAR in subflags) != (IS_CLASSVAR in superflags):
                        return False
    ```
    ilevkivskyi authored Jun 13, 2025
    Configuration menu
    Copy the full SHA
    5081c59 View commit details
    Browse the repository at this point in the history
Loading