Skip to content

Commit d79aa5b

Browse files
committed
Small cleanup
1 parent 4a8911c commit d79aa5b

File tree

3 files changed

+3
-22
lines changed

3 files changed

+3
-22
lines changed

Makefile

Lines changed: 0 additions & 14 deletions
This file was deleted.

pylintrc

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ disable=
1313
unused-argument,
1414
# tests
1515
abstract-method,
16-
bare-except,
1716
duplicate-code,
1817
import-outside-toplevel,
1918
inconsistent-return-statements,

tests/__init__.py

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
from contextlib import asynccontextmanager
1+
from contextlib import asynccontextmanager, suppress
22

33
from scrapy.utils.test import get_crawler
44

@@ -10,11 +10,7 @@ async def make_handler(settings_dict: dict):
1010

1111
crawler = get_crawler(settings_dict=settings_dict)
1212
handler = ScrapyPlaywrightDownloadHandler(crawler=crawler)
13-
try:
13+
with suppress(Exception):
1414
await handler._launch_browser()
15-
except: # noqa (E722)
16-
pass
17-
else:
1815
yield handler
19-
finally:
20-
await handler._close()
16+
await handler._close()

0 commit comments

Comments
 (0)