Is `check_comparison` needed at all?
Opened this issue · 2 comments
The check_comparison()
function seems to be reluctant. It works the same way as check_if()
, but seems to be less clear. For instance,
check_if(x >= y)
is clearer, and more natural, than
from easycheck import gt
check_comparison(x, gt, y)
Should we deprecate check_comparison()
?
On one hand I am thinking that there is no reason to remove this function and it will be better to give user as many toys as many we can. But as you say everything we can do in check_if() and without validation that function can be used in unexpected way (e.g. when somebody by mistake give unsupported operator).
If it's not a problem for us, I would leave it as it is.
Okay. This function, even if not used, does not constitute the problem, maybe a minor one: it makes the packages API more complicated than it can be. Let this issue be open for some time, and we will return to this in some time. Maybe we will change our decision to keep the function.