[BE] add noqa for flake8 rule B036: found except BaseException without re-raising (#159043)

Pull Request resolved: https://github.com/pytorch/pytorch/pull/159043
Approved by: https://github.com/Skylion007
This commit is contained in:
Xuehai Pan
2025-07-25 01:07:16 +08:00
committed by PyTorch MergeBot
parent 4261e26a8b
commit f903bc475c
16 changed files with 29 additions and 29 deletions

View File

@ -686,7 +686,7 @@ def logging_manager(*, debug: bool = False) -> Generator[logging.Logger, None, N
logging_record_exception(e)
print(f"log file: {log_file}")
sys.exit(1)
except BaseException as e:
except BaseException as e: # noqa: B036
# You could logging.debug here to suppress the backtrace
# entirely, but there is no reason to hide it from technically
# savvy users.