Bug 52284 - Split Host object off from WebKitPatch for easier re-use
Summary: Split Host object off from WebKitPatch for easier re-use
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Other OS X 10.5
: P2 Normal
Assignee: Eric Seidel (no email)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-01-12 02:46 PST by Eric Seidel (no email)
Modified: 2011-01-21 03:24 PST (History)
5 users (show)

See Also:


Attachments
Patch (7.90 KB, patch)
2011-01-12 02:47 PST, Eric Seidel (no email)
no flags Details | Formatted Diff | Diff
Patch for landing (7.92 KB, patch)
2011-01-21 01:37 PST, Eric Seidel (no email)
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Eric Seidel (no email) 2011-01-12 02:46:51 PST
Split Host object off from WebKitPatch for easier re-use
Comment 1 Eric Seidel (no email) 2011-01-12 02:47:47 PST
Created attachment 78669 [details]
Patch
Comment 2 Eric Seidel (no email) 2011-01-12 02:49:19 PST
Should be trivial to write additional scripts which use webkitpy (including steps and command objects) w/o being webkit-patch now.
Comment 3 Adam Barth 2011-01-12 02:57:05 PST
Comment on attachment 78669 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=78669&action=review

We should probably rename all the tool variables / properties to host.

> Tools/Scripts/webkitpy/common/host.py:30
> +# Command objects expect to have a self.tool which provides these interfaces.

Command objects aren't a concept that make sense in common.  I'd just remove this comment.

> Tools/Scripts/webkitpy/common/host.py:44
> +        self.bugs = bugzilla.Bugzilla()
> +        self.buildbot = buildbot.BuildBot()
> +        self.executive = executive.Executive()

Why don't we just import these names directly instead of using this goofy syntax?

> Tools/Scripts/webkitpy/common/host.py:81
> +    def command_completed(self):
> +        if self._irc:
> +            self._irc.disconnect()

This probably needs a more semantic name like disconnect_from_irc

> Tools/Scripts/webkitpy/tool/main.py:36
> +from webkitpy.common.host import Host

Shouldn't this be alphabetized like everything else?
Comment 4 Eric Seidel (no email) 2011-01-21 01:37:00 PST
Created attachment 79709 [details]
Patch for landing
Comment 5 WebKit Commit Bot 2011-01-21 03:23:56 PST
Comment on attachment 79709 [details]
Patch for landing

Clearing flags on attachment: 79709

Committed r76339: <http://trac.webkit.org/changeset/76339>
Comment 6 WebKit Commit Bot 2011-01-21 03:24:01 PST
All reviewed patches have been landed.  Closing bug.