Changeset 53126 in webkit


Ignore:
Timestamp:
Jan 12, 2010 2:17:31 AM (14 years ago)
Author:
abarth@webkit.org
Message:

2010-01-12 Adam Barth <abarth@webkit.org>

Reviewed by Eric Seidel.

EWS should show purple when svn-apply fails
https://bugs.webkit.org/show_bug.cgi?id=33527

  • Scripts/webkitpy/commands/early_warning_system.py:
  • Scripts/webkitpy/commands/queues.py:
Location:
trunk/WebKitTools
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebKitTools/ChangeLog

    r53123 r53126  
     12010-01-12  Adam Barth  <abarth@webkit.org>
     2
     3        Reviewed by Eric Seidel.
     4
     5        EWS should show purple when svn-apply fails
     6        https://bugs.webkit.org/show_bug.cgi?id=33527
     7
     8        * Scripts/webkitpy/commands/early_warning_system.py:
     9        * Scripts/webkitpy/commands/queues.py:
     10
    1112010-01-12  Adam Barth  <abarth@webkit.org>
    212
  • trunk/WebKitTools/Scripts/webkitpy/commands/early_warning_system.py

    r53123 r53126  
    3434from webkitpy.executive import ScriptError
    3535from webkitpy.webkitport import WebKitPort
     36from webkitpy.queueengine import QueueEngine
    3637
    3738
     
    6364    @classmethod
    6465    def handle_script_error(cls, tool, state, script_error):
    65         status_id = cls._update_status_for_script_error(tool, state, script_error)
    66         # FIXME: This won't be right for ports that don't use build-webkit!
    67         if not script_error.command_name() == "build-webkit":
    68             return
     66        is_svn_apply = script_error.command_name() == "svn-apply"
     67        status_id = cls._update_status_for_script_error(tool, state, script_error, is_error=is_svn_apply)
     68        if is_svn_apply:
     69            QueueEngine.exit_after_handled_error(e)
    6970        results_link = tool.status_server.results_url_for_status(status_id)
    7071        message = "Attachment %s did not build on %s:\nBuild output: %s" % (state["patch"]["id"], cls.port_name, results_link)
    7172        tool.bugs.post_comment_to_bug(state["patch"]["bug_id"], message, cc=cls.watchers)
     73        exit(1)
    7274
    7375
  • trunk/WebKitTools/Scripts/webkitpy/commands/queues.py

    r53123 r53126  
    125125
    126126    @classmethod
    127     def _update_status_for_script_error(cls, tool, state, script_error):
    128         return tool.status_server.update_status(cls.name, script_error.message, state["patch"], StringIO(script_error.output))
     127    def _update_status_for_script_error(cls, tool, state, script_error, is_error=False):
     128        message = script_error.output
     129        if is_error:
     130            message = "Error: %s" % message
     131        return tool.status_server.update_status(cls.name, script_error.message, state["patch"], StringIO(message))
    129132
    130133
     
    242245            self._did_pass(patch)
    243246        except ScriptError, e:
    244             self._did_fail(patch)
     247            if e.exit_code != QueueEngine.handled_error_code:
     248                self._did_fail(patch)
    245249            raise e
    246250
     
    269273    @classmethod
    270274    def handle_script_error(cls, tool, state, script_error):
    271         status_id = cls._update_status_for_script_error(tool, state, script_error)
    272         if not script_error.command_name() == "check-webkit-style":
    273             return
     275        is_svn_apply = script_error.command_name() == "svn-apply"
     276        status_id = cls._update_status_for_script_error(tool, state, script_error, is_error=is_svn_apply)
     277        if is_svn_apply:
     278            QueueEngine.exit_after_handled_error(e)
    274279        message = "Attachment %s did not pass %s:\n\n%s" % (state["patch"]["id"], cls.name, script_error.message_with_output(output_limit=3*1024))
    275280        tool.bugs.post_comment_to_bug(state["patch"]["bug_id"], message, cc=cls.watchers)
     281        exit(1)
Note: See TracChangeset for help on using the changeset viewer.