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

sphinx-book-theme option "repository_url" and "use_edit_page_button" bug with Gitlab button edit link #1310

Open
Sefran007 opened this issue Apr 27, 2021 · 7 comments
Labels
bug Something isn't working

Comments

@Sefran007
Copy link

**After activate "use_repository_button": True, "use_issues_button": True, with gitlab all working well. Only "use_edit_page_button": True, bug with Gitlab button edit link **

Sphinx html doc return bad link edit option :
https://github.com/utilisateur/initiation_developpement_python_pour_administrateur/edit/master/docs/sources-documents/index.rst

The correct link is :
http://gitlab.domaine-perso.fr/utilisateur/initiation_developpement_python_pour_administrateur/edit/master/docs/sources-documents/index.rst

Sphinx book theme don't replace https://github.com with http://gitlab.domaine-perso.fr

**File theme configuration with conf.py from sphinx :

html_theme = 'sphinx_book_theme'
html_theme_options = {
"repository_url": "http://gitlab.domaine-perso.fr/utilisateur/initiation_developpement_python_pour_administrateur",
"use_repository_button": True,
"use_issues_button": True,
"use_edit_page_button": True,
#"repository_branch": "master",
"path_to_docs": "docs/sources-documents",
"use_download_button": True,
"use_fullscreen_button": True,
"home_page_in_toc": False,
"toc_title": "Titre panneau latéral droite",
"extra_navbar": "

Mon HTML de navigation

",
}
html_title = "Documentation développement python pour l'administrateur"
html_logo = "images/logo.png"
html_favicon = "images/favicon.png"
**

Steps to reproduce the behavior:

  1. Go to Gitlab (Github ?) icon.
  2. Scroll down to "suggested modification"
  3. Click on suggested modification
  4. See link error

Click return correct URL http://gitlab.domaine-perso.fr/utilisateur/initiation_developpement_python_pour_administrateur/edit/master/docs/sources-documents/index.rst and replace https://github.com with http://gitlab.domaine-perso.fr

Environment

  • Python Version [3.9.4]:
  • Package version of sphinx-book-theme 0.1.0`:
  • Operating System: Kubuntu 21.04

Sphinx doc conf select to french langage

Gitlab is locally installed .

@Sefran007 Sefran007 added the bug Something isn't working label Apr 27, 2021
@welcome
Copy link

welcome bot commented Apr 27, 2021

Thanks for opening your first issue here! Engagement like this is essential for open source projects! 🤗

If you haven't done so already, check out EBP's Code of Conduct. Also, please try to follow the issue template as it helps other community members to contribute more effectively.

If your issue is a feature request, others may react to it, to raise its prominence (see Feature Voting).

Welcome to the EBP community! 🎉

@roblem
Copy link

roblem commented May 9, 2021

Seeing this as well, even with

repository:
  url: https://gitlab.com/username/project
  path_to_book: book  # An optional path to your book, defaults to repo root
html:
  # Launch button settings
  use_edit_page_button: true

in _config.yml

@NikosAlexandris
Copy link

With

repository:
  url: https://gitlab.com/username/project

and

html:
  use_edit_page_button      : true
  use_repository_button     : true
  use_issues_button         : true

The use_edit_page_button and use_repository_button work. The use_issues_button goes to github instead of gitlab.

@roblem
Copy link

roblem commented Aug 18, 2021

@NikosAlexandris for me on jupyter-book 0.11.2:

  • use_edit_page_button goes to github instead of gitlab
  • use_repository_button works
  • use_issues_button partially works. It opens an issue at the gitlab repo but fails to automatically populate the issue subject field with the page name as discussed in Open Issue button link that works for gitlab #1333

@NikosAlexandris
Copy link

* `use_issues_button` partially works.  It opens an issue at the gitlab repo but fails to automatically populate the issue subject field with the page name as discussed in

Indeed, same behavior here.

@fmfreeze
Copy link

fmfreeze commented Sep 1, 2022

Experiencing the same issue.

Has any of the developers any hint, where to dig into to solve this?
Especially the use_edit_page_button which links to github might be quite easy to solve, when knowing where to search for.

I would like to help, but no time to dive deep into this repo atm. At least it doesn't seem to be a simple hardcoded issue ':)

@siko1056
Copy link

Probably an upstream bug: executablebooks/sphinx-book-theme#418

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants