This page is within the scope of WikiProject Redirect, a collaborative effort to improve the standard of redirects and their categorization on Wikipedia. If you would like to participate, please visit the project page, where you can join the discussion and see a list of open tasks. Note: This banner should be placed on the talk pages of project, template and category pages that exist and operate to maintain redirects. This banner is not designed to be placed on the talk pages of most redirects and almost never on the talk pages of mainspace redirects. For more information see the template documentation.RedirectWikipedia:WikiProject RedirectTemplate:WikiProject Redirectredirect
You'll see that %% shows up at the top of the main-namespace link. I think the only one that is supposed to be on that list (in the first 50) is Icelandic alphabet. I recall that being there before and have not taken the time to debug it. The others you can make go away by doing null edits (unless they use the sandbox). Wbm1058 (talk) 23:57, 3 July 2014 (UTC)[reply]
I found the code in the sandbox that caused the error; however, all the code did was to produce its own error when the rcat tags a redirect in any other namespace besides mainspace and project namespace. This whispers to me that there may be a problem with {{Error}} if it doesn't show any kind of error box or message on the redirect, and it shows it's "mysteriously" transcluded. Something's up – let me make some checks. (Also found several "Unicodes" here in project space.)– Paine01:01, 4 July 2014 (UTC)[reply]
Okay, Wbm1058, how well-versed are you in the Lua module code? The challenge seems to lie in the new, beta version of the {{Category handler}} template. I tested the old template wikimarkup in the Template:Category handler/sandbox (check Template:R from Unicode/sandbox) and the old markup does not produce the errors you found. It's only when the beta version of cat handler, which uses Module:Category handler, is transcluded to the rcat sandbox that the error is generated. Can you fix this? (I am Lua code-poor, myself) or should we seek help? – Paine08:32, 4 July 2014 (UTC)[reply]
PS. (This may be unlikely, though, since the cat handler sandbox also calls these.)
PPS. It may save some time to mention that I tried a workaround by use of cat handler's 2nd parameter, i.e., I set 2={{IRT|[[WP:Mainspace|main]]|[[WP:Project namespace|Wikipedia]]}} and other=2, but that also generated the error you found. PS & PPS left by – Paine
Since the category handler template and module have been stable since last October, I doubt that they are the problem here. Looking at this diff the problem would seem to be in the highlighted text that was removed, more specifically I see that template:Incorrect redirect template can transclude {{error}}s, so I think that's probably the template that needs to be fixed, or something is transcluding {{Incorrect redirect template}} when nothing is incorrect. Wbm1058 (talk) 16:03, 4 July 2014 (UTC)[reply]
Yes, the IRT uses {{Error}}, but it is only called when the rcat is used to tag a redirect in any other namespace than main and project. It is not called if the redirect is in one of those two namespaces. You don't think it's suspicious that the sandbox version of the cat handler, which has the old template wikimarkup code, works just fine and does not return the error, but the new beta version that invokes the module does return the error? – Paine EllsworthCLIMAX!20:36, 4 July 2014 (UTC)[reply]
@Wbm1058 and Paine Ellsworth: Sorry, what? I'm afraid I don't quite understand what the issue here is. All parameters are expanded before they are passed to Lua, so it doesn't matter if a template transclusion is part of a parameter. All Lua sees is the expanded wikitext. I gather that something is happening with Module:Category handler that didn't happen with the old Template:Category handler, but I'm not sure exactly what that is. Can you point me to an example, or construct a minimal test case for me if you have managed to pin down the issue far enough? — Mr. Stradivarius♪ talk ♪15:18, 5 July 2014 (UTC)[reply]
Hi, Mr. S. – I found that the {{R from Unicode}} rcat, which uses the cat handler to cat in the main and Wikipedia namespaces, was not showing an error box in the other namespaces to let editors know not to tag redirects in those namespaces. I tested the {{Incorrect redirect template}} in the "other=" param to generate the error box and to sort those redirects to Category:Pages with templates in the wrong namespace. After tests, I applied the change to the live template. Wbm1058 caught an error while monitoring this page. Scratched my head several times and found that somehow the cat handler module allows those errors to occur in both the main and Wikipedia namespaces, but with no other error indication on the redirects themselves. I put the cat handler's previously used template code in the cat handler sandbox and found that the template code works as it should. I used the %% redirect to test this. When the cat handler's sandbox is used in the Unicode rcat, the % redirect disappears from the Error template's transclusion-list page. If I go back to the cat handler module (erase /sandbox from the Unicode rcat), then the % redirect reappears on the Error template's transclusion-list page. Something does seem amiss with the way the cat handler module's "other" param is behaving. Since I am still Lua-poor, I am unable to pinpoint the error in the module code, which might actually be generated elsewhere from an associated source. In any case, we are unable to use the Incorrect redirect template in the live Unicode rcat, because that would just fill up the Error template's transclusion-list page – again. The Unicode symbols that are now on that list can be erased by null edits. Help! – Paine EllsworthCLIMAX!16:07, 5 July 2014 (UTC)[reply]
(edit conflict) Ok, I've found the cause. So basically, we are calling category handler with code like this: {{Category handler|1=Some category|main=1|other={{Error|Error we don't want to be transcluded.}}}} Following the logic through in the old Template:Category handler, the "other" parameter never gets expanded. This is thanks to User:David Göthberg's elegant and economical template design, which only uses parameters if they have to be used. Unfortunately, my module isn't so clever, and all the parameters get expanded right at the start with the code starting on line 274:
fork,vinpairs(origArgs)do-- ...end
This means that parameters are expanded in the Lua whether or not they are actually used to generate the template output. And it is the act of expanding the "other" parameter, not the act of showing it in the module output, that makes it labled as a transclusion. This can be fixed, but it will require re-engineering of the module, so don't expect it to start working overnight. I'll try and look at it when I next have a chance. — Mr. Stradivarius♪ talk ♪16:33, 5 July 2014 (UTC)[reply]
fork,vinpairs(origArgs)doiftype(v)=='string'thenv=mw.text.trim(v)-- Trim whitespace.end
Since I don't have line numbers, I don't know to which of these you refer. I had wondered if it might be just a matter of the inclusion of one more line, as in:
But I really don't have a clue, do I! Might mean that you have a fairly teejus job of configgin' ahead?– Paine18:08, 5 July 2014 (UTC)[reply]
It's the second one, although there is a chance that the first one will expand the "other" argument depending on which one is listed first in the template invocation, so I'll rewrite that as well. The basic fix for this is to switch the module to use Module:Arguments, which allows the arguments to only be expanded when necessary. The main algorithms shouldn't need to be changed, although I will have to go through and check them. The thing is that I've also had a request that the title blacklist matching should be cached per page rather than generated for every #invoke, and the test cases need rewriting too. It's best to do all of these at once, but it isn't a small job. — Mr. Stradivarius♪ talk ♪02:15, 6 July 2014 (UTC)[reply]
Can't thank you enough, Mr. S! Regarding the tests at Module talk:Category handler/testcases, can we assume that the green check marks to the left indicate a pass, and that the only time the two right columns might have entries are when one or more tests fail? Thank you for all your work on this! For me, it's like watching an astronaut perform an EVA with the Earth's curvature in the background. I have no idea what he or she is doing, but I'm thoroughly impressed with the procedure and outcome. I'll be happy to re-introduce the error code to the Unicorn rcat as soon as you enliven the module with the sandbox code you wrote. Again, thank you for all this; I believe I'm beginning to get a very fundamental and basic inkling of Lua. – Paine09:07, 8 July 2014 (UTC)[reply]
You're welcome. :) And you're right about the test cases; the second and third columns only display anything if there is an error. That's so that if there is an error, it's easy to tell at a glance what and where it is. — Mr. Stradivarius♪ talk ♪11:19, 8 July 2014 (UTC)[reply]
To Mr. Stradivarius – I just noticed this anomaly and wonder if it's related to the above? I checked this rcat on several types (namespaces) of redirects and it works just fine on redirects, but for some reason that large red-print "error"(?) appears in the alphabetical index. – Paine07:08, 18 June 2015 (UTC)[reply]
Sometimes the categories give only "skeletal" explanations and other times they give more information than the rcats. I have added the |to= information to the category's page. The correct answer is now given by both the rcat and the category page. Thank you, Gorobay, for catching and questioning this! Temporal SunshinePaine01:08, 10 August 2016 (UTC)[reply]
I had thought the point was to list all code points that were redirects. Since it is not, I have another question. Why is it useful to maintain a list of redirects to articles about characters that excludes single-character redirects like הּהּ and 🇨🇳🇨🇳 just because they use multiple code points? Gorobay (talk) 02:23, 10 August 2016 (UTC)[reply]
Well, I'm not sure I know the answer to that Gorobay. Your first question remains up in the air, though, because while making a perhaps feeble attempt to improve this rcat, I added the "to" statement back on 2 July 2014 with this edit. You know far more than I do about Unicode and this type of rcat, so if you think that the "to" statement is wrong or needs improvement, then by all means please make it right. Or let me know here what it should say and I'll change it, so it won't appear to others as if you molded it to your own suiting. In the mean time, I shall try to make it a more general statement. Temporal SunshinePaine17:39, 10 August 2016 (UTC)[reply]
The problem is that there are single-character redirects that do not link to an article that names the character and describes its usage. So they do not fit into the category, nor is the template correct for them. As Gorobay mentioned above, 비비 is a case in point. So are many, many of the "emoji" characters. 🍽🍽 redirects to table setting, and 🌎🌎 redirects to Earth. Those articles don't even mention symbols, much less Unicode. — Gorthian (talk) 03:08, 11 August 2016 (UTC)[reply]
I've removed the "that names the character" part that I had inserted without knowing the extent of the need to categorize other symbols. While the symbols might not actually be mentioned in the target article, they should at least be described or inferred by the target, as is the case with 🍽🍽 and 🌎🌎. Therefore those two redirects should be sorted to Category:Redirects from Unicode characters. The 비비 redirect is perhaps more iffy? Is it just one symbol? Is it two symbols used together? I would have to leave that up to others more knowledgable than I am. Temporal SunshinePaine03:32, 11 August 2016 (UTC)[reply]
This template gives redirects sort keys of “~” for Category:Redirects from Unicode characters, and {{Category TOC Unicode}} uses that convention to provide table of contents entries for each Unicode block. However, the block links no longer always work: it appears that, since 2012, categories have become sorted using Unicode collation, instead of sorting in Unicode code point order. This is good for most purposes, but it is more useful for the category of Unicode characters to be sorted by code point. Is there any magic word to change a category’s collation system? If not, I propose that this template sort by the following.
I’ve made the change in the sandbox and tested it in ,,, ¢¢, and 🌐🌐. index.php?action=raw&templates=expand shows that each gets the expected sort key. Once the sandbox has been copied and pasted over the template, I will fix those three test redirects. Gorobay (talk) 17:08, 5 January 2019 (UTC)[reply]
{{#invoke:BaseConvert|convert|n={{#invoke:ustring|codepoint|\{{PAGENAME}}}}|base=16|width=6}} would work better than the current system for finding the hexadecimal representation. The current system yields strings like .00.00.C3.85 (å) normally but .00.00..0025 (%) for printable ASCII. This is inconsistent and breaks sorting; the suggestion above yields 000025 for %, 0000C5 for å, and 01F373 for 🍳. Six digits are the maximum needed; Unicode extends up to 10FFFFF. User:GKFXtalk18:03, 26 March 2021 (UTC)[reply]
This edit request has been answered. Set the |answered= parameter to no to reactivate your request.
As described in the section above with no complaints, please make the following change: [1]. It ensures that all items in the category sort consistently. User:GKFXtalk15:55, 1 April 2021 (UTC)[reply]
For instance, the redirect ⬇️⬇️ has this rcat, but it technically has two Unicode characters: U+2B07 and U+FE0F. Should this rcat be placed on such redirects? jlwoodwa (talk) 20:37, 6 May 2024 (UTC)[reply]
No, it is one character that needs two code points to represent it. For comparison, there are many 'letters with diacritic' that are formed using the base letter plus a combining diacritic: still one character. 𝕁𝕄𝔽 (talk) 10:40, 3 June 2025 (UTC)[reply]
Standing back a bit, why does this template even exist? What is a "Unicode character"? The currency signs given in the example are just characters that have a Unicode code point. Methinks that this template was created 20 years ago, that it must have made sense at the time, but what does it actually mean?