Closed Bug 1553929 Opened 5 years ago Closed 5 years ago

If a profile's path in profiles.ini doesn't match the expected serialisation then finding and setting the default profile is broken.

Categories

(Toolkit :: Startup and Profile System, defect, P2)

67 Branch
x86_64
Linux
defect

Tracking

()

RESOLVED FIXED
mozilla69
Tracking Status
firefox-esr60 --- unaffected
firefox67 --- wontfix
firefox67.0.1 --- wontfix
firefox68 --- fixed
firefox69 --- fixed

People

(Reporter: u639538, Assigned: mossop)

References

(Regression)

Details

(Keywords: regression)

Attachments

(4 files)

User Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:67.0) Gecko/20100101 Firefox/67.0

Steps to reproduce:

On starting firefox (canonical ubuntu 64 bits)
I always get the "Firefox - Choose User Profile" page, although
I mark the "Use the selected profile ..." box

Actual results:

I am always presented by the "Firefox- Chhose User profile window"

Expected results:

This should not happen. It is new with this last version of firefox

firefox
67.0
20190517140819

Please do the following:

  1. Enter about:support into the address bar.
  2. Click the Open Folder button. This opens a file manager window with your current Firefox profile folder.
  3. Click the Attach File link above the description here and attach compatibility.ini from that folder.
Component: Untriaged → Startup and Profile System
Flags: needinfo?(jean-pierre.eckmann)
OS: Unspecified → Linux
Product: Firefox → Toolkit
Regressed by: 1474285
Hardware: Unspecified → x86_64
Summary: firefox-canonical 64 bits. I need to choose a user profile (among 1) on each restar of firefox although "use selected" is clicked → firefox-canonical 64 bits. I need to choose a user profile (among 1) on each restart of firefox although "use selected" is clicked

as per your demand

Please attach the compatibility.ini file from your profile folder as requested at comment 1.

Attached file compatibility.ini
Flags: needinfo?(jean-pierre.eckmann) → needinfo?(dtownsend)

Please attach a copy of profiles.ini, it should be a directory or two above where compatibility.ini was. Also what is the path to the profile folder you are using?

Flags: needinfo?(dtownsend) → needinfo?(jean-pierre.eckmann)
Attached file profiles.ini

Note that I tried many variants of profiles.ini to make the problem disappear.

Also note that if I use about:profiles
and say use as default "yes", it immediatly turn back to "no"

Also, I checked the attributes of these files. they are writable...

NB. I am willing to do tests on my side.

Attachment #9067251 - Attachment mime type: application/octet-stream → text/plain
Attachment #9067376 - Attachment mime type: application/octet-stream → text/plain

How do you launch Firefox?

Thanks for asking.

I tried many variants, result does not change

In particular, it also breaks with /usr/bin/firefox

I also tried some flags, no good

any suggestions?

/usr/bin/firefox sounds likely to be a shell script or a symlink that causes Firefox to be launched from wherever it is actually installed. Are you able to figure that out?

Does the same problem occur with the official Mozilla build of Firefox?

question 1: the script starts the binary /usr/lib/firefox/firefox which is an elf executable (without any flags)

question2: Tell me exactly which firefox I should download (not using ubuntu package) and I can check if the mistake is by canonical...

(In reply to jean-pierre.eckmann@unige.ch from comment #10)

question2: Tell me exactly which firefox I should download (not using ubuntu package) and I can check if the mistake is by canonical...

https://download.mozilla.org/?product=firefox-latest-ssl&os=linux64&lang=en-US

ok. Downloaded firefox from the official mozilla site
2649703 Mai 24 19:45 firefox-67.0.tar.bz2

unpacked it ,. went into unpacked directory, and launched ./firefox

it tells me it wants me to use synchronize with other devices, which I do not want

it proposes a new profile, but of course, I want to keep the old one.

now the incriminated window appears again.,
with 3 profiles

my old one, and

the bizarre phenomenon persists

NB. perhaps you want nmy email, and I yours, then we can zoom in faster into what the problem is.
If you are interested.

Jean-Pierre Eckmann (University of Geneva)

(In reply to jean-pierre.eckmann@unige.ch from comment #12)

ok. Downloaded firefox from the official mozilla site
2649703 Mai 24 19:45 firefox-67.0.tar.bz2

unpacked it ,. went into unpacked directory, and launched ./firefox

it tells me it wants me to use synchronize with other devices, which I do not want

it proposes a new profile, but of course, I want to keep the old one.

So did it show the profile manager on first launch or go straight into Firefox?

now the incriminated window appears again.,
with 3 profiles

Can you upload the updated profiles.ini now?

Also, previously you mentioned that when you try to set the default in about:profiles it immediately changes back to no. Can you explain more

It sounds like you're saying when you open about:profiles none of the profiles are marked as the default?
When you click to set one as the default it changes to yes then immediately back to no?
If you open the browser console (menu -> web developer -> browser console) and then click set default is anything logged to the console window?

th browser console

Security Error: Content at moz-extension://7da2947f-167c-4ebd-bfda-a7ef865101f2/ may not load data from blob:null/88917021-fa23-422d-8f3f-385816f0c3b4.
Unknown localization message weh_prefs_label_downloadcompletedelay main.js:1
Unknown localization message weh_prefs_description_downloadcompletedelay main.js:1
Unknown localization message weh_prefs_label_tbvwsgrabdelay main.js:1
Unknown localization message weh_prefs_description_tbvwsgrabdelay main.js:1
Unknown localization message weh_prefs_label_forcedcoappversion main.js:1
Unknown localization message weh_prefs_description_forcedcoappversion main.js:1
Successfully compiled asm.js code (total compilation time 6ms) adblockplus.js
listener not re-registered ExtensionCommon.jsm:2173
response is undefined include.preload.js:556
Unchecked lastError value: Error: frame.state is undefined include.preload.js:546
Content Security Policy: Ignoring “'unsafe-inline'” within script-src or style-src: nonce-source or hash-source specified
Content Security Policy: Ignoring ‘x-frame-options’ because of ‘frame-ancestors’ directive.
Content Security Policy: Ignoring “'unsafe-inline'” within script-src or style-src: nonce-source or hash-source specified

In add-on {d10d0bf8-f5b5-c8b4-a8b2-2b9879e08c5d}, attempting to use listener "notifications.onButtonClicked", which is unimplemented. ExtensionParent.jsm:1027:13
Content Security Policy: The page’s settings blocked the loading of a resource at inline (“script-src”). show_bug.cgi:1:1
Request to access cookie or storage on “https://www.google-analytics.com/analytics.js” was blocked because we are blocking all third-party storage access requests and content blocking is enabled.
show_bug.cgi
Request to access cookie or storage on “https://secure.gravatar.com/avatar/dccf2b38c619d3ed9ab5113bb64bc694?d=mm&size=64” was blocked because we are blocking all third-party storage access requests and content blocking is enabled.
show_bug.cgi
Request to access cookie or storage on “https://secure.gravatar.com/avatar/cc5bc8d9afda0459276592e8ce5a2265?d=mm&size=64” was blocked because we are blocking all third-party storage access requests and content blocking is enabled.
show_bug.cgi
Request to access cookie or storage on “https://secure.gravatar.com/avatar/8f56e46f0120d9477f8f320991a2196a?d=mm&size=64” was blocked because we are blocking all third-party storage access requests and content blocking is enabled.
show_bug.cgi
Loading failed for the <script> with source “https://bugzilla.mozilla.org/static/v20190516.1/extensions/GoogleAnalytics/web/js/analytics.js”. show_bug.cgi:94:1
Request to access cookie or storage on “https://www.google-analytics.com/analytics.js” was blocked because we are blocking all third-party storage access requests and content blocking is enabled.
show_bug.cgi
Loading failed for the <script> with source “https://www.google-analytics.com/analytics.js”. show_bug.cgi:103:1
Unchecked lastError value: Error: Could not establish connection. Receiving end does not exist. chrome.js:106
Unknown localization message freshtab_app_top_box_import_bookmarks_hdr background.js:48
Unknown localization message freshtab_app_top_box_import_bookmarks_cta background.js:48
Unknown localization message freshtab_app_top_box_import_bookmarks_later background.js:48
Error: Promised response from onMessage listener went out of scope background.js:48:707869

profiles ini

[Profile3]
Name=default-release-2
IsRelative=1
Path=c3bbi2pa.default-release-2

[Install4F96D1932A9F858E]
Default=m7x1u74e.default-1459407583778
Locked=1

[Profile1]
Name=default-release
IsRelative=1
Path=v5388dml.default-release

[Profile0]
Name=jpe
IsRelative=0
Path=/home/eckmann/.mozilla/firefox/m7x1u74e.default-1459407583778/
Default=1

[General]
StartWithLastProfile=0
Version=2

[Profile4]
Name=default-release-3
IsRelative=1
Path=1h3ykdtn.default-release-3

[InstallB98AE417CCECC4B2]
Default=m7x1u74e.default-1459407583778
Locked=1

[Profile2]
Name=default-release-1
IsRelative=1
Path=25fihdjp.default-release-1

It sounds like you're saying when you open about:profiles none of the profiles are marked as the default?
When you click to set one as the default it changes to yes then immediately back to no?

"immediately" means the following:The "no" changes to "yes" . Then I click the restart button on the right and after that, it is "no" again.

(so , its exactly as ineffective as ticking the "remember the default" in the windo when I start the old or the new firefox.

NB. I did not study the browser console
NB2. I did not "install" the new firefox, but ran it from within the unpacked directory (with ./firefox ;) )

Solved (sort of)

Sir, I did the following
with the old firefox I created a new profile.
then I replaced the new profile (i.e., the whole directory, with a backup of my ofld profile directory.

The problem is gone.

I suggest that firefox makes an option which allows the user to use the old profile.
(The new firefox says that the old profile is "outdated" and wants to make a new one.

So I let it make the new one and then copied the old one over it

Not sure the standard user wants to do this

(In reply to jean-pierre.eckmann@unige.ch from comment #15)

Solved (sort of)

Sir, I did the following
with the old firefox I created a new profile.
then I replaced the new profile (i.e., the whole directory, with a backup of my ofld profile directory.

Hmm I might see what is going on here. Do you know the full paths of those two profiles?

In ubuntu , for many years all the mozilla stuff is in ~/.mozilla

and in it there is a firefox directory.

The profile directories are all in it. (I have, on many occasions, eg, when changing computers, just transferred those directories to the new computer ) and firefox seems to find them ;)

what is your idea about this?

(In reply to jean-pierre.eckmann@unige.ch from comment #17)

In ubuntu , for many years all the mozilla stuff is in ~/.mozilla

And what is the full path to that directory? What is your home directory path?

/home/eckmann is my home directory

All this is on a laptop, all directories are on a local disk on the laptop

so the full path is /home/eckmann/.mozilla/firefox

NO hard or soft links involved

Ok, I see the issue here. Somehow your profiles.ini ended up listing your profile's path as /home/eckmann/.mozilla/firefox/m7x1u74e.default-1459407583778/ when it really should have used m7x1u74e.default-1459407583778. Internally we use that path string as an identifer for the profile and so a few things are breaking if it isn't what we expect. I'm not sure how it could have ended up in that state but I think I can fix things to cope with that case.

Thanks for all the help tracking this down.

Assignee: nobody → dtownsend
Flags: needinfo?(jean-pierre.eckmann)
Priority: -- → P1
Summary: firefox-canonical 64 bits. I need to choose a user profile (among 1) on each restart of firefox although "use selected" is clicked → If a profile's path in profiles.ini doesn't match the expected serialisation then finding and setting the default profile is broken.

I am not sure this is right. Because, when the bug occured first, I did indeed change the suggested m7x1u74e.default-1459407583778. I
after some tries to the /home/eckmann/.mozilla/firefox/m7x1u74e.default-1459407583778/
and set the corresponding flag to "fullpath=1 " or whatever it was.

I fear the problem is independent of this.

NB. I live in europe and will go to bed...
Let me know what happens...

(In reply to jean-pierre.eckmann@unige.ch from comment #21)

I am not sure this is right. Because, when the bug occured first, I did indeed change the suggested m7x1u74e.default-1459407583778. I
after some tries to the /home/eckmann/.mozilla/firefox/m7x1u74e.default-1459407583778/
and set the corresponding flag to "fullpath=1 " or whatever it was.

Well for now I'm going to fix the issues I can reproduce here. If you wanted to dig further and could reproduce the issue with the path set correctly in profiles.ini then we can investigate that further. Probably best to file a new bug in that case since all the discussion in this bug was with the bad path in profiles.ini.

Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true

Given that in this case the change was done manually this probably isn't quite as important to fix.

Priority: P1 → P2
Regressions: 1554419
No longer regressions: 1554419
Pushed by dtownsend@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/29fdbc50c0a1
Make some attempt to correctly match default profiles after profiles.ini has been manually edited by the user. r=froydnj
Status: ASSIGNED → RESOLVED
Closed: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla69

Comment on attachment 9070396 [details]
Bug 1553929: Make some attempt to correctly match default profiles after profiles.ini has been manually edited by the user. r=froydnj

Beta/Release Uplift Approval Request

  • User impact if declined: Some users who have manually edited their profiles.ini file may no longer be able to set a default profile to use and will always see the profile manager on startup.
  • 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 is a straightforward change to how we parse profiles.ini. It only has an effect if there is a problem detected in the file.
  • String changes made/needed: None
Attachment #9070396 - Flags: approval-mozilla-release?
Attachment #9070396 - Flags: approval-mozilla-beta?

Comment on attachment 9070396 [details]
Bug 1553929: Make some attempt to correctly match default profiles after profiles.ini has been manually edited by the user. r=froydnj

approved for 68.0b11.

Attachment #9070396 - Flags: approval-mozilla-beta? → approval-mozilla-beta+
Attachment #9070396 - Flags: approval-mozilla-release? → approval-mozilla-release-
Has Regression Range: --- → yes
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: