RESOLVED FIXED 134698
Web Inspector: SearchResultTreeElement.representedObject is missing a saveIdentityToCookie implementation
https://bugs.webkit.org/show_bug.cgi?id=134698
Summary Web Inspector: SearchResultTreeElement.representedObject is missing a saveIde...
Joseph Pecoraro
Reported 2014-07-07 15:30:52 PDT
Represented object types: console.assert(representedObject instanceof WebInspector.DOMSearchMatchObject || representedObject instanceof WebInspector.ResourceSearchMatchObject); Seems like we should avoid having a saved cookie for search results.
Attachments
[PATCH] Proposed Fix (4.98 KB, patch)
2015-03-10 22:21 PDT, Joseph Pecoraro
no flags
Joseph Pecoraro
Comment 1 2014-07-07 15:31:43 PDT
Full console log was: [Error] Error: TreeElement.representedObject is missing a saveIdentityToCookie implementation. TreeElement.constructor: function (representedObject) { console.assert(representedObject instanceof WebInspector.DOMSearchMatchObject || representedObject instanceof WebInspector.ResourceSearchMatchObject); var title = WebInspector.SearchResultTreeElement.truncateAndHighlightTitle(representedObject.title, representedObject.searchTerm, representedObject.sourceCodeTextRange); WebInspector.GeneralTreeElement.call(this, representedObject.className, title, null, representedObject, false); this.small = true; } Meaning it was WebInspector.SearchResultTreeElement represented object types listed in the above comment.
Radar WebKit Bug Importer
Comment 2 2014-07-07 15:31:52 PDT
Radar WebKit Bug Importer
Comment 3 2014-07-07 15:32:02 PDT
Joseph Pecoraro
Comment 4 2014-07-07 15:51:57 PDT
Test comment.
Joseph Pecoraro
Comment 5 2015-03-10 21:51:42 PDT
* STEPS TO REPRODUCE 1. Inspect <http://bogojoker.com> 2. Shift+Cmd+F for global search "div" 3. Select any result (text result or DOM result) 5. Cmd+R Reload => error and sidebar is empty, it hasn't re-triggered the search or cleared the search
Joseph Pecoraro
Comment 6 2015-03-10 21:56:35 PDT
Also, the backtrace is: [Error] Error: TreeElement.representedObject is missing a saveIdentityToCookie implementation.... saveStateToCookie (Main.js, line 4379) _updateCookieForInspectorViewState (Main.js, line 10938) _provisionalLoadStarted (Main.js, line 10853) dispatch (Main.js, line 67) dispatchEventToListeners (Main.js, line 69) startProvisionalLoad (Main.js, line 1947) _addResourceToFrame (Main.js, line 10293) _addNewResourceToFrame (Main.js, line 10288) resourceRequestWillBeSent (Main.js, line 10248) requestWillBeSent (Main.js, line 716) dispatchEvent (Main.js, line 605) _dispatchEvent (Main.js, line 583) dispatch (Main.js, line 556) dispatchNextQueuedMessageFromBackend (Main.js, line 707)
Joseph Pecoraro
Comment 7 2015-03-10 22:19:30 PDT
(In reply to comment #5) > * STEPS TO REPRODUCE > 1. Inspect <http://bogojoker.com> > 2. Shift+Cmd+F for global search "div" > 3. Select any result (text result or DOM result) > 4. Cmd+R Reload > => error and sidebar is empty, it hasn't re-triggered the search or Better steps here for testing is to replace step 4: 4. Close Inspector 5. Open Inspector => ensure same search tree item is selected. Now, we still should fix the scenario above for search term, but that can be handled separately. I have a fix for saveIdentityToCookie here, testable with these steps.
Joseph Pecoraro
Comment 8 2015-03-10 22:21:15 PDT
Created attachment 248399 [details] [PATCH] Proposed Fix
WebKit Commit Bot
Comment 9 2015-03-11 07:09:59 PDT
Comment on attachment 248399 [details] [PATCH] Proposed Fix Clearing flags on attachment: 248399 Committed r181386: <http://trac.webkit.org/changeset/181386>
WebKit Commit Bot
Comment 10 2015-03-11 07:10:05 PDT
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.