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

Replace string format by os.path.join wherever we want to create file paths #952

Open
BeritJanssen opened this issue Apr 15, 2024 · 0 comments
Assignees

Comments

@BeritJanssen
Copy link
Collaborator

BeritJanssen commented Apr 15, 2024

This surfaced in #950: the RELOAD_PARTICIPANT_URL had a leading slash in the production settings, leading to problems with social media sharing. We should go over all the places where format strings are used to create file paths or urls. For file paths, we can use os.path.join instead, which would avoid duplicating slashes, and make sure this also works on non-unix systems. For urls, there doesn't seem to be a standard library solution (urllib.parse provides some functionality but only works with full urls as far as I can tell).

@BeritJanssen BeritJanssen changed the title Replace string format by os.path.join wherever we want to create url or file paths Replace string format by os.path.join wherever we want to create file paths Jul 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants