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

fix: json attribute error for GET with parameters #477

Merged
merged 1 commit into from
Nov 7, 2024

Conversation

ehendrix23
Copy link
Contributor

When doing an API call for which the method is get but where parameters are provided an exception occurs for unknown attribute json=data.
This is due to the httpx get method not supporting the json parameter, instead the params parameter has to be provided.

This fixed checks if the method is get and if it is will provide the additional parameters through params parameter instead.

The httpx get method does not support the json parameter, instead the params parameter has to be provided.
@ehendrix23 ehendrix23 changed the title Fix json attribute error when calling API for a GET with parameters fix: json attribute error when calling API for a GET with parameters Nov 6, 2024
@ehendrix23
Copy link
Contributor Author

Fixed the title issue.

Not sure why 3.10 failed the test as I do not see how my small change would cause it to fail.

@alandtse alandtse changed the title fix: json attribute error when calling API for a GET with parameters fix: json attribute error for GET with parameters Nov 7, 2024
@alandtse alandtse merged commit 3f544e7 into zabuldon:dev Nov 7, 2024
2 of 5 checks passed
alandtse added a commit that referenced this pull request Nov 7, 2024
fix: json attribute error for GET with parameters (#477)
@ehendrix23 ehendrix23 deleted the patch-1 branch November 7, 2024 17:13
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.

2 participants