Opened 11 months ago

Closed 10 months ago

Last modified 10 months ago

#13497 closed defect (fixed)

Symbol markup cannot be escaped

Reported by: Ryan J Ollos Owned by: Jun Omae
Priority: normal Component: WikiExtrasPlugin
Severity: normal Keywords:
Cc: Trac Release:


See TracDev/Proposals/VerticalHorizontalParsing@4.

The transformation of (C) to the copyright symbol can't be escaped using !(C).

Attachments (0)

Change History (4)

comment:1 Changed 11 months ago by Jun Omae

The result of prepare_regexp should be enclosed with (?: and ) but missing parentheses in tracwikiextras/

$ git grep 'prepare_regexp(' -- '*.py'
tracwikiextras/            yield (r"(?<!\w)!?(?:%s)" % prepare_regexp(self.smileys),
tracwikiextras/        yield ('!?(?:%s)' % prepare_regexp(self.text), self._format_phrase)
tracwikiextras/            yield ('!?%s' % prepare_regexp(self.symbols), self._format_symbol)
tracwikiextras/ prepare_regexp(d):
  • wikiextrasplugin/trunk/tracwikiextras/

    diff --git a/wikiextrasplugin/trunk/tracwikiextras/ b/wikiextrasplugin/trunk/tracwikiextras/
    index aa997828c..3563c09c2 100755
    a b class Symbols(Component): 
    119119                    del self.symbols[keyword]
    121121        if self.symbols:
    122             yield ('!?%s' % prepare_regexp(self.symbols), self._format_symbol)
     122            yield ('!?(?:%s)' % prepare_regexp(self.symbols),
     123                   self._format_symbol)
    123124        else:
    124125            yield (None, None)

comment:2 Changed 10 months ago by Ryan J Ollos

Thanks. If you can commit the change, I will go ahead and update the plugin on t.e.o.

comment:3 Changed 10 months ago by Jun Omae

Resolution: fixed
Status: newclosed

In 17307:

TracWikiExtras 1.3.1dev: fix unable to escape symbol markups (closes #13497)

comment:4 Changed 10 months ago by Jun Omae

Owner: changed from Mikael Relbe to Jun Omae

Modify Ticket

Change Properties
Set your email in Preferences
as closed The owner will remain Jun Omae.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment

E-mail address and name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.