patch[cli] Fix bug in check_imports.py (#24918)

The variable `has_failure` in check_imports.py is wrong-declared. It's
actually an another variable.
This commit is contained in:
ZhangShenao 2024-08-01 21:08:12 +08:00 committed by GitHub
parent f14121faaf
commit b2dd9ffaaf
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -9,7 +9,7 @@ if __name__ == "__main__":
try: try:
SourceFileLoader("x", file).load_module() SourceFileLoader("x", file).load_module()
except Exception: except Exception:
has_faillure = True has_failure = True
print(file) # noqa: T201 print(file) # noqa: T201
traceback.print_exc() traceback.print_exc()
print() # noqa: T201 print() # noqa: T201