Template talk:NewWork

From ChoralWiki
Jump to navigation Jump to search

Proposal to eliminate this template

Claude T has found this template unnecessarily time-consuming, especially because it populates Category:New works. To me, Category:New Works doesn't seem to serve any function, and this template's usefulness is limited to putting the new icon on works less than 30 days old and assigning works to appropriate date-related categories. For the past few weeks, I have been testing a new version of {{PostedDate}}, that incorporates the relevant code from NewWork and {{IsNew}} without using either of them. On the test server, Template:NewWork has been disabled, Template:PostedDate has been rewritten without Template:NewWork or Template:IsNew, Category:New works has been emptied and has no subcategories. Category:New works and the Templates NewWork, IsNew, and IsRecent are not used by any other page outside this group (ChoralWiki:New scores archive mentions NewWork in the header, but doesn't use it). The tasks that NewWork used to do are now done by PostedDate, except no Category:New works.

After these changes, I have seen no effects to other programs and lists on the Test server.

I propose to change Template:PostedDate to the new version, empty Category:New works and delete it, and eliminate Template:NewWork. Template:IsNew would then have no purpose, but might be kept for future use anyway.

There has been a lot of discussion over the years; see this (hide transclusions) and this (hide transclusions), (especially here and here). Perhaps I have missed something. — Barry Johnston (talk) 15:49, 11 June 2020 (UTC)

Thanks, Barry. Anyone can go to that page to see how many pages calculate eternally their own age since 2006 for ever and ever, on each page-opening, to no avail: now 20,915 pages, more than yesterday and less than tomorrow. Claude (talk) 16:32, 11 June 2020 (UTC)
Claude, you seem to not understand that time calculations will always be performed inside every single works page, whether using this template or not. This is required for the proper functioning of the Latest Scores list displayed on the Main Page; for the Multi-Category Search (which also relies on categories New works and New works in the past 30 days); and for several other categories that display works in a range of time. Such calculations are not too demanding on server resources and you shouldn't worry about them.
Barry, regarding the elimination of this template: I think there's no problem in incorporating the functionality of NewWork into PostedDate. Please just don't delete unused templates, they might be useful someday (and they are sometimes required when we preview an old revision). Just categorize them under Obsolete templates. Thanks —Carlos (talk) 00:57, 16 June 2020 (UTC)
But, Carlos, we may easily retrieve composers birthday anniversaries by external scripts, without including inside each composer page a calculation that runs at each composer page-opening. The date of birth is sufficient! Claude (talk) 05:57, 16 June 2020 (UTC)
Thank you, Carlos. There seem to be at least ten active categories involving calculation of time: 1. New works in the past 30 days (PostedDate, using NewWork); 2. At least 30 days old (Editor); 3. New works (NewWork, 90 days); 4. Posted in <month> (NewWork); 5. At least 90 days old (Editor); 6. At least 2 years old (Editor); 7. At least 5 years old (Editor); 8. Before this month (Editor); 9. Before this year (Editor); and 10. Before last year (Editor).
Category:New works has too many members! Currently, PostedDate assigns a page to Category:New works, when the page is created, a new edition is added, or the page is opened or edited within 90 days of creation. The main problem is that Category:New works will continue to accumulate pages older than 90 days that have not been opened or edited. Currently Category:New works has many members with posted dates over 90 days ago, which was my main motivation for redesigning PostedDate to eliminate Category:New works. I have been told that this can be corrected by running some script from time to time, but that seems unnecessary. If Category:New works is retained, we need a way to automatically correct this.
Category:New works in the past 30 days has many members older than 30 days ago. — Barry Johnston (talk) 15:56, 16 June 2020 (UTC) (revised 2 July 2020)
How would I write code that would eliminate a category from a page? Otherwise, another possibility for the "Category:New works" and "Category:New Works in the past 30 days" dilemmas, would be to redefine (and rename) "Category:At least 90 days old" to be "More than 90 days old", and redefine "Category:At least 30 days old" to be "More than 30 days old". Then could Cat:New works and Cat:New Works in the past 30 days be eliminated? In their stead would be two ChoralWiki pages, calculated using notcategory=More than 90 days old and notcategory=More than 30 days old. Would this work? — Barry Johnston (talk) 15:10, 2 July 2020 (UTC)