bitter-ability-32190
09/22/2022, 2:57 PM_GoalSubsystemT = TypeVar("_GoalSubsystemT", bound=GoalSubsystem)
async def _get_subpartitions(
subsystem: type[_GoalSubsystemT],
): ...
...
_get_subpartitions(lint_subsystem)
# Note: `LintSubsystem` is `class LintSubsystem(GoalSubsystem):`
yields
error: Argument 1 to "_get_subpartitions" has incompatible type "LintSubsystem"; expected "Type[<nothing>]" [arg-type]
https://mypy.readthedocs.io/en/stable/kinds_of_types.html#the-type-of-class-objects makes me think what I'm doing is OKancient-vegetable-10556
09/22/2022, 3:03 PMbitter-ability-32190
09/22/2022, 3:04 PM<nothing>
is what kills me 😐ancient-vegetable-10556
09/22/2022, 3:04 PMlint_subsystem
?ancient-vegetable-10556
09/22/2022, 3:04 PMbitter-ability-32190
09/22/2022, 3:04 PMbitter-ability-32190
09/22/2022, 3:04 PMancient-vegetable-10556
09/22/2022, 3:05 PMLintSubsystem
, rather than the type object itselfbitter-ability-32190
09/22/2022, 3:06 PMbitter-ability-32190
09/22/2022, 3:06 PMancient-vegetable-10556
09/22/2022, 3:07 PMbitter-ability-32190
09/22/2022, 3:17 PM