Markdown not parsing certain TLDs #66550

Closed
opened 2019-07-08 11:06:19 +02:00 by Pablo Vazquez · 5 comments

Markdown parsing on comments or posts is not taking certain TLDs into account:

e.g:

Maybe others I'm missing.

Example: https://cloud.blender.org/blog/introducing-blender-sync#5d1cb4ad091a6635445b7c1c

Markdown parsing on comments or posts is not taking certain TLDs into account: e.g: * .chat - https://blender.chat * .today - https://blender.today * .cloud - https://blender.cloud * .fund - https://blender.fund Maybe others I'm missing. Example: https://cloud.blender.org/blog/introducing-blender-sync#5d1cb4ad091a6635445b7c1c
Sybren A. Stüvel was assigned by Pablo Vazquez 2019-07-08 11:06:19 +02:00
Author

Added subscriber: @pablovazquez

Added subscriber: @pablovazquez

I did a quick test with CommonMark, and it turns out it doesn't auto-link anything unless you use explicit markup:

Python 3.6.8 (tags/v3.6.8:3c6b436a57, Dec 24 2018, 00:16:47) [MSC v.1916 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import commonmark
>>> commonmark.commonmark('blender.org')

'<p>blender.org</p>\n'
>>> commonmark.commonmark('https://blender.org')

'<p>https://blender.org</p>\n'
>>> commonmark.commonmark('https://imgur.com/29WbUt8')

'<p>https://imgur.com/29WbUt8</p>\n'
>>> commonmark.commonmark('<https://blender.org>')

'<p><a href="https:*blender.org">https:*blender.org</a></p>\n'

So either we have some extra code (hiding from me right now) that handles the auto-linking, or people are using the <url> or [title](url) markup to get the links.

I did a quick test with CommonMark, and it turns out it doesn't auto-link anything unless you use explicit markup: ``` Python 3.6.8 (tags/v3.6.8:3c6b436a57, Dec 24 2018, 00:16:47) [MSC v.1916 64 bit (AMD64)] on win32 Type "help", "copyright", "credits" or "license" for more information. >>> import commonmark >>> commonmark.commonmark('blender.org') '<p>blender.org</p>\n' >>> commonmark.commonmark('https://blender.org') '<p>https://blender.org</p>\n' >>> commonmark.commonmark('https://imgur.com/29WbUt8') '<p>https://imgur.com/29WbUt8</p>\n' >>> commonmark.commonmark('<https://blender.org>') '<p><a href="https:*blender.org">https:*blender.org</a></p>\n' ``` So either we have some extra code (hiding from me right now) that handles the auto-linking, or people are using the `<url>` or `[title](url)` markup to get the links.
Sybren A. Stüvel removed their assignment 2019-10-17 12:24:04 +02:00

Added subscriber: @dr.sybren

Added subscriber: @dr.sybren
Author

Changed status from 'Confirmed' to: 'Resolved'

Changed status from 'Confirmed' to: 'Resolved'
Pablo Vazquez self-assigned this 2022-11-19 04:16:31 +01:00
Author

cloud.blender.org became studio.blender.org, running on a completely new system where this issue doesn't apply.

cloud.blender.org became studio.blender.org, running on a completely new system where this issue doesn't apply.
Sign in to join this conversation.
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: archive/pillar#66550
No description provided.