Description
Description
The class Prerequisite
has an is_valid()
method.
If the prerequisite passes the check, it returns (True, "")
.
There is no mention what the tuple means, and the only caller (check_and_install_default_prerequisites
) just cares about its truthiness, anyway. It should just return True.
If the prerequisite fails the check, and is mandatory, an error is logged... and the function falls out without returning a value. It should explicitly return False for clarity, rather than implicitly returning None.
If the prerequisite fails the check, but is not mandatory, a warning is logged... and again the function falls out without returning a value. Given the context (anything returning False is attempted to be installed), I believe this should return True
[This is low priority for me; I am not sure if a PR will follow later, so I am recording it as an issue.]