BSK-E0049 error

Multiple unbounded tuple components in a single tuple type

A tuple... type annotation may contain at most one unbounded component. An unbounded component is: - tupleT, ... — a starred subscript where the inner tuple is variadic - Ts / *<Name> — a starred TypeVarTuple unpack - Unpacktuple[T, ...] — the legacy unpack form

For example, tupletuple[str, ..., tupleint, ...] is invalid because it has two unbounded components.

t: tuple[*tuple[str, ...], *tuple[int, ...]]  # E — two unbounded components
t: tuple[*tuple[str, ...], *Ts]               # E — two unbounded components
t: tuple[*tuple[str, ...], str]               # OK — only one unbounded

How to handle it

Every rule is on by default — strict is the default, not a cage. You can dial BSK-E0049 down per-file or per-path from your editor or pyproject.toml, or fix the code so it type-checks. See the Type System rules and the complete diagnostic reference.

Canonical URL: https://www.basilisk-python.dev/errors/BSK-E0049