Enable Ruff SIM105 (#86759)

* Enable Ruff SIM105

* Adjust existing cases
This commit is contained in:
Franck Nijhof
2023-01-27 03:06:22 +01:00
committed by GitHub
parent 71d7098530
commit e738924780
13 changed files with 36 additions and 47 deletions

View File

@ -6,6 +6,7 @@ This is NOT a full CI/linting replacement, only a quick check during development
"""
import asyncio
from collections import namedtuple
from contextlib import suppress
import itertools
import os
import re
@ -249,7 +250,5 @@ async def main():
if __name__ == "__main__":
try:
with suppress(FileNotFoundError, KeyboardInterrupt):
asyncio.run(main())
except (FileNotFoundError, KeyboardInterrupt):
pass