I believe there is a conflict between what Torbutton does and what is already included in Firefox. When I first denied to spoof the locale (twice), but later clicked on the corresponding box in the "General" part of about:preferences to set it to "on" ("spoof locale"), in this session the "accepted languages" seem to be changed to only include en-us/en. But after closing and restarting Tor Browser my locale (de) is included again, although the checkbox setting is not changed. I first noticed this when visiting trac.torproject.org. What is even more weird: When I uncheck the box to delete "German [de]", after a restart it is there again, independent of the setting of the checkbox.
This particularly affects Tails users who will see this every time they start Tor Browser in Tails. Besides, previously we could set extensions.torbutton.prompted_language to true and hide the prompt, but that does not work anymore (tried patching defaults/preferences/000-tor-browser.js in browser/omni.ja, prefs.js and user.js in the profile directory). Thankfully, by setting privacy.spoof_english to 2, at least we have only one prompt, but we ideally we want zero in Tails :)
I've tested this in a running Tails system with 8.0a9 (by applying your patches inside omni.ja and the torbutton xpi) and it worked just fine. Thanks!
Code review passes modulo a couple nitpicks:
website/design/design.xml and website/design/index.html.en still refer to the obsolete extensions.torbutton.spoof_english; this probably does not block merging these branches though since even without this fix, the corresponding sections were obsolete already (they don't mention the new Firefox locale spoofing feature that we now rely upon)
the localized torbutton.properties files still have torbutton.popup.prompted_language; maybe they're updated automatically later during the build or release process?
I'm not a Torbutton developer so even though I'm quite at ease with this part of the code, I'm leaving this is needs_review. Let me know if I should have been bold enough to make this merge_ready.
Thanks for the review (and it counts as one :) ). We don't use merge_ready, thus just leaving state is fine.
Regarding your two points:
The design doc currently specifies the state of Tor Browser 7.0. Once we update it to 8.0 mentioning the pref will be removed.
Yes, once we fetch the updated localized files they won't have the string in it anymore after it's gone in the en version. Thus, we are good here.
The torbutton commit got applied to master (e950aeac23670983bedd84c6526bb9a865450a25) and the tor-browser one to tor-browser-60.1.0esr-8.0-1 (49b80d55c275d4a59484b8e955d9d4eeac2d8d44), thanks!
Trac: Resolution: N/Ato fixed Status: needs_review to closed