-2

I found * , / in the typing source code, but I don't understand what it means.

def TypedDict(typename, fields=None, /, *, total=True, **kwargs):
    pass

1 Answers1

1

Anything before / means that the argument is position-only (see PEP-570, while anything after *is keyword only (see PEP-3102). Anything in between can be both positional and keyword.

Ftagliacarne
  • 675
  • 8
  • 16