-
Notifications
You must be signed in to change notification settings - Fork 19
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
no 400 default response #31
base: master
Are you sure you want to change the base?
Conversation
Signed-off-by: Gaetan Semet <[email protected]>
c6f7258
to
175160a
Compare
@stibbons it's pretty guaranteed that it's possible to get a 400 response from a transmute API, as any violation of the schema will return that back as an error code. How about an optional flag in the decorator instead? Or one can do global switches by modifying either the global (or passing in a new instance) of transmutecontext |
Agree with the optional flag |
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.
The code looks good, but I think you'll need to pipe that config through @Describe, by adding that option to TransmuteAttribute:
https://github.com/toumorokoshi/transmute-core/blob/master/transmute_core/decorators.py#L35
https://github.com/toumorokoshi/transmute-core/blob/master/transmute_core/attributes/__init__.py#L7
That gets wired into TransmuteFunction, which can then pull fields from that attributes struct and apply it to itself:
Also a unit test on this would be great!
No description provided.