]> git.apps.os.sepia.ceph.com Git - teuthology.git/commitdiff
orch/run: set mutable default arguments as None
authorVallari Agrawal <val.agl002@gmail.com>
Mon, 20 Jun 2022 18:33:11 +0000 (00:03 +0530)
committerVallari Agrawal <val.agl002@gmail.com>
Thu, 29 Sep 2022 16:30:31 +0000 (22:00 +0530)
Signed-off-by: Vallari Agrawal <val.agl002@gmail.com>
teuthology/orchestra/run.py

index 0c661c7b8aab48f19d9ed15b610b8fafa83cdcc1..a697306246ada01a01a540cd904f5f39b65e72fe 100644 (file)
@@ -40,7 +40,7 @@ class RemoteProcess(object):
     deadlock_warning = "Using PIPE for %s without wait=False would deadlock"
 
     def __init__(self, client, args, check_status=True, hostname=None,
-                 label=None, timeout=None, wait=True, logger=None, cwd=None, scan_tests_errors=[]):
+                 label=None, timeout=None, wait=True, logger=None, cwd=None, scan_tests_errors=None):
         """
         Create the object. Does not initiate command execution.
 
@@ -265,7 +265,7 @@ class ErrorScanner(object):
                 return True
         return False
 
-    def scan(self, test_names=[]):
+    def scan(self, test_names=None):
         logfile = self.__logfile__
         if not logfile or not test_names:
             return None, None
@@ -473,7 +473,7 @@ def run(
     quiet=False,
     timeout=None,
     cwd=None,
-    scan_tests_errors=[],
+    scan_tests_errors=None,
     # omit_sudo is used by vstart_runner.py
     omit_sudo=False
 ):