-
Notifications
You must be signed in to change notification settings - Fork 987
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refs #4478 - API doc strings marked for translation #1626
Conversation
@mbacovsky there are a couple of test failures due to the changed messages, but this one's puzzling me, I can't think why it'd change: http://ci.theforeman.org/job/test_develop_pr_core/1723/database=mysql,puppet=3.0,ruby=1.9.3/testReport/junit/%28root%29/Api__V2__HostsControllerTest/test_0029_when_a_bad__type_is_requested___unprocessable_entity_is_returned/ |
Same here. The method is returning: |
end | ||
rescue => e | ||
raise ::Foreman::Exception.new("A problem occurred when detecting host type: #{e.message}") | ||
raise ::Foreman::Exception.new(N_("A problem occurred when detecting host type: %s"), e.message) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@domcleal , the formatting of the message changed. The e.message
is now parameter of the message and not its part. Error codes are computed from the message without parameters so the code for this message is different. I fixed it in the tests. However I'm not sure if this is proper fix or if it violates some error codes rules somehow.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@mbacovsky ah ok, thanks. I think that's unavoidable for now, let's just change it. Maybe one day we can implement some kind of override for error codes so we can keep them static.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This case is a simple one - it was wrong and Martin fixed it, therefore the code must change. I'd rather fix the error code on the wiki than introducing overridable codes.
Thanks @mbacovsky, merged as 2656873 and Transifex updated. |
No description provided.