Closed Bug 1067568 Opened 10 years ago Closed 9 years ago

Intermittent test_filehandle_readonly_exceptions.html | Assertion count 4 is greater than expected (ASSERTION: We don't know anyting about this file handle?!: 'Error', file dom/filehandle/FileService.cpp, line 234)

Categories

(Core :: Storage: IndexedDB, defect)

x86_64
macOS
defect
Not set
normal

Tracking

()

RESOLVED WORKSFORME
Tracking Status
firefox37 --- fixed
firefox38 --- fixed
firefox39 --- fixed
firefox-esr31 --- unaffected
b2g-v2.1 --- unaffected
b2g-v2.2 --- fixed
b2g-master --- fixed

People

(Reporter: RyanVM, Assigned: janv)

Details

(Keywords: assertion, crash, intermittent-failure)

Attachments

(2 files)

https://tbpl.mozilla.org/php/getParsedLog.php?id=48105472&tree=Fx-Team

Rev5 MacOSX Mountain Lion 10.8 fx-team debug test mochitest-2 on 2014-09-15 09:24:01 PDT for push 4a953a406eaa
slave: talos-mtnlion-r5-071

09:58:37     INFO -  2128 INFO TEST-START | /tests/dom/indexedDB/test/test_filehandle_readonly_exceptions.html
09:58:37     INFO -  ++DOMWINDOW == 46 (0x115750400) [pid = 1303] [serial = 4270] [outer = 0x122b0f800]
09:58:37     INFO -  [Parent 1303] WARNING: Enqueue failed!: file /builds/slave/fx-team-osx64-d-00000000000000/build/dom/filehandle/FileService.cpp, line 491
09:58:37     INFO -  [Parent 1303] WARNING: Enqueue failed!: file /builds/slave/fx-team-osx64-d-00000000000000/build/dom/filehandle/FileService.cpp, line 491
09:58:37     INFO -  [Parent 1303] WARNING: Enqueue failed!: file /builds/slave/fx-team-osx64-d-00000000000000/build/dom/filehandle/FileService.cpp, line 491
09:58:37     INFO -  [Parent 1303] WARNING: Enqueue failed!: file /builds/slave/fx-team-osx64-d-00000000000000/build/dom/filehandle/FileService.cpp, line 491
09:58:37     INFO -  [Parent 1303] ###!!! ASSERTION: We don't know anyting about this file handle?!: 'Error', file /builds/slave/fx-team-osx64-d-00000000000000/build/dom/filehandle/FileService.cpp, line 234
09:58:48     INFO -  JavaScript error: jar:file:///builds/slave/talos-slave/test/build/application/FirefoxNightlyDebug.app/Contents/MacOS/omni.ja!/components/nsHandlerService.js, line 891: NS_ERROR_FAILURE: Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIProperties.get]
09:58:58     INFO -  nsThread::ProcessNextEvent(bool, bool*) [xpcom/threads/nsThread.cpp:823]
09:58:58     INFO -  NS_ProcessPendingEvents(nsIThread*, unsigned int) [xpcom/glue/nsThreadUtils.cpp:207]
09:58:58     INFO -  nsBaseAppShell::NativeEventCallback() [widget/xpwidgets/nsBaseAppShell.cpp:99]
09:58:58     INFO -  nsAppShell::ProcessGeckoEvents(void*) [widget/cocoa/nsAppShell.mm:375]
09:58:58     INFO -  CoreFoundation + 0x12841
09:58:58     INFO -  CoreFoundation + 0x12165
09:58:58     INFO -  CoreFoundation + 0x354e5
09:58:58     INFO -  CoreFoundation + 0x34dd2
09:58:58     INFO -  HIToolbox + 0x5f774
09:58:58     INFO -  HIToolbox + 0x5f512
09:58:58     INFO -  HIToolbox + 0x5f3a3
09:58:58     INFO -  AppKit + 0x156fa3
09:58:58     INFO -  -AppKit + 0x156862
09:58:58     INFO -  -[GeckoNSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] [widget/cocoa/nsAppShell.mm:129]
09:58:58     INFO -  -AppKit + 0x14dc03
09:58:58     INFO -  nsAppShell::Run() [xpcom/glue/nsCOMPtr.h:643]
09:58:58     INFO -  nsAppStartup::Run() [toolkit/components/startup/nsAppStartup.cpp:280]
09:58:58     INFO -  XREMain::XRE_mainRun() [toolkit/xre/nsAppRunner.cpp:4123]
09:58:58     INFO -  XREMain::XRE_main(int, char**, nsXREAppData const*) [toolkit/xre/nsAppRunner.cpp:4194]
09:58:58     INFO -  XRE_main [toolkit/xre/nsAppRunner.cpp:4408]
09:58:58     INFO -  main [browser/app/nsBrowserApp.cpp:282]
09:58:58     INFO -  [Parent 1303] ###!!! ASSERTION: We don't know anyting about this file handle?!: 'Error', file /builds/slave/fx-team-osx64-d-00000000000000/build/dom/filehandle/FileService.cpp, line 234
09:58:58     INFO -  nsThread::ProcessNextEvent(bool, bool*) [xpcom/threads/nsThread.cpp:823]
09:58:58     INFO -  NS_ProcessPendingEvents(nsIThread*, unsigned int) [xpcom/glue/nsThreadUtils.cpp:207]
09:58:58     INFO -  nsBaseAppShell::NativeEventCallback() [widget/xpwidgets/nsBaseAppShell.cpp:99]
09:58:58     INFO -  nsAppShell::ProcessGeckoEvents(void*) [widget/cocoa/nsAppShell.mm:375]
09:58:58     INFO -  CoreFoundation + 0x12841
09:58:58     INFO -  CoreFoundation + 0x12165
09:58:58     INFO -  CoreFoundation + 0x354e5
09:58:58     INFO -  CoreFoundation + 0x34dd2
09:58:58     INFO -  HIToolbox + 0x5f774
09:58:58     INFO -  HIToolbox + 0x5f512
09:58:58     INFO -  HIToolbox + 0x5f3a3
09:58:58     INFO -  AppKit + 0x156fa3
09:58:58     INFO -  -AppKit + 0x156862
09:58:58     INFO -  -[GeckoNSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] [widget/cocoa/nsAppShell.mm:129]
09:58:58     INFO -  -AppKit + 0x14dc03
09:58:58     INFO -  nsAppShell::Run() [xpcom/glue/nsCOMPtr.h:643]
09:58:58     INFO -  nsAppStartup::Run() [toolkit/components/startup/nsAppStartup.cpp:280]
09:58:58     INFO -  XREMain::XRE_mainRun() [toolkit/xre/nsAppRunner.cpp:4123]
09:58:58     INFO -  XREMain::XRE_main(int, char**, nsXREAppData const*) [toolkit/xre/nsAppRunner.cpp:4194]
09:58:58     INFO -  XRE_main [toolkit/xre/nsAppRunner.cpp:4408]
09:58:58     INFO -  main [browser/app/nsBrowserApp.cpp:282]
09:58:58     INFO -  [Parent 1303] ###!!! ASSERTION: We don't know anyting about this file handle?!: 'Error', file /builds/slave/fx-team-osx64-d-00000000000000/build/dom/filehandle/FileService.cpp, line 234
09:58:58     INFO -  nsThread::ProcessNextEvent(bool, bool*) [xpcom/threads/nsThread.cpp:823]
09:58:58     INFO -  NS_ProcessPendingEvents(nsIThread*, unsigned int) [xpcom/glue/nsThreadUtils.cpp:207]
09:58:58     INFO -  nsBaseAppShell::NativeEventCallback() [widget/xpwidgets/nsBaseAppShell.cpp:99]
09:58:58     INFO -  nsAppShell::ProcessGeckoEvents(void*) [widget/cocoa/nsAppShell.mm:375]
09:58:58     INFO -  CoreFoundation + 0x12841
09:58:58     INFO -  CoreFoundation + 0x12165
09:58:58     INFO -  CoreFoundation + 0x354e5
09:58:58     INFO -  CoreFoundation + 0x34dd2
09:58:58     INFO -  HIToolbox + 0x5f774
09:58:58     INFO -  HIToolbox + 0x5f512
09:58:58     INFO -  HIToolbox + 0x5f3a3
09:58:58     INFO -  AppKit + 0x156fa3
09:58:58     INFO -  -AppKit + 0x156862
09:58:58     INFO -  -[GeckoNSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] [widget/cocoa/nsAppShell.mm:129]
09:58:58     INFO -  -AppKit + 0x14dc03
09:58:58     INFO -  nsAppShell::Run() [xpcom/glue/nsCOMPtr.h:643]
09:58:58     INFO -  nsAppStartup::Run() [toolkit/components/startup/nsAppStartup.cpp:280]
09:58:58     INFO -  XREMain::XRE_mainRun() [toolkit/xre/nsAppRunner.cpp:4123]
09:58:58     INFO -  XREMain::XRE_main(int, char**, nsXREAppData const*) [toolkit/xre/nsAppRunner.cpp:4194]
09:58:58     INFO -  XRE_main [toolkit/xre/nsAppRunner.cpp:4408]
09:58:58     INFO -  main [browser/app/nsBrowserApp.cpp:282]
09:58:58     INFO -  [Parent 1303] ###!!! ASSERTION: We don't know anyting about this file handle?!: 'Error', file /builds/slave/fx-team-osx64-d-00000000000000/build/dom/filehandle/FileService.cpp, line 234
09:58:58     INFO -  nsThread::ProcessNextEvent(bool, bool*) [xpcom/threads/nsThread.cpp:823]
09:58:58     INFO -  NS_ProcessPendingEvents(nsIThread*, unsigned int) [xpcom/glue/nsThreadUtils.cpp:207]
09:58:58     INFO -  nsBaseAppShell::NativeEventCallback() [widget/xpwidgets/nsBaseAppShell.cpp:99]
09:58:58     INFO -  nsAppShell::ProcessGeckoEvents(void*) [widget/cocoa/nsAppShell.mm:375]
09:58:58     INFO -  CoreFoundation + 0x12841
09:58:58     INFO -  CoreFoundation + 0x12165
09:58:58     INFO -  CoreFoundation + 0x354e5
09:58:58     INFO -  CoreFoundation + 0x34dd2
09:58:58     INFO -  HIToolbox + 0x5f774
09:58:58     INFO -  HIToolbox + 0x5f512
09:58:58     INFO -  HIToolbox + 0x5f3a3
09:58:58     INFO -  AppKit + 0x156fa3
09:58:58     INFO -  -AppKit + 0x156862
09:58:58     INFO -  -[GeckoNSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] [widget/cocoa/nsAppShell.mm:129]
09:58:58     INFO -  -AppKit + 0x14dc03
09:58:58     INFO -  nsAppShell::Run() [xpcom/glue/nsCOMPtr.h:643]
09:58:58     INFO -  nsAppStartup::Run() [toolkit/components/startup/nsAppStartup.cpp:280]
09:58:58     INFO -  XREMain::XRE_mainRun() [toolkit/xre/nsAppRunner.cpp:4123]
09:58:58     INFO -  XREMain::XRE_main(int, char**, nsXREAppData const*) [toolkit/xre/nsAppRunner.cpp:4194]
09:58:58     INFO -  XRE_main [toolkit/xre/nsAppRunner.cpp:4408]
09:58:58     INFO -  main [browser/app/nsBrowserApp.cpp:282]
09:58:58     INFO -  2129 INFO TEST-OK | /tests/dom/indexedDB/test/test_filehandle_readonly_exceptions.html | took 521ms
09:58:58     INFO -  ++DOMWINDOW == 47 (0x115e82400) [pid = 1303] [serial = 4271] [outer = 0x122b0f800]
09:58:58     INFO -  2130 INFO TEST-UNEXPECTED-ERROR | /tests/dom/indexedDB/test/test_filehandle_readonly_exceptions.html | Assertion count 4 is greater than expected range 0-0 assertions.
09:58:58     INFO -  TEST-INFO
The four warnings are from here: http://mxr.mozilla.org/mozilla-central/source/dom/filehandle/FileService.cpp#157

So something is going wrong with invalidated filehandles?
I think I know what the problem is. Let me test a patch.
https://tbpl.mozilla.org/?tree=Try&rev=9f8f647e1668

I'll retrigger once the first m-2 starts
Attached patch patch — — Splinter Review
try looks good
Assignee: nobody → Jan.Varga
Status: NEW → ASSIGNED
Attachment #8491844 - Flags: review?(bent.mozilla)
Attachment #8491844 - Flags: review?(bent.mozilla) → review+
(In reply to TBPL Robot from comment #37)

This is post-comment 35 :(
Keywords: leave-open
Attached patch additional patch — — Splinter Review
This should fix it.

Try run:
https://tbpl.mozilla.org/?tree=Try&rev=a0db1f387a4e
Attachment #8559337 - Flags: review?(bent.mozilla)
Comment on attachment 8559337 [details] [diff] [review]
additional patch

Review of attachment 8559337 [details] [diff] [review]:
-----------------------------------------------------------------

::: dom/indexedDB/IDBMutableFile.cpp
@@ +324,5 @@
>      return nullptr;
>    }
>  
> +  // Do nothing if the window is closed
> +  if (!GetOwner()) {

I think we should be able to assert this now?

@@ +382,2 @@
>    // Do nothing if the window is closed
>    if (!GetOwner()) {

Same here.
Attachment #8559337 - Flags: review?(bent.mozilla) → review+
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Keywords: leave-open
Resolution: --- → FIXED
Target Milestone: --- → mozilla39
Please request Aurora and Beta approval on this when you get a chance.
Ben, can you please help with an approval request otherwise? :)
Flags: needinfo?(bent.mozilla)
Comment on attachment 8559337 [details] [diff] [review]
additional patch

Approval Request Comment
[Feature/regressing bug #]: Unknown
[User impact if declined]: Poorly timed usage of FileHandle can crash
[Describe test coverage new/current, TreeHerder]: Tests caught this
[Risks and why]: Very low risk, this feature is not widely used but this is a frequent intermittent test failure. Since the branches will live a while (b2g2.2 and esr38) I think it's worth uplifting.
[String/UUID change made/needed]: None
Flags: needinfo?(bent.mozilla)
Flags: needinfo?(Jan.Varga)
Attachment #8559337 - Flags: approval-mozilla-beta?
Attachment #8559337 - Flags: approval-mozilla-aurora?
(In reply to Ben Turner [:bent] (use the needinfo flag!) from comment #114)
> Approval Request Comment

Note that both patches need to be uplifted.
Attachment #8559337 - Flags: approval-mozilla-beta?
Attachment #8559337 - Flags: approval-mozilla-beta+
Attachment #8559337 - Flags: approval-mozilla-aurora?
Attachment #8559337 - Flags: approval-mozilla-aurora+
(In reply to Treeherder Robot from comment #118)
(In reply to Treeherder Robot from comment #120)

:(
Status: RESOLVED → REOPENED
Flags: needinfo?(Jan.Varga)
Resolution: FIXED → ---
Target Milestone: mozilla39 → ---
Is there a chance that fx-team wasn't merged with m-c in since 2015-03-03 ? :)
Flags: needinfo?(Jan.Varga)
Very unlikely :P
Inactive; closing (see bug 1180138).
Status: REOPENED → RESOLVED
Closed: 9 years ago9 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: