Page MenuHomePhabricator

Initial parsing ( != PST parsing) of a newly created page should be done after the page is there
Open, LowPublic

Description

Test case:

Create a page [[Template:SelfA]] with the following content:

{{ {{PAGENAME}} | 0 }}

Create a page [[Template:TselfA]] with the following content:

{{ #if: {{{1|}}} | + | {{selfA}} }}

After saving of the second page, I see this on the page:

Template:TselfA

which is actually a selflink.

After purging I see:

+

which is expected on the first view.


Version: 1.20.x
Severity: normal

Details

Reference
bz35750

Event Timeline

bzimport raised the priority of this task from to Low.Nov 22 2014, 12:13 AM
bzimport set Reference to bz35750.
bzimport added a subscriber: Unknown Object (MLST).

Parsing needs to be done before save so that AbuseFilter and SpamBlacklist can reject the edit based on the parse results. It's possible to do parsing both before and after edit, and we do if you use {{REVISIONID:}}, but this doubles the save time and allows spam filtering to be bypassed.

(In reply to comment #1)

Parsing needs to be done before save so that AbuseFilter and SpamBlacklist can
reject the edit based on the parse results. It's possible to do parsing both
before and after edit, and we do if you use {{REVISIONID:}}, but this doubles
the save time and allows spam filtering to be bypassed.

Hmm from your comment I found another bug which is submitted as bug 35754.

A better solution can be to do initial parsing before saving but treat the page to parse as if it's there already in parsing progress.