[BE][Ez]: Update ruff to 0.12.2 (#157937)

Updates to the latest version of ruff and apply some fixes that it flagged and silence a few new lints

Pull Request resolved: https://github.com/pytorch/pytorch/pull/157937
Approved by: https://github.com/ezyang
This commit is contained in:
Aaron Gokaslan
2025-07-11 15:16:20 +00:00
committed by PyTorch MergeBot
parent 0d17029fea
commit 7a08755c5f
5 changed files with 18 additions and 9 deletions

View File

@ -2597,11 +2597,14 @@ class AlgorithmSelectorCache(PersistentCache):
"Exception %s for benchmark choice %s",
e,
futures[future],
exc_info=True,
exc_info=e,
)
else:
log.error(
"Exception %s for benchmark choice %s", e, futures[future]
log.exception( # noqa: G202
"Exception %s for benchmark choice %s",
e,
futures[future],
exc_info=e,
)
else:
counters["inductor"]["select_algorithm_num_precompiles"] += 1