I have a class with an init that takes many arguments--some required, some not.
If one of the needed arguments is not supplied, you may get a TypeError, with an unhelpful message like 'requires at least 10 arguments (14 given)'.
I would like to have a custom TypeError subclass that actually informs the user of which arguments are missing.
Aucun commentaire:
Enregistrer un commentaire