-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Make Process generic #13385
base: main
Are you sure you want to change the base?
Make Process generic #13385
Conversation
Diff from mypy_primer, showing the effect of this PR on open source code: com2ann (https://github.com/ilevkivskyi/com2ann)
+ /tmp/mypy_primer/new_typeshed/typeshed_to_test/stdlib/asyncio/subprocess.pyi:22: error: Type parameter lists are only supported in Python 3.12 and greater [syntax]
werkzeug (https://github.com/pallets/werkzeug): 6.40x faster (12.4s -> 1.9s in a single noisy sample)
+ /tmp/mypy_primer/new_typeshed/typeshed_to_test/stdlib/asyncio/subprocess.pyi:22: error: Type parameter lists are only supported in Python 3.12 and greater [syntax]
- src/werkzeug/_reloader.py:327: error: Class cannot subclass "PatternMatchingEventHandler" (has type "Any") [misc]
- src/werkzeug/_reloader.py:341: error: Unused "type: ignore" comment [unused-ignore]
- src/werkzeug/debug/tbtools.py:261: error: Incompatible types in assignment (expression has type "Optional[TracebackException]", variable has type "TracebackException") [assignment]
- tests/test_internal.py:6: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_internal.py:6: note: Use "-> None" if function does not return a value
- tests/middleware/test_shared_data.py:9: error: Function is missing a return type annotation [no-untyped-def]
- tests/middleware/test_shared_data.py:9: note: Use "-> None" if function does not return a value
- tests/middleware/test_shared_data.py:10: error: Argument 1 to "SharedDataMiddleware" has incompatible type "None"; expected "Callable[[dict[str, Any], StartResponse], Iterable[bytes]]" [arg-type]
- tests/middleware/test_shared_data.py:14: error: Function is missing a type annotation [no-untyped-def]
- tests/middleware/test_shared_data.py:15: error: Function is missing a type annotation [no-untyped-def]
- tests/middleware/test_shared_data.py:45: error: Value of type variable "_SupportsCloseT" of "closing" cannot be "Iterable[bytes]" [type-var]
- tests/middleware/test_shared_data.py:54: error: Value of type variable "_SupportsCloseT" of "closing" cannot be "Iterable[bytes]" [type-var]
- tests/middleware/test_profiler.py:7: error: Module "werkzeug.middleware.profiler" does not explicitly export attribute "Profile" [attr-defined]
- tests/middleware/test_profiler.py:12: error: Function is missing a type annotation [no-untyped-def]
- tests/middleware/test_profiler.py:17: error: Function is missing a return type annotation [no-untyped-def]
- tests/middleware/test_profiler.py:21: error: Function is missing a type annotation [no-untyped-def]
- tests/middleware/test_profiler.py:37: error: Argument "filename_format" to "ProfilerMiddleware" has incompatible type "Callable[[Any], Any]"; expected "str" [arg-type]
- tests/middleware/test_dispatcher.py:6: error: Function is missing a return type annotation [no-untyped-def]
- tests/middleware/test_dispatcher.py:6: note: Use "-> None" if function does not return a value
- tests/middleware/test_dispatcher.py:7: error: Function is missing a type annotation [no-untyped-def]
- tests/middleware/test_dispatcher.py:11: error: Function is missing a type annotation [no-untyped-def]
- tests/live_apps/streaming_app.py:6: error: Function is missing a type annotation [no-untyped-def]
- tests/live_apps/streaming_app.py:7: error: Function is missing a return type annotation [no-untyped-def]
- tests/live_apps/streaming_app.py:14: error: Call to untyped function "gen" in typed context [no-untyped-call]
- tests/live_apps/standard_app.py:8: error: Function is missing a type annotation [no-untyped-def]
- tests/live_apps/run.py:16: error: Function is missing a type annotation [no-untyped-def]
- tests/live_apps/run.py:35: error: Cannot assign to a method [method-assign]
- tests/live_apps/run.py:35: error: Incompatible types in assignment (expression has type "Callable[[WSGIRequestHandler], Any]", variable has type "Callable[[WSGIRequestHandler], str]") [assignment]
- tests/live_apps/reloader_app.py:17: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wsgi.py:60: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wsgi.py:65: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wsgi.py:65: note: Use "-> None" if function does not return a value
- tests/test_wsgi.py:77: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wsgi.py:78: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wsgi.py:87: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wsgi.py:87: note: Use "-> None" if function does not return a value
- tests/test_wsgi.py:92: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wsgi.py:92: note: Use "-> None" if function does not return a value
- tests/test_wsgi.py:94: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wsgi.py:94: note: Use "-> None" if function does not return a value
- tests/test_wsgi.py:114: error: Incompatible types in assignment (expression has type "LimitedStream", variable has type "RaisingLimitedStream") [assignment]
- tests/test_wsgi.py:119: error: Incompatible types in assignment (expression has type "LimitedStream", variable has type "RaisingLimitedStream") [assignment]
- tests/test_wsgi.py:123: error: Incompatible types in assignment (expression has type "LimitedStream", variable has type "RaisingLimitedStream") [assignment]
- tests/test_wsgi.py:128: error: Incompatible types in assignment (expression has type "LimitedStream", variable has type "RaisingLimitedStream") [assignment]
- tests/test_wsgi.py:132: error: Incompatible types in assignment (expression has type "LimitedStream", variable has type "RaisingLimitedStream") [assignment]
- tests/test_wsgi.py:136: error: Incompatible types in assignment (expression has type "LimitedStream", variable has type "RaisingLimitedStream") [assignment]
- tests/test_wsgi.py:143: error: Incompatible types in assignment (expression has type "LimitedStream", variable has type "RaisingLimitedStream") [assignment]
- tests/test_wsgi.py:147: error: Incompatible types in assignment (expression has type "LimitedStream", variable has type "RaisingLimitedStream") [assignment]
- tests/test_wsgi.py:150: error: Incompatible types in assignment (expression has type "LimitedStream", variable has type "RaisingLimitedStream") [assignment]
- tests/test_wsgi.py:154: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wsgi.py:154: note: Use "-> None" if function does not return a value
- tests/test_wsgi.py:158: error: Incompatible types in assignment (expression has type "TextIOWrapper[BufferedReader]", variable has type "LimitedStream") [assignment]
- tests/test_wsgi.py:163: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wsgi.py:163: note: Use "-> None" if function does not return a value
- tests/test_wsgi.py:178: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wsgi.py:197: error: Cannot instantiate abstract class "OneByteStream" with abstract attributes "__enter__", "__exit__", ... and "writelines" (15 methods suppressed) [abstract]
- tests/test_wsgi.py:207: error: Cannot instantiate abstract class "OneByteStream" with abstract attributes "__enter__", "__exit__", ... and "writelines" (15 methods suppressed) [abstract]
- tests/test_wsgi.py:214: error: Cannot instantiate abstract class "OneByteStream" with abstract attributes "__enter__", "__exit__", ... and "writelines" (15 methods suppressed) [abstract]
- tests/test_wsgi.py:217: error: Cannot instantiate abstract class "OneByteStream" with abstract attributes "__enter__", "__exit__", ... and "writelines" (15 methods suppressed) [abstract]
- tests/test_wsgi.py:221: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wsgi.py:221: note: Use "-> None" if function does not return a value
- tests/test_wsgi.py:244: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wsgi.py:244: note: Use "-> None" if function does not return a value
- tests/test_wsgi.py:250: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wsgi.py:250: note: Use "-> None" if function does not return a value
- tests/test_wsgi.py:259: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wsgi.py:259: note: Use "-> None" if function does not return a value
- tests/test_wsgi.py:261: error: Argument 1 to "_RangeWrapper" has incompatible type "Union[Iterable[str], Iterable[bytes]]"; expected "Union[Iterable[bytes], IO[bytes]]" [arg-type]
- tests/test_wsgi.py:265: error: Argument 1 to "_RangeWrapper" has incompatible type "Union[Iterable[str], Iterable[bytes]]"; expected "Union[Iterable[bytes], IO[bytes]]" [arg-type]
- tests/test_wsgi.py:270: error: Argument 1 to "_RangeWrapper" has incompatible type "Union[Iterable[str], Iterable[bytes]]"; expected "Union[Iterable[bytes], IO[bytes]]" [arg-type]
- tests/test_wsgi.py:274: error: Argument 1 to "_RangeWrapper" has incompatible type "Union[Iterable[str], Iterable[bytes]]"; expected "Union[Iterable[bytes], IO[bytes]]" [arg-type]
- tests/test_wsgi.py:280: error: Argument 1 to "_RangeWrapper" has incompatible type "Union[Iterable[str], Iterable[bytes]]"; expected "Union[Iterable[bytes], IO[bytes]]" [arg-type]
- tests/test_wsgi.py:288: error: Argument 1 to "_RangeWrapper" has incompatible type "Union[Iterable[str], Iterable[bytes]]"; expected "Union[Iterable[bytes], IO[bytes]]" [arg-type]
- tests/test_wsgi.py:297: error: Argument 1 to "_RangeWrapper" has incompatible type "Union[Iterable[str], Iterable[bytes]]"; expected "Union[Iterable[bytes], IO[bytes]]" [arg-type]
- tests/test_wsgi.py:305: error: Argument 1 to "_RangeWrapper" has incompatible type "Union[Iterable[str], Iterable[bytes]]"; expected "Union[Iterable[bytes], IO[bytes]]" [arg-type]
- tests/test_wsgi.py:311: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wsgi.py:317: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wsgi.py:323: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wsgi.py:327: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wsgi.py:327: note: Use "-> None" if function does not return a value
- tests/test_wsgi.py:330: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wsgi.py:330: note: Use "-> None" if function does not return a value
- tests/test_wsgi.py:333: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wsgi.py:334: error: Call to untyped function "Response" in typed context [no-untyped-call]
- tests/test_wsgi.py:338: error: Argument 1 to "join" of "str" has incompatible type "Iterable[bytes]"; expected "Iterable[str]" [arg-type]
- tests/test_wrappers.py:39: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wrappers.py:44: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wrappers.py:53: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:53: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:62: error: Call to untyped function "assert_environ" in typed context [no-untyped-call]
- tests/test_wrappers.py:77: error: Call to untyped function "assert_environ" in typed context [no-untyped-call]
- tests/test_wrappers.py:89: error: Call to untyped function "assert_environ" in typed context [no-untyped-call]
- tests/test_wrappers.py:100: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:100: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:105: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:105: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:112: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:112: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:124: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:124: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:140: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:140: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:149: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:174: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:174: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:179: error: Item "None" of "Optional[Authorization]" has no attribute "type" [union-attr]
- tests/test_wrappers.py:180: error: Item "None" of "Optional[Authorization]" has no attribute "username" [union-attr]
- tests/test_wrappers.py:181: error: Item "None" of "Optional[Authorization]" has no attribute "password" [union-attr]
- tests/test_wrappers.py:184: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:184: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:189: error: Item "None" of "Optional[Authorization]" has no attribute "type" [union-attr]
- tests/test_wrappers.py:190: error: Item "None" of "Optional[Authorization]" has no attribute "username" [union-attr]
- tests/test_wrappers.py:191: error: Item "None" of "Optional[Authorization]" has no attribute "password" [union-attr]
- tests/test_wrappers.py:194: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:196: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wrappers.py:200: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wrappers.py:212: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:212: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:221: error: Non-overlapping equality check (left operand type: "HeaderSet", right operand type: "set[str]") [comparison-overlap]
- tests/test_wrappers.py:225: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:225: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:229: error: Incompatible types in assignment (expression has type "list[str]", variable has type "HeaderSet") [assignment]
- tests/test_wrappers.py:237: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:243: error: Argument 1 to "write" of "ResponseStream" has incompatible type "str"; expected "bytes" [arg-type]
- tests/test_wrappers.py:282: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:282: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:285: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wrappers.py:288: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:288: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:295: error: Argument 1 to "join" of "str" has incompatible type "Iterable[bytes]"; expected "Iterable[str]" [arg-type]
- tests/test_wrappers.py:315: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wrappers.py:336: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wrappers.py:347: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:347: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:355: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:356: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wrappers.py:363: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:368: error: Need type annotation for "fake_env" (hint: "fake_env: dict[<type>, <type>] = ...") [var-annotated]
- tests/test_wrappers.py:371: error: Argument 1 to "force_type" of "Response" has incompatible type "Union[Callable[[Any, Any], Any], Response]"; expected "Response" [arg-type]
- tests/test_wrappers.py:373: error: "Response" has no attribute "foo" [attr-defined]
- tests/test_wrappers.py:381: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:381: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:416: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:416: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:442: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:442: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:450: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:452: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wrappers.py:455: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wrappers.py:458: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wrappers.py:465: error: Call to untyped function "LowercasingStream" in typed context [no-untyped-call]
- tests/test_wrappers.py:465: error: Incompatible types in assignment (expression has type "LowercasingStream", variable has type "IO[bytes]") [assignment]
- tests/test_wrappers.py:469: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:469: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:479: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:479: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:514: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:514: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:543: error: Incompatible types in assignment (expression has type "int", variable has type "Optional[datetime]") [assignment]
- tests/test_wrappers.py:555: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:555: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:587: error: Incompatible types in assignment (expression has type "int", variable has type "Optional[datetime]") [assignment]
- tests/test_wrappers.py:599: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:599: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:611: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:611: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:623: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:623: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:642: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:642: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:661: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wrappers.py:669: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:669: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:677: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:677: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:683: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:683: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:691: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:691: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:708: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:708: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:710: error: Argument 1 to "write" of "ResponseStream" has incompatible type "str"; expected "bytes" [arg-type]
- tests/test_wrappers.py:711: error: Argument 1 to "write" of "ResponseStream" has incompatible type "str"; expected "bytes" [arg-type]
- tests/test_wrappers.py:716: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:716: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:764: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:764: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:790: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:790: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:795: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:806: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:806: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:828: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:828: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:851: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:851: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:873: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:873: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:881: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:885: error: Call to untyped function "gen" in typed context [no-untyped-call]
- tests/test_wrappers.py:889: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:889: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:890: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wrappers.py:894: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:899: error: Call to untyped function "generator" in typed context [no-untyped-call]
- tests/test_wrappers.py:901: error: Call to untyped function "uppercasing" in typed context [no-untyped-call]
- tests/test_wrappers.py:906: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:906: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:907: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:911: error: Call to untyped function "generate" in typed context [no-untyped-call]
- tests/test_wrappers.py:917: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:917: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:922: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:922: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:934: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:934: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:943: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:947: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wrappers.py:951: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:959: error: Call to untyped function "get_content_length" in typed context [no-untyped-call]
- tests/test_wrappers.py:967: error: Call to untyped function "get_content_length" in typed context [no-untyped-call]
- tests/test_wrappers.py:972: error: Call to untyped function "generate_items" in typed context [no-untyped-call]
- tests/test_wrappers.py:1002: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1002: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1019: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1019: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1034: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1034: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1036: error: Incompatible types in assignment (expression has type "type[dict[Any, Any]]", base class "Request" defined the type as "type[MultiDict[str, Any]]") [assignment]
- tests/test_wrappers.py:1038: error: Incompatible types in assignment (expression has type "type[dict[Any, Any]]", base class "Request" defined the type as "type[MultiDict[str, Any]]") [assignment]
- tests/test_wrappers.py:1057: error: Incompatible types in assignment (expression has type "type[tuple[Any, ...]]", variable has type "type[list[Any]]") [assignment]
- tests/test_wrappers.py:1059: error: Non-overlapping identity check (left operand type: "type[list[str]]", right operand type: "type[tuple[Any, ...]]") [comparison-overlap]
- tests/test_wrappers.py:1062: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1062: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1068: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1068: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1074: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1074: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1079: error: Item "None" of "Optional[Range]" has no attribute "ranges" [union-attr]
- tests/test_wrappers.py:1082: error: Item "None" of "Optional[Range]" has no attribute "make_content_range" [union-attr]
- tests/test_wrappers.py:1082: error: Incompatible types in assignment (expression has type "Union[ContentRange, Any, None]", variable has type "ContentRange") [assignment]
- tests/test_wrappers.py:1099: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1099: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1109: error: Incompatible types in assignment (expression has type "None", variable has type "ContentSecurityPolicy") [assignment]
- tests/test_wrappers.py:1113: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1113: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1122: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1122: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1124: error: List item 0 has incompatible type "str"; expected "bytes" [list-item]
- tests/test_wrappers.py:1124: error: List item 1 has incompatible type "str"; expected "bytes" [list-item]
- tests/test_wrappers.py:1124: error: List item 2 has incompatible type "str"; expected "bytes" [list-item]
- tests/test_wrappers.py:1129: error: List item 0 has incompatible type "str"; expected "bytes" [list-item]
- tests/test_wrappers.py:1129: error: List item 1 has incompatible type "str"; expected "bytes" [list-item]
- tests/test_wrappers.py:1129: error: List item 2 has incompatible type "str"; expected "bytes" [list-item]
- tests/test_wrappers.py:1133: error: List item 0 has incompatible type "str"; expected "bytes" [list-item]
- tests/test_wrappers.py:1133: error: List item 1 has incompatible type "str"; expected "bytes" [list-item]
- tests/test_wrappers.py:1137: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1137: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1165: error: Function is missing a type annotation [no-untyped-def]
- tests/test_wrappers.py:1173: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1173: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1187: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1187: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1196: error: Non-overlapping container check (element type: "str", container item type: "tuple[str, str]") [comparison-overlap]
- tests/test_wrappers.py:1200: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1200: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1207: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1207: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1213: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1213: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1227: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1227: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1249: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1249: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1272: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1272: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1295: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1295: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1319: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1319: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1325: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1325: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1332: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1332: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1342: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1342: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1351: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1351: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1361: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1361: note: Use "-> None" if function does not return a value
- tests/test_wrappers.py:1368: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_wrappers.py:1368: note: Use "-> None" if function does not return a value
- tests/test_utils.py:42: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:42: note: Use "-> None" if function does not return a value
- tests/test_utils.py:54: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:54: note: Use "-> None" if function does not return a value
- tests/test_utils.py:65: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:69: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:73: error: Incompatible types in assignment (expression has type "cached_property[Any]", variable has type "Callable[[A], Any]") [assignment]
- tests/test_utils.py:78: error: Non-overlapping equality check (left operand type: "Callable[[], Any]", right operand type: "Literal[42]") [comparison-overlap]
- tests/test_utils.py:83: error: Name "A" already defined on line 68 [no-redef]
- tests/test_utils.py:84: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:94: error: Non-overlapping equality check (left operand type: "Callable[[], Any]", right operand type: "Literal[42]") [comparison-overlap]
- tests/test_utils.py:98: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:101: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:109: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:114: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:135: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:138: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:148: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:148: note: Use "-> None" if function does not return a value
- tests/test_utils.py:152: error: Need type annotation for "string" [var-annotated]
- tests/test_utils.py:154: error: Need type annotation for "read_only" [var-annotated]
- tests/test_utils.py:160: error: Need type annotation for "foo" [var-annotated]
- tests/test_utils.py:166: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:166: note: Use "-> None" if function does not return a value
- tests/test_utils.py:177: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:177: note: Use "-> None" if function does not return a value
- tests/test_utils.py:194: error: Function is missing a type annotation [no-untyped-def]
- tests/test_utils.py:214: error: Function is missing a type annotation [no-untyped-def]
- tests/test_utils.py:230: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:230: note: Use "-> None" if function does not return a value
- tests/test_utils.py:238: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:238: note: Use "-> None" if function does not return a value
- tests/test_utils.py:267: error: Function is missing a type annotation [no-untyped-def]
- tests/test_utils.py:269: error: Function is missing a type annotation [no-untyped-def]
- tests/test_utils.py:284: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:285: error: Argument 1 to "cached_property" has incompatible type "Callable[[], Any]"; expected "Callable[[Any], Any]" [arg-type]
- tests/test_utils.py:286: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:295: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_utils.py:295: note: Use "-> None" if function does not return a value
- tests/test_urls.py:6: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_urls.py:6: note: Use "-> None" if function does not return a value
- tests/test_urls.py:24: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_urls.py:24: note: Use "-> None" if function does not return a value
- tests/test_urls.py:31: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_urls.py:31: note: Use "-> None" if function does not return a value
- tests/test_urls.py:36: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_urls.py:36: note: Use "-> None" if function does not return a value
- tests/test_urls.py:42: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_urls.py:42: note: Use "-> None" if function does not return a value
- tests/test_urls.py:48: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_urls.py:48: note: Use "-> None" if function does not return a value
- tests/test_urls.py:54: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_urls.py:54: note: Use "-> None" if function does not return a value
- tests/test_urls.py:60: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_urls.py:60: note: Use "-> None" if function does not return a value
- tests/test_urls.py:66: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_urls.py:66: note: Use "-> None" if function does not return a value
- tests/test_urls.py:82: error: Function is missing a type annotation [no-untyped-def]
- tests/test_urls.py:93: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_urls.py:93: note: Use "-> None" if function does not return a value
- tests/test_urls.py:97: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_urls.py:97: note: Use "-> None" if function does not return a value
- tests/test_test.py:25: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:34: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:39: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:54: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:59: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:67: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:75: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:75: note: Use "-> None" if function does not return a value
- tests/test_test.py:82: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:82: note: Use "-> None" if function does not return a value
- tests/test_test.py:88: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:88: note: Use "-> None" if function does not return a value
- tests/test_test.py:94: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:94: note: Use "-> None" if function does not return a value
- tests/test_test.py:100: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:100: note: Use "-> None" if function does not return a value
- tests/test_test.py:107: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:107: note: Use "-> None" if function does not return a value
- tests/test_test.py:114: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:114: note: Use "-> None" if function does not return a value
- tests/test_test.py:140: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:140: note: Use "-> None" if function does not return a value
- tests/test_test.py:149: error: Incompatible types in assignment (expression has type "int", target has type "str") [assignment]
- tests/test_test.py:164: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:164: note: Use "-> None" if function does not return a value
- tests/test_test.py:166: error: Item "IO[bytes]" of "Optional[IO[bytes]]" has no attribute "getvalue" [union-attr]
- tests/test_test.py:166: error: Item "None" of "Optional[IO[bytes]]" has no attribute "getvalue" [union-attr]
- tests/test_test.py:168: error: Item "IO[bytes]" of "Optional[IO[bytes]]" has no attribute "getvalue" [union-attr]
- tests/test_test.py:168: error: Item "None" of "Optional[IO[bytes]]" has no attribute "getvalue" [union-attr]
- tests/test_test.py:175: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:182: error: Call to untyped function "check_list_content" in typed context [no-untyped-call]
- tests/test_test.py:184: error: Call to untyped function "check_list_content" in typed context [no-untyped-call]
- tests/test_test.py:187: error: Call to untyped function "check_list_content" in typed context [no-untyped-call]
- tests/test_test.py:189: error: Call to untyped function "check_list_content" in typed context [no-untyped-call]
- tests/test_test.py:192: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:194: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:206: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:206: note: Use "-> None" if function does not return a value
- tests/test_test.py:222: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:222: note: Use "-> None" if function does not return a value
- tests/test_test.py:223: error: Dict entry 0 has incompatible type "str": "str"; expected "tuple[str, str]": "str" [dict-item]
- tests/test_test.py:227: error: Dict entry 0 has incompatible type "str": "str"; expected "tuple[str, str]": "str" [dict-item]
- tests/test_test.py:237: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:237: note: Use "-> None" if function does not return a value
- tests/test_test.py:246: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:246: note: Use "-> None" if function does not return a value
- tests/test_test.py:279: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:279: note: Use "-> None" if function does not return a value
- tests/test_test.py:303: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:303: note: Use "-> None" if function does not return a value
- tests/test_test.py:306: error: Item "None" of "Optional[Authorization]" has no attribute "username" [union-attr]
- tests/test_test.py:307: error: Item "None" of "Optional[Authorization]" has no attribute "password" [union-attr]
- tests/test_test.py:310: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:310: note: Use "-> None" if function does not return a value
- tests/test_test.py:318: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:318: note: Use "-> None" if function does not return a value
- tests/test_test.py:337: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:337: note: Use "-> None" if function does not return a value
- tests/test_test.py:361: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:361: note: Use "-> None" if function does not return a value
- tests/test_test.py:378: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:378: note: Use "-> None" if function does not return a value
- tests/test_test.py:402: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:402: note: Use "-> None" if function does not return a value
- tests/test_test.py:407: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:407: note: Use "-> None" if function does not return a value
- tests/test_test.py:425: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:429: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:432: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:432: note: Use "-> None" if function does not return a value
- tests/test_test.py:438: error: Argument 2 to "add_file" of "FileMultiDict" has incompatible type "SpecialInput"; expected "Union[str, PathLike[str], IO[bytes], FileStorage]" [arg-type]
- tests/test_test.py:443: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:443: note: Use "-> None" if function does not return a value
- tests/test_test.py:463: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:467: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:484: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:486: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:508: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:516: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:534: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:534: note: Use "-> None" if function does not return a value
- tests/test_test.py:540: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:542: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:555: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:555: note: Use "-> None" if function does not return a value
- tests/test_test.py:557: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:561: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:572: error: Call to untyped function "Middleware" in typed context [no-untyped-call]
- tests/test_test.py:573: error: Call to untyped function "Middleware" in typed context [no-untyped-call]
- tests/test_test.py:579: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:581: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:607: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:609: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:631: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:632: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:644: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:644: note: Use "-> None" if function does not return a value
- tests/test_test.py:655: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:655: note: Use "-> None" if function does not return a value
- tests/test_test.py:663: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:666: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:670: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:675: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:681: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:686: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:691: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:691: note: Use "-> None" if function does not return a value
- tests/test_test.py:698: error: Call to untyped function "iterable_middleware" in typed context [no-untyped-call]
- tests/test_test.py:702: error: Argument 1 to "join" of "str" has incompatible type "Iterable[bytes]"; expected "Iterable[str]" [arg-type]
- tests/test_test.py:711: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:713: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:716: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:719: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:719: note: Use "-> None" if function does not return a value
- tests/test_test.py:724: error: Cannot assign to a type [misc]
- tests/test_test.py:724: error: Call to untyped function "iterable_middleware" in typed context [no-untyped-call]
- tests/test_test.py:728: error: Argument 1 to "join" of "str" has incompatible type "Iterable[bytes]"; expected "Iterable[str]" [arg-type]
- tests/test_test.py:731: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:732: error: Need type annotation for "got_close" (hint: "got_close: list[<type>] = ...") [var-annotated]
- tests/test_test.py:735: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:735: note: Use "-> None" if function does not return a value
- tests/test_test.py:738: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:741: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:741: note: Use "-> None" if function does not return a value
- tests/test_test.py:744: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:750: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:752: error: Call to untyped function "CloseIter" in typed context [no-untyped-call]
- tests/test_test.py:757: error: No overload variant of "next" matches argument type "Iterable[bytes]" [call-overload]
- tests/test_test.py:757: note: Possible overload variants:
- tests/test_test.py:757: note: def [_T] next(SupportsNext[_T], /) -> _T
- tests/test_test.py:757: note: def [_T, _VT] next(SupportsNext[_T], _VT, /) -> Union[_T, _VT]
- tests/test_test.py:759: error: "Iterable[bytes]" has no attribute "close" [attr-defined]
- tests/test_test.py:761: error: Non-overlapping equality check (left operand type: "Iterable[bytes]", right operand type: "list[str]") [comparison-overlap]
- tests/test_test.py:766: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:769: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:773: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:778: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:778: note: Use "-> None" if function does not return a value
- tests/test_test.py:786: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:788: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:801: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:805: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:812: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:821: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:821: note: Use "-> None" if function does not return a value
- tests/test_test.py:827: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:831: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:841: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:843: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:851: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:863: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:865: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:877: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:879: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:896: error: Function is missing a type annotation [no-untyped-def]
- tests/test_test.py:903: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:903: note: Use "-> None" if function does not return a value
- tests/test_test.py:909: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_test.py:909: note: Use "-> None" if function does not return a value
- tests/test_send_file.py:21: error: Function is missing a type annotation [no-untyped-def]
- tests/test_send_file.py:30: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_send_file.py:30: note: Use "-> None" if function does not return a value
- tests/test_send_file.py:37: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_send_file.py:37: note: Use "-> None" if function does not return a value
- tests/test_send_file.py:47: error: Function is missing a type annotation [no-untyped-def]
- tests/test_send_file.py:56: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_send_file.py:56: note: Use "-> None" if function does not return a value
- tests/test_send_file.py:61: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_send_file.py:61: note: Use "-> None" if function does not return a value
- tests/test_send_file.py:70: error: Function is missing a type annotation [no-untyped-def]
- tests/test_send_file.py:78: error: Function is missing a type annotation [no-untyped-def]
- tests/test_send_file.py:84: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_send_file.py:84: note: Use "-> None" if function does not return a value
- tests/test_send_file.py:115: error: Function is missing a type annotation [no-untyped-def]
- tests/test_send_file.py:127: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_send_file.py:127: note: Use "-> None" if function does not return a value
- tests/test_send_file.py:131: error: Dict entry 0 has incompatible type "str": "str"; expected "tuple[str, str]": "str" [dict-item]
- tests/test_send_file.py:144: error: Function is missing a type annotation [no-untyped-def]
- tests/test_send_file.py:154: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_send_file.py:154: note: Use "-> None" if function does not return a value
- tests/test_send_file.py:167: error: Function is missing a type annotation [no-untyped-def]
- tests/test_send_file.py:180: error: Function is missing a type annotation [no-untyped-def]
- tests/test_send_file.py:188: error: Function is missing a type annotation [no-untyped-def]
- tests/test_send_file.py:193: error: Function is missing a type annotation [no-untyped-def]
- tests/test_send_file.py:208: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_security.py:11: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_security.py:11: note: Use "-> None" if function does not return a value
- tests/test_security.py:19: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_security.py:19: note: Use "-> None" if function does not return a value
- tests/test_security.py:25: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_security.py:25: note: Use "-> None" if function does not return a value
- tests/test_security.py:31: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_security.py:31: note: Use "-> None" if function does not return a value
- tests/test_security.py:39: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_security.py:39: note: Use "-> None" if function does not return a value
- tests/test_security.py:44: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_security.py:44: note: Use "-> None" if function does not return a value
- tests/test_security.py:58: error: Function is missing a type annotation [no-untyped-def]
- tests/test_security.py:62: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_security.py:62: note: Use "-> None" if function does not return a value
- tests/test_security.py:66: error: Incompatible types in assignment (expression has type "str", variable has type "list[str]") [assignment]
- tests/test_security.py:68: error: Module has no attribute "_os_alt_steps"; maybe "_os_alt_seps"? [attr-defined]
- tests/test_security.py:71: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_security.py:71: note: Use "-> None" if function does not return a value
- tests/test_routing.py:16: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:91: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:136: error: Function is missing a type annotation [no-untyped-def]
- tests/test_routing.py:152: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:152: note: Use "-> None" if function does not return a value
- tests/test_routing.py:164: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:164: note: Use "-> None" if function does not return a value
- tests/test_routing.py:219: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:219: note: Use "-> None" if function does not return a value
- tests/test_routing.py:249: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:249: note: Use "-> None" if function does not return a value
- tests/test_routing.py:260: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:260: note: Use "-> None" if function does not return a value
- tests/test_routing.py:269: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:322: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:322: note: Use "-> None" if function does not return a value
- tests/test_routing.py:339: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:356: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:379: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:379: note: Use "-> None" if function does not return a value
- tests/test_routing.py:398: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:459: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:466: error: Function is missing a type annotation [no-untyped-def]
- tests/test_routing.py:471: error: Function is missing a type annotation [no-untyped-def]
- tests/test_routing.py:473: error: Argument 1 to "force_type" of "Response" has incompatible type "Callable[[dict[str, Any], StartResponse], Iterable[bytes]]"; expected "Response" [arg-type]
- tests/test_routing.py:476: error: Call to untyped function "dispatch" in typed context [no-untyped-call]
- tests/test_routing.py:477: error: Call to untyped function "dispatch" in typed context [no-untyped-call]
- tests/test_routing.py:479: error: Call to untyped function "dispatch" in typed context [no-untyped-call]
- tests/test_routing.py:480: error: Call to untyped function "dispatch" in typed context [no-untyped-call]
- tests/test_routing.py:483: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:483: note: Use "-> None" if function does not return a value
- tests/test_routing.py:504: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:504: note: Use "-> None" if function does not return a value
- tests/test_routing.py:518: error: Function is missing a type annotation [no-untyped-def]
- tests/test_routing.py:525: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:536: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:536: note: Use "-> None" if function does not return a value
- tests/test_routing.py:545: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:545: note: Use "-> None" if function does not return a value
- tests/test_routing.py:554: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:554: note: Use "-> None" if function does not return a value
- tests/test_routing.py:568: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:568: note: Use "-> None" if function does not return a value
- tests/test_routing.py:575: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:575: note: Use "-> None" if function does not return a value
- tests/test_routing.py:597: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:597: note: Use "-> None" if function does not return a value
- tests/test_routing.py:601: error: Item "None" of "Optional[set[str]]" has no attribute "add" [union-attr]
- tests/test_routing.py:603: error: Item "None" of "Optional[set[str]]" has no attribute "discard" [union-attr]
- tests/test_routing.py:604: error: Unsupported target for indexed assignment ("Optional[Mapping[str, Any]]") [index]
- tests/test_routing.py:608: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:608: note: Use "-> None" if function does not return a value
- tests/test_routing.py:613: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:613: note: Use "-> None" if function does not return a value
- tests/test_routing.py:616: error: List item 0 has incompatible type "Submount"; expected "Rule" [list-item]
- tests/test_routing.py:624: error: List item 1 has incompatible type "EndpointPrefix"; expected "Rule" [list-item]
- tests/test_routing.py:631: error: List item 2 has incompatible type "Subdomain"; expected "Rule" [list-item]
- tests/test_routing.py:681: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:681: note: Use "-> None" if function does not return a value
- tests/test_routing.py:687: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:687: note: Use "-> None" if function does not return a value
- tests/test_routing.py:730: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:730: note: Use "-> None" if function does not return a value
- tests/test_routing.py:732: error: Incompatible types in assignment (expression has type "dict[str, type[BaseConverter]]", base class "Map" defined the type as "ImmutableDict[str, type[BaseConverter]]") [assignment]
- tests/test_routing.py:733: error: Cannot determine type of "default_converters" [has-type]
- tests/test_routing.py:751: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:751: note: Use "-> None" if function does not return a value
- tests/test_routing.py:758: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:766: error: Function is missing a type annotation [no-untyped-def]
- tests/test_routing.py:770: error: Function is missing a type annotation [no-untyped-def]
- tests/test_routing.py:774: error: Function is missing a type annotation [no-untyped-def]
- tests/test_routing.py:786: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:786: note: Use "-> None" if function does not return a value
- tests/test_routing.py:792: error: Function is missing a type annotation [no-untyped-def]
- tests/test_routing.py:815: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:815: note: Use "-> None" if function does not return a value
- tests/test_routing.py:867: error: Function is missing a type annotation [no-untyped-def]
- tests/test_routing.py:899: error: Function is missing a type annotation [no-untyped-def]
- tests/test_routing.py:933: error: Function is missing a type annotation [no-untyped-def]
- tests/test_routing.py:955: error: Function is missing a type annotation [no-untyped-def]
- tests/test_routing.py:962: error: Function is missing a return type annotation [no-untyped-def]
- tests/test_routing.py:962: note: Use "-> None" if function does not return a value
- tests/test_routing.py:968: error: Dict entry 0 has incompatible type "str": "str"; expected "str": "None" [di
... (truncated 3470 lines) ... |
@@ -19,7 +19,7 @@ class SubprocessStreamProtocol(streams.FlowControlMixin, protocols.SubprocessPro | |||
def __init__(self, limit: int, loop: events.AbstractEventLoop) -> None: ... | |||
def pipe_data_received(self, fd: int, data: bytes | str) -> None: ... | |||
|
|||
class Process: | |||
class Process[CommOut: (PIPE, int, IO[Any], None), CommErr: (PIPE, int, IO[Any], None)]: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like PIPE is a value of type int
, not a type alias. I don't think it's a valid constraint for your type variable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I changed the type to a Literal. My assumption then is that mypy etc. can detect if the PIPE itself is used as opposed to another (unknown) int.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The problem isn't int vs literal, it's that PIPE Is a value with that type, not a type, so it can't be used in the constraints.
Alternative to #13384.
We could make stdin/stdout/stderr generic too, but as there's no overloads for attributes, I think this would require 5 TypeVars to achieve...