Module talk:WikiProject banner

(Redirected from Template talk:WPBannerMeta)
Latest comment: 22 hours ago by Izno in topic usages of |BANNER_NAME= in talk pages
WikiProject iconCouncil
WikiProject iconThis module relates to the WikiProject Council, a collaborative effort regarding WikiProjects in general. If you would like to participate, please visit the project discussion page.

Hook conversion Edit

The project of converting all the hooks into the Lua version continues, with support for |image-needed= added today. The status of the others are:

  • aclass –   Done
  • article todolist –   Not done only used by one banner, will probably hardcode it
  • bchecklist –   Done in /auxiliary, except for those projects which use a checklist but do not use it to automatically demote the class of an article to C-class if it doesn't meet the criteria. Some discussion of this in the archives and there was a proposal to change the way incomplete checklists are handled.
  • cats – to do, but notes can be used instead with blank |NOTE_n_TEXT=
  • collaboration –   Done
  • collapsed – to do
  • image needed –   Done in /auxiliary
  • notecounter – may not be needed when all hooks converted
  • notes – not needed anymore as infinite number of notes are now supported, except for those projects which hook this in a different place or have an additional collapsed section.
  • peerreview –   Done
  • qualimpintersect –   Done in /auxiliary, but need to add support for |UNASSESSED_APPENDIX= to convert the few remaining projects using this
  • qualitycats –   Done using task forces with |TF_n_TEXT=none
  • taskforces – not needed as infinite number of task forces are now supported, except for those projects which are putting their task forces in a collapsed section.
  • tfnested – will not be needed when all task forces are converted
  • todolist –   Done in /auxiliary

— Martin (MSGJ · talk) 10:58, 7 September 2023 (UTC)Reply[reply]

Parameter rename Edit

Propose renaming B_MAIN_CAT to B_INCOMPLETE_CAT as a more accurate description of its actual purpose (a category for B-class checklist which are incomplete) — Martin (MSGJ · talk) 14:55, 11 September 2023 (UTC)Reply[reply]

Additional taskforce categories Edit

Several of the large projects use extra categories inside taskforces, which they hook using TF_n_HOOK parameters with Template:WPBannerMeta/hooks/cats. I'm wondering if we could add better support for this, e.g. |tf 1 cat 1= and |TF_1_CAT_1= — Martin (MSGJ · talk) 08:09, 13 September 2023 (UTC)Reply[reply]

This is now coded in the sandbox — Martin (MSGJ · talk) 09:03, 14 September 2023 (UTC)Reply[reply]
  Done - deployed and documented — Martin (MSGJ · talk) 11:52, 15 September 2023 (UTC)Reply[reply]

Needs-infobox by task force Edit

Greetings. Most pages in Category:Physics articles needing infoboxes are also members of Category:Physics biographies articles. Would it be possible to create the intersection, Category:Physics biographies needing infoboxes, please? Notice bio is a task force of WP Phys (Template:WikiProject_Physics#Usage). Thanks! fgnievinski (talk) 04:09, 15 September 2023 (UTC)Reply[reply]

This very timely request can now be implemented using the new "additional taskforce category" feature. It is so new that I haven't even documented it yet — Martin (MSGJ · talk) 07:43, 15 September 2023 (UTC)Reply[reply]
Very nice! Could you give me some pointers so that I can try to implement it in WP Phys, please? fgnievinski (talk) 01:26, 17 September 2023 (UTC)Reply[reply]
Already done here. You just need to create the category — Martin (MSGJ · talk) 19:29, 17 September 2023 (UTC)Reply[reply]
Created: Category:Physics biographies needing infoboxes -- thanks! Would it be possible to diffuse Category:Physics articles needing infoboxes, please? I'd like to isolate the non-biography articles needing infoboxes, especially physical quantities and physical units needing infobox. fgnievinski (talk) 04:02, 19 September 2023 (UTC)Reply[reply]
You can create categories based on the task forces that you have defined in your template. For example, for relativity articles needing an infobox you could add the code |tf 1 cat 1={{{needs-infobox|}}} and |TF_1_CAT_1=Name of the category — Martin (MSGJ · talk) 07:55, 19 September 2023 (UTC)Reply[reply]

Collapsed taskforces Edit

Some projects have their taskforces in a separate collapsible section. Currently this is not possible without using an complicated method with Template:WPBannerMeta/hooks/collapsed and Template:WPBannerMeta/hooks/taskforces. I am proposing parameters |TF_COLLAPSE= and |TF_HEADER= that would do this instead. — Martin (MSGJ · talk) 08:12, 13 September 2023 (UTC)Reply[reply]

Suggested implementation. If either |TF_COLLAPSE= or |TF_HEADER= is defined then taskforces will be put in a collapsible section. In that case,
  • if |TF_COLLAPSE= is not specified then it will default to zero, i.e. section will always collapse
  • if |TF_HEADER= is not defined then it will default to "Associated task forces"
Any input welcome — Martin (MSGJ · talk) 21:31, 17 September 2023 (UTC)Reply[reply]
This now coded on the sandbox and there is a demo on Template:WikiProject France/sandbox — Martin (MSGJ · talk) 09:30, 18 September 2023 (UTC)Reply[reply]
That page, and a few others that use the /sandbox module, are currently showing Linter errors, specifically misnested table and tr elements. Special:ExpandTemplates should be able to show you the expanded code. Ping me if you need help with diagnosis. – Jonesey95 (talk) 12:59, 18 September 2023 (UTC)Reply[reply]
Thanks for the note. Seems to be fixed now — Martin (MSGJ · talk) 13:43, 18 September 2023 (UTC)Reply[reply]
Yes, all cleaned up. Thanks. – Jonesey95 (talk) 14:34, 18 September 2023 (UTC)Reply[reply]

I propose two default thresholds for collapsing:

  • 0 if |TF_HEADER= is defined (i.e. we assume that task forces should always collapse if the header is defined)
  • 5 if |TF_HEADER= is not defined (i.e. any banner with 5 or more task forces will collapse by default, to take up less space on the page)

The default can be changed with the |TF_COLLAPSE= parameter — Martin (MSGJ · talk) 07:58, 19 September 2023 (UTC)Reply[reply]

Auto for unassessed articles Edit

auto=yes does not work for talk pages which do not have class/importance. e.g. Talk:Benzoate degradation via hydroxylation. I do not know if it worked with the old version of WPBannerMeta. Christian75 (talk) 00:44, 23 September 2023 (UTC)Reply[reply]

@Christian75: No, it did not. Its purpose was purely to show that the |class= parameter had been filled in automatically by a bot. There were three ways that |class= could be filled in: (i) based on the length of the article (very short articles would be given |class=stub), in which case you got |auto=length; (ii) by copying the value for |class= from another WikiProject banner on the same page, in which case you got |auto=inherit - clearly if there were two or more with ratings, they would need to be the same rating otherwise the bot wouldn't do anything; (iii) if the article uses a stub template, in which case you got |auto=yes (or |auto=stub) and also |class=stub.
Hence, if the WikiProject did not recognise |class=, it was pointless for it to recognise |auto=. Importance had nothing to do with it. --Redrose64 🌹 (talk) 10:43, 23 September 2023 (UTC)Reply[reply]
But the recent bot which tagged a lot of pages automatically added auto=yes. Just like the example i gave where WP Science should be removed. IMHO all talk pages with auto=yes (or similar) should be checked and therefore, should be in a auto-category Christian75 (talk) 12:16, 23 September 2023 (UTC)Reply[reply]
The bot concerned is Qwerfjkl (bot) (talk · contribs), which is very buggy - see the numerous threads at User talk:Qwerfjkl and its archives, going back months, e.g. User talk:Qwerfjkl/Archive 32#auto. Your example edit is dated 1 July 2023 - do you have any recent examples? --Redrose64 🌹 (talk) 15:48, 23 September 2023 (UTC)Reply[reply]
Strange. So adding class=something to a talk page which have auto=yes - will also make the article be in the Automatically assessed Chemistry articles (example: [1]) . I suggest adding all articles with auto to the automatically assessed categories and not just after they have been tagged with class. Christian75 (talk) 12:23, 24 September 2023 (UTC)Reply[reply]
|auto=inherit or |auto=length will work for any class (as long as the article has been assessed otherwise it would make no sense!) And |auto=stub only works when |class=stub — Martin (MSGJ · talk) 16:58, 24 September 2023 (UTC)Reply[reply]
@Redrose64, I wouldn't say it's very buggy - after all, that's what I coded it to do. There were a few problems when running it (mostly the ORES thing which is only tagentially related to this). Anyway, I switched to using an invisible comment pretty much because of this issue. I have no problem going over previous edits and fixing them, I just figured that it wasn't a huge issue.
There won't be any recent edits, because the bot task finished some time ago. — Qwerfjkltalk 15:45, 25 September 2023 (UTC)Reply[reply]

Template:WikiProject Mammals/Bats Task Force Edit

Will you just look at the horrendous code on this template? I think someone (or a bot) needs to go around and convert all the unnamed parameters to the standard named parameters "class", "importance" and "photo" — Martin (MSGJ · talk) 13:06, 25 September 2023 (UTC)Reply[reply]

Category:Bats articles using unnamed parameters - see what turns up — Martin (MSGJ · talk) 13:57, 25 September 2023 (UTC)Reply[reply]
I did a null edit on every page transcluding Template:WikiProject Mammals/Bats Task Force (just over 2,000 pages), so anything that could have ended up in the category should be there now. The category is empty. It should be safe to remove the excess code. You could leave the tracking category code in for a while if you are not confident in my work. – Jonesey95 (talk) 18:29, 25 September 2023 (UTC)Reply[reply]
Thank you! Of course I am confident in your work ... — Martin (MSGJ · talk) 19:30, 25 September 2023 (UTC)Reply[reply]

Category:WikiProject banners with non-standard names Edit

Do we still need this tracking category? — Martin (MSGJ · talk) 09:50, 26 September 2023 (UTC)Reply[reply]

Having a non-standard name inhibits AWB from moving these into the banner shell as part of its general fixes and/or in general putting them in the place they're supposed to be on talk pages. So, yes, we should still have a tracking category. Izno (talk) 18:33, 26 September 2023 (UTC)Reply[reply]
I'm not sure how the remaining ones can be "fixed" but okay — Martin (MSGJ · talk) 18:42, 26 September 2023 (UTC)Reply[reply]
I mean, I don't know why some of those pages have non-standard names, but for the ones that obviously do, the correct thing to do is rename them. Izno (talk) 19:45, 26 September 2023 (UTC)Reply[reply]
Some are incorrect task forces that should be converted to use the main WikiProject template. Others can maybe be added to an exclude list (like Template:WikiProject C/C++ and Template:WikiProject Hinduism/Shaktism, though really per MOS:SLASH the name of the project should use "and" and as an added benefit, these probably won't be added to the category). Gonnym (talk) 17:15, 29 September 2023 (UTC)Reply[reply]

Slight change to behaviour of task forces on non-article pages Edit

I've got code on the sandbox which will improve how the banner handles task forces on non-article pages. There are projects that use exotic extended classes like FM-class and Portal-class, but sometimes the separate task forces do not support the full range of these classes.

For example, Category:FM-Class mammal articles‎ exists but Category:FM-Class Pocket pets articles‎ does not. The proposed version will automatically use NA-class for the task force if the category does not exist or is blank. This involves a few more ifexist checks, but hopefully will not cause any performance issue. — Martin (MSGJ · talk) 15:21, 27 September 2023 (UTC)Reply[reply]

This is deployed and seems to be working okay — Martin (MSGJ · talk) 08:35, 29 September 2023 (UTC)Reply[reply]

usages of |BANNER_NAME= in talk pages Edit

There should probably be some code added to catch usages of |BANNER_NAME= in talk pages so usages like Talk:Basshunter videography can be added to a category and fixed. Gonnym (talk) 18:41, 29 September 2023 (UTC)Reply[reply]

Wow, never seen that before! There doesn't seem to be any banner template for Basshunter — Martin (MSGJ · talk) 21:55, 29 September 2023 (UTC)Reply[reply]
I am fairly certain there was at some point. WP:WikiProject Basshunter exists and is a redirect to a task force. Izno (talk) 00:44, 30 September 2023 (UTC)Reply[reply]