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

Avoid redirects in MPRester requests #3496

Merged
merged 1 commit into from
Dec 5, 2023
Merged

Avoid redirects in MPRester requests #3496

merged 1 commit into from
Dec 5, 2023

Conversation

tschaume
Copy link
Member

@tschaume tschaume commented Dec 5, 2023

add trailing slash to all MPRester requests to avoid unnecessary redirects

add trailing slash to all MPRester requests to avoid unnecessary redirects

Signed-off-by: Patrick Huck <[email protected]>
@janosh janosh changed the title avoid redirects Avoid redirects in MPRester requests Dec 5, 2023
@janosh janosh added performance Some functionality is too slow or regressed api Application programming interface labels Dec 5, 2023
Copy link
Member

@janosh janosh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @tschaume, I'll merge this as is. Do you think it's worth adding tests for this? We'd need to intercept HTTP requests and check the endpoint URL.

@janosh janosh merged commit 53aaa84 into master Dec 5, 2023
22 checks passed
@janosh janosh deleted the avoid-307s branch December 5, 2023 23:02
@tschaume
Copy link
Member Author

tschaume commented Dec 5, 2023

Thanks @janosh! Probably not worth adding tests for it. I'd suggest to either keep it in mind for any new MPRester.request() calls or to ensure that MPRester.request() always adds a trailing-slash.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api Application programming interface performance Some functionality is too slow or regressed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants