Closed Bug 1555117 Opened 1 year ago Closed 1 year ago

Starting Firefox with -reset-profile when there is no currently selected profile will do nothing

Categories

(Toolkit :: Startup and Profile System, defect)

defect
Not set

Tracking

()

VERIFIED FIXED
mozilla69
Tracking Status
firefox67 --- wontfix
firefox68 --- verified
firefox69 --- verified

People

(Reporter: mossop, Assigned: mossop)

References

Details

Attachments

(1 file)

The command line argument -reset-profile tells Firefox to refresh its profile on launch. The installer will pass this argument in some cases.

Bug 1518587 made it so if something is telling us to refresh the profile (env value or command line argument) but there is no profile selected (before we attempt to create a new profile) then we consider it an error state and exit.

This break the installer launching Firefox in some cases.

Instead if no profile is found we should just go ahead and create a new one and not refresh it.

Duplicate of this bug: 1553532

Since bug 1518587 when a command line argument or environment variable requests
a profile refresh but no existing profile is selected we would just exit
thinking that there is some problem here. But it turns out that the installer
sometimes passes this argument when it doesn't know that the new install will
not use the existing profiles.

So instead we just ignore attempts to refresh when we create a new profile. To
do this we just have to remove the checks that bail out and continue to create
the new profile, nsAppRunner will see that a new profile has been created and
cancel the attempted refresh anyway:
https://searchfox.org/mozilla-central/rev/ddb81c7a43ffada1f6cb4200c4f625e50e44dcf3/toolkit/xre/nsAppRunner.cpp#2021

Pushed by dtownsend@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/57fd8dc8fcdd
Ignore attempts to reset the profile when a new profile had to be created for the install. r=froydnj
Status: NEW → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla69
Regressions: 1556173

Comment on attachment 9068167 [details]
Bug 1555117: Ignore attempts to reset the profile when a new profile had to be created for the install. r=froydnj

Beta/Release Uplift Approval Request

  • User impact if declined: In certain cases requesting a profile refresh from the installer will make firefox fail to launch when the installer finishes.
  • Is this code covered by automated tests?: Yes
  • Has the fix been verified in Nightly?: Yes
  • Needs manual test from QE?: No
  • If yes, steps to reproduce:
  • List of other uplifts needed: None
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): This just removes a few checks that bail out of startup.
  • String changes made/needed: None
Attachment #9068167 - Flags: approval-mozilla-release?
Attachment #9068167 - Flags: approval-mozilla-beta?

Bug 1556173 makes me suspect tests will go red if we uplift this to beta as-is.

Flags: needinfo?(dtownsend)

Cheers

FYI, I'd like it to be verified on beta before considering an uplift to release.

(In reply to Julien Cristau [:jcristau] from comment #6)

Bug 1556173 makes me suspect tests will go red if we uplift this to beta as-is.

I've just queued that up for landing.

Flags: needinfo?(dtownsend)

Comment on attachment 9068167 [details]
Bug 1555117: Ignore attempts to reset the profile when a new profile had to be created for the install. r=froydnj

fix an issue with profile reset, approved for 68.0b10

Attachment #9068167 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
Flags: qe-verify+
QA Whiteboard: [qa-triaged]

Build ID 20190613215335
User Agent Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:69.0) Gecko/20100101 Firefox/69.0

Verified as fixed on the latest Nightly build on Windows 10.

Build ID 20190613141208
User Agent Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:68.0) Gecko/20100101 Firefox/68.0

Verified as fixed on the latest Beta build (v68b10) on Windows 10.

Status: RESOLVED → VERIFIED
QA Whiteboard: [qa-triaged]
Flags: qe-verify+
Attachment #9068167 - Flags: approval-mozilla-release? → approval-mozilla-release-

We're not going to ship another 67 dot release.

You need to log in before you can comment on or make changes to this bug.