forked from python/typing
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcallables_kwargs.toml
More file actions
37 lines (37 loc) · 2.46 KB
/
Copy pathcallables_kwargs.toml
File metadata and controls
37 lines (37 loc) · 2.46 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
conformant = "Partial"
notes = """
Allows callable without kwargs to be assigned to callable with unpacked kwargs
"""
output = """
callables_kwargs.py:28:5 - error: Could not access item in TypedDict
"v2" is not a required key in "TD2", so access may result in runtime exception (reportTypedDictNotRequiredAccess)
callables_kwargs.py:46:5 - error: Arguments missing for parameters "v1", "v3" (reportCallIssue)
callables_kwargs.py:51:32 - error: No parameter named "v4" (reportCallIssue)
callables_kwargs.py:52:11 - error: Expected 0 positional arguments (reportCallIssue)
callables_kwargs.py:58:13 - error: Argument of type "str" cannot be assigned to parameter "v1" of type "int" in function "func1"
"str" is not assignable to "int" (reportArgumentType)
callables_kwargs.py:63:19 - error: Unable to match unpacked TypedDict argument to parameters
Parameter "v1" is already assigned (reportCallIssue)
callables_kwargs.py:64:16 - error: Unable to match unpacked TypedDict argument to parameters
Parameter "v3" is already assigned (reportCallIssue)
callables_kwargs.py:65:19 - error: Unable to match unpacked TypedDict argument to parameters
Parameter "v1" is already assigned (reportCallIssue)
callables_kwargs.py:101:19 - error: Type "(**kwargs: **TD2) -> None" is not assignable to declared type "TDProtocol3"
Type "(**kwargs: **TD2) -> None" is not assignable to type "(*, v1: int, v2: int, v3: str) -> None"
Keyword parameter "v2" of type "int" is incompatible with type "str"
"int" is not assignable to "str" (reportAssignmentType)
callables_kwargs.py:102:19 - error: Type "(**kwargs: **TD2) -> None" is not assignable to declared type "TDProtocol4"
Type "(**kwargs: **TD2) -> None" is not assignable to type "(*, v1: int) -> None"
Extra parameter "v3" (reportAssignmentType)
callables_kwargs.py:103:19 - error: Type "(**kwargs: **TD2) -> None" is not assignable to declared type "TDProtocol5"
Type "(**kwargs: **TD2) -> None" is not assignable to type "(v1: int, v3: str) -> None"
Function accepts too many positional parameters; expected 0 but received 2
Extra parameter "v1"
Extra parameter "v3" (reportAssignmentType)
callables_kwargs.py:111:30 - error: Typed dictionary overlaps with keyword parameter: v1 (reportGeneralTypeIssues)
callables_kwargs.py:122:21 - error: Expected TypedDict type argument for Unpack (reportGeneralTypeIssues)
"""
conformance_automated = "Fail"
errors_diff = """
Line 134: Expected 1 errors
"""