Open FRidh opened 1 year ago
I think this is a great candidate for thinking about pandera config (which is non-existent today).
Basically the idea is to have both env vars and config option to modify pandera's behavior:
Env var:
PANDERA_DISABLE_RUNTIME_CHECKING=1
Config file, e.g. pandera.yml
:
disable_runtime_checking: true
Will also need to define the behavior of:
What do you think @FRidh ?
Yes, indeed something like that.
I'm quite fresh to pandera so I don't know yet what other kind of configuration could be of interest. Regarding the file, personally I would much more prefer to see a .toml file
over a .yml file
.
Would you be able to come up with a PR for the environment variable-based solution? I think basically it should modify the check_types
decorator to return the wrapped function if PANDERA_DISABLE_RUNTIME_CHECKING=1
Is your feature request related to a problem? Please describe. We have a situation where we do a tremendous amount of calls and would prefer not to have the overhead of Pandera.
Describe the solution you'd like We would like to be able to disable Pandera runtime checking, e.g., using a environment variable.
Describe alternatives you've considered Wrapper or monkeypatching decorators such as
check_types
.Additional context Discussion