[openstreetmap/openstreetmap-website] Forcing English language error response for /api/0.6/user/details (#2227)
mmd
notifications at github.com
Tue May 21 17:04:48 UTC 2019
After looking into the XML topic some more, I believe it's too expensive for this use case and given the effort involved, provides too little value.
In the meantime, I favor a solution, which gets rid of the I18N for blocked messages altogether and only returns the English text.
Reasons:
- API error messages are in English. Pretty much all of them.
- Currently, none of the translated blocked user messages ever reach a user UI, neither on osm.org, nor in any editor I checked (!)
- If editors wish to show a localized version of a blocked user message, they can do so at their own discretion.
The second point probably deserves a few words, which is I added a short analysis for setup_user_auth below:
- changesets_controller: only applies to anonymous changesets, concept no longer exists -> irrelevant
- old_controller: history+version for redacted versions: GET /api/0.6/object/* call without Authentication simply skips redacted versions. Only a call with successful authentication would return an error message for a blocked user.
- notes_controller: blocked user cannot add notes. Trying to post new notes via /note/new will trigger a POST to /api/0.6/notes.json, which returns with 403 and an error message. However, the UI doesn't handle the error message at all, and simply gets stuck, i.e. the user never sees the error message.
- permission_controller: only relevant for editors anyway, which are expected to handle error messages.
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/issues/2227#issuecomment-494476005
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20190521/7cb63fa3/attachment.html>
More information about the rails-dev
mailing list