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

Typing issues for jaraco/skeleton based projects #12595

Open
Avasam opened this issue Aug 26, 2024 · 0 comments
Open

Typing issues for jaraco/skeleton based projects #12595

Avasam opened this issue Aug 26, 2024 · 0 comments
Labels
stubs: false positive Type checkers report false errors stubs: incomplete Annotations or sub-modules missing from an existing package or module

Comments

@Avasam
Copy link
Sponsor Collaborator

Avasam commented Aug 26, 2024

I'm currently going through all mypy failures in jaraco/skeleton#143
Some of those are caused by typeshed stubs that could be improved, I'll be using this issue as an aggregated checklist of everything I find. CC @jaraco if you find anything else feel free to let me know or comment here.

pywin32:

from win32wnet import NETRESOURCE, WNetAddConnection2
res = WNetAddConnection2(...)  # WNetAddConnection2" does not return a value (it only ever returns None)  [func-returns-value]
import isapi.install  # Skipping analyzing "isapi.install": module is installed, but missing library stubs or py.typed marker  [import-untyped]

docutils:

def return_parts(source: str) -> str:
    return docutils.core.publish_parts(source)  # Returning Any from function declared to return "str"  [no-any-return]

setuptools:

from setuptools import setup
setup(script_args=('py2exe',))  # Argument "script_args" to "setup" has incompatible type "tuple[str]"; expected "list[str]"

pypa/setuptools#4604 (comment) (validate whether using None as a default_section is valid usage)

from configparser import ConfigParser
parser = ConfigParser(default_section=None, delimiters=("=",)) # No overload variant of "ConfigParser" matches argument types "None", "tuple[str]" [call-overload]

stdlib:

import ctypes
ctypes.wintypes.DWORD() # "wintypes" is not a known attribute of module "ctypes" (reportAttributeAccessIssue)
@python python deleted a comment Aug 26, 2024
@Avasam Avasam changed the title Typing issues for pypa/skeleton based projects Typing issues for jaraco/skeleton based projects Aug 26, 2024
@Avasam Avasam added the stubs: false positive Type checkers report false errors label Aug 26, 2024
@Avasam Avasam added the stubs: incomplete Annotations or sub-modules missing from an existing package or module label Aug 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stubs: false positive Type checkers report false errors stubs: incomplete Annotations or sub-modules missing from an existing package or module
Projects
None yet
Development

No branches or pull requests

2 participants
@Avasam and others