Open ascillitoe opened 2 years ago
Some detector kwarg's are "magic strings" with a limited set of options, e.g. correction and alternative is the univariate detectors. We should update these kwarg's to type them as Literal. For example, in ksdrift.py:
correction
alternative
Literal
ksdrift.py
correction: str = 'bonferroni', alternative: str = 'two-sided',
would become:
correction: str = Literal['bonferroni', 'fdr'] alternative: str = Literal['two-sided', 'less', 'greater']
The same changes should be made in the pydantic schema's once the config PR is merged (#389), in order to tighten the validation of these kwarg's.
The same should also be done for other public facing classes, such as DeepKernel.
DeepKernel
Some detector kwarg's are "magic strings" with a limited set of options, e.g.
correction
andalternative
is the univariate detectors. We should update these kwarg's to type them asLiteral
. For example, inksdrift.py
:would become:
The same changes should be made in the pydantic schema's once the config PR is merged (#389), in order to tighten the validation of these kwarg's.