Bug 66245

Summary: garden-o-matic frontend needs a generic way to track updates.
Product: WebKit Reporter: Dimitri Glazkov (Google) <dglazkov>
Component: Tools / TestsAssignee: Dimitri Glazkov (Google) <dglazkov>
Status: RESOLVED FIXED    
Severity: Normal CC: abarth
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 66144    
Attachments:
Description Flags
Patch abarth: review+

Dimitri Glazkov (Google)
Reported 2011-08-15 12:20:16 PDT
garden-o-matic frontend needs a generic way to track updates.
Attachments
Patch (5.40 KB, patch)
2011-08-15 12:22 PDT, Dimitri Glazkov (Google)
abarth: review+
Dimitri Glazkov (Google)
Comment 1 2011-08-15 12:22:57 PDT
Dimitri Glazkov (Google)
Comment 2 2011-08-15 12:23:23 PDT
Adam Barth
Comment 3 2011-08-15 13:24:49 PDT
Comment on attachment 103941 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=103941&action=review > Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/base.js:271 > + thisObject = thisObject || {}; You and MarkM have been talking! > Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/base.js:274 > + callback.call(thisObject || item, item, key, !!this._updated[key]); How can thisObject be falsy here? It was falsy, it would be replaced with {} above. > Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/base.js:278 > + removeCallback = removeCallback || function() {} Missing ; > Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/base.js:280 > + if (!updated) { I'd use early return. > Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/base.js:281 > + removeCallback.call(thisObject || item, item); I'd make this match forEach, whichever way you decided to make forEach work. > Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/base_unittests.js:279 > + dict.purge(function() { > + removeCount++; > + }); I'd add one test with purge that uses the thisObject parameter.
Dimitri Glazkov (Google)
Comment 4 2011-08-15 14:27:46 PDT
Comment on attachment 103941 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=103941&action=review >> Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/base.js:274 >> + callback.call(thisObject || item, item, key, !!this._updated[key]); > > How can thisObject be falsy here? It was falsy, it would be replaced with {} above. Oops. I didn't mean to leave the one at the top. >> Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/base.js:278 >> + removeCallback = removeCallback || function() {} > > Missing ; I blame Python. >> Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/base.js:280 >> + if (!updated) { > > I'd use early return. Sounds good, will change. >> Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/base.js:281 >> + removeCallback.call(thisObject || item, item); > > I'd make this match forEach, whichever way you decided to make forEach work. ok. >> Tools/BuildSlaveSupport/build.webkit.org-config/public_html/TestFailures/base_unittests.js:279 >> + }); > > I'd add one test with purge that uses the thisObject parameter. Will do.
Dimitri Glazkov (Google)
Comment 5 2011-08-15 14:31:49 PDT
Note You need to log in before you can comment on or make changes to this bug.