Open-Assistant icon indicating copy to clipboard operation
Open-Assistant copied to clipboard

create prompt can be accessed through url, but keeps original language

Open iurimatias opened this issue 2 years ago • 1 comments

  1. go to a language in which prompt creation is available
  2. change url manually to add en like from https://open-assistant.io/es/create/initial_prompt to https://open-assistant.io/en/create/initial_prompt
  3. it redirects to https://open-assistant.io/create/initial_prompt
  4. click on dashboard

result: it seems to redirect to english but it's actually still in the previous section, problem is that this might then add prompts and reviews assuming the wrong language

iurimatias avatar Jan 28 '23 23:01 iurimatias

@fozziethebeat I am giving this issue priority urgent. Under certain circumstances it seems that the web-frontend sends requests to the backend with a lang-tag that does not match the currently active language. I discovered this when someone told me that he did not see any ranking tasks on our staging instance. Inspecting the logs showed that requests were send with lang="de" although on corresponding screenshots the language selector drop down was set to "English" (e.g. on the dashboard).

andreaskoepf avatar Jan 29 '23 14:01 andreaskoepf

Are people actually changing the language code via the URL?

With the localization framework we're using we have to figure out how to set the NEXT_LOCALE properly whenever someone manually goes to a different locale or make sure we're always including the url based locale to all requests.

fozziethebeat avatar Jan 30 '23 05:01 fozziethebeat

Figured out a fix. Testing and making PR now

fozziethebeat avatar Jan 30 '23 11:01 fozziethebeat