API does not translate errors based on Accept-Language header

Bug #1300939 reported by aeva black
16
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Ironic
Won't Fix
Low
Unassigned

Bug Description

the API service is missing a hook in the ParsableErrorMiddleware to translate error messages based on the client's Accept-Language header. Instead, all API messages are translated based on the system language setting.

Tags: i18n
aeva black (tenbrae)
Changed in ironic:
status: New → Triaged
importance: Undecided → Low
milestone: none → juno-1
tags: added: i18n
Haomeng,Wang (whaom)
Changed in ironic:
assignee: nobody → Haomeng,Wang (whaom)
Haomeng,Wang (whaom)
Changed in ironic:
status: Triaged → In Progress
Haomeng,Wang (whaom)
Changed in ironic:
assignee: Haomeng,Wang (whaom) → nobody
aeva black (tenbrae)
Changed in ironic:
status: In Progress → Triaged
aeva black (tenbrae)
Changed in ironic:
milestone: juno-1 → juno-2
aeva black (tenbrae)
Changed in ironic:
milestone: juno-2 → juno-3
Changed in ironic:
assignee: nobody → Jim Rollenhagen (jim-rollenhagen)
Thierry Carrez (ttx)
Changed in ironic:
milestone: juno-3 → juno-rc1
Revision history for this message
Dmitry Tantsur (divius) wrote :

Hi Jim! this bug is targeted to rc1 and you're assigned, but now patch was provided for nearly a month. Could you give some update on it?

Revision history for this message
aeva black (tenbrae) wrote :

Discussed with Jim as this is getting close to the RC1 deadline.

He raised the point that, since this only affects users where the client's locale is different from the servers, and Ironic's API should not be exposed outside of operations site anyway, this will probably have a very small impact on users. Given that, I don't feel we should block the release on this.

Changed in ironic:
milestone: juno-rc1 → none
status: Triaged → Confirmed
Revision history for this message
Haomeng,Wang (whaom) wrote :

Hi Jim

I had no idea to fix this issue, but I have interesting about the solution, would you please share your idea here? Thank you!

Revision history for this message
Haomeng,Wang (whaom) wrote :

And share some patch history for this issue:

 https://review.openstack.org/#/c/84362/

Revision history for this message
John Stafford (john-stafford) wrote :

This appears to be the same as https://bugs.launchpad.net/ironic/+bug/1436173

Revision history for this message
John Stafford (john-stafford) wrote :

4:09 PM <Haomeng> BadCub: for this one https://bugs.launchpad.net/ironic/+bug/1300939, I worked on it for long time, but not working and no soultion now , blocking at - https://bugs.launchpad.net/wsme/+bug/1256042, so I am not sure I can find new way to support lazy translation now, you can check https://review.openstack.org/#/c/84362/ for details

Changed in ironic:
milestone: none → kilo-rc1
milestone: kilo-rc1 → none
Changed in ironic:
assignee: Jim Rollenhagen (jim-rollenhagen) → nobody
Polly Zhou (polly-zhou)
Changed in ironic:
assignee: nobody → Polly Zhou (polly-zhou)
Polly Zhou (polly-zhou)
Changed in ironic:
assignee: Polly Zhou (polly-zhou) → nobody
Revision history for this message
Ruby Loo (rloo) wrote :

I checked and this is still a problem.

Changed in ironic:
status: Confirmed → Triaged
Revision history for this message
Dmitry Tantsur (divius) wrote :

Given the sad state of translations for Ironic, I think we can close this.

Changed in ironic:
status: Triaged → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.