Closed Bug 1241969 Opened 9 years ago Closed 6 years ago

Old Firefox page URL redirects according to the accepted languages preference in the browser even if the locale is specified in the URL

Categories

(www.mozilla.org :: General, defect)

Production
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED INVALID

People

(Reporter: mstanke, Unassigned)

References

(Blocks 1 open bug, )

Details

(Whiteboard: [kb=1945455])

Attachments

(1 file)

How to reproduce:
1. Have other than Czech language as preferred in your browser (e.g. en-US).
2. Visit https://www.mozilla.org/cs/firefox/, but affects all locales.
3. You're redirected to https://www.mozilla.org/en-US/firefox/new/.

Expected:
The redirection should lead to https://www.mozilla.org/cs/firefox/new/.
Thanks for the report
Whiteboard: [kb=1945455]
I can't reproduce the issue. If my preferred locale is Czech [cs], I'm redirected from /cs/firefox/ to /cs/firefox/new/.
Oh, you mean the redirect should happen based on the URL's locale suffix? Hmm...
Yes. I hope the already specified locale should be preserved regardless on the browser settings.
Can we get this fixed soon as it impacts almost all locales (didn't check all)? I can verify for zh-CN, and the dup bug was tested on lt.
Could it be this commit at fault: https://github.com/mozilla/bedrock/commit/22a2e276e506fad0b666106a0da80cd7db698739 ? Apart from dropping usage of `patterns`, it also added a `locale_prefix=False` param to a bunch of URL's, among which are /firefox/ and /firefox/channel/android/ I just tested the second link (by opening www.mozilla.org/ru/firefox/channel/android/), and it exhibits the same symptom: I ended up being redirected to www.mozilla.org/lt/firefox/channel/.
Attached file Github PR (deleted) —
Commits pushed to master at https://github.com/mozilla/bedrock

https://github.com/mozilla/bedrock/commit/2feac5cba40ccde68fd82baff63be61f12f87874
[Bug 1241969] don't ignore the requested language when opening /ab-CD/firefox/

Same applies to /ab-CD/firefox/channel/android/, so fixed it as well.

https://github.com/mozilla/bedrock/commit/93f588079766b95fd4334c842f863788d5bbb477
Merge pull request #4133 from rimas-kudelis/patch-1

[Bug 1241969] don't ignore the requested language when opening /ab-CD/firefox/
Commits pushed to master at https://github.com/mozilla/bedrock

https://github.com/mozilla/bedrock/commit/3b7b9966f84b3560a597b80a346922fb33d55912
Revert "[Bug 1241969] don't ignore the requested language when opening /ab-CD/firefox/"

https://github.com/mozilla/bedrock/commit/c47013d07fc17131c6b4279bf01b390f7185a18c
Merge pull request #4150 from mozilla/revert-4133-patch-1

Revert "[Bug 1241969] don't ignore the requested language when opening /ab-CD/firefox/"
(In reply to [github robot] from comment #10)
> Commits pushed to master at https://github.com/mozilla/bedrock
> 
> https://github.com/mozilla/bedrock/commit/
> 3b7b9966f84b3560a597b80a346922fb33d55912
> Revert "[Bug 1241969] don't ignore the requested language when opening
> /ab-CD/firefox/"
> 
> https://github.com/mozilla/bedrock/commit/
> c47013d07fc17131c6b4279bf01b390f7185a18c
> Merge pull request #4150 from mozilla/revert-4133-patch-1
> 
> Revert "[Bug 1241969] don't ignore the requested language when opening
> /ab-CD/firefox/"

After merging PR 4133, triggering and automatic deployment to dev, we found that it did not work as expected. For example, https://bedrock-dev.us-west.moz.works/it/firefox/ would still redirect to https://bedrock-dev.us-west.moz.works/en-US/firefox/new/ so I reverted the change.
The old URLs are already in use now, so it's not reproducible anymore.
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: