You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Apr 26, 2024. It is now read-only.
spantaleev opened this issue
Dec 18, 2021
· 1 comment
Labels
P3(OBSOLETE: use S- labels.) Approved backlog: not yet scheduled, will accept patchesT-TaskRefactoring, removal, replacement, enabling or disabling functionality, other engineering tasks.
This is about the url_preview_accept_language setting, which seems to have a default value of ['en'].
This may be site-specific, but.. as an example, I find that doing curl -H 'Accept-Language: en' 'https://www.imdb.com/title/tt13207508/' | grep Schwanengesang yields a result for me ("Schwanengesang" being the German title of the "Swan Song" movie) when done from a German IP address.
A way to get it to stop IMDB from feeding me German content (when accessing it from a German IP address) is to use a different Accept-Language value. Both en-US and en-US, en seem to work well.
Given that browsers (Firefox, Chromium) seem to pass both {languageCode}-{countryCode} and {languageCode} at the same time, it's probably more reliable if Synapse does the same (sending Accept-Language: en-US, en).
Version information
Version: v1.49.0 seems affected by default
The text was updated successfully, but these errors were encountered:
spantaleev
added a commit
to spantaleev/matrix-docker-ansible-deploy
that referenced
this issue
Dec 18, 2021
Related to matrix-org/synapse#11604
Getting an upstream fix is preferable. In any case, it's probably nice
to have this defined explicitly in our configuration. This way, people
can more easily discover that they can override the URL preview
language.
Seems like it would be a reasonable change to make. Would you mind making a pull request to update the default/sample configuration(s)?
richvdh
changed the title
'Accept-Language: en' is less reliable than 'en-US, en'
URL preview should use Accept-Language: en-US, en by default
Dec 23, 2021
richvdh
added
P3
(OBSOLETE: use S- labels.) Approved backlog: not yet scheduled, will accept patches
T-Task
Refactoring, removal, replacement, enabling or disabling functionality, other engineering tasks.
labels
Dec 23, 2021
HarHarLinks
pushed a commit
to HarHarLinks/matrix-docker-ansible-deploy
that referenced
this issue
Feb 16, 2022
Related to matrix-org/synapse#11604
Getting an upstream fix is preferable. In any case, it's probably nice
to have this defined explicitly in our configuration. This way, people
can more easily discover that they can override the URL preview
language.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Labels
P3(OBSOLETE: use S- labels.) Approved backlog: not yet scheduled, will accept patchesT-TaskRefactoring, removal, replacement, enabling or disabling functionality, other engineering tasks.
Description
This is about the
url_preview_accept_language
setting, which seems to have a default value of['en']
.This may be site-specific, but.. as an example, I find that doing
curl -H 'Accept-Language: en' 'https://www.imdb.com/title/tt13207508/' | grep Schwanengesang
yields a result for me ("Schwanengesang" being the German title of the "Swan Song" movie) when done from a German IP address.A way to get it to stop IMDB from feeding me German content (when accessing it from a German IP address) is to use a different
Accept-Language
value. Bothen-US
anden-US, en
seem to work well.Given that browsers (Firefox, Chromium) seem to pass both
{languageCode}-{countryCode}
and{languageCode}
at the same time, it's probably more reliable if Synapse does the same (sendingAccept-Language: en-US, en
).Version information
The text was updated successfully, but these errors were encountered: