2010-08-19 Ojan Vafai <ojan@chromium.org>
authorojan@chromium.org <ojan@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 19 Aug 2010 20:04:22 +0000 (20:04 +0000)
committerojan@chromium.org <ojan@chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 19 Aug 2010 20:04:22 +0000 (20:04 +0000)
        Reviewed by Adam Barth.

        add --webkit_patch_id to reitveld uploads
        https://bugs.webkit.org/show_bug.cgi?id=44289

        This is the first step in having rietveld store which
        patches have been uploaded and getting rid of the
        in-rietveld flag.

        * Scripts/webkitpy/common/net/rietveld.py:
        * Scripts/webkitpy/tool/mocktool.py:
        * Scripts/webkitpy/tool/steps/postcodereview.py:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@65694 268f45cc-cd09-0410-ab3c-d52691b4dbfc

WebKitTools/ChangeLog
WebKitTools/Scripts/webkitpy/common/net/rietveld.py
WebKitTools/Scripts/webkitpy/tool/mocktool.py
WebKitTools/Scripts/webkitpy/tool/steps/postcodereview.py

index 8e7beacfa1c6c321801fc197c0cc0d37f88fe7f4..3f0c266b1c90c567a581d894b218976a96bf3ea6 100644 (file)
@@ -1,3 +1,18 @@
+2010-08-19  Ojan Vafai  <ojan@chromium.org>
+
+        Reviewed by Adam Barth.
+
+        add --webkit_patch_id to reitveld uploads
+        https://bugs.webkit.org/show_bug.cgi?id=44289
+
+        This is the first step in having rietveld store which
+        patches have been uploaded and getting rid of the
+        in-rietveld flag.
+
+        * Scripts/webkitpy/common/net/rietveld.py:
+        * Scripts/webkitpy/tool/mocktool.py:
+        * Scripts/webkitpy/tool/steps/postcodereview.py:
+
 2010-08-19  Kenneth Russell  <kbr@google.com>
 
         Reviewed by David Levin.
index 0c6a31347892b645169fb2cd1a826cd6595ff563..b9a08213872726139ee5bc69ba036186727e20aa 100644 (file)
@@ -47,7 +47,7 @@ class Rietveld(object):
             return None
         return "%s%s" % (config.codereview_server_url, codereview_issue)
 
-    def post(self, diff, message=None, codereview_issue=None, cc=None):
+    def post(self, diff, patch_id, codereview_issue, message=None, cc=None):
         if not message:
             raise ScriptError("Rietveld requires a message.")
 
@@ -61,6 +61,7 @@ class Rietveld(object):
             "--assume_yes",
             "--server=%s" % config.codereview_server_host,
             "--message=%s" % message,
+            "--webkit_patch_id=%s" % patch_id,
         ]
         if codereview_issue:
             args.append("--issue=%s" % codereview_issue)
index 2114c305816f4eaff32055d955f8225d4bb0e8bd..61b5d6684759ef89210a6b79bde29f7098ece98d 100644 (file)
@@ -551,7 +551,7 @@ class MockRietveld():
     def __init__(self, executive, dryrun=False):
         pass
 
-    def post(self, diff, message=None, codereview_issue=None, cc=None):
+    def post(self, diff, patch_id, codereview_issue, message=None, cc=None):
         log("MOCK: Uploading patch to rietveld")
 
 
index f9bc6856b891cb4816706d60a8a9839c90b7d971..d2f79f38bf828a903bedbc3f6cdcf85e4b640b41 100644 (file)
@@ -64,6 +64,7 @@ class PostCodeReview(AbstractStep):
         created_issue = self._tool.codereview.post(diff=self.cached_lookup(state, "diff"),
                                                    message=message,
                                                    codereview_issue=bug_id,
-                                                   cc=self._options.cc)
+                                                   cc=self._options.cc,
+                                                   patch_id=patch.id())
 
         self._tool.bugs.set_flag_on_attachment(patch.id(), 'in-rietveld', '+')