Bug 1707963 Comment 28 Edit History

Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.

Yes, that makes sense.  My understanding from my [restating comment](https://phabricator.services.mozilla.com/D26491#792652) in the review is that our rationale for explicitly initiating startup early was that we had no easy way to know when we were already in shutdown and the fix was a band-aid.  You (:jstutte) have since added such functionality, so the hack to compel startup at layout statics isn't necessary.

I vaguely remember that in some other cases with similar problems that we'd hooked up the initialization of things that are reading data from disk to "profile-after-change".  I see that there is an observer notification for "profile-do-change" which is a step earlier (and likely appropriate for a core component), so that seems reasonable and like it should cover the initialization.  Also, the good news is that although invoking `profile_do_change()` with its default false argument for `notifyProfileAfterChange` won't file "profile-after-change", it DOES fire "profile-do-change", so there should be minimal breakage for xpcshell tests from this.  (And it also suggests maybe I should have been recommending "profile-do-change" more those times I suggested "profile-after-change"...)

Tim, you're [module owner of this code](https://wiki.mozilla.org/Modules/All#Permissions), what are your thoughts/preference?
Yes, that makes sense.  My understanding from my [restating comment](https://phabricator.services.mozilla.com/D26491#792652) in the review is that our rationale for explicitly initiating startup early was that we had no easy way to know when we were already in shutdown and the fix was a band-aid.  You (:jstutte) have since added such functionality, so the hack to compel startup at layout statics isn't necessary.

I vaguely remember that in some other cases with similar problems that we'd hooked up the initialization of things that are reading data from disk to "profile-after-change".  I see that there is an observer notification for "profile-do-change" which is a step earlier (and likely appropriate for a core component), so that seems reasonable and like it should cover the initialization.  Also, the good news is that although invoking `profile_do_change()` with its default false argument for `notifyProfileAfterChange` won't fire "profile-after-change", it DOES fire "profile-do-change", so there should be minimal breakage for xpcshell tests from this.  (And it also suggests maybe I should have been recommending "profile-do-change" more those times I suggested "profile-after-change"...)

Tim, you're [module owner of this code](https://wiki.mozilla.org/Modules/All#Permissions), what are your thoughts/preference?

Back to Bug 1707963 Comment 28