NNPDF / reportengine

A framework for declarative data analysis
https://data.nnpdf.science/validphys-docs/guide.html
GNU General Public License v2.0
1 stars 3 forks source link

checks should have an apply method #6

Open Zaharid opened 6 years ago

Zaharid commented 6 years ago

... Especially argchecks.

When the make_argcheck decorator is applied, the result is a function that takes another function as argument, and instructs reportengine to apply the corresponding check. However we may be interested in simply using the function outside the loop. A possible solution is to make it so make_argcheck adds an apply method to the checks, that has the same effect as the original function.