Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/sphinx_book_theme/header_buttons/launch.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ def add_launch_buttons(
# Any non-standard repository URL should be passed-through raw
if provider_url not in ["https://github.com", "https://gitlab.com"]:
# Generic git repository using the full repo URL as a fallback
url = f"{binderhub_url}/v2/git/{quote(repo_url)}/{branch}"
url = f"{binderhub_url}/v2/git/{quote(repo_url, safe='')}/{branch}"
elif provider.lower() == "github":
url = f"{binderhub_url}/v2/gh/{org}/{repo}/{branch}"
elif provider.lower() == "gitlab":
Expand Down
4 changes: 2 additions & 2 deletions tests/test_build/header__launch-buttons--bitbucket.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
section1/ntbk.html
https://mybinder.org/v2/git/https%3A//opensource.ncsa.illinois.edu/bitbucket/scm/u3d/3dutilities/foo?urlpath=tree/docs/section1/ntbk.ipynb
https://mybinder.org/v2/git/https%3A%2F%2Fopensource.ncsa.illinois.edu%2Fbitbucket%2Fscm%2Fu3d%2F3dutilities/foo?urlpath=tree/docs/section1/ntbk.ipynb
https://hub.myorg.edu/hub/user-redirect/git-pull?repo=https%3A//opensource.ncsa.illinois.edu/bitbucket/scm/u3d/3dutilities&urlpath=tree/3dutilities/docs/section1/ntbk.ipynb&branch=foo

section1/ntbkmd.html
https://mybinder.org/v2/git/https%3A//opensource.ncsa.illinois.edu/bitbucket/scm/u3d/3dutilities/foo?urlpath=tree/docs/section1/ntbkmd.md
https://mybinder.org/v2/git/https%3A%2F%2Fopensource.ncsa.illinois.edu%2Fbitbucket%2Fscm%2Fu3d%2F3dutilities/foo?urlpath=tree/docs/section1/ntbkmd.md
https://hub.myorg.edu/hub/user-redirect/git-pull?repo=https%3A//opensource.ncsa.illinois.edu/bitbucket/scm/u3d/3dutilities&urlpath=tree/3dutilities/docs/section1/ntbkmd.md&branch=foo
4 changes: 2 additions & 2 deletions tests/test_build/header__launch-buttons--gitlab_manual.html
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
section1/ntbk.html
https://mybinder.org/v2/git/https%3A//mywebsite.com/gitlab/gitlab-org/gitlab/foo?urlpath=tree/docs/section1/ntbk.ipynb
https://mybinder.org/v2/git/https%3A%2F%2Fmywebsite.com%2Fgitlab%2Fgitlab-org%2Fgitlab/foo?urlpath=tree/docs/section1/ntbk.ipynb
https://hub.myorg.edu/hub/user-redirect/git-pull?repo=https%3A//mywebsite.com/gitlab/gitlab-org/gitlab&urlpath=tree/gitlab/docs/section1/ntbk.ipynb&branch=foo

section1/ntbkmd.html
https://mybinder.org/v2/git/https%3A//mywebsite.com/gitlab/gitlab-org/gitlab/foo?urlpath=tree/docs/section1/ntbkmd.md
https://mybinder.org/v2/git/https%3A%2F%2Fmywebsite.com%2Fgitlab%2Fgitlab-org%2Fgitlab/foo?urlpath=tree/docs/section1/ntbkmd.md
https://hub.myorg.edu/hub/user-redirect/git-pull?repo=https%3A//mywebsite.com/gitlab/gitlab-org/gitlab&urlpath=tree/gitlab/docs/section1/ntbkmd.md&branch=foo