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

External link in TOC cannot contain "?" #4641

Closed
Silmathoron opened this issue Feb 18, 2018 · 3 comments
Closed

External link in TOC cannot contain "?" #4641

Silmathoron opened this issue Feb 18, 2018 · 3 comments

Comments

@Silmathoron
Copy link

Including external links in the TOC doesn't work if these links contain question marks (e.g. php).

Example

.. toctree::
   :glob:
   :maxdepth: 1
   :caption: Miscellaneous

   various/various
   GitHub <https://github.com/Silmathoron/>
   Other <https://duckduckgo.com/?q=sphinx+link+%22question+mark%22+toc&t=lm&ia=web>

The GitHub links works fine, but not the Other.

Error logs / results

WARNING: toctree glob pattern u'Other <https://duckduckgo.com/?q=sphinx+link+%22question+mark%22+toc&t=lm&ia=web>' didn't match any documents

Is there an already existing way to solve this? If not, is there a way to fix it

Environment info

  • OS: Linux Mint 18.3
  • Python version: 2.7.12
  • Sphinx version: 1.6.6 and 1.7
@tk0miya
Copy link
Member

tk0miya commented Feb 18, 2018

This comes from the combination of :glob: option and URL containing ?.
I fixed this in #4644.

@Silmathoron
Copy link
Author

Ok, looking forward to 1.7.1 then, thanks!

tk0miya added a commit to tk0miya/sphinx that referenced this issue Feb 19, 2018
tk0miya added a commit that referenced this issue Feb 19, 2018
Fix #4641: A external link in TOC cannot contain "?" with ``:glob:`` option
@tk0miya
Copy link
Member

tk0miya commented Feb 19, 2018

Now #4644 is merged.
Thank you for reporting!

@tk0miya tk0miya closed this as completed Feb 19, 2018
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 19, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants