From dc52e29ed73680f5d0e304584254348de113f63d Mon Sep 17 00:00:00 2001 From: symonk Date: Mon, 24 Jul 2023 18:08:33 +0100 Subject: [PATCH] [py]: Remove unused vars --- py/selenium/webdriver/common/bidi/cdp.py | 2 +- py/selenium/webdriver/firefox/webdriver.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/py/selenium/webdriver/common/bidi/cdp.py b/py/selenium/webdriver/common/bidi/cdp.py index f7e18c0896cc9..5eba00af157b5 100644 --- a/py/selenium/webdriver/common/bidi/cdp.py +++ b/py/selenium/webdriver/common/bidi/cdp.py @@ -275,7 +275,7 @@ def _handle_cmd_response(self, data): # Otherwise, continue the generator to parse the JSON result # into a CDP object. try: - response = cmd.send(data["result"]) + _ = cmd.send(data["result"]) raise InternalError("The command's generator function " "did not exit when expected!") except StopIteration as exit: return_ = exit.value diff --git a/py/selenium/webdriver/firefox/webdriver.py b/py/selenium/webdriver/firefox/webdriver.py index 371d6c0f97d62..d79f5a334f46d 100644 --- a/py/selenium/webdriver/firefox/webdriver.py +++ b/py/selenium/webdriver/firefox/webdriver.py @@ -122,7 +122,7 @@ def install_addon(self, path, temporary=False) -> str: fp = BytesIO() path_root = len(path) + 1 # account for trailing slash with zipfile.ZipFile(fp, "w", zipfile.ZIP_DEFLATED) as zipped: - for base, dirs, files in os.walk(path): + for base, _, files in os.walk(path): for fyle in files: filename = os.path.join(base, fyle) zipped.write(filename, filename[path_root:])