Closed
Bug 1649612
Opened 5 years ago
Closed 4 years ago
DownloadStore.jsm imports OS.File during startup
Categories
(Toolkit Graveyard :: OS.File, task)
Toolkit Graveyard
OS.File
Tracking
(firefox84 fixed)
RESOLVED
FIXED
84 Branch
Tracking | Status | |
---|---|---|
firefox84 | --- | fixed |
People
(Reporter: beth, Assigned: masterwayz, Mentored)
References
Details
(Whiteboard: [lang=js])
Attachments
(1 file)
According to this startup profile, DownloadStore.jsm runs during startup and imports osfile.jsm. We should migrate this to the new IOUtils replacement for osfile.jsm when possible.
Stack:
(root) []
XREMain::XRE_main []
XREMain::XRE_main(int, char**, mozilla::BootstrapConfig const&) [libxul.so]
XREMain::XRE_mainRun() [libxul.so]
nsAppStartup::Run() [libxul.so]
nsBaseAppShell::Run() [libxul.so]
MessageLoop::Run() [libxul.so]
mozilla::ipc::MessagePump::Run(base::MessagePump::Delegate*) [libxul.so]
nsThread::ProcessNextEvent(bool, bool*) [libxul.so]
mozilla::ipc::MessageChannel::MessageTask::Run() [libxul.so]
mozilla::ipc::MessageChannel::DispatchMessage(IPC::Message&&) [libxul.so]
mozilla::ipc::PBackgroundChild::OnMessageReceived(IPC::Message const&) [libxul.so]
PBackgroundIDBRequest::Msg___delete__ []
mozilla::dom::indexedDB::PBackgroundIDBRequestChild::OnMessageReceived(IPC::Message const&) [libxul.so]
mozilla::dom::indexedDB::BackgroundRequestChild::Recv__delete__(mozilla::dom::indexedDB::RequestResponse&&) [libxul.so]
IndexedDB:SetResultAndDispatchSuccessEvent []
mozilla::dom::indexedDB::BackgroundRequestChild::HandleResponse(mozilla::dom::indexedDB::SerializedStructuredCloneReadInfo&&) [libxul.so]
mozilla::dom::indexedDB::(anonymous namespace)::detail::DispatchSuccessEvent(RefPtr<mozilla::dom::IDBRequest> const&, mozilla::SafeRefPtr<mozilla::dom::IDBTransaction> const&, RefPtr<mozilla::dom::Event> const&) [libxul.so]
mozilla::dom::EventTarget::DispatchEvent(mozilla::dom::Event&, mozilla::ErrorResult&) [libxul.so]
mozilla::DOMEventTargetHelper::DispatchEvent(mozilla::dom::Event&, mozilla::dom::CallerType, mozilla::ErrorResult&) [libxul.so]
mozilla::EventDispatcher::DispatchDOMEvent(nsISupports*, mozilla::WidgetEvent*, mozilla::dom::Event*, nsPresContext*, nsEventStatus*) [libxul.so]
EventDispatcher::Dispatch []
EventDispatcher::Dispatch success []
mozilla::EventDispatcher::Dispatch(nsISupports*, nsPresContext*, mozilla::WidgetEvent*, mozilla::dom::Event*, nsEventStatus*, mozilla::EventDispatchingCallback*, nsTArray<mozilla::dom::EventTarget*>*) [libxul.so]
mozilla::EventTargetChainItem::HandleEventTargetChain(nsTArray<mozilla::EventTargetChainItem>&, mozilla::EventChainPostVisitor&, mozilla::EventDispatchingCallback*, mozilla::ELMCreationDetector&) [libxul.so]
mozilla::EventListenerManager::HandleEventInternal(nsPresContext*, mozilla::WidgetEvent*, mozilla::dom::Event**, mozilla::dom::EventTarget*, nsEventStatus*, bool) [libxul.so]
<name omitted> [libxul.so]
promise callback []
mozilla::PromiseJobRunnable::Run(mozilla::AutoSlowOperation&) [libxul.so]
mozilla::dom::PromiseJobCallback::Call(mozilla::dom::BindingCallContext&, JS::Handle<JS::Value>, mozilla::ErrorResult&) [libxul.so]
JS::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, JS::HandleValueArray const&, JS::MutableHandle<JS::Value>) [libxul.so]
js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct, js::CallReason) [libxul.so]
PromiseReactionJob(JSContext*, unsigned int, JS::Value*) [libxul.so]
AsyncFunctionResume(JSContext*, JS::Handle<js::AsyncFunctionGeneratorObject*>, ResumeKind, JS::Handle<JS::Value>) [libxul.so]
js::CallSelfHostedFunction(JSContext*, JS::Handle<js::PropertyName*>, JS::Handle<JS::Value>, js::AnyInvokeArgs const&, JS::MutableHandle<JS::Value>) [libxul.so]
js::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, js::AnyInvokeArgs const&, JS::MutableHandle<JS::Value>, js::CallReason) [libxul.so]
js::RunScript []
js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct, js::CallReason) [libxul.so]
AsyncFunctionNext [self-hosted:688:26]
0xff4eaa5ea9f []
js::jit::InterpretResume(JSContext*, JS::Handle<JSObject*>, JS::Value*, JS::MutableHandle<JS::Value>) [libxul.so]
js::CallSelfHostedFunction(JSContext*, JS::Handle<js::PropertyName*>, JS::Handle<JS::Value>, js::AnyInvokeArgs const&, JS::MutableHandle<JS::Value>) [libxul.so]
js::Call(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, js::AnyInvokeArgs const&, JS::MutableHandle<JS::Value>, js::CallReason) [libxul.so]
js::RunScript []
InterpretGeneratorResume [self-hosted:1146:33]
initializePublicDownloadList [resource://gre/modules/DownloadIntegration.jsm:231:36]
loadPublicDownloadListFromStore [resource://gre/modules/DownloadIntegration.jsm:260:39]
DS_load [resource://gre/modules/DownloadStore.jsm:90:24]
> DS_load/< [resource://gre/modules/DownloadStore.jsm:91:18]
js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct, js::CallReason) [libxul.so]
Interpret(JSContext*, js::RunState&) [libxul.so]
js::NativeGetExistingProperty(JSContext*, JS::Handle<JSObject*>, JS::Handle<js::NativeObject*>, JS::Handle<js::Shape*>, JS::MutableHandle<JS::Value>) [libxul.so]
js::CallGetter(JSContext*, JS::Handle<JS::Value>, JS::Handle<JS::Value>, JS::MutableHandle<JS::Value>) [libxul.so]
js::InternalCallOrConstruct(JSContext*, JS::CallArgs const&, js::MaybeConstruct, js::CallReason) [libxul.so]
mozilla::dom::module_getter::ModuleGetter(JSContext*, unsigned int, JS::Value*) [libxul.so]
mozJSComponentLoader::Import(JSContext*, nsTSubstring<char> const&, JS::MutableHandle<JSObject*>, JS::MutableHandle<JSObject*>, bool) [libxul.so]
profiler_get_backtrace() [libxul.so]
Registers::SyncPopulate() [libxul.so]
Comment 1•4 years ago
|
||
We should look at removing the following instances of OS.File in DownloadStore.jsm: https://searchfox.org/mozilla-central/source/toolkit/components/downloads/DownloadStore.jsm#42,94,96,172,178,181. The errors returned from IOUtils are DomExceptions, so we will need to change our error handling as well.
Mentor: emalysz
Whiteboard: [lang=js]
Assignee | ||
Comment 2•4 years ago
|
||
Updated•4 years ago
|
Assignee: nobody → michael
Status: NEW → ASSIGNED
Pushed by emalysz@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/33bbc54d09e3
Make DownloadStore.jsm use new IOUtils instead of OS.File with test r=emalysz
Comment 4•4 years ago
|
||
bugherder |
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
status-firefox84:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → 84 Branch
Updated•2 years ago
|
Product: Toolkit → Toolkit Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•