Closed Bug 897104 Opened 7 years ago Closed 6 years ago

"TypeError: gControllerSources.getCache is not a function: testStateBeforeReload@chrome://mochitests/content/browser/browser/devtools/debugger/test/browser_dbg_sources-cache.js:117" on green debug test runs

Categories

(DevTools :: Debugger, defect)

x86_64
macOS
defect
Not set

Tracking

(firefox24 unaffected, firefox25 fixed)

RESOLVED FIXED
Firefox 25
Tracking Status
firefox24 --- unaffected
firefox25 --- fixed

People

(Reporter: emorley, Assigned: RyanVM)

References

(Blocks 1 open bug)

Details

(Whiteboard: [qa-])

Attachments

(1 file)

A soon to be deployed TBPL parser improvement has found a whole bunch of log spam in green debug mochitest-browser-chrome runs.

a) Should these be making the test run fail?
b) We should handle/fix, so we don't spam the annotated failure summary once this TBPL patchset is rolled out.

eg:

https://tbpl-dev.allizom.org/php/getParsedLog.php?id=25604620&tree=Mozilla-Central#error3

Rev4 MacOSX Lion 10.7 mozilla-central debug test mochitest-browser-chrome on 2013-07-23 02:32:38 PDT for push fb4bf993a58a

slave: talos-r4-lion-044

{
03:30:28     INFO -  var foo = {
03:30:28     INFO -    a_test: function() {
03:30:28     INFO -    },
03:30:28     INFO -    n_test: function x() {
03:30:28     INFO -    },
03:30:28     INFO -    sub: {
03:30:28     INFO -      a_test: function() {
03:30:28     INFO -      },
03:30:28     INFO -      n_test: function y() {
03:30:28     INFO -      },
03:30:28     INFO -      sub: {
03:30:28     INFO -        a_test: function() {
03:30:28     INFO -        },
03:30:28     INFO -        n_test: function z() {
03:30:28     INFO -        },
03:30:28     INFO -        sub: {
03:30:28     INFO -          test_SAME_NAME: function test_SAME_NAME() {
03:30:28     INFO -          }
03:30:28     INFO -        }
03:30:28     INFO -      }
03:30:28     INFO -    }
03:30:28     INFO -  };
03:30:28     INFO -  DBG-FRONTEND: Handling tab navigation in the DebuggerView
03:30:28     INFO -  WARNING: NS_ENSURE_TRUE(mDisabledJSAndPlugins) failed: file ../../../../editor/composer/src/nsEditingSession.cpp, line 208
03:30:28     INFO -  WARNING: NS_ENSURE_TRUE(rootContent) failed: file ../../../../editor/composer/src/nsEditorSpellCheck.cpp, line 698
03:30:28     INFO -  TEST-PASS | chrome://mochitests/content/browser/browser/devtools/debugger/test/browser_dbg_sources-cache.js | There should be no sources present in the sources list during reload.
03:30:28     INFO -  TypeError: gControllerSources.getCache is not a function: testStateBeforeReload@chrome://mochitests/content/browser/browser/devtools/debugger/test/browser_dbg_sources-cache.js:117
}

http://hg.mozilla.org/mozilla-central/file/b717a7945dfb/browser/devtools/debugger/test/browser_dbg_sources-cache.js#l117

   114 function testStateBeforeReload() {
   115   is(gSources.itemCount, 0,
   116     "There should be no sources present in the sources list during reload.");
   117   is(gControllerSources.getCache().length, 0,
   118     "The sources cache should be empty during reload.");
   119   is(gDebugger.SourceUtils._labelsCache, gPrevLabelsCache,
   120     "The labels cache has been refreshed during reload and no new objects were created.");
   121   is(gDebugger.SourceUtils._groupsCache, gPrevGroupsCache,
   122     "The groups cache has been refreshed during reload and no new objects were created.");
   123   is(gDebugger.SourceUtils._labelsCache.size, 0,
   124     "There should be no labels cached during reload");
   125   is(gDebugger.SourceUtils._groupsCache.size, 0,
   126     "There should be no groups cached during reload");
   127 }
Flags: needinfo?(vporof)
Bug 896534 should cut down on the log spam, but we should certainly fix any errors. Do you have the complete list somewhere, or is it just this one?
This should definitely have been failing :/ The function was removed in bug 886170. The |is| check can be safely removed since the function doesn't exist anymore.
Flags: needinfo?(vporof)
Attached patch patchSplinter Review
Per comment 2.
Attachment #783873 - Flags: review?(vporof)
Attachment #783873 - Flags: review?(past)
Attachment #783873 - Flags: review?(past) → review+
I would love to understand how this exception wasn't being propagated to the mochitest onerror handler!
https://hg.mozilla.org/mozilla-central/rev/cdda582f86ce
Assignee: nobody → ryanvm
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 25
(In reply to :Gavin Sharp (use gavin@gavinsharp.com for email) from comment #4)
> I would love to understand how this exception wasn't being propagated to the
> mochitest onerror handler!

I think exception in event listeners do that?
I guess we should have been using our makeInfallible helper here:

http://mxr.mozilla.org/mozilla-central/source/toolkit/devtools/DevToolsUtils.js#41
Attachment #783873 - Flags: review?(vporof)
No longer blocks: 892958
Blocks: log-SnR
Assuming no verification needed here. Please add the verifyme keyword and remove the [qa-] whiteboard tag to request verification.
Whiteboard: [qa-]
Blocks: 920191
No longer blocks: log-SnR
Product: Firefox → DevTools
You need to log in before you can comment on or make changes to this bug.