mirror of https://github.com/astral-sh/ruff
fixup
This commit is contained in:
parent
36bf0f3ada
commit
551f2527b4
|
|
@ -990,7 +990,7 @@ discord/ext/commands/converter.py:267: error: Incompatible types in assignment (
|
|||
discord/ext/commands/converter.py:379: error: Incompatible return value type (got "Tuple[Union[Guild, int, None], int, int]", expected "Tuple[Optional[int], int, int]") [return-value]
|
||||
discord/ext/commands/converter.py:483: error: Name "result" already defined on line 476 [no-redef]
|
||||
discord/ext/commands/converter.py:517: error: Name "result" already defined on line 510 [no-redef]
|
||||
discord/ext/commands/converter.py:1280: error: Argument 2 to "issubclass" has incompatible type "<typing special-form>"; expected "_ClassInfo" [arg-type]
|
||||
discord/ext/commands/converter.py:1280: error: Argument 2 to "issubclass" has incompatible type "<typing special form>"; expected "_ClassInfo" [arg-type]
|
||||
discord/ext/commands/converter.py:1413: error: Need type annotation for "conversions" (hint: "conversions: Dict[<type>, <type>] = ...") [var-annotated]
|
||||
discord/ext/commands/parameters.py:63: error: Parameter 1 of Literal[...] is invalid [valid-type]
|
||||
discord/ext/commands/parameters.py:64: error: Parameter 1 of Literal[...] is invalid [valid-type]
|
||||
|
|
|
|||
|
|
@ -123,8 +123,8 @@ discord/ext/commands/bot.py:330:50: error[invalid-type-arguments] Too many type
|
|||
discord/ext/commands/bot.py:655:16: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, Any]` has no attribute `__name__`
|
||||
discord/ext/commands/bot.py:681:16: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, Any]` has no attribute `__name__`
|
||||
discord/ext/commands/bot.py:1546:13: error[invalid-parameter-default] Default value of type `_DefaultRepr` is not assignable to annotated parameter type `HelpCommand | None`
|
||||
discord/ext/commands/cog.py:288:36: error[invalid-type-arguments] Type `<special-form 'typing.Self'>` is not assignable to upper bound `Cog | None` of type variable `CogT@Command`
|
||||
discord/ext/commands/cog.py:289:79: error[invalid-type-arguments] Type `<special-form 'typing.Self'>` is not assignable to upper bound `Group | Cog` of type variable `GroupT@Command`
|
||||
discord/ext/commands/cog.py:288:36: error[invalid-type-arguments] Type `<special form 'typing.Self'>` is not assignable to upper bound `Cog | None` of type variable `CogT@Command`
|
||||
discord/ext/commands/cog.py:289:79: error[invalid-type-arguments] Type `<special form 'typing.Self'>` is not assignable to upper bound `Group | Cog` of type variable `GroupT@Command`
|
||||
discord/ext/commands/context.py:411:15: error[invalid-method-override] Invalid override of method `_get_channel`: Definition is incompatible with `Messageable._get_channel`
|
||||
discord/ext/commands/context.py:783:9: error[invalid-method-override] Invalid override of method `typing`: Definition is incompatible with `Messageable.typing`
|
||||
discord/ext/commands/converter.py:402:39: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `TextChannel | VoiceChannel | StageChannel | ... omitted 4 union elements`, found `(VoiceChannel & ~AlwaysFalsy) | (StageChannel & ~AlwaysFalsy) | (ForumChannel & Messageable & ~AlwaysFalsy) | ... omitted 5 union elements`
|
||||
|
|
@ -312,7 +312,7 @@ discord/sticker.py:434:16: warning[possibly-missing-attribute] Attribute `_get_g
|
|||
discord/sticker.py:489:43: warning[possibly-missing-attribute] Attribute `http` may be missing on object of type `Any | None | ConnectionState[Client]`
|
||||
discord/sticker.py:490:29: error[invalid-argument-type] Argument to bound method `__init__` is incorrect: Expected `ConnectionState[Client]`, found `Any | None | ConnectionState[Client]`
|
||||
discord/sticker.py:511:15: warning[possibly-missing-attribute] Attribute `http` may be missing on object of type `Any | None | ConnectionState[Client]`
|
||||
discord/ui/action_row.py:122:67: error[invalid-type-arguments] Type `<special-form 'typing.Self'>` is not assignable to upper bound `BaseView | ActionRow[Unknown] | Container[Unknown]` of type variable `C@ContainedItemCallbackType`
|
||||
discord/ui/action_row.py:122:67: error[invalid-type-arguments] Type `<special form 'typing.Self'>` is not assignable to upper bound `BaseView | ActionRow[Unknown] | Container[Unknown]` of type variable `C@ContainedItemCallbackType`
|
||||
discord/ui/action_row.py:163:26: error[unresolved-attribute] Object of type `(Unknown, Interaction[Any], Unknown, /) -> Coroutine[Any, Any, Any]` has no attribute `__discord_ui_model_type__`
|
||||
discord/ui/action_row.py:163:59: error[unresolved-attribute] Object of type `(Unknown, Interaction[Any], Unknown, /) -> Coroutine[Any, Any, Any]` has no attribute `__discord_ui_model_kwargs__`
|
||||
discord/ui/action_row.py:166:27: error[unresolved-attribute] Object of type `(Unknown, Interaction[Any], Unknown, /) -> Coroutine[Any, Any, Any]` has no attribute `__name__`
|
||||
|
|
@ -328,7 +328,7 @@ discord/ui/button.py:276:9: error[invalid-method-override] Invalid override of m
|
|||
discord/ui/button.py:287:9: error[invalid-method-override] Invalid override of method `_refresh_component`: Definition is incompatible with `Item._refresh_component`
|
||||
discord/ui/button.py:376:9: error[unresolved-attribute] Unresolved attribute `__discord_ui_model_type__` on type `(S@button, Interaction[Any], Button[V@button], /) -> Coroutine[Any, Any, Any]`.
|
||||
discord/ui/button.py:377:9: error[unresolved-attribute] Unresolved attribute `__discord_ui_model_kwargs__` on type `(S@button, Interaction[Any], Button[V@button], /) -> Coroutine[Any, Any, Any]`.
|
||||
discord/ui/container.py:109:77: error[invalid-type-arguments] Type `<special-form 'typing.Self'>` is not assignable to upper bound `BaseView | ActionRow[Unknown] | Container[Unknown]` of type variable `C@ContainedItemCallbackType`
|
||||
discord/ui/container.py:109:77: error[invalid-type-arguments] Type `<special form 'typing.Self'>` is not assignable to upper bound `BaseView | ActionRow[Unknown] | Container[Unknown]` of type variable `C@ContainedItemCallbackType`
|
||||
discord/ui/container.py:151:30: error[unresolved-attribute] Object of type `((Unknown, Interaction[Any], Unknown, /) -> Coroutine[Any, Any, Any]) & ~Item[object]` has no attribute `__discord_ui_model_type__`
|
||||
discord/ui/container.py:151:62: error[unresolved-attribute] Object of type `((Unknown, Interaction[Any], Unknown, /) -> Coroutine[Any, Any, Any]) & ~Item[object]` has no attribute `__discord_ui_model_kwargs__`
|
||||
discord/ui/container.py:153:31: error[unresolved-attribute] Object of type `((Unknown, Interaction[Any], Unknown, /) -> Coroutine[Any, Any, Any]) & ~Item[object]` has no attribute `__name__`
|
||||
|
|
@ -343,7 +343,7 @@ discord/ui/file_upload.py:184:9: error[invalid-method-override] Invalid override
|
|||
discord/ui/label.py:112:9: error[invalid-method-override] Invalid override of method `to_component_dict`: Definition is incompatible with `Item.to_component_dict`
|
||||
discord/ui/label.py:125:9: error[invalid-method-override] Invalid override of method `from_component`: Definition is incompatible with `Item.from_component`
|
||||
discord/ui/media_gallery.py:259:9: error[invalid-method-override] Invalid override of method `from_component`: Definition is incompatible with `Item.from_component`
|
||||
discord/ui/modal.py:109:55: error[invalid-type-arguments] Type `<special-form 'typing.Self'>` is not assignable to upper bound `BaseView` of type variable `V@Item`
|
||||
discord/ui/modal.py:109:55: error[invalid-type-arguments] Type `<special form 'typing.Self'>` is not assignable to upper bound `BaseView` of type variable `V@Item`
|
||||
discord/ui/modal.py:159:15: error[invalid-method-override] Invalid override of method `on_error`: Definition is incompatible with `BaseView.on_error`
|
||||
discord/ui/modal.py:176:9: error[invalid-method-override] Invalid override of method `_refresh`: Definition is incompatible with `BaseView._refresh`
|
||||
discord/ui/modal.py:202:15: error[invalid-method-override] Invalid override of method `_scheduled_task`: Definition is incompatible with `BaseView._scheduled_task`
|
||||
|
|
|
|||
|
|
@ -3060,8 +3060,8 @@ homeassistant/components/rfxtrx/switch.py:149:36: error[unresolved-attribute] Ob
|
|||
homeassistant/components/ring/camera.py:186:17: error[invalid-argument-type] Argument to function `async_aiohttp_proxy_stream` is incorrect: Expected `StreamReader`, found `StreamReader`
|
||||
homeassistant/components/ring/entity.py:79:54: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, _R@exception_wrap]` has no attribute `__name__`
|
||||
homeassistant/components/ring/entity.py:190:16: error[invalid-return-type] Return type does not match returned value: expected `RingDevices`, found `Unknown | RingDevices | dict[str, Any]`
|
||||
homeassistant/components/ring/switch.py:103:38: error[invalid-argument-type] Argument is incorrect: Expected `<special-form 'typing.Self'>`, found `RingSwitchEntityDescription[Any]`
|
||||
homeassistant/components/ring/switch.py:124:57: error[invalid-argument-type] Argument is incorrect: Expected `<special-form 'typing.Self'>`, found `RingSwitchEntityDescription[RingDeviceT@RingSwitch]`
|
||||
homeassistant/components/ring/switch.py:103:38: error[invalid-argument-type] Argument is incorrect: Expected `<special form 'typing.Self'>`, found `RingSwitchEntityDescription[Any]`
|
||||
homeassistant/components/ring/switch.py:124:57: error[invalid-argument-type] Argument is incorrect: Expected `<special form 'typing.Self'>`, found `RingSwitchEntityDescription[RingDeviceT@RingSwitch]`
|
||||
homeassistant/components/ripple/sensor.py:7:6: error[unresolved-import] Cannot resolve imported module `pyripple`
|
||||
homeassistant/components/risco/config_flow.py:272:51: error[non-subscriptable] Cannot subscript object of type `int` with no `__getitem__` method
|
||||
homeassistant/components/risco/config_flow.py:294:32: warning[possibly-missing-attribute] Attribute `values` may be missing on object of type `Unknown | int | dict[Unknown | str, Unknown | AlarmControlPanelState] | dict[Unknown | AlarmControlPanelState, Unknown | str]`
|
||||
|
|
@ -4122,8 +4122,8 @@ homeassistant/components/yeelight/device.py:200:9: error[invalid-assignment] Obj
|
|||
homeassistant/components/yeelight/light.py:256:47: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, _R@_async_cmd]` has no attribute `__name__`
|
||||
homeassistant/components/yeelight/light.py:264:43: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, _R@_async_cmd]` has no attribute `__name__`
|
||||
homeassistant/components/yeelight/light.py:270:43: error[unresolved-attribute] Object of type `(...) -> Coroutine[Any, Any, _R@_async_cmd]` has no attribute `__name__`
|
||||
homeassistant/components/yeelight/scanner.py:55:13: error[invalid-assignment] Object of type `Self@async_get` is not assignable to attribute `_scanner` of type `<special-form 'typing.Self'> | None`
|
||||
homeassistant/components/yeelight/scanner.py:56:16: error[invalid-return-type] Return type does not match returned value: expected `Self@async_get`, found `<special-form 'typing.Self'> | None`
|
||||
homeassistant/components/yeelight/scanner.py:55:13: error[invalid-assignment] Object of type `Self@async_get` is not assignable to attribute `_scanner` of type `<special form 'typing.Self'> | None`
|
||||
homeassistant/components/yeelight/scanner.py:56:16: error[invalid-return-type] Return type does not match returned value: expected `Self@async_get`, found `<special form 'typing.Self'> | None`
|
||||
homeassistant/components/yeelightsunflower/light.py:9:8: error[unresolved-import] Cannot resolve imported module `yeelightsunflower`
|
||||
homeassistant/components/yi/camera.py:7:6: error[unresolved-import] Cannot resolve imported module `aioftp`
|
||||
homeassistant/components/yi/camera.py:144:34: error[invalid-argument-type] Argument to bound method `open_camera` is incorrect: Expected `str`, found `Unknown | None`
|
||||
|
|
|
|||
|
|
@ -8230,10 +8230,10 @@ torch/_library/infer_schema.py:63:18: error[unresolved-attribute] Object of type
|
|||
torch/_library/infer_schema.py:132:37: error[unresolved-attribute] Module `torch._C` has no member `ScriptObject`
|
||||
torch/_library/infer_schema.py:185:50: error[unresolved-attribute] Module `torch` has no member `device`
|
||||
torch/_library/infer_schema.py:187:44: error[unresolved-attribute] Module `torch` has no member `dtype`
|
||||
torch/_library/infer_schema.py:222:80: error[invalid-assignment] Object of type `list[tuple[type | _SpecialForm | GenericAlias, str] | tuple[<types.UnionType special-form>, str]]` is not assignable to `list[tuple[type | _SpecialForm | GenericAlias, str]]`
|
||||
torch/_library/infer_schema.py:244:46: error[invalid-argument-type] Argument to function `derived_seq_types` is incorrect: Expected `type | _SpecialForm`, found `<types.UnionType special-form>`
|
||||
torch/_library/infer_schema.py:248:13: error[invalid-argument-type] Argument to bound method `extend` is incorrect: Expected `Iterable[tuple[type | _SpecialForm | GenericAlias, str]]`, found `GeneratorType[tuple[<types.UnionType special-form 'Unknown | None'>, str], None, None]`
|
||||
torch/_library/infer_schema.py:256:82: error[invalid-assignment] Object of type `list[tuple[type | _SpecialForm, str, bool, bool, bool] | tuple[<types.UnionType special-form 'int | float'>, str, bool, bool, bool] | tuple[<NewType pseudo-class 'OpaqueType'>, str, bool, bool, bool]]` is not assignable to `list[tuple[type | _SpecialForm, str, bool, bool, bool]]`
|
||||
torch/_library/infer_schema.py:222:80: error[invalid-assignment] Object of type `list[tuple[type | _SpecialForm | GenericAlias, str] | tuple[<types.UnionType special form>, str]]` is not assignable to `list[tuple[type | _SpecialForm | GenericAlias, str]]`
|
||||
torch/_library/infer_schema.py:244:46: error[invalid-argument-type] Argument to function `derived_seq_types` is incorrect: Expected `type | _SpecialForm`, found `<types.UnionType special form>`
|
||||
torch/_library/infer_schema.py:248:13: error[invalid-argument-type] Argument to bound method `extend` is incorrect: Expected `Iterable[tuple[type | _SpecialForm | GenericAlias, str]]`, found `GeneratorType[tuple[<types.UnionType special form 'Unknown | None'>, str], None, None]`
|
||||
torch/_library/infer_schema.py:256:82: error[invalid-assignment] Object of type `list[tuple[type | _SpecialForm, str, bool, bool, bool] | tuple[<types.UnionType special form 'int | float'>, str, bool, bool, bool] | tuple[<NewType pseudo-class 'OpaqueType'>, str, bool, bool, bool]]` is not assignable to `list[tuple[type | _SpecialForm, str, bool, bool, bool]]`
|
||||
torch/_library/opaque_object.py:23:36: error[unresolved-attribute] Module `torch._C` has no member `ScriptObject`
|
||||
torch/_library/opaque_object.py:26:41: error[unresolved-attribute] Module `torch._C` has no member `ScriptObject`
|
||||
torch/_library/opaque_object.py:84:12: error[unresolved-attribute] Module `torch._C` has no member `_make_opaque_object`
|
||||
|
|
@ -24835,14 +24835,14 @@ torch/utils/_pytree.py:1119:30: error[unresolved-attribute] Special form `typing
|
|||
torch/utils/_pytree.py:1120:31: error[unresolved-attribute] Special form `typing.Self` has no attribute `num_leaves`
|
||||
torch/utils/_pytree.py:1131:62: error[too-many-positional-arguments] Too many positional arguments to bound method `__repr__`: expected 1, got 2
|
||||
torch/utils/_pytree.py:1135:58: error[too-many-positional-arguments] Too many positional arguments to bound method `__repr__`: expected 1, got 2
|
||||
torch/utils/_pytree.py:1167:16: error[invalid-return-type] Return type does not match returned value: expected `list[Self@children_specs]`, found `list[<special-form 'typing.Self'>]`
|
||||
torch/utils/_pytree.py:1173:16: error[invalid-return-type] Return type does not match returned value: expected `list[Self@children]`, found `list[<special-form 'typing.Self'>]`
|
||||
torch/utils/_pytree.py:1176:16: error[invalid-return-type] Return type does not match returned value: expected `Self@child`, found `<special-form 'typing.Self'>`
|
||||
torch/utils/_pytree.py:1167:16: error[invalid-return-type] Return type does not match returned value: expected `list[Self@children_specs]`, found `list[<special form 'typing.Self'>]`
|
||||
torch/utils/_pytree.py:1173:16: error[invalid-return-type] Return type does not match returned value: expected `list[Self@children]`, found `list[<special form 'typing.Self'>]`
|
||||
torch/utils/_pytree.py:1176:16: error[invalid-return-type] Return type does not match returned value: expected `Self@child`, found `<special form 'typing.Self'>`
|
||||
torch/utils/_pytree.py:1280:20: error[unresolved-attribute] Special form `typing.Self` has no attribute `num_leaves`
|
||||
torch/utils/_pytree.py:1281:34: error[unresolved-attribute] Special form `typing.Self` has no attribute `unflatten`
|
||||
torch/utils/_pytree.py:1341:18: warning[deprecated] The class `LeafSpec` is deprecated: `isinstance(treespec, LeafSpec)` is deprecated, use `isinstance(treespec, TreeSpec) and treespec.is_leaf()` instead.
|
||||
torch/utils/_pytree.py:1344:24: warning[deprecated] The class `LeafSpec` is deprecated: `isinstance(treespec, LeafSpec)` is deprecated, use `isinstance(treespec, TreeSpec) and treespec.is_leaf()` instead.
|
||||
torch/utils/_pytree.py:1917:40: error[invalid-argument-type] Argument to function `_treespec_to_json` is incorrect: Expected `TreeSpec`, found `<special-form 'typing.Self'>`
|
||||
torch/utils/_pytree.py:1917:40: error[invalid-argument-type] Argument to function `_treespec_to_json` is incorrect: Expected `TreeSpec`, found `<special form 'typing.Self'>`
|
||||
torch/utils/_stats.py:26:12: error[unresolved-attribute] Object of type `(**_P@count) -> _R@count` has no attribute `__qualname__`
|
||||
torch/utils/_stats.py:27:33: error[unresolved-attribute] Object of type `(**_P@count) -> _R@count` has no attribute `__qualname__`
|
||||
torch/utils/_stats.py:28:29: error[unresolved-attribute] Object of type `(**_P@count) -> _R@count` has no attribute `__qualname__`
|
||||
|
|
|
|||
Loading…
Reference in New Issue