unwanted html links inserted
See original GitHub issueDescribe the bug
If a pattern resembling a URL occurs in the markdown of an ipynb file then it is tagged <a class="reference external">
in the built html and appears as a broken link, despite no link being requested in the markdown syntax (i.e. no []()
). This affects things like filenames, presumably because of the presence of the .
character.
Maybe this is a desired feature rather than a bug. But it seems like an undesirable one to have set by default. As far as I can find, it is also undocumented. A response to an old issue #1068 suggests that MyST markdown should not automatically hyperlink URLs.
Is this the work of the linkify myst extension? But the documentation on sphinx configuration claims that this extension is not enabled by default. Or is it maybe the result of the default setting myst_url_schemes: None
? In which case, what should this setting be in order to disable automatic recognition of URLs?
To Reproduce
- Clone this minimal example repo.
- Run
jupyter-book build a_short_book
. - View the file a_short_book/_build/html/page1.html.
- The phrase program.py is tagged as a link. (Though not my_program.py, the presence of an underscore seems to prevent it.)
Expected behavior
No html link should be inserted unless requested in the markdown. (Or failing that, the documentation should warn about this behavior).
Environment
- Python Version: 3.8.10
- Package versions or output of
jupyter-book --version
:- Jupyter Book: 0.11.1
- External ToC: 0.2.2
- MyST-Parser: 0.13.7
- MyST-NB: 0.12.3
- Sphinx Book Theme: 0.1.0
- Jupyter-Cache: 0.4.2
- NbClient: 0.5.3
- Operating System: Ubuntu 20.04.2
Issue Analytics
- State:
- Created 2 years ago
- Comments:7 (3 by maintainers)
yep: https://github.com/tsutsu3/linkify-it-py/blob/c7c62c5aef8bf116ce0ba0924e574f4d8ac84cf4/linkify_it/main.py#L217
Note: https://github.com/executablebooks/MyST-Parser/pull/464 adds the option to turn off fuzzy links.