Defect #30259

URLs end with "-" are rendered incorrectly in Textile

Added by Hirofumi Kadoya about 1 month ago. Updated 11 days ago.

Status:ConfirmedStart date:
Priority:NormalDue date:
Assignee:-% Done:


Category:Text formatting
Target version:Candidate for next minor release
Resolution: Affected version:


Last character "-" makes wrong link
please add link "-" character

for example googledrive use "-"


概要、説明、注記等で、URLリンクの最後の文字が "-"だった場合
グーグルドライブなどは、最終文字が "-" となることがあり、修正してほしいです


Screenshot 2018-12-21 at 16.30.09 - Display 1.png (21.8 KB) Hirofumi Kadoya, 2018-12-21 08:31

0001-Remove-unnecessary-trailing-white-spaces.patch Magnifier (23.6 KB) Yuichi HARADA, 2019-01-08 09:07

0002-Interpret-trailing-hyphens-as-URL.patch Magnifier (4.29 KB) Yuichi HARADA, 2019-01-08 09:07

output.trailing.special.characters.png (12.6 KB) Guillermo ML, 2019-01-10 14:32


#1 Updated by Go MAEDA about 1 month ago

  • Subject changed from Last character "-" makes wrong link to URLs end with "-" are rendered incorrectly in Textile
  • Description updated (diff)
  • Category set to Text formatting
  • Status changed from New to Confirmed

confirmed the problem. This issue is reproducible in Textile. Markdown is not affected.


Expected output:

<a class="external" href=""></a>

Actual output:

<a class="external" href=""></a>-

#2 Updated by Yuichi HARADA 13 days ago

I reviewed the regular expression to interpret the trailing hyphens as URL.
I attached patches.

#3 Updated by Go MAEDA 11 days ago

  • Target version set to Candidate for next minor release

#4 Updated by Guillermo ML 11 days ago

Same with ?, &, # and $ characters. These URL:$

will be rendered (3.4.4.stable) as:

For example the second link could be generated by glpi tool and the third one is sometimes generated by otrs tool. I think all four are valid characters at the end of an URL.

Also available in: Atom PDF