Markdown processor should not replace tokens like __foo__ inside links #13415

Closed
opened 2025-11-02 10:41:42 -06:00 by GiteaMirror · 2 comments
Owner

Originally created by @silverwind on GitHub (Aug 21, 2024).

Description

When a link contains text like __init__.py, the markdown processor will incorrectly bolden the text and break the link. The same link works fine on GitHub.

Gitea Version

main

Can you reproduce the bug on the Gitea demo site?

Yes

Screenshots

Gitea (https://demo.gitea.com/silverwind/symlink-test/issues/4):

image

GitHub (https://github.com/silverwind/symlink-test/issues/17):

image
Originally created by @silverwind on GitHub (Aug 21, 2024). ### Description When a link contains text like `__init__.py`, the markdown processor will incorrectly bolden the text and break the link. The same link works fine on GitHub. ### Gitea Version main ### Can you reproduce the bug on the Gitea demo site? Yes ### Screenshots Gitea (https://demo.gitea.com/silverwind/symlink-test/issues/4): <img width="208" alt="image" src="https://github.com/user-attachments/assets/98fbfca3-d551-4134-99e2-428b9b01b187"> GitHub (https://github.com/silverwind/symlink-test/issues/17): <img width="899" alt="image" src="https://github.com/user-attachments/assets/c7b4e7dc-ff5e-4f54-b28a-964928834cd3">
GiteaMirror added the type/bug label 2025-11-02 10:41:42 -06:00
Author
Owner

@wxiaoguang commented on GitHub (Aug 21, 2024):

The same report from 2021 : Formatting tokens in URLs should not be parsed #17958

@wxiaoguang commented on GitHub (Aug 21, 2024): The same report from 2021 : Formatting tokens in URLs should not be parsed #17958
Author
Owner

@silverwind commented on GitHub (Aug 21, 2024):

Right, it's a duplicate.

@silverwind commented on GitHub (Aug 21, 2024): Right, it's a duplicate.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/gitea#13415