Jump to content

Module talk:WikiProject banner/Archive 5

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by MiszaBot II (talk | contribs) at 08:13, 6 May 2009 (Archiving 3 thread(s) from Template talk:WPBannerMeta.). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.
Archive 1Archive 3Archive 4Archive 5Archive 6Archive 7Archive 10

"Investigate balance of C_NOTEs vs TFs"

As promised... From the tracking category, we see that 27 banners use one or more of the collapsed notes. From WhatLinksHere, we see that 21 banners use the /taskforces hook, indicating that they have an inadequate number of taskforces built into the banner. These results surprised me a little, I admit, but they seem correct. I remember that several of the projects using the hook have a huge number of taskforces, such that it would be a hopeless task trying to add enough taskforces for them. Consequently, and a little surprisingly, I don't think there's anything to be done here. Comments? Happymelon 19:36, 10 April 2009 (UTC)

Another question that could be asked is: Should WPBannerMeta still support the collapsed notes directly or should those banners use the HOOK_COLLAPSED parameter and the hooks/notes template instead? -- WOSlinker (talk) 19:56, 10 April 2009 (UTC)
I think it's important to have some support for 'basic' functionality in the core code; we could split a whole host of things out into hooks, but we'd soon find ourselves with nothing left in the main banner. Whether collapsed notes count as "basic" functionality is not entirely unequivocal, however. Happymelon 20:03, 10 April 2009 (UTC)
27 is not so many, and it would actually simplify the syntax somewhat to just use hook_collapsed. — Martin (MSGJ · talk) 22:49, 12 April 2009 (UTC)

Importance

Now that the banner is using the {{Class}} template, just thinking about having something similar for Importance. The Importance template is already being used, so would need to think of another name to use though. -- WOSlinker (talk) 12:45, 7 April 2009 (UTC)

In general, yes, I'd love to do that. I think it's worth making at least an attempt to get hold of that template name; that template itself is essentially a fork of {{notability}} and so should be merged/redirected there. Do we have icons for the importance scale? Happymelon 13:25, 7 April 2009 (UTC)
What about using an abbreviation such as {{Impor}}? We don't have icons for importance, and (not surprising given my comments above) I don't see why we would need any. PC78 (talk) 18:47, 7 April 2009 (UTC)
FWIW, {{priority}} is unused. I also went ahead and created {{importancecol}} in anticipation of future use. PC78 (talk) 15:09, 8 April 2009 (UTC)
No way are we mixing up importance and priority any more than we already have :D It's a real shame we can't get hold of {{importance}}; we may have to go for something silly like {{importance-rating}}, and create a similar redirect for {{class-rating}} for consistency. Anyone fancy setting this up? Happymelon 15:14, 8 April 2009 (UTC)
 Done I've gone ahead and created {{Impor}} and {{Imporicon}}. There are icons for NA-Importance and Unknown-Importance. The only thing left is to bring {{Impor}} into the template.  Dylanlip  (talk) 16:55, 8 April 2009 (UTC)
Hello? I never got a response from anyone about this. This seems extremely important. :|  Dylanlip  (talk) 12:22, 9 April 2009 (UTC)
Is it? IMO the total borkage on Safari would seem to be more important, although a much trickier problem to resolve. Having said that, I am grateful to you for putting the code together. Happymelon 13:16, 9 April 2009 (UTC)

Will also need some support for the priority categories as well, either by adding support in {{impor}} or by having a separate template. -- WOSlinker (talk) 17:33, 9 April 2009 (UTC)

Would that not be done via the |category= parameter as with the existing templates? PC78 (talk) 17:45, 9 April 2009 (UTC)
He means that the "-importance" part of the category link is hardcoded into {{impor}}, which will break when "-priority" should be used. Happymelon 17:53, 9 April 2009 (UTC)
Why hardcode it then? That seems counterproductive here. PC78 (talk) 15:43, 14 April 2009 (UTC)

Minor bug

The ASSESSMENT_CAT value is being ignored in favor of PROJECT (I think), in the case of the category name used when AUTO_ASSESS is on. That is, for Template:WikiProject Belgium for example, all of categories used by this template for assessment and cleanup sorting are in the form "Category:Top-importance Belgium-related articles", "Category:Belgium-related articles needing attention", etc., with the sole exception of "Category:Automatically assessed Belgium articles". — SMcCandlish [talk] [cont] ‹(-¿-)› 21:41, 12 April 2009 (UTC)

Yes you are right, it will set to Automatically assessed {{{PROJECT}}} articles by default. I'm hesitant to just change it though because it may affect quite a lot of banners which already have the category in the current location ... — Martin (MSGJ · talk) 22:46, 12 April 2009 (UTC)
It would require help at WP:CFD, a mass speedy rename. — SMcCandlish [talk] [cont] ‹(-¿-)› 01:17, 13 April 2009 (UTC)
Don't forget |AUTO_ASSESS_CAT=; there is already the facility to customise this category. I agree that it should include the value of |ASSESSMENT_CAT= in the fallback chain, but we can probably make the change silently if we're careful. Happymelon 09:30, 13 April 2009 (UTC)
Resolved

Happymelon 16:14, 19 April 2009 (UTC)

Please see requests at Template talk:WikiProject Middle Ages#adding to wrong assessment categories. Thank you. --Funandtrvl (talk) 15:02, 19 April 2009 (UTC)

Still has assessment problems, see: Template talk:WikiProject Middle Ages#Still has assessment problems. Thanks --Funandtrvl (talk) 17:52, 19 April 2009 (UTC)
Please see: Template talk:WikiProject Middle Ages#Addendum. --Funandtrvl (talk) 19:35, 19 April 2009 (UTC)

Could you add parameters to Template WikiProject Architecture

Just a request to add the full parameters to the WP Architecture template. Thanks. --Funandtrvl (talk) 19:48, 20 April 2009 (UTC)

Created cats and updated doc. Just noticed that a File-Class cat is now there, which name are we supposed to use, Image or File, because the WPBM is still prompting for Image? Just curious --Funandtrvl (talk) 23:51, 20 April 2009 (UTC)
We might have crossed tracks while I was checking your banner: can you be a bit more specific (it looks OK to me). For the Image/File question, I don't think we have a standard yet! Physchim62 (talk) 23:54, 20 April 2009 (UTC)
Yes, there are now two categories for images under WP Architecture, one that I created using the prompts (Image-Class) and one that MSGJ created later on (File-Class). Since these cats duplicate each other, just wondering which one should be changed to redirect to the other. --Funandtrvl (talk) 00:00, 21 April 2009 (UTC)
I thin this needs a more specific header! Physchim62 (talk) 00:14, 21 April 2009 (UTC) (discussion continued below)
Funandtrvl simply replied in the wrong place. I'll copy this to Template talk:WikiProject Architecture. — Martin (MSGJ · talk) 05:14, 21 April 2009 (UTC)

Redundant parameters

I propose to deprecate the FULL_QUALITY_SCALE parameter in favour of QUALITY_SCALE=full. This could be done silently, while still supporting the current syntax by using something like

QUALITY_SCALE = {{#switch:{{{QUALITY_SCALE|}}}
                      |         = <!-- Null -->
                      |full     = full
                      |#default = {{#if:{{{FULL_QUALITY_SCALE|}}}|full|yes}}
                }}

We could do something similar with COMMENTS=force instead of COMMENTS_FORCE=yes.

This would shorten the code and simplify the syntax I think. Thoughts? — Martin (MSGJ · talk) 07:41, 20 April 2009 (UTC)

If we're going to change the syntax, it ought to be a complete schema; that is, we should specify what value we want to activate the 'short' scale. Something like:
|QUALITY_SCALE = {{#switch:{{{QUALITY_SCALE|}}}
                      |         = <!-- Null -->
                      |short    = short
                      |full     = full
                      |#default = {{#if:{{{FULL_QUALITY_SCALE|}}}|full|short}}
                }}
Other than that, I can't see anything against it. Happymelon 09:12, 20 April 2009 (UTC)
Excellent suggestion. And that leaves the way open for QUALITY_SCALE=medium (or something) later on :) — Martin (MSGJ · talk) 09:28, 20 April 2009 (UTC)
Short ... or "standard"? — Martin (MSGJ · talk) 09:29, 20 April 2009 (UTC)
Just a question on this, instead of just checking for the existence of Template:BANNER/class, and using it automatically if it does exist, how about QUALITY_SCALE = custom ? One advantage of this is that currently, if a banner is editprotected, anyone can still come along & create a /class page and mess things up for that banner. Only using it if QUALITY_SCALE = custom would close that issue. -- WOSlinker (talk) 10:43, 20 April 2009 (UTC)
Hmn.... I agree that that's an attack vector for protected banners. But I don't want to think about the mess that would be created by transcluding a nonexistent custom mask. Perhaps what this parameter should be doing is acting as an override to any 'intelligence' in the banner; in that case we're looking at values of "no", "short"/"standard" (still not sure which is better there), "full" and "custom". And anything else is "auto" - the banner does its best to work out what is intended. We could do ¬ checking on |class= and actually do away with the requirement to set this parameter altogether: if class is passed through, we assume quality scale is active. Maybe. Thoughts? Happymelon 10:57, 20 April 2009 (UTC)
I hadn't even thought of someone trying to use the class file as an attack vector during the last discussion. I guess this one will end up revisited after all :/ --Tothwolf (talk) 14:18, 20 April 2009 (UTC)
(e/c)I agree that it would be good not to check for a custom class unless class=custom. This would save a lot of ifexist calls and prevent possible disruption as WOS describes. In reply to H-M, no this will not work I think. In that case, if class wasn't defined by an instance of the banner, then the banner would not know whether quality scale was being used. (I thought about doing that exact thing in the past.) — Martin (MSGJ · talk) 14:22, 20 April 2009 (UTC)
We have the ability to differentiate between a banner that is passing the class parameter through and one that isn't:
{{WikiProject Tulips|class=<foo>}}
  --> {{WPBannerMeta|...|class={{{class|}}}|...}}
    --> {{WPBannerMeta/core|...|class={{{class|¬}}}|...}}
      --> class != ¬ for all foo, including undefined

{{WikiProject Tulips|class=<foo>}}
  --> {{WPBannerMeta|...|no class=|...}}
    --> {{WPBannerMeta/core|...|class={{{class|¬}}}|...}}
      --> class == ¬ for all foo
That's the whole principle of the ¬ chains - if they're broken at any point they pick up a unique value at the endpoint. We'd just need to set a default of ¬ in WPBM main and /core. Even ignoring WP:PERFORMANCE, the performance benefits of only using the custom mask with |QUALITY_SCALE=custom would be minimal because we would have to do the #ifexist: check on the custom mask anyway if told to use it; the results of not doing it would be too ugly to think about. And we have no need to ignore WP:PERFORMANCE; we can instead legitimately ignore performance :D. The proportion of banners using custom masks is about 10% now, and will only go upwards IMO. Usability has the higher priority.
I think we're agreed that |QUALITY_SCALE=custom should be expecting a custom mask, but what do we do when that mask does not exist?
Equally, banners with |QUALITY_SCALE=full/short should not use the custom mask even if it exists. We can do some pretty crazy things on /templatepage with the resources we have available; we could add a warning message only on protected templates suggesting that they switch to one of these values to close the attack vector. But I'm not convinced that removing the 'automagic' from the scale-selection process is a positive step. Happymelon 15:33, 20 April 2009 (UTC)
  1. Hmm, I think that if class was defined empty then it wouldn't pick up a ¬ currently.
  2. If custom is defined but there doesn't exist a custom mask then just use the standard scale I guess.
  3. If we can make the code more efficient for 90% of banners, then why not?
  4. Advising about an "attack vector" is WP:BEANS, isn't it? :P — Martin (MSGJ · talk) 15:52, 20 April 2009 (UTC)
Yes, that's exactly the point. It'd take a few tweaks which we could probably do live (passing a default of ¬ to /class, and returning ¬=¬ in the #switch statement); the point is that the only way WPBM/core can ever receive |class=¬ is if the parameter is not passed through from the WikiProject banner at the end of the line, and so the default value of something-other-than-¬ is injected there.
I guess we'd have to, but that just reinforces this new |QUALITY_SCALE=custom as just another switch to flick in order to use a custom mask. We're not launching nuclear missiles here :D.
If it makes the code more efficient for 90% of banners, but makes life more difficult for 10% of users, then we shouldn't do it.
It would if I thought that any serious vandals actually watched this page :D. It's more important that we properly decide how best to close it than worry about its existence leaking. For the record, filling a custom mask with rubbish makes banners look like this. Irritating, but hardly devastating; and the vandalism will be at the top of the "related changes" link and can be quickly reverted. It's not actually as bad as I thought it would be; I expect transcluding a nonexistent mask would be worse.
In summary, I'm mainly concerned that adding "you must set |QUALITY_SCALE=custom" to the (currently very short) list of things you need to do to use a custom mask, is sacrificing ease of use for performance and for security against a threat that's not particularly severe. I fully agree that there should be a way to disable the use of a custom mask even if it exists; I think |QUALITY_SCALE=short/full should do that. I guess |QUALITY_SCALE=custom should "force" the use of a custom mask, although that's a fairly toothless assertion since we have to do existence checking and fall back to standard if it's not there. I just don't think we should lose the 'magic' from |QUALITY_SCALE=yes without good cause; if anything, we should be trying to make it more 'magical'. Happymelon 10:41, 21 April 2009 (UTC)
Thanks for the long reply. It's useful to hear what others are thinking. So if I'm reading this right, there is at least one point on which we all agree: if class has been set to standard/short or full then it shouldn't use a custom mask even if it exists. There are still a several other points to be ironed out. I anticpate being busy for the next couple of days, but after that I will try to set out the advantages and disadvantages of each approach that we have identified so far. About the ¬ thing, I guess you are right; I have to admit to never understanding fully what the ¬ thing was all about :) But I feel that whatever we decide with regards to QUALITY_SCALE is likely to make that consideration moot, so I suggest we forget about that for the time being. — Martin (MSGJ · talk) 23:28, 21 April 2009 (UTC)

Image-Class or File-Class?

Many projects have followed the guidelines and set up a Category:Image-Class XXX articles. Now the code appears to be prompting for a Category:File-Class XXX articles as well. Obviously both categories refer to the same type of page, so which naming convention should we use? My preference is for "File", as this matches the new(ish) name of the namespace. Physchim62 (talk) 00:14, 21 April 2009 (UTC)

Currently, File-Class can only be achieved with a custom class mask, and it would be a lot of work to change the default behaviour because 550 categories would have to be created and another 550 deleted. — Martin (MSGJ · talk) 05:13, 21 April 2009 (UTC)
However, I think that such a transition would probably be a constructive way to proceed. I agree that it would be a huge undertaking, and would have to be bot-assisted. I have approval for a bot script that could duplicate all the "Image-Class" categories as "File-Class", and then we could do one massive switch (and lots of little ones on the templates with custom masks) to change the categories over. I could write another script to go through all the then-empty Image-Class categories changing all WhatLinksHere to point to the File-Class ones, and then delete the old categories. However, while technically feasible it's still quite a noticeable change. Ignore the technical aspects: it can be done. Is it a "good idea"?? Happymelon 10:15, 21 April 2009 (UTC)
Sure it is. :) Having already initiated a switch to File-Class it makes no sense to stop at this point. If you feel you need the thumbs up from a wider section of the community then that's fine, but there's no logic in continuing to have File-Class feed Image-Class categories. PC78 (talk) 14:52, 21 April 2009 (UTC)
I agree, it is important to keep it consistent. If the category is now called "File-Class", then the automatic prompts from WPBM should be pointing to "File-Class", not "Image-Class", otherwise, it is too confusing. (For example, see discussion above concerning WP Archy). --Funandtrvl (talk) 15:14, 21 April 2009 (UTC)
I also agree that we should move forward with this. But calling it low priority would be an overstatement in my opinion :) — Martin (MSGJ · talk) 23:24, 21 April 2009 (UTC)

Just a comment. Since this banner started to use {{class}}, the classification does match the categorisation, which is probably appropriate. — Martin (MSGJ · talk) 15:48, 21 April 2009 (UTC)

Lotsa notes

Is there a limit on the number of notes which can be defined in the banner? I've got a somewhat specialized set of notes I'm trying to do over here, but they don't seem to be working. I'd like the section to be collapsed so it doesn't get too long, but I think I need some assistance with it. Thanks! ···日本穣? · Talk to Nihonjoe 08:52, 21 April 2009 (UTC)

You can use up to five uncollapsed (note 1, note 2, etc.) and five collapsed (c note 1, c note 2, etc.) with the usual syntax. For more than that, you will need to use the hook: Template:WPBannerMeta/hooks/notes which can either be attached using HOOK_NOTE (for uncollapsed) or HOOK_COLLAPSED (for collapsed). I'll come and look at what you're doing. — Martin (MSGJ · talk) 08:56, 21 April 2009 (UTC)
Aha. I figured there would be something like that. I appreciate any help. ···日本穣? · Talk to Nihonjoe 08:57, 21 April 2009 (UTC)
49 notes!!!?? This is ridiculous, frankly. Let me try to find a better way to do this. And I suggest working in the sandbox for now. — Martin (MSGJ · talk) 08:59, 21 April 2009 (UTC)
Yes, like I said, "Lotsa notes". I've been trying to figure out a way which would be shorter, but I'm not big into programming. I can implement something someone makes, but can't always figure out how to do it myself. :)
One thing which is a special case here are these two categories: Category:Wikipedia requested photographs in Hokkaidō and Category:Wikipedia requested photographs in Tokyo. Unlike the other related categories, they don't have "Prefecture" tacked onto the end. So, these two would require special code to accommodate that. ···日本穣? · Talk to Nihonjoe 09:08, 21 April 2009 (UTC)

I'm going to reply on Template talk:WikiProject Japan. — Martin (MSGJ · talk) 09:09, 21 April 2009 (UTC)