Skip to content

Bug or not? Input-variables of type JSON #586

Answered by rafalp
taffit asked this question in Q&A
Discussion options

You must be logged in to vote

IMHO this is a bug

I'll say its a limitation and design decision. Decorator was designed to be simple, fast, and work in most of cases.

Ofc we could roll in something super complex that introspects the schema, but that would grow up the complexity by a great deal, and I don't see much value when I compare gains to new maintenance burden.

IMHO you are missing alternative no. 4: roll in your own convert_kwargs_to_snake_case fork that takes extra argument (exclude=) that lets you explicitly disable given variables, eg:

@convert_kwargs_to_snake_case(exclude=["input.raw_data"])
def resolve_smthing(*_, id, input):
    ...

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by taffit
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants