Template talk:REVISIONUSER
Appearance
Issue with Template:Revisionuser related to this template
[edit]This does not work within a template if used, so it would be better as a redlink. Example: {{talkback|{{revisionuser}}}} returns this error:
Hello, REVISIONUSER. You have new messages at [[User talk:{{revisionuser}}|User talk:{{revisionuser}}]].
You can remove this notice at any time by removing the {{Talkback}} or {{Tb}} template.
You can remove this notice at any time by removing the {{Talkback}} or {{Tb}} template.
but {{talkback|{{REVISIONUSER}}}} (not using the redirect) works properly
Hello, REVISIONUSER. You have new messages at Zinnober9's talk page.
You can remove this notice at any time by removing the {{Talkback}} or {{Tb}} template.
You can remove this notice at any time by removing the {{Talkback}} or {{Tb}} template.
Oiyarbepsy (talk) 20:10, 8 September 2014 (UTC)
- Why would you ever use
{{REVISIONUSER}}
inside{{talkback}}
?{{REVISIONUSER}}
gives the name of the person who last edited the page, not the person who added the template. See how the demo above has changed now that I have edited this page. --Redrose64 (talk) 21:27, 8 September 2014 (UTC)- I can only think of one use case, if I really think of trying to find a problem this might be a solution to. If your username was more than 22 characters long (which, although is pushing the limit, there are a few out there), then it would be less keystrokes to type out {{subst:REVISIONUSER}} than the full username. This might be useful when editing from a mobile device where pushing keys can be a pain. However, like I said in my opening sentence, I really had to dig deep for this, and I'm not sure why that would be used instead of just a three or four tilde signature... — {{U|Technical 13}} (e • t • c) 15:32, 11 November 2014 (UTC)
- @Technical 13: That's a use case for {{subst:REVISIONUSER}}, which I knew existed. I still don't think there are any for {{REVISIONUSER}} inside talkbacks though. Jackmcbarn (talk) 16:03, 11 November 2014 (UTC)
- Jackmcbarn, I'm not going to debate how the magic word/template is used with you here, as it is just not worth it. My point was just that there is a very small use-case for using Template:REVISIONUSER inside of {{Tb}}, and the same result can (and actually will) be achieved with just the magic word. — {{U|Technical 13}} (e • t • c) 16:28, 11 November 2014 (UTC)
- @Technical 13: That's a use case for {{subst:REVISIONUSER}}, which I knew existed. I still don't think there are any for {{REVISIONUSER}} inside talkbacks though. Jackmcbarn (talk) 16:03, 11 November 2014 (UTC)
- I can only think of one use case, if I really think of trying to find a problem this might be a solution to. If your username was more than 22 characters long (which, although is pushing the limit, there are a few out there), then it would be less keystrokes to type out {{subst:REVISIONUSER}} than the full username. This might be useful when editing from a mobile device where pushing keys can be a pain. However, like I said in my opening sentence, I really had to dig deep for this, and I'm not sure why that would be used instead of just a three or four tilde signature... — {{U|Technical 13}} (e • t • c) 15:32, 11 November 2014 (UTC)
Keep. No rationale provided for deletion; the nomination is essentially a request to improve the functionality of the template. This discussion should take place on the template's talk page. In fact, I would go to a length to say that this discussion should be closed to "wrong venue". Steel1943 (talk) 22:21, 8 September 2014 (UTC)
On a completely unrelated note, I am now going to enjoy being easily amused as the user name displayed in{{talkback|{{REVISIONUSER}}}}
is the most recent editor of this page. Steel1943 (talk) 22:28, 8 September 2014 (UTC)
- Hmmm... honestly, I'm having a hard time recalling my exact thought process, and the lowercase redirect was just an afterthought. Given that it was just a redirect, I'm surprised Template:revisionuser returned a blank text when I transclude it here when the capitalized version works. I ought to try to understand the bug, but out of laziness I've just copied the single-line contents of the target template into this one, so hopefully that will be the end of the bugs. (I should note I ended up removing the RfD template from the page though, because it gives a message that it can't find the redirect in it now that there's not a redirect in it) ---- erm, except, that didn't fix it! Hmmmm, time to have another look... OK, the thing was, if it was just {{REVISIONUSER}}, with no parameters, it would go to the built-in function, not the template. But the lowercase version was running the template, with no parameters, i.e. {{REVISIONUSER:}}. So I put an #if into the lowercase version. I'm not going to touch the uppercase version lest I am still confused and foul it up, because some pages actually use that. Wnt (talk) 22:53, 8 September 2014 (UTC)
- @Wnt: Looks good! ... But now, the edits essentially make Template:Revisionuser eligible for speedy deletion criterion T3. I think another editor, Jackmcbarn, recently dealt with something like this, so I'm pinging them to see if there's a better way to resolve the issue with Template:Revisionuser rather than making it a duplicate of Template:REVISIONUSER. (I'm thinking that the main template, {{REVISIONUSER}} may need to be converted to a module to prevent issues with redirects.) Steel1943 (talk) 23:56, 8 September 2014 (UTC)
- Also, pinging Oiyarbepsy and Redrose64 to let them know that the discussion regarding Template:Revisionuser moved here. Steel1943 (talk) 23:59, 8 September 2014 (UTC)
- Template:Revisionuser definitely should not exist. Arguably, Template:REVISIONUSER shouldn't either. The only purpose either of them serve is to make things not break when someone uses a pipe instead of a colon when calling it. Also, the reason that {{REVISIONUSER}} works and {{Revisionuser}} doesn't is because {{REVISIONUSER}} is calling the magic word REVISIONUSER, not the template. Jackmcbarn (talk) 00:05, 9 September 2014 (UTC)
- @Jackmcbarn: the purpose of {{REVISIONUSER}} with arguments was to allow a Lua module to use expandTemplate to get at this function without a full frame:preprocess. There might well be a different way to do it. I don't even really recall why I was doing it at this point, but it's in use. I could add the #if to {{REVISIONUSER}} and make {{revisionuser}} a redirect again, but that involves putting the actual uses of the template through an unnecessary #if. Honestly I didn't think the lowercase page hurts anything, but I'm not going to waste any more time arguing about a redirect/template that isn't even being used and shouldn't even be used; I only debugged it because, well, it was bugged. It would ultimately be most useful to create a Lua function (or better document it) that allows any arbitrary magic word like {{REVISIONUSER}} to be accessed efficiently. Wnt (talk) 00:46, 9 September 2014 (UTC)
- @Wnt: I already fixed that module to not need that anymore. Jackmcbarn (talk) 00:52, 9 September 2014 (UTC)
- @Jackmcbarn: Ummm, which module was that? I honestly can't remember, and "what links here" never seems to get me far with modules. Wnt (talk) 00:58, 9 September 2014 (UTC)
- Oh, I think it's Module:Related changes. Which seems out of use and now has a bug in it in (!) Module:Documentation. Which is a bit remarkable at first sight because it doesn't import anything and there's no line in my module given for the script error! Oh, but the documentation page does exist (its display is bugged at the module) at [1] and its test case works, so thanks! Wnt (talk) 01:08, 9 September 2014 (UTC)
- It's not really a bug in Module:Documentation. Your module is exceeding parser limits, and just about every module goes sideways when you exceed parser limits. Jackmcbarn (talk) 01:15, 9 September 2014 (UTC)
- Really? I didn't see any message about parser limits, it was a message about concatenating a nil because line 828 of Module:Documentation returns a nil if one of four different things it expects to find is missing. -- oh, I see now on preview it's saying there are too many expensive parser calls. Wnt (talk) 01:25, 9 September 2014 (UTC)
- It's not really a bug in Module:Documentation. Your module is exceeding parser limits, and just about every module goes sideways when you exceed parser limits. Jackmcbarn (talk) 01:15, 9 September 2014 (UTC)
- @Wnt: I already fixed that module to not need that anymore. Jackmcbarn (talk) 00:52, 9 September 2014 (UTC)
- @Jackmcbarn: The reason we should have pages at pages like Template:REVISIONUSER is for those editors who might not know it's a magic word. At the very least, these pages need to transclude a documentation subpage to explain to editors that this is not technically a template but a magic word, as well as what it returns and how to use it. Oiyarbepsy (talk) 04:19, 10 September 2014 (UTC)
- @Oiyarbepsy: In that case, it should be full of dire warnings and a tracking category, like Template:FULLPAGENAME is. Jackmcbarn (talk) 11:55, 10 September 2014 (UTC)
- @Jackmcbarn: Exactly. I modified the documentation page, changing the "few transclusions" message to a message that there should be none, and adding enough text so that the uninitiated can get a basic understanding of magic words. Oiyarbepsy (talk) 14:40, 10 September 2014 (UTC)
- Template:Revisionuser should still be deleted though. We don't have Template:Basepagename, etc. Jackmcbarn (talk) 14:49, 10 September 2014 (UTC)
- @Jackmcbarn: with that reasoning, as I stated above, Template:Revisionuser should, in theory, be eligible for speedy deletion criterion T3. However, due to its previous history as a redirect, I believe that the speedy deletion would righteously get denied. With your reasoning, if Template:Revisionuser were to be nominated for WP:TFD or reconverted into a redirect and then renominated for WP:RFD, I'd support deletion due to the technical problems with redirects to Template:REVISIONUSER, as explained above. Steel1943 (talk) 14:54, 10 September 2014 (UTC)
- I need a damn clarification. REVISIONUSER previously, pointed to the user viewing the particular template, but now, it points to the user who last edited the page. What is going on? --Ankit Maity «T § C» 17:57, 10 November 2014 (UTC)
- @Ankit Maity: That was (1) a really long time ago, (2) a bug rather than a feature, (3) only functional on interface pages, not regular templates, and (4) not at all relevant to this template or any redirects to it. Jackmcbarn (talk) 05:15, 11 November 2014 (UTC)
- I need a damn clarification. REVISIONUSER previously, pointed to the user viewing the particular template, but now, it points to the user who last edited the page. What is going on? --Ankit Maity «T § C» 17:57, 10 November 2014 (UTC)
- @Jackmcbarn: with that reasoning, as I stated above, Template:Revisionuser should, in theory, be eligible for speedy deletion criterion T3. However, due to its previous history as a redirect, I believe that the speedy deletion would righteously get denied. With your reasoning, if Template:Revisionuser were to be nominated for WP:TFD or reconverted into a redirect and then renominated for WP:RFD, I'd support deletion due to the technical problems with redirects to Template:REVISIONUSER, as explained above. Steel1943 (talk) 14:54, 10 September 2014 (UTC)
- Template:Revisionuser should still be deleted though. We don't have Template:Basepagename, etc. Jackmcbarn (talk) 14:49, 10 September 2014 (UTC)
- @Jackmcbarn: Exactly. I modified the documentation page, changing the "few transclusions" message to a message that there should be none, and adding enough text so that the uninitiated can get a basic understanding of magic words. Oiyarbepsy (talk) 14:40, 10 September 2014 (UTC)
- @Oiyarbepsy: In that case, it should be full of dire warnings and a tracking category, like Template:FULLPAGENAME is. Jackmcbarn (talk) 11:55, 10 September 2014 (UTC)
- @Jackmcbarn: the purpose of {{REVISIONUSER}} with arguments was to allow a Lua module to use expandTemplate to get at this function without a full frame:preprocess. There might well be a different way to do it. I don't even really recall why I was doing it at this point, but it's in use. I could add the #if to {{REVISIONUSER}} and make {{revisionuser}} a redirect again, but that involves putting the actual uses of the template through an unnecessary #if. Honestly I didn't think the lowercase page hurts anything, but I'm not going to waste any more time arguing about a redirect/template that isn't even being used and shouldn't even be used; I only debugged it because, well, it was bugged. It would ultimately be most useful to create a Lua function (or better document it) that allows any arbitrary magic word like {{REVISIONUSER}} to be accessed efficiently. Wnt (talk) 00:46, 9 September 2014 (UTC)
- Template:Revisionuser definitely should not exist. Arguably, Template:REVISIONUSER shouldn't either. The only purpose either of them serve is to make things not break when someone uses a pipe instead of a colon when calling it. Also, the reason that {{REVISIONUSER}} works and {{Revisionuser}} doesn't is because {{REVISIONUSER}} is calling the magic word REVISIONUSER, not the template. Jackmcbarn (talk) 00:05, 9 September 2014 (UTC)
It worked appreciably on my editnotice, though. xD And, congrats on getting a mop. --Ankit Maity «T § C» 14:32, 11 November 2014 (UTC)
- The use of {{REVISIONUSER}} (note, the variable and not this template) in editnotices to display the name of the person currently editing the page relied on the same bug that Jackmcbarn mentioned at 05:15, 11 November 2014; it stopped "working" in editnotices at the same time that it stopped "working" in interface pages. This was with the release of MediaWiki 1.18 in early October 2011, but certainly no later than 6 October. --Redrose64 (talk) 01:05, 12 November 2014 (UTC)