Title: [271158] trunk/Tools
Revision
271158
Author
[email protected]
Date
2021-01-05 10:33:43 -0800 (Tue, 05 Jan 2021)

Log Message

Remove some unused variables from webkitpy
https://bugs.webkit.org/show_bug.cgi?id=220180

Reviewed by Aakash Jain, Sam Weinig and Jonathan Bedard.

* Scripts/webkitpy/benchmark_runner/webdriver_benchmark_runner.py:
* Scripts/webkitpy/benchmark_runner/webserver_benchmark_runner.py:
* Scripts/webkitpy/codegen/main.py:
* Scripts/webkitpy/common/checkout/changelog.py:
* Scripts/webkitpy/common/checkout/checkout.py:
* Scripts/webkitpy/common/checkout/scm/git.py:
* Scripts/webkitpy/common/checkout/scm/svn.py:
* Scripts/webkitpy/common/config/committers.py:
* Scripts/webkitpy/common/config/contributionareas.py:
* Scripts/webkitpy/common/message_pool.py:
* Scripts/webkitpy/common/net/buildbot/buildbot.py:
* Scripts/webkitpy/common/net/credentials.py:
* Scripts/webkitpy/common/system/crashlogs.py:
* Scripts/webkitpy/common/system/executive.py:
* Scripts/webkitpy/common/system/profiler.py:
* Scripts/webkitpy/common/system/user.py:
* Scripts/webkitpy/generate_xcfilelists_lib/application.py:
* Scripts/webkitpy/generate_xcfilelists_lib/generators.py:
* Scripts/webkitpy/layout_tests/controllers/manager.py:
* Scripts/webkitpy/layout_tests/controllers/single_test_runner.py:
* Scripts/webkitpy/layout_tests/servers/apache_http_server.py:
* Scripts/webkitpy/layout_tests/servers/http_server.py:
* Scripts/webkitpy/layout_tests/views/buildbot_results.py:
* Scripts/webkitpy/layout_tests/views/metered_stream.py:
* Scripts/webkitpy/performance_tests/perftest.py:
* Scripts/webkitpy/port/device_port.py:
* Scripts/webkitpy/port/factory.py:
* Scripts/webkitpy/port/leakdetector_valgrind.py:
* Scripts/webkitpy/port/server_process.py:
* Scripts/webkitpy/style/checkers/js.py:
* Scripts/webkitpy/tool/bot/layouttestresultsreader.py:
* Scripts/webkitpy/tool/bot/patchanalysistask.py:
* Scripts/webkitpy/tool/bot/queueengine.py:
* Scripts/webkitpy/tool/commands/download.py:
* Scripts/webkitpy/tool/commands/earlywarningsystem.py:
* Scripts/webkitpy/tool/commands/queues.py:
* Scripts/webkitpy/tool/commands/suggestnominations.py:
* Scripts/webkitpy/tool/commands/upload.py:
* Scripts/webkitpy/tool/multicommandtool.py:
* Scripts/webkitpy/tool/servers/rebaselineserver.py:
* Scripts/webkitpy/tool/steps/commit.py:
* Scripts/webkitpy/tool/steps/confirmdiff.py:
* Scripts/webkitpy/tool/steps/haslanded.py:
* Scripts/webkitpy/tool/steps/preparechangelog.py:
* Scripts/webkitpy/tool/steps/promptforbugortitle.py:
* Scripts/webkitpy/tool/steps/sortxcodeprojectfiles.py:
* Scripts/webkitpy/tool/steps/suggestreviewers_unittest.py:
* Scripts/webkitpy/w3c/test_exporter.py:
* Scripts/webkitpy/xcode/simulated_device.py:

Modified Paths

Diff

Modified: trunk/Tools/ChangeLog (271157 => 271158)


--- trunk/Tools/ChangeLog	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/ChangeLog	2021-01-05 18:33:43 UTC (rev 271158)
@@ -1,3 +1,60 @@
+2021-01-05  Alexey Proskuryakov  <[email protected]>
+
+        Remove some unused variables from webkitpy
+        https://bugs.webkit.org/show_bug.cgi?id=220180
+
+        Reviewed by Aakash Jain, Sam Weinig and Jonathan Bedard.
+
+        * Scripts/webkitpy/benchmark_runner/webdriver_benchmark_runner.py:
+        * Scripts/webkitpy/benchmark_runner/webserver_benchmark_runner.py:
+        * Scripts/webkitpy/codegen/main.py:
+        * Scripts/webkitpy/common/checkout/changelog.py:
+        * Scripts/webkitpy/common/checkout/checkout.py:
+        * Scripts/webkitpy/common/checkout/scm/git.py:
+        * Scripts/webkitpy/common/checkout/scm/svn.py:
+        * Scripts/webkitpy/common/config/committers.py:
+        * Scripts/webkitpy/common/config/contributionareas.py:
+        * Scripts/webkitpy/common/message_pool.py:
+        * Scripts/webkitpy/common/net/buildbot/buildbot.py:
+        * Scripts/webkitpy/common/net/credentials.py:
+        * Scripts/webkitpy/common/system/crashlogs.py:
+        * Scripts/webkitpy/common/system/executive.py:
+        * Scripts/webkitpy/common/system/profiler.py:
+        * Scripts/webkitpy/common/system/user.py:
+        * Scripts/webkitpy/generate_xcfilelists_lib/application.py:
+        * Scripts/webkitpy/generate_xcfilelists_lib/generators.py:
+        * Scripts/webkitpy/layout_tests/controllers/manager.py:
+        * Scripts/webkitpy/layout_tests/controllers/single_test_runner.py:
+        * Scripts/webkitpy/layout_tests/servers/apache_http_server.py:
+        * Scripts/webkitpy/layout_tests/servers/http_server.py:
+        * Scripts/webkitpy/layout_tests/views/buildbot_results.py:
+        * Scripts/webkitpy/layout_tests/views/metered_stream.py:
+        * Scripts/webkitpy/performance_tests/perftest.py:
+        * Scripts/webkitpy/port/device_port.py:
+        * Scripts/webkitpy/port/factory.py:
+        * Scripts/webkitpy/port/leakdetector_valgrind.py:
+        * Scripts/webkitpy/port/server_process.py:
+        * Scripts/webkitpy/style/checkers/js.py:
+        * Scripts/webkitpy/tool/bot/layouttestresultsreader.py:
+        * Scripts/webkitpy/tool/bot/patchanalysistask.py:
+        * Scripts/webkitpy/tool/bot/queueengine.py:
+        * Scripts/webkitpy/tool/commands/download.py:
+        * Scripts/webkitpy/tool/commands/earlywarningsystem.py:
+        * Scripts/webkitpy/tool/commands/queues.py:
+        * Scripts/webkitpy/tool/commands/suggestnominations.py:
+        * Scripts/webkitpy/tool/commands/upload.py:
+        * Scripts/webkitpy/tool/multicommandtool.py:
+        * Scripts/webkitpy/tool/servers/rebaselineserver.py:
+        * Scripts/webkitpy/tool/steps/commit.py:
+        * Scripts/webkitpy/tool/steps/confirmdiff.py:
+        * Scripts/webkitpy/tool/steps/haslanded.py:
+        * Scripts/webkitpy/tool/steps/preparechangelog.py:
+        * Scripts/webkitpy/tool/steps/promptforbugortitle.py:
+        * Scripts/webkitpy/tool/steps/sortxcodeprojectfiles.py:
+        * Scripts/webkitpy/tool/steps/suggestreviewers_unittest.py:
+        * Scripts/webkitpy/w3c/test_exporter.py:
+        * Scripts/webkitpy/xcode/simulated_device.py:
+
 2021-01-05  Sihui Liu  <[email protected]>
 
         Fail speech recognition when page is muted for audio capture

Modified: trunk/Tools/Scripts/webkitpy/benchmark_runner/webdriver_benchmark_runner.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/benchmark_runner/webdriver_benchmark_runner.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/benchmark_runner/webdriver_benchmark_runner.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -18,7 +18,6 @@
 
     def _run_one_test(self, web_root, test_file):
         from selenium.webdriver.support.ui import WebDriverWait
-        result = None
         try:
             url = ''.format(root=web_root, plan_name=self._plan_name, test_file=test_file)
             driver = self._browser_driver.launch_driver(url, self._plan['options'], self._build_dir, self._browser_path)

Modified: trunk/Tools/Scripts/webkitpy/benchmark_runner/webserver_benchmark_runner.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/benchmark_runner/webserver_benchmark_runner.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/benchmark_runner/webserver_benchmark_runner.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -31,7 +31,6 @@
         return result
 
     def _run_one_test(self, web_root, test_file):
-        result = None
         try:
             self._http_server_driver.serve(web_root)
             url = "" self._plan_name + '/' + test_file)

Modified: trunk/Tools/Scripts/webkitpy/codegen/main.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/codegen/main.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/codegen/main.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -101,7 +101,7 @@
         combined_outputs = output_mode == "Combined"
         return self.generate_from_js_builtins(test_files, work_directory, framework_name=framework_name, combined_outputs=combined_outputs)
 
-    def wrappers_builtin_test(self, test_name, test_files, work_directory):
+    def wrappers_builtin_test(self, test_files, work_directory):
         return self.generate_from_js_builtins(test_files, work_directory, framework_name="WebCore", generate_wrappers=True)
 
     def run_test(self, reference_directory, test_name, test_files, generate_builtin_callback):

Modified: trunk/Tools/Scripts/webkitpy/common/checkout/changelog.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/common/checkout/changelog.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/common/checkout/changelog.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -321,7 +321,7 @@
     def parse_latest_entry_from_file(cls, changelog_file):
         try:
             return next(cls.parse_entries_from_file(changelog_file))
-        except StopIteration as e:
+        except StopIteration:
             return None
 
     svn_blame_regexp = re.compile(r'^(\s*(?P<revision>\d+) [^ ]+)\s*(?P<line>.*?\n)')

Modified: trunk/Tools/Scripts/webkitpy/common/checkout/checkout.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/common/checkout/checkout.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/common/checkout/checkout.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -155,7 +155,7 @@
     def bug_id_for_this_commit(self, git_commit, changed_files=None):
         try:
             return parse_bug_id_from_changelog(self.commit_message_for_this_commit(git_commit, changed_files).message())
-        except ScriptError as e:
+        except ScriptError:
             pass  # We might not have ChangeLogs.
 
     def apply_patch(self, patch):

Modified: trunk/Tools/Scripts/webkitpy/common/checkout/scm/git.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/common/checkout/scm/git.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/common/checkout/scm/git.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -113,7 +113,7 @@
         try:
             executive = executive or Executive()
             return executive.run_command([cls.executable_name, 'rev-parse', '--is-inside-work-tree'], cwd=path, ignore_errors=True).rstrip() == "true"
-        except OSError as e:
+        except OSError:
             # The Windows bots seem to through a WindowsError when git isn't installed.
             return False
 
@@ -122,7 +122,7 @@
         try:
             executive = executive or Executive()
             return executive.run_command([cls.executable_name, 'clone', '-v', url, directory], ignore_errors=True)
-        except OSError as e:
+        except OSError:
             return False
 
     def find_checkout_root(self, path):
@@ -386,7 +386,7 @@
     def _string_to_int_or_none(self, string):
         try:
             return int(string)
-        except ValueError as e:
+        except ValueError:
             return None
 
     @memoized

Modified: trunk/Tools/Scripts/webkitpy/common/checkout/scm/svn.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/common/checkout/scm/svn.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/common/checkout/scm/svn.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -102,7 +102,7 @@
             svn_info_args = [cls.executable_name, 'info']
             exit_code = executive.run_command(svn_info_args, cwd=path, return_exit_code=True)
             return (exit_code == 0)
-        except OSError as e:
+        except OSError:
             return False
 
     def find_uuid(self, path):
@@ -248,7 +248,7 @@
         log_command = ['log', '--quiet', '--limit=%s' % limit, path]
         try:
             log_output = self._run_svn(log_command, cwd=self.checkout_root)
-        except ScriptError as e:
+        except ScriptError:
             return []
         for line in log_output.splitlines():
             match = re.search('^r(?P<revision>\d+) ', line)

Modified: trunk/Tools/Scripts/webkitpy/common/config/committers.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/common/config/committers.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/common/config/committers.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -213,7 +213,6 @@
         self._reviewers = []
 
         for name, data in contributors.items():
-            contributor = None
             status = data.get('status')
             if status == "reviewer":
                 contributor = Reviewer(name, data.get('emails'), data.get('nicks'), data.get('aliases'), data.get('expertise'))

Modified: trunk/Tools/Scripts/webkitpy/common/config/contributionareas.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/common/config/contributionareas.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/common/config/contributionareas.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -201,7 +201,6 @@
         areas = set()
         for file_path in touched_files:
             split_file_path = self._split_path(file_path)
-            tokenized_file_path = None
             tokenized_file_path = sum([self._split_camelcase(token, lambda x: x.lower()) for token in split_file_path], [])
             for area in self._contribution_areas:
                 if area.matches(split_file_path) or area.matches(tokenized_file_path):

Modified: trunk/Tools/Scripts/webkitpy/common/message_pool.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/common/message_pool.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/common/message_pool.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -268,7 +268,6 @@
             self._set_up_logging()
 
         worker = self._worker
-        exception_msg = ""
         _log.debug("%s starting" % self.name)
 
         try:
@@ -286,9 +285,9 @@
             _log.debug("%s exiting" % self.name)
         except queue.Empty:
             assert False, '%s: ran out of messages in worker queue.' % self.name
-        except KeyboardInterrupt as e:
+        except KeyboardInterrupt:
             self._raise(sys.exc_info())
-        except Exception as e:
+        except Exception:
             self._raise(sys.exc_info())
         finally:
             try:

Modified: trunk/Tools/Scripts/webkitpy/common/net/buildbot/buildbot.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/common/net/buildbot/buildbot.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/common/net/buildbot/buildbot.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -137,7 +137,7 @@
         def predicate(form):
             try:
                 return form.find_control("username")
-            except Exception as e:
+            except Exception:
                 return False
 
         if not self._browser:
@@ -436,7 +436,6 @@
 
     def failure_map(self):
         failure_map = FailureMap()
-        revision_to_failing_bots = {}
         for builder_status in self.builder_statuses():
             if builder_status["is_green"]:
                 continue

Modified: trunk/Tools/Scripts/webkitpy/common/net/credentials.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/common/net/credentials.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/common/net/credentials.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -59,7 +59,7 @@
                 return (None, None)
             return (Git.read_git_config(self.git_prefix + "username"),
                     Git.read_git_config(self.git_prefix + "password"))
-        except OSError as e:
+        except OSError:
             # Catch and ignore OSError exceptions such as "no such file
             # or directory" (OSError errno 2), which imply that the Git
             # command cannot be found/is not installed.

Modified: trunk/Tools/Scripts/webkitpy/common/system/crashlogs.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/common/system/crashlogs.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/common/system/crashlogs.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -53,7 +53,7 @@
         if self._host.platform.is_mac() or self._host.platform.is_ios():
             return self._find_newest_log_darwin(process_name, pid, include_errors, newer_than)
         elif self._host.platform.is_win():
-            return self._find_newest_log_win(process_name, pid, include_errors, newer_than)
+            return self._find_newest_log_win(pid, include_errors, newer_than)
         return None
 
     def find_all_logs(self, include_errors=False, newer_than=None):
@@ -100,7 +100,7 @@
             return errors
         return None
 
-    def _find_newest_log_win(self, process_name, pid, include_errors, newer_than):
+    def _find_newest_log_win(self, pid, include_errors, newer_than):
         def is_crash_log(fs, dirpath, basename):
             if self._crash_logs_to_skip and fs.join(dirpath, basename) in self._crash_logs_to_skip:
                 return False

Modified: trunk/Tools/Scripts/webkitpy/common/system/executive.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/common/system/executive.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/common/system/executive.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -297,7 +297,7 @@
                     if process_name_filter(process_name):
                         running_pids.append(int(pid))
                         self.pid_to_system_pid[int(pid)] = int(winpid)
-                except ValueError as e:
+                except ValueError:
                     pass
         else:
             with self.popen(['ps', '-eo', 'pid,comm'], stdout=self.PIPE, stderr=self.PIPE) as ps_process:
@@ -309,7 +309,7 @@
                         pid, process_name = line.strip().split(b' ', 1)
                         if process_name_filter(string_utils.decode(process_name, target_type=str)):
                             running_pids.append(int(pid))
-                    except ValueError as e:
+                    except ValueError:
                         pass
 
         return sorted(running_pids)

Modified: trunk/Tools/Scripts/webkitpy/common/system/profiler.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/common/system/profiler.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/common/system/profiler.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -70,7 +70,7 @@
     # Used by ProfilerFactory to lookup a profiler from the --profiler=NAME option.
     name = None
 
-    def __init__(self, host, executable_path, output_dir, identifier=None):
+    def __init__(self, host, executable_path, output_dir):
         self._host = host
         self._executable_path = executable_path
         self._output_dir = output_dir
@@ -92,7 +92,7 @@
 
 class SingleFileOutputProfiler(Profiler):
     def __init__(self, host, executable_path, output_dir, output_suffix, identifier=None):
-        super(SingleFileOutputProfiler, self).__init__(host, executable_path, output_dir, identifier)
+        super(SingleFileOutputProfiler, self).__init__(host, executable_path, output_dir)
         # FIXME: Currently all reports are kept as test.*, until we fix that, search up to 1000 names before giving up.
         self._output_path = self._host.workspace.find_unused_filename(self._output_dir, self._identifier, output_suffix, search_limit=1000)
         assert(self._output_path)

Modified: trunk/Tools/Scripts/webkitpy/common/system/user.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/common/system/user.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/common/system/user.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -107,7 +107,7 @@
                             indices += range(int(parts[0]) - 1, int(parts[1]))
                         else:
                             indices.append(int(value) - 1)
-                except ValueError as err:
+                except ValueError:
                     continue
 
                 return [list_items[i] for i in indices]
@@ -114,7 +114,7 @@
             else:
                 try:
                     result = int(cls.prompt("Enter a number: ", raw_input=raw_input)) - 1
-                except ValueError as err:
+                except ValueError:
                     continue
                 return list_items[result]
 
@@ -158,7 +158,7 @@
             # Note: Not thread safe: http://bugs.python.org/issue2320
             child_process = subprocess.Popen([pager], stdin=subprocess.PIPE)
             child_process.communicate(input=message)
-        except IOError as e:
+        except IOError:
             pass
 
     def confirm(self, message=None, default=DEFAULT_YES, raw_input=input_func):
@@ -174,7 +174,7 @@
         try:
             webbrowser.get()
             return True
-        except webbrowser.Error as e:
+        except webbrowser.Error:
             return False
 
     def open_url(self, url):

Modified: trunk/Tools/Scripts/webkitpy/generate_xcfilelists_lib/application.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/generate_xcfilelists_lib/application.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/generate_xcfilelists_lib/application.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -120,7 +120,7 @@
 
             try:
                 func = self.dispatch[args.command]
-            except KeyError as e:
+            except KeyError:
                 raise util.InvalidCommandError(args.command)
 
             return func()
@@ -139,7 +139,7 @@
         except SystemExit:
             raise
 
-        except BaseException as e:
+        except BaseException:
             traceback.print_exc()
             return os.EX_SOFTWARE
 
@@ -329,7 +329,7 @@
             self._log_progress("Generating .xcfilelists for {}/{}/{}".format(*triple))
             try:
                 generators = core_operation(generator, generators)
-            except BaseException as e:
+            except BaseException:
                 # TODO: Turn the traceback into a string, and then allow
                 # this field to be pickled and printed by the calling
                 # context. Right now, pickling raises an exception if it

Modified: trunk/Tools/Scripts/webkitpy/generate_xcfilelists_lib/generators.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/generate_xcfilelists_lib/generators.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/generate_xcfilelists_lib/generators.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -146,7 +146,7 @@
                     generator = pickle.load(pickle_file)
                     generator.application = self.application
                     generators.append(generator)
-                except EOFError as e:
+                except EOFError:
                     break
             return generators
 

Modified: trunk/Tools/Scripts/webkitpy/layout_tests/controllers/manager.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/layout_tests/controllers/manager.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/controllers/manager.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -614,7 +614,7 @@
                 response_text = response.read()
                 try:
                     response_json = json.loads(response_text)
-                except ValueError as error:
+                except ValueError:
                     _log.error("JSON upload failed; failed to parse the response: %s", response_text)
                     continue
 

Modified: trunk/Tools/Scripts/webkitpy/layout_tests/controllers/single_test_runner.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/layout_tests/controllers/single_test_runner.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/controllers/single_test_runner.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -194,7 +194,6 @@
               which html file is used for producing the driver_output.
         """
         failures = []
-        fs = self._filesystem
         if driver_output.timeout:
             failures.append(test_failures.FailureTimeout(bool(reference_filename)))
 

Modified: trunk/Tools/Scripts/webkitpy/layout_tests/servers/apache_http_server.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/layout_tests/servers/apache_http_server.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/servers/apache_http_server.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -90,7 +90,7 @@
 
         # FIXME: We shouldn't be calling a protected method of _port_obj!
         executable = self._port_obj._path_to_apache()
-        config_file_path = self._copy_apache_config_file(self.tests_dir, output_dir)
+        config_file_path = self._copy_apache_config_file(output_dir)
 
         start_cmd = [executable,
             '-f', config_file_path,
@@ -152,10 +152,9 @@
         self._start_cmd = start_cmd
         self._stop_cmd = stop_cmd
 
-    def _copy_apache_config_file(self, test_dir, output_dir):
+    def _copy_apache_config_file(self, output_dir):
         """Copy apache config file and returns the path to use.
         Args:
-          test_dir: absolute path to the LayoutTests directory.
           output_dir: absolute path to the layout test results directory.
         """
         httpd_config = self._port_obj._path_to_apache_config_file()

Modified: trunk/Tools/Scripts/webkitpy/layout_tests/servers/http_server.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/layout_tests/servers/http_server.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/servers/http_server.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -41,7 +41,7 @@
 
 class Lighttpd(http_server_base.HttpServerBase):
 
-    def __init__(self, port_obj, output_dir, background="" port=None,
+    def __init__(self, port_obj, output_dir, port=None,
                  root=None, run_background=None, additional_dirs=None,
                  layout_tests_dir=None):
         """Args:
@@ -194,7 +194,7 @@
         for log_prefix in ('access.log-', 'error.log-'):
             try:
                 self._remove_log_files(self._output_dir, log_prefix)
-            except OSError as e:
+            except OSError:
                 _log.warning('Failed to remove old %s %s files' % (self._name, log_prefix))
 
     def _spawn_process(self):

Modified: trunk/Tools/Scripts/webkitpy/layout_tests/views/buildbot_results.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/layout_tests/views/buildbot_results.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/views/buildbot_results.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -147,7 +147,6 @@
                     result = resultsjsonparser.result_for_test(summarized_results['tests'], test)
                     actual = result['actual'].split(" ")
                     expected = result['expected'].split(" ")
-                    result = TestExpectations.EXPECTATIONS[key.lower()]
                     # FIXME: clean this up once the old syntax is gone
                     new_expectations_list = [TestExpectationParser._inverted_expectation_tokens[exp] for exp in list(set(actual) | set(expected))]
                     self._print("  %s [ %s ]" % (test, " ".join(new_expectations_list)))

Modified: trunk/Tools/Scripts/webkitpy/layout_tests/views/metered_stream.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/layout_tests/views/metered_stream.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/views/metered_stream.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -124,7 +124,6 @@
         self.write(self._ensure_newline(txt), now, pid)
 
     def _erase_last_partial_line(self):
-        num_chars = len(self._last_partial_line)
         self._stream.write(self._erasure(self._last_partial_line))
         self._last_partial_line = ''
         self._stream.flush()

Modified: trunk/Tools/Scripts/webkitpy/performance_tests/perftest.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/performance_tests/perftest.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/performance_tests/perftest.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -185,7 +185,6 @@
         if self.run_failed(output):
             return False
 
-        current_metric = None
         for line in re.split('\n', output.text):
             description_match = self._description_regex.match(line)
             if description_match:

Modified: trunk/Tools/Scripts/webkitpy/port/device_port.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/port/device_port.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/port/device_port.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -250,7 +250,6 @@
             model += u' {}'.format(device_type.hardware_type)
 
         version = self.device_version()
-        version_name = None
         for table in [INTERNAL_TABLE, PUBLIC_TABLE]:
             version_name = VersionNameMap.map(self.host.platform).to_name(version, platform=device_type.software_variant.lower(), table=table)
             if version_name:

Modified: trunk/Tools/Scripts/webkitpy/port/factory.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/port/factory.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/port/factory.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -127,7 +127,7 @@
     def __init__(self, host):
         self._host = host
 
-    def _default_port(self, options):
+    def _default_port(self):
         platform = self._host.platform
         if platform.is_linux() or platform.is_freebsd():
             return 'gtk'
@@ -141,7 +141,7 @@
         """Returns an object implementing the Port interface. If
         port_name is None, this routine attempts to guess at the most
         appropriate port on this platform."""
-        port_name = port_name or self._default_port(options)
+        port_name = port_name or self._default_port()
 
         classes = []
         for port_class in self.PORT_CLASSES:

Modified: trunk/Tools/Scripts/webkitpy/port/leakdetector_valgrind.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/port/leakdetector_valgrind.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/port/leakdetector_valgrind.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -109,8 +109,6 @@
                 frames = gather_frames(stack, source_dir)
                 self._backtraces.append([description, frames])
                 description = None
-                stack = None
-                frames = None
             elif description and node.localName != None:
                 # The lastest description has no stack, e.g. "Address 0x28 is unknown".
                 self._additional.append(description)
@@ -222,7 +220,6 @@
         try:
             parsed_string = parseString(leaks_output)
         except ExpatError as e:
-            parse_failed = True
             _log.error("could not parse %s: %s" % (string_utils.decode(leaks_output, target_type=str), e))
             return
 

Modified: trunk/Tools/Scripts/webkitpy/port/server_process.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/port/server_process.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/port/server_process.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -186,7 +186,7 @@
         try:
             self._proc.stdin.write(string_utils.encode(bytes))
             self._proc.stdin.flush()
-        except (IOError, ValueError) as e:
+        except (IOError, ValueError):
             self.stop(0.0)
             # stop() calls _reset(), so we have to set crashed to True after calling stop()
             # unless we already know that this is a timeout.
@@ -314,7 +314,7 @@
                     _log.debug('{} because of no data while reading stdout for the server process.'.format(self._crash_message))
                     self._crashed = True
                 self._error += data
-        except IOError as e:
+        except IOError:
             # We can ignore the IOErrors because we will detect if the subporcess crashed
             # the next time through the loop in _read()
             pass

Modified: trunk/Tools/Scripts/webkitpy/style/checkers/js.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/style/checkers/js.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/style/checkers/js.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -58,7 +58,6 @@
         self._handle_style_error = handle_style_error
 
     def check(self, lines):
-        in_multiline_comment = False
         line_number = 0
         for line in lines:
             line = line.strip()
@@ -65,11 +64,9 @@
             line_number = line_number + 1
 
             if (line.endswith("*/")):
-                in_multiline_comment = False
                 continue
 
             if (line.startswith("/*") or line.startswith("*")):
-                in_multiline_comment = True
                 continue
 
             # Remove "double quoted" strings.

Modified: trunk/Tools/Scripts/webkitpy/tool/bot/layouttestresultsreader.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/tool/bot/layouttestresultsreader.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/tool/bot/layouttestresultsreader.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -49,7 +49,7 @@
     def _read_file_contents(self, path):
         try:
             return self._host.filesystem.read_text_file(path)
-        except IOError as e:  # File does not exist or can't be read.
+        except IOError:  # File does not exist or can't be read.
             return None
 
     # FIXME: This logic should move to the port object.

Modified: trunk/Tools/Scripts/webkitpy/tool/bot/patchanalysistask.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/tool/bot/patchanalysistask.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/tool/bot/patchanalysistask.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -242,7 +242,6 @@
         if self._test():
             return True
         second_results = self._delegate.test_results()
-        second_script_error = self._script_error
         if second_results is None:
             return False
 

Modified: trunk/Tools/Scripts/webkitpy/tool/bot/queueengine.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/tool/bot/queueengine.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/tool/bot/queueengine.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -112,13 +112,13 @@
                         continue
                     message = "Unexpected failure when processing patch!  Please file a bug against webkit-patch.\n%s" % e.message_with_output(output_limit=5000)
                     self._delegate.handle_unexpected_error(work_item, message)
-            except TerminateQueue as e:
+            except TerminateQueue:
                 self._stopping("TerminateQueue exception received.")
                 return 0
-            except KeyboardInterrupt as e:
+            except KeyboardInterrupt:
                 self._stopping("User terminated queue.")
                 return 1
-            except Exception as e:
+            except Exception:
                 traceback.print_exc()
                 # Don't try tell the status bot, in case telling it causes an exception.
                 self._sleep("Exception while preparing queue")

Modified: trunk/Tools/Scripts/webkitpy/tool/commands/download.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/tool/commands/download.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/tool/commands/download.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -192,7 +192,6 @@
     main_steps = None
 
     def __init__(self):
-        options = []
         self._prepare_sequence = StepSequence(self.prepare_steps)
         self._main_sequence = StepSequence(self.main_steps)
         options = sorted(set(self._prepare_sequence.options() + self._main_sequence.options()), key=lambda option: option.dest)

Modified: trunk/Tools/Scripts/webkitpy/tool/commands/earlywarningsystem.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/tool/commands/earlywarningsystem.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/tool/commands/earlywarningsystem.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -95,11 +95,11 @@
         try:
             succeeded = task.run()
             return succeeded
-        except PatchIsNotValid as error:
+        except PatchIsNotValid:
             return False
-        except UnableToApplyPatch as e:
+        except UnableToApplyPatch:
             return False
-        except PatchIsNotApplicable as e:
+        except PatchIsNotApplicable:
             return False
         except ScriptError as e:
             self._post_reject_message_on_bug(self._tool, patch, task.failure_status_id, self._failing_tests_message(task, patch))

Modified: trunk/Tools/Scripts/webkitpy/tool/commands/queues.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/tool/commands/queues.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/tool/commands/queues.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -62,7 +62,7 @@
     def _cc_watchers(self, bug_id):
         try:
             self._tool.bugs.add_cc_to_bug(bug_id, self.watchers)
-        except Exception as e:
+        except Exception:
             traceback.print_exc()
             _log.error("Failed to CC watchers.")
 

Modified: trunk/Tools/Scripts/webkitpy/tool/commands/suggestnominations.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/tool/commands/suggestnominations.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/tool/commands/suggestnominations.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -213,7 +213,7 @@
         for commit_message in self._recent_commit_messages():
             try:
                 self._count_commit(self._parse_commit_message(commit_message), analysis)
-            except CommitLogError as exception:
+            except CommitLogError:
                 continue
         return analysis['counters_by_email']
 
@@ -263,7 +263,6 @@
         for author_email, counter in counters:
             if author_email != counter['latest_email']:
                 continue
-            contributor = self._committer_list.contributor_by_email(author_email)
             author_name = counter['latest_name']
             patch_count = counter['count']
             counter['names'] = counter['names'] - set([author_name])

Modified: trunk/Tools/Scripts/webkitpy/tool/commands/upload.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/tool/commands/upload.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/tool/commands/upload.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -81,7 +81,6 @@
         return join_with_separators(what_was_cleared)
 
     def execute(self, options, args, tool):
-        committers = CommitterList()
         for bug_id in tool.bugs.queries.fetch_bug_ids_from_pending_commit_list():
             bug = self._tool.bugs.fetch_bug(bug_id)
             patches = bug.patches(include_obsolete=True)
@@ -477,8 +476,6 @@
 
         commit_id = commit_ids[0]
 
-        bug_title = ""
-        comment_text = ""
         if options.prompt:
             (bug_title, comment_text) = self.prompt_for_bug_title_and_comment()
         else:
@@ -498,8 +495,6 @@
             PostCommits.execute(self, options, commit_ids[1:], tool)
 
     def create_bug_from_patch(self, options, args, tool):
-        bug_title = ""
-        comment_text = ""
         if options.prompt:
             (bug_title, comment_text) = self.prompt_for_bug_title_and_comment()
         else:
@@ -508,7 +503,7 @@
             comment_text = commit_message.body(lstrip=True)
 
         diff = tool.scm().create_patch(options.git_commit)
-        bug_id = tool.bugs.create_bug(bug_title, comment_text, options.component, diff, "Patch", cc=options.cc, mark_for_review=options.review, mark_for_commit_queue=options.request_commit)
+        tool.bugs.create_bug(bug_title, comment_text, options.component, diff, "Patch", cc=options.cc, mark_for_review=options.review, mark_for_commit_queue=options.request_commit)
 
     def prompt_for_bug_title_and_comment(self):
         bug_title = User.prompt("Bug title: ")

Modified: trunk/Tools/Scripts/webkitpy/tool/multicommandtool.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/tool/multicommandtool.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/tool/multicommandtool.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -304,7 +304,7 @@
             try:
                 result = command.check_arguments_and_execute(options, args, self)
                 break
-            except TryAgain as e:
+            except TryAgain:
                 pass
 
         self.command_completed()

Modified: trunk/Tools/Scripts/webkitpy/tool/servers/rebaselineserver.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/tool/servers/rebaselineserver.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/tool/servers/rebaselineserver.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -71,7 +71,6 @@
     filesystem = test_config.filesystem
     scm = test_config.scm
     layout_tests_directory = test_config.layout_tests_directory
-    results_directory = test_config.results_directory
     target_expectations_directory = filesystem.join(
         layout_tests_directory, 'platform', baseline_target, test_directory)
     test_results_directory = test_config.filesystem.join(
@@ -179,8 +178,6 @@
         def platform_from_directory(self, directory):
             return self._platforms_by_directory[directory]
 
-    test_path = test_config.filesystem.join(test_config.layout_tests_directory, test_file)
-
     host = test_config.host
     host.initialize_scm()
     all_platforms_port = AllPlatformsPort(host)

Modified: trunk/Tools/Scripts/webkitpy/tool/steps/commit.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/tool/steps/commit.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/tool/steps/commit.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -61,7 +61,7 @@
         args.extend(test_expectations_files)
         try:
             self._tool.executive.run_and_throw_if_fail(self._tool.deprecated_port().check_webkit_style_command() + args, cwd=self._tool.scm().checkout_root)
-        except ScriptError as e:
+        except ScriptError:
             if self._options.non_interactive:
                 raise
             if not self._tool.user.confirm("Are you sure you want to continue?", default="n"):

Modified: trunk/Tools/Scripts/webkitpy/tool/steps/confirmdiff.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/tool/steps/confirmdiff.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/tool/steps/confirmdiff.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -62,9 +62,9 @@
             # We return the pretty_diff_file here because we need to keep the
             # file alive until the user has had a chance to confirm the diff.
             return pretty_diff_file
-        except ScriptError as e:
+        except ScriptError:
             _log.warning("PrettyPatch failed.  :(")
-        except OSError as e:
+        except OSError:
             _log.warning("PrettyPatch unavailable.")
 
     def run(self, state):

Modified: trunk/Tools/Scripts/webkitpy/tool/steps/haslanded.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/tool/steps/haslanded.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/tool/steps/haslanded.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -81,7 +81,7 @@
         try:
             return executive.run_command(
                 ["interdiff", diff1_patch.name, diff2_patch.name], decode_output=False)
-        except ScriptError as e:
+        except ScriptError:
             _log.warning("Unable to find interdiff util (part of GNU difftools package) which is required.")
             raise
 

Modified: trunk/Tools/Scripts/webkitpy/tool/steps/preparechangelog.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/tool/steps/preparechangelog.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/tool/steps/preparechangelog.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -125,7 +125,7 @@
 
         try:
             output = self._tool.executive.run_and_throw_if_fail(args, self._options.quiet, cwd=self._tool.scm().checkout_root)
-        except ScriptError as e:
+        except ScriptError:
             _log.error("Unable to prepare ChangeLogs.")
             sys.exit(1)
 

Modified: trunk/Tools/Scripts/webkitpy/tool/steps/promptforbugortitle.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/tool/steps/promptforbugortitle.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/tool/steps/promptforbugortitle.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -54,7 +54,7 @@
         # Otherwise we assume it's a bug subject.
         try:
             state["bug_id"] = int(user_response)
-        except ValueError as TypeError:
+        except ValueError:
             parsed_url = None
             try:
                 parsed_url = urlparse(user_response)

Modified: trunk/Tools/Scripts/webkitpy/tool/steps/sortxcodeprojectfiles.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/tool/steps/sortxcodeprojectfiles.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/tool/steps/sortxcodeprojectfiles.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -53,6 +53,6 @@
                 try:
                     output = self._tool.executive.run_and_throw_if_fail(args, self._options.quiet, cwd=self._tool.scm().checkout_root)
                     self.did_modify_checkout(state)
-                except ScriptError as e:
+                except ScriptError:
                     _log.error("Unable to sort modified xcode projects.")
                     sys.exit(1)

Modified: trunk/Tools/Scripts/webkitpy/tool/steps/suggestreviewers_unittest.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/tool/steps/suggestreviewers_unittest.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/tool/steps/suggestreviewers_unittest.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -45,7 +45,6 @@
         self.assertEqual(captured.root.log.getvalue(), '')
 
     def test_basic(self):
-        capture = OutputCapture()
         step = SuggestReviewers(MockTool(), MockOptions(suggest_reviewers=True, git_commit=None))
         with OutputCapture(level=logging.INFO) as captured:
             step.run(dict(bug_id='123'))

Modified: trunk/Tools/Scripts/webkitpy/w3c/test_exporter.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/w3c/test_exporter.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/w3c/test_exporter.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -239,7 +239,7 @@
         headers = {'Accept': 'application/vnd.github.v3+json', 'Authorization': 'token {}'.format(token)}
         try:
             response = self._host.web.request(method='GET', url="" data="" headers=headers)
-        except HTTPError as e:
+        except HTTPError:
             raise Exception("OAuth token is not valid")
         data = ""
         login = data.get('login', None)
@@ -254,7 +254,6 @@
                 self._git.set_local_config('github.username', username)
 
     def _ensure_wpt_repository(self, url, wpt_repository_directory, gitClass):
-        git = None
         if not self._filesystem.exists(wpt_repository_directory):
             _log.info('Cloning %s into %s...' % (url, wpt_repository_directory))
             gitClass.clone(url, wpt_repository_directory, self._host.executive)

Modified: trunk/Tools/Scripts/webkitpy/xcode/simulated_device.py (271157 => 271158)


--- trunk/Tools/Scripts/webkitpy/xcode/simulated_device.py	2021-01-05 18:18:50 UTC (rev 271157)
+++ trunk/Tools/Scripts/webkitpy/xcode/simulated_device.py	2021-01-05 18:33:43 UTC (rev 271158)
@@ -637,8 +637,6 @@
         def _log_debug_error(error):
             _log.debug(error.message_with_output())
 
-        output = None
-
         with Timeout(timeout, handler=RuntimeError(u'Timed out waiting for process to open {} on {}'.format(bundle_id, self.udid)), patch=False):
             while True:
                 output = self.executive.run_command(
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to