8000 Selected Typeshed stubs for the wrong version · Issue #2153 · python/mypy · GitHub
[go: up one dir, main page]

Skip to content
8000
Selected Typeshed stubs for the wrong version #2153
Closed
@berdario

Description

@berdario

From my understanding, 2and3 stubs should be ovverriden by 3, which should be overriden by 3.5 (assuming 3.5)

After updating to Mypy 0.4.4 (from 0.4.1) though I get a new spurious error:

No overload variant of "itemgetter" matches argument types [builtins.str]

The code for itemgetter here seems correct:

https://github.com/python/typeshed/blob/master/stdlib/3/_operator.pyi

But here instead it's picking up

 def itemgetter(item: int)

https://github.com/python/typeshed/blob/master/stdlib/2and3/operator.pyi

Why is the code from 2and3 used, instead of the more specific one?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0