Drop requirement on which in Python system tests (#18588)

This commit is contained in:
Zanie Blue
2026-03-20 11:26:07 -05:00
committed by GitHub
parent cedae1aa42
commit cb093394b3
+3 -7
View File
@@ -152,13 +152,9 @@ if __name__ == "__main__":
if code.returncode != 0:
raise Exception("The package `pylint` isn't installed (but should be).")
# TODO(charlie): Windows is failing to find the `pylint` binary, despite
# confirmation that it's being written to the intended location.
if os.name != "nt":
logging.info("Checking that `pylint` is in the path.")
code = subprocess.run(["which", "pylint"], cwd=temp_dir)
if code.returncode != 0:
raise Exception("The package `pylint` isn't in the path.")
logging.info("Checking that `pylint` is in the path.")
if shutil.which("pylint") is None:
raise Exception("The package `pylint` isn't in the path.")
# Uninstall the package (`pylint`).
logging.info("Uninstalling the package `pylint`.")