Skip to content
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

respect the 'by_alias' route config also in generated docs for 'json body' data #1193

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

kristian-lindin
Copy link

if you have an alias_generator to_camel, the current behavior does not respect the by_alias config from the router when it comes to request body data and how the api documentation then is generated for that request body. Today the code that generates the request body docs, defaults to True without ever passing the operation.by_alias into the function.
This PR should correct that.

@vitalik
Copy link
Owner

vitalik commented Jun 26, 2024

Hi @kristian-lindin

Thank you for PR - could you also make a test case that covers this ?

kristian-lindin and others added 3 commits July 16, 2024 23:27
…the "by_alias" parameter.

Also ran "make format" that altered client.py and schema.py, since CI was complaning about the formating.
@kristian-lindin
Copy link
Author

I have added tests for it now. Feel free to check it out. I think the CI should succeed.

On another note: It seems like the "make lint" uses a ruff formatting that is incompatible with the formatting check on the CI.

@jboutros
Copy link

Hey @kristian-lindin this was super helpful for a similar issue I was facing, thanks!

@vitalik is there anything else this needs before it's ready to merge? Happy to assist if so.

@kristian-lindin
Copy link
Author

@vitalik Please let me know if there is anything else I can do to move this PR forward.

@kristian-lindin
Copy link
Author

@vitalik As mentioned, I feel like this PR should be ready. Let me know if I can do anything to get this PR to move forward or help in any way!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants