from typing import Generic, TypeVarTuple, Unpack Shape = TypeVarTuple('Shape') class C(Generic[*Shape]): pass