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

Convert error .ngscript to .html #2144

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
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
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -1586,6 +1586,7 @@ raw template
{%- endblock in_prompt -%}
"""


exporter_attr = AttrExporter()
output_attr, _ = exporter_attr.from_notebook_node(nb)
assert "raw template" in output_attr
Expand Down
3 changes: 2 additions & 1 deletion nbconvert/filters/markdown_mistune.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
import os
from html import escape
from typing import Any, Callable, Dict, Iterable, Match, Optional, Tuple
from urllib.parse import unquote

import bs4
from pygments import highlight
Expand Down Expand Up @@ -383,7 +384,7 @@ def _embed_image_or_attachment(self, src: str) -> str:

attachment_prefix = "attachment:"
if src.startswith(attachment_prefix):
name = src[len(attachment_prefix) :]
name = unquote(src[len(attachment_prefix) :])

if name not in self.attachments:
msg = f"missing attachment: {name}"
Expand Down
Loading