Closed Bug 1828390 Opened 2 years ago Closed 9 months ago

Update "myst_parser" to version 2.0

Categories

(Developer Infrastructure :: Firefox Source Docs: Content, defect)

defect

Tracking

(firefox125 fixed)

RESOLVED FIXED
Tracking Status
firefox125 --- fixed

People

(Reporter: jdescottes, Assigned: Sylvestre)

References

(Blocks 1 open bug, )

Details

Attachments

(1 file)

Examples:

Probably others?

How can we write those links to be properly rendered by Sphinx?

Summary: All `&` in URLs are encoded as `&amp%3B` leading to bad links → All `&` in URLs from markdown content are encoded as `&amp%3B` leading to bad links

The severity field is not set for this bug.
:Sylvestre, could you have a look please?

For more information, please visit BugBot documentation.

Flags: needinfo?(sledru)
Severity: -- → S2
Flags: needinfo?(sledru)
Blocks: 1878168

I wondered if URL (%) encoding these URLs would work, but it doesn't. With:

diff --git a/docs/bug-mgmt/processes/accessibility-review.md b/docs/bug-mgmt/processes/accessibility-review.md
index 3358defd7e3dc..47bc7e53521da 100644
--- a/docs/bug-mgmt/processes/accessibility-review.md
+++ b/docs/bug-mgmt/processes/accessibility-review.md
@@ -94,7 +94,7 @@ If you have any questions, please don't hesitate to contact the Accessibility
 team:
 
 * \#accessibility on
-  [Matrix](https://matrix.to/#/!jmuErVonajdNMbgdeY:mozilla.org?via=mozilla.org&via=matrix.org)
+  [Matrix](https://matrix.to/#/!jmuErVonajdNMbgdeY:mozilla.org?via=mozilla.org%26via=matrix.org)
   or [Slack](https://mozilla.slack.com/archives/C4E0W8B8E)
 * Email: accessibility@mozilla.com
 * Please avoid reaching out to individual team members directly -- containing review requests and questions in these channels helps us balance our workload. Thank you!

I get rendering like:

$ grep -i matrix ../objdirs/objdir-browser-compile/docs/html/bug-mgmt/processes/accessibility-review.html
<a class="reference external" href="https://matrix.to/#/!jmuErVonajdNMbgdeY:mozilla.org?via=mozilla.org%26via=matrix.org">Matrix</a>

But the browser doesn't interpret that URL as expected. :(

This is a known issue in myst_parser: https://github.com/executablebooks/MyST-Parser/issues/127.

A helpful soul suggested that this is addressed in newer myst_parser versions -- we're on 1.0 and the latest is 2.0.0.

Summary: All `&` in URLs from markdown content are encoded as `&amp%3B` leading to bad links → Update `myst_parser` to 2.0+ to avoid all `&` in URLs from markdown content being encoded as `&amp%3B` and leading to bad links

Hi Sylvestre, would an upgrade of myst_parser to at least version 2.0.0 be doable? It would fix quite a bit of broken links in our documentation. Thanks.

Flags: needinfo?(sledru)
Assignee: nobody → sledru
Status: NEW → ASSIGNED
Pushed by sledru@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/83d790607247 doc: upgrade to myst-parser 2.0 (fixes link issues) r=firefox-source-docs-reviewers,championshuttler DONTBUILD
Status: ASSIGNED → RESOLVED
Closed: 9 months ago
Resolution: --- → FIXED

(In reply to Nick Alexander :nalexander [he/him] from comment #3)

A helpful soul suggested that this is addressed in newer myst_parser versions -- we're on 1.0 and the latest is 2.0.0.

I actually do not see a change with the new 2.0.0 version. & is still not correctly encoded. Now when I take a look at the referenced GitHub issue I can actually see that the topic of it was around URLs within a table.

Nick, can you confirm that it also still not work for you? If not we should file a follow-up bug.

Flags: needinfo?(sledru) → needinfo?(nalexander)

The specific issue we have here is discussed at https://github.com/executablebooks/MyST-Parser/issues/760 and is still not resolved

Flags: needinfo?(nalexander)
Blocks: 1885098
See Also: → 1885098
See Also: 1885098

Lets then just make this bug about updating the myst_parser to version 2.0.

Summary: Update `myst_parser` to 2.0+ to avoid all `&` in URLs from markdown content being encoded as `&amp%3B` and leading to bad links → Update "myst_parser" to version 2.0
No longer blocks: 1878168

(In reply to Julian Descottes [:jdescottes] from comment #9)

The specific issue we have here is discussed at https://github.com/executablebooks/MyST-Parser/issues/760 and is still not resolved

Oh damn, sorry to mislead.

(In reply to Nick Alexander :nalexander [he/him] from comment #11)

Oh damn, sorry to mislead.

no worries, it is still relevant to upgrade it :)

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: