Title: [140528] trunk/Tools
Revision
140528
Author
[email protected]
Date
2013-01-23 02:06:57 -0800 (Wed, 23 Jan 2013)

Log Message

Removing command line shortening as it makes it difficult to see the command during errors.
https://bugs.webkit.org/show_bug.cgi?id=107643

Patch by Tim 'mithro' Ansell <[email protected]> on 2013-01-23
Reviewed by Eric Seidel.

* Scripts/webkitpy/common/system/executive.py:
(ScriptError):
(ScriptError.__init__):
* Scripts/webkitpy/common/system/executive_unittest.py:

Modified Paths

Diff

Modified: trunk/Tools/ChangeLog (140527 => 140528)


--- trunk/Tools/ChangeLog	2013-01-23 10:03:22 UTC (rev 140527)
+++ trunk/Tools/ChangeLog	2013-01-23 10:06:57 UTC (rev 140528)
@@ -1,5 +1,17 @@
 2013-01-23  Tim 'mithro' Ansell  <[email protected]>
 
+        Removing command line shortening as it makes it difficult to see the command during errors.
+        https://bugs.webkit.org/show_bug.cgi?id=107643
+
+        Reviewed by Eric Seidel.
+
+        * Scripts/webkitpy/common/system/executive.py:
+        (ScriptError):
+        (ScriptError.__init__):
+        * Scripts/webkitpy/common/system/executive_unittest.py:
+
+2013-01-23  Tim 'mithro' Ansell  <[email protected]>
+
         Adding myself as contributor in committers.py (as requested by eseidel).
         https://bugs.webkit.org/show_bug.cgi?id=107647
 

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


--- trunk/Tools/Scripts/webkitpy/common/system/executive.py	2013-01-23 10:03:22 UTC (rev 140527)
+++ trunk/Tools/Scripts/webkitpy/common/system/executive.py	2013-01-23 10:06:57 UTC (rev 140528)
@@ -46,14 +46,6 @@
 
 class ScriptError(Exception):
 
-    # This is a custom List.__str__ implementation to allow size limiting.
-    def _string_from_args(self, args, limit=100):
-        args_string = unicode(args)
-        # We could make this much fancier, but for now this is OK.
-        if len(args_string) > limit:
-            return args_string[:limit - 3] + "..."
-        return args_string
-
     def __init__(self,
                  message=None,
                  script_args=None,
@@ -61,7 +53,7 @@
                  output=None,
                  cwd=None):
         if not message:
-            message = 'Failed to run "%s"' % self._string_from_args(script_args)
+            message = 'Failed to run "%s"' % script_args
             if exit_code:
                 message += " exit_code: %d" % exit_code
             if cwd:

Modified: trunk/Tools/Scripts/webkitpy/common/system/executive_unittest.py (140527 => 140528)


--- trunk/Tools/Scripts/webkitpy/common/system/executive_unittest.py	2013-01-23 10:03:22 UTC (rev 140527)
+++ trunk/Tools/Scripts/webkitpy/common/system/executive_unittest.py	2013-01-23 10:06:57 UTC (rev 140528)
@@ -50,12 +50,6 @@
 
 
 class ScriptErrorTest(unittest.TestCase):
-    def test_string_from_args(self):
-        error = ScriptError()
-        self.assertEqual(error._string_from_args(None), 'None')
-        self.assertEqual(error._string_from_args([]), '[]')
-        self.assertEqual(error._string_from_args(map(str, range(30))), "['0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12', '13', '14', '15', '16', '17'...")
-
     def test_message_with_output(self):
         error = ScriptError('My custom message!', '', -1)
         self.assertEqual(error.message_with_output(), 'My custom message!')
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to