Sanitize ANSI characters from generated RST#838
Merged
larsoner merged 3 commits intosphinx-gallery:masterfrom Jun 28, 2021
Merged
Sanitize ANSI characters from generated RST#838larsoner merged 3 commits intosphinx-gallery:masterfrom
larsoner merged 3 commits intosphinx-gallery:masterfrom
Conversation
Contributor
Author
|
@lucyleeow what do you think? Any guidance to add a test or anything you expect from me is very welcome |
Contributor
|
A test similar to (This is for my future reference: https://en.wikipedia.org/wiki/ANSI_escape_code) |
Contributor
Author
|
let me know what you think
… |
lucyleeow
approved these changes
Jun 27, 2021
Contributor
lucyleeow
left a comment
There was a problem hiding this comment.
LGTM! Just a note - we don't bother with the change log as we auto generate this from closed issues and merged PRs when doing the release.
Will wait a fews days to see if anyone else reviews, then merge!
Contributor
Author
|
I am sure @larsoner will be glad to review :) |
Contributor
|
Thanks @agramfort ! |
sdhiscocks
added a commit
to sdhiscocks/sphinx-gallery
that referenced
this pull request
Mar 10, 2023
This resolves an issue with HTML being ANSI sanitized, which can cause issues. For example, this breaks Plotly when rendering with plotly.min.js embedded, due to ANSI escape in JS code, causing plots to not be displayed. Relates to original sphinx-gallery#838
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
See the problem in the output block in https://braindecode.org/auto_examples/plot_sleep_staging.html#training
See all the
[36mwhich are otherwise used to get colors in the terminal.With this fix it looks much better !
cc @robintibor