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
Fix linking to topic names containing multiple backticks with in-message markdown #19873
Comments
Some discussion in that chat thread. The complete fix is that we should replace Python-Markdown with some other Markdown implementation that has a saner architecture. That probably won't happen soon. A straightforward workaround would be for our autocompleters to not generate references that trigger this bug. Instead, they can fall back to generating the normal Markdown syntax for a link. As for when that fallback should apply: @andersk writes:
A rough cut would be to check if the stream name, topic, or (for @-mentions) user name contain any of a list of strings like |
A related issue: #6534 |
We should make sure this gets fixed as part of the expected migration to use Djot for markdown processing. |
Yes. There's also a straightforward fix we could implement without waiting for that, if we feel users are running into it too often:
|
@zulipbot claim |
The #**stream>topic** syntax generates broken links for topics containing two backticks or ending with *, because of architectural flaws in the backend markdown processor. So we avoid generating the syntax for such topics and instead generate the normal link syntax in markdown. Fixes zulip#19873
The #**stream>topic** syntax generates broken links for topics containing two backticks or ending with *, because of architectural flaws in the backend markdown processor. So we avoid generating the syntax for such topics and instead generate the normal link syntax in markdown. Fixes zulip#19873
The #**stream>topic** syntax generates broken links for topics containing two backticks or ending with *, because of architectural flaws in the backend markdown processor. So we avoid generating the syntax for such topics and instead generate the normal link syntax in markdown. Fixes zulip#19873
The #**stream>topic** syntax generates broken links for topics containing two backticks or ending with *, because of architectural flaws in the backend markdown processor. So we avoid generating the syntax for such topics and instead generate the normal link syntax in markdown. Fixes zulip#19873
The #**stream>topic** syntax generates broken links for topics containing two backticks or ending with *, because of architectural flaws in the backend markdown processor. So we avoid generating the syntax for such topics and instead generate the normal link syntax in markdown. Fixes zulip#19873
The #**stream>topic** syntax generates broken links for topics containing two backticks or ending with *, because of architectural flaws in the backend markdown processor. So we avoid generating the syntax for such topics and instead generate the normal link syntax in markdown. Fixes zulip#19873
The #**stream>topic** syntax generates broken links for topics containing two backticks or ending with *, because of architectural flaws in the backend markdown processor. So we avoid generating the syntax for such topics and instead generate the normal link syntax in markdown. Fixes zulip#19873
The following syntax (note the two backticks) to link to a topic will generate a corrupted link that does not point to the intended topic.
I don't understand the cause, but it's presumably some bad interaction between the code block functionality and this feature. Original report here: https://chat.zulip.org/#narrow/stream/9-issues/topic/broken.20topic.20link/near/1258861
I'm not sure what the best solution is. Banning backticks from topic names is an option, but perhaps a bad one, since this came up in real usage. Likely what we want is for this syntax to escape backticks, but I'm not sure how best to do that, given that this link generation feature doesn't have an already defined escape character.
The text was updated successfully, but these errors were encountered: