Skip to content

Handle case where the frontend url already contains query parameters #366

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

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

PythonCoderAS
Copy link

To my knowledge, if there is a "?" in the URL, everything after is a query parameter, so we check for a "?" and if one does exist we use "&" instead of "?".

Fix #365

@CLAassistant
Copy link

CLAassistant commented Apr 8, 2025

CLA assistant check
All committers have signed the CLA.

@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@mostafa
Copy link
Member

mostafa commented Apr 8, 2025

How about using urllib? https://stackoverflow.com/a/64117554/6999563

@PythonCoderAS
Copy link
Author

How about using urllib? https://stackoverflow.com/a/64117554/6999563

Not necessarily because the frontend url might be a relative URL (ie "/login" and not "http://my-domain.com/login") which won't parse under urlparse

mostafa

This comment was marked as outdated.

@mostafa mostafa dismissed their stale review April 9, 2025 14:25

Coverage dropped. It would be nice to add a test.

@mostafa
Copy link
Member

mostafa commented Apr 9, 2025

@PythonCoderAS It would be nice if you could add a test as well.

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.

Does not properly add query params if next_url already contains query params
3 participants