Closed Bug 1541312 Opened 5 years ago Closed 5 years ago

Accept-language is changed when connecting to Sync

Categories

(Firefox :: Sync, defect)

66 Branch
defect
Not set
normal

Tracking

()

VERIFIED WORKSFORME

People

(Reporter: lsatenstein, Unassigned)

Details

User Agent: Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:66.0) Gecko/20100101 Firefox/66.0
Firefox for Android

Steps to reproduce:

I am experiencing the problem with Firefox but not with chrome Fedora 28,29,30
Region and Language English(canada)
Keyboard (French Canada)

I do not use French other than it is my standard keyboard.

When viewing a English webpage or even youtube and I click to view a link, firefox brings up the link in French. my browser does not have the french language setup.

Consider this webpage

https://fedoramagazine.org/announcing-the-release-of-fedora-30-beta/

When I click onto a link to a second page, the page

Actual results:

It has links to
Download the prerelease from our Get Fedora site:

Get Fedora 30 Beta Workstation
Get Fedora 30 Beta Server
Get Fedora 30 Beta Silverblue

All of them are English language links

youtube footing has some links as well, these started appearing in French.

What I believe is that the programmer incorrectly used the French Keyboard layout to choose the display language, and not the language of firefox installation.

I am using Fedora 29

Expected results:

Sample output
Ce logiciel est en pré-version et est maintenu par le Workstation Working Group. Veuillez adresser vos questions à leur liste de diffusion ou #fedora-workstation sur freenode. Les problèmes rencontrés doivent être rapportés sur le Bugzilla Red Hat. Le Projet Fedora ne donne aucune garantie quant à son utilité ni à sa pertinence. Pour plus d’informations sur ses modifications et nouvelles fonctionnalités veuillez consulter les notes de version et la page recensant les anomalies courantes et la manière de les résoudre.

Expected output Web page is displayed in English.

Just tried FF on Tumbleweed. Same issue. Very annoying with youtube.com

Can you visit this page and copy and paste the ACCEPT_LANGUAGE row?
https://www.whatismybrowser.com/detect/what-http-headers-is-my-browser-sending

I expect you (or something on your system) set French as first language for web content. Keyboard layout is not involved in language negotiation.

Flags: needinfo?(lsatenstein)

What HTTP Headers is my browser sending?

Every time your web browser opens a web page, it sends a "request" for that page. Part of that request includes a series of "headers".

Here is the list of all the headers your browser sent when requesting this page.

There were 9 headers sent:
ACCEPT text/html,application/xhtml+xml,application/xml;q=0.9,/;q=0.8
ACCEPT_ENCODING gzip, deflate, br
ACCEPT_LANGUAGE en-CA,fr;q=0.5
DNT 1
HOST www.whatismybrowser.com
REFERER https://mail.yahoo.com/
TE trailers
UPGRADE_INSECURE_REQUESTS 1
USER_AGENT Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:66.0) Gecko/20100101 Firefox/66.0

These headers may vary from site to site (in particular the HOST and COOKIE headers!) depending on your settings.

If you're curious and want to learn more about HTTP (a protocol which the World Wide Web relies on) and HTTP Headers, please read the Wikipedia pages on Hypertext Transfer Protocol and List of HTTP header fields.
More questions?

If you have any more questions, use the contact form and we'll answer it and add your question here.

WHERE is fr;q=0.f coming from and how do I remove fr ? Its putting fr as first.
When I install second and third Linux distributions (Fedora(2), Suse(1), Manjaro(2), five locations, my browser is FF. I login and provide ff with the password to sync, and ff does the rest, it pulls in the address book and other settings that I know little to nothing about.

Flags: needinfo?(lsatenstein)

accept language row:
ACCEPT_LANGUAGE en-CA,fr;q=0.5

(In reply to Les. Satenstein from comment #5)

accept language row:
ACCEPT_LANGUAGE en-CA,fr;q=0.5

One more thing: open about:support (type it in the address bar, press enter).

And the end of the page there's a table called Internationalization & Localization. What's the value of "App locales"?

Even if you're using the en-CA build, the default accept language for that build is "en-CA, en-US, en", so I suspect something in your distribution is setting your accept-language header to those values.

If you open the Preferences, search for languages. You'll find "Choose your preferred language for displaying pages", and you can change your settings from there, and put English first.

Good morning Fransceso.
As requested.

Internationalization & Localization
Application Settings
Requested Locales ["en-CA"]
Available Locales ["en-CA","en-US"]
App Locales ["en-CA","en-US","und"]
Regional Preferences ["en-CA"]
Default Locale "und"
Operating System
System Locales ["en-CA"]
Regional Preferences ["en-CA"]

The following is some extra information for you

Just updated to 66.0.2 Fedora 29 Linux. The above is from the update.
It will also be showing up later today when I switch to 5 other Linux systems.
I do not use windows.

I don't see French in this internationalization group.
This version just updated to 66.0.2 and the problem / issue is present.

What about the default Locale, should it be set to "en-CA" ?

Here again is the heading test info for 66.0.2
ACCEPT_LANGUAGE en-CA,fr;q=0.5

I am in Montreal, Quebec. I am English in my corresponding, but I also speak read/write French and understand Spanish.
Do I have to wipe the cache in my $HOME/.mozilla

Here are some extra info.
/home/leslie/.mozilla/extensions
{3550f703-e582-4d05-9a08-453d09bdfdc6}
{ec8030f7-c20a-464f-9b0e-13a3a9e97384}

If you need a tar file of the contents, let me know.

Flags: needinfo?(francesco.lodolo)

The package from Fedora has

pref("intl.locale.requested",               "");

in ./usr/lib/firefox/browser/defaults/preferences/firefox-redhat-default-prefs.js.

Since your system is set to en-CA, and there's an en-CA language pack, you'll get Firefox en-CA. That doesn't really explain how you got French in accept-languages. I've double checked the language pack, and it contains the right value.

If you create a new profile in Firefox, does it get the same values?
https://support.mozilla.org/en-US/kb/profile-manager-create-and-remove-firefox-profiles

Flags: needinfo?(francesco.lodolo)

I disabled all addons and renamed the preferences. firefox created a new empty one, and the problem still persists.

I do not want to lose my bookmarks, and since I am signed in, I guess it is pulling thoat info down from somewhere.

You can simply fix your settings manually in your profile

If you open the Preferences, search for languages. You'll find "Choose your preferred language for displaying pages", and you can change your settings from there, and put English first.

I'm asking you to create a profile to check, you can go back to your existing profile afterwards.

I will rename the firefox .mozilla subdirectory and retry. I do want to first save my bookmarks.

I renamed .mozilla/firefox to .mozilla/.firefox (to make it hidden),
A new .mozilla/firefox was created and there is no problem.

I will login to sync with the new firefox just to confirm that the problem originates with the firefox archive download.
back later.

Summary

With a clean $HOME/.mozilla/firefox the problem has disappeared.
After logging in to Firefox to sync, the problem returns.

Firefox downloads my remembered bookmarks and other settings.
Therein is the error. And that error is why this bug has been raised.

Here is what I would like to do

If you need it to solve the problem, I can provide my logon and a password, you can become me.
Once you solve the problem, I will create a new password.

I'm afraid that's as far as I can help. I'll tentatively try to move this to Firefox::Sync, and see if someone can help there.

Component: Untriaged → Sync
Summary: Firefox is incorrectly using keyboard language to show web pages → Accept-language is changed when connecting to Sync

Removing French as the second language solved the problem.

I read French as my second language so I have French as a second language so Firefox will render the page correctly. I do not use it for correspondence. The problem is new, as my preferences have not changed in 12 years of firefox use.

I live in bilingual Quebec. I will initiate a sync and hopefully it gets propagated to the other Firefox

Something changed in the way FF treats second languages. It is putting them first. English is first and French was second, and that is the way it was until version 66.

It is a version 66 change

A final comment.
Thank you for your help. It is appreciated.

Prior to version 66, the system checked the language of the page being received, and always returned English for English sites.

There is a bug with some code revision made with version 66. It was ok with FF v 65.

Again, thank you for your help

The sync just is the propagator from one FF install to the other.

The sync just is the propagator from one FF install to the other.

Sync does indeed sync the intl.accept_languages pref, so if there's a value in there that's causing trouble then sync will propagate that trouble from device to device. Hopefully it will sync the fixed value around to all your devices (you can directly view the value that will be propagated, by entering "about:config" in your address bar and then searching for "intl.accept_languages").

Something changed in the way FF treats second languages. It is putting them first.
English is first and French was second, and that is the way it was until version 66.

If you put French back as a second language, does the problem return?

Flags: needinfo?(lsatenstein)

All is well that ends well.
Mark, thank you for following up.

Off topic but about FF. A recommendation

The menu and tool bars take up two lines and the tile panel/bar 1 line. I would like to merge the menu bar with the title panel. When I edit an email with yahoo.com My bcc list is 5 lines. It sometimes leaves me with only 3 lines for the response area.

F11, full screen is not the answer

Flags: needinfo?(lsatenstein)

Off topic but about FF. A recommendation ...

You will probably be better off filing another issue about that if you want (although it's a large change and I'm unsure how much traction you will get).

We're the sync team and have little say or opinion on non-sync related UI issues.

Worth noting you can turn either of those menu bars off if you want (Although I don't blame you for having them on).

Flags: needinfo?(markh)

Hi Les,
Thanks for reporting this issue and we're sorry you had this problem, but glad that you found the right preference to change and that everything now looks good.

Status: UNCONFIRMED → RESOLVED
Closed: 5 years ago
Flags: needinfo?(markh)
Resolution: --- → WORKSFORME

Please close

Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.