VisualEditor: {{NAMESPACE}} not running in context so doesn't know what namespace you're in
Closed, ResolvedPublic

Description

See https://en.wikipedia.org/wiki/Template:Userspace draft - when rendered in the VE it displays the mainspace appropriate text regardless of what namespace it is in.


Version: unspecified
Severity: minor

bzimport set Reference to bz50172.
Ironholds created this task.Via LegacyJun 25 2013, 12:42 PM
Jdforrester-WMF added a comment.Via ConduitJun 25 2013, 3:07 PM

By the time we get the template, the evaluation of the parser functions - in this case, {{NAMESPACE}} - has already been done (by Parsoid). In general, I believe that most parser functions are just "return true" at this point, and will be coming in future.

GWicke added a comment.Via ConduitJun 25 2013, 4:14 PM

We pass in the title to the PHP preprocessor, so namespace-dependent parserfunctions should work as expected. Are you talking about Parsoid rendering or the VE's preview rendering after inserting a new template?

GWicke added a comment.Via ConduitJul 2 2013, 1:24 AM

I'm guessing this is actually about newly inserted {{NAMESPACE}} calls:

http://www.mediawiki.org/wiki/User:GWicke/TestNamespace?veaction=edit

Reassigning to VE.

Jdforrester-WMF added a comment.Via ConduitJul 2 2013, 8:13 PM

This was originally about the Parsoid issue, which is now fixed, but re-purposing to be about the DM re-render to PHP parser issue.

Jdforrester-WMF added a comment.Via ConduitJul 2 2013, 8:14 PM
  • Bug 50582 has been marked as a duplicate of this bug. ***
jayvdb added a comment.Via ConduitOct 7 2013, 1:29 AM

Is this fixed?

When I look at this page which uses [[template:userspace draft]]:

https://en.wikipedia.org/wiki/User:JohnArmagh/Heads_of_Government_of_the_State_of_Victoria,_Australia?veaction=edit

The appropriate message is shown.

However part of that box should render as
"This draft was last edited 13 months ago"
but in VE is renders as
This draft was last edited 1 second's time"

which means {{REVISIONTIMESTAMP}} isnt expanding correctly as, based on the future tense, it is giving a value that is CURRENTTIME+1..?

Krenair added a comment.Via ConduitApr 19 2014, 1:53 PM

I think this was resolved in Gerrit change 127388

Add Comment

Column Prototype
This is a very early prototype of a persistent column. It is not expected to work yet, and leaving it open will activate other new features which will break things. Press "\" (backslash) on your keyboard to close it now.