Cannabis Sativa

If process guidelines are met, move templates to the appropriate subsection here to prepare to delete. Before deleting a template, ensure that it is not in use on any pages (other than talk pages where eliminating the link would change the meaning of a prior discussion), by checking Special:Whatlinkshere for '(transclusion)'. Consider placing {{Being deleted}} on the template page.

Tools

There are several tools that can help when implementing TfDs. Some of these are listed below.

Closing discussions

The closing procedures are outlined at Wikipedia:Templates for discussion/Closing instructions.

To review

Templates for which each transclusion requires individual attention and analysis before the template is deleted.

To merge

Templates to be merged into another template.

Infoboxes

Param mapping
    mapping = {
        # Header / misc
        'boxtype' => nil, # only support boxtype = 'locomotive'
        'Farbe1' => nil, # color
        'Farbe2' => nil, # color
        'Baureihe' => 'name',
        'Abbildung' => 'image',
        'Name' => 'caption',

        # General
        'Nummerierung' => '', # "Number(s) allocated to the vehicle(s)"
        'Hersteller' => 'builder',
        'Baujahre' => 'builddate',
        'Indienststellung' => 'firstrundate',
        'Ausmusterung' => 'retiredate',
        'Anzahl' => 'totalproduction',
        'Wheel arrangement' => 'whytetype | aarwheels', # ambiguous? which one is it?
        'Achsformel' => '', # same as above
        'Gattung' => '', # some form of class (eg "S 37.19")
        'Spurweite' => 'gauge',
        'Höchstgeschwindigkeit' => 'maxspeed',

        # Wheels (should wheelbase sub-params be used in [[Template:Infobox locomotive]]?)
        'Laufraddurchmesser vorn' => 'leadingdiameter',
        'Laufraddurchmesser hinten' => 'trailingdiameter',
        'Laufraddurchmesser außen' => '', # Outer carrying wheel diameter, Garratt locomotives
        'Laufraddurchmesser innen' => '', # Inner carrying wheel diameter, Garratt locomotives
        'Laufraddurchmesser' => '',
        'Treibraddurchmesser' => 'driverdiameter',

        # Weight, dimensions and Axles
        'Leermasse' => 'locoweight', # "Total weight of vehicle when empty"
        'Dienstmasse' => 'tenderweight',
        'Reibungsmasse' => 'weightondrivers',
        'Radsatzfahrmasse' => 'axleload',
        'Höhe' => 'height',
        'Breite' => 'width',

        # Steam traction / cylinders
        'Zylinderanzahl' => 'cylindercount',
        'Zylinderdurchmesser' => 'cylindersize',
        'Kolbenhub' => '', # "[[Piston stroke]] - I think current template requires this to be <br>'d onto cyclindercount, if so, that should probably be changed in template"
        'Heizrohrlänge' => '', # Heating tube length. totalsurface/tubearea is provided, but this is an area, not a length?
        'Rostfläche' => '', # "Grate area"
        'Strahlungsheizfläche' => '', # "Radiative heating area, Firebox + combustion chamber"
        'Überhitzerfläche' => '', # Superheater area
        'Verdampfungsheizfläche' => '', # Evaporative heating area, Firebox heating area + combustion chamber + heating tubes + smoke tubes (total heating area)

        # Misc
        'Steuerungsart' => 'valvegear',
        'Tenderbauart' => '', # Tender
        'Wasser' => 'watercap',
        'Brennstoff' => 'fueltype + fuelcap', # in practice, may solely be 'fuelcap'
        'Lokbremse' => 'locobrakes',
        'Bremsen' => 'trainbrakes',

        # Undocumented
        'VorneLaufraddurchmesser' => '',
        'HintenLaufraddurchmesser' => '',
        'LängeÜberPuffer' => 'length/over bufferbeams', # ?
        'Kesseldruck' => 'boilerpressure',
        'AnzahlHeizrohre' => '',
        'AnzahlRauchrohre' => '',
        'IndizierteLeistung' => '',
        'HDZylinderdurchmesser' => '',
        'NDZylinderdurchmesser' => ''
    }
Parameter comparison
Infobox reality talent
competition parameter
Infobox reality competition
season parameter
Result from the merge
name
series
season_name
(Infobox television season parameter)
Delete (unnecessary)
logo image Rename to image
logo_size image_size Rename to image_size
image_alt
logo_alt
image_alt Keep (change any uses of logo_alt to image_alt)
caption caption Keep
season season_number
season_number
(Infobox television season parameter)
Delete (unnecessary)
British
british
Australian
australian
N/A Delete
aired released
(Infobox television season parameter)
Rename to released
first_aired first_aired
(Infobox television season parameter)
Keep
last_aired last_aired
(Infobox television season parameter)
Keep
judges
judge
judges Keep (change any use of "judge" to "judges")
coaches N/A New parameter, merge over
presenter
presenters
presenter Keep (change any use of "presenters" to "presenter")
host host Keep
copresenter N/A Delete, merge content to "presenter"
cohost N/A Delete, merge content to "host"
broadcaster network
(Infobox television season parameter)
Rename to network
competitors num_contestants Rename to num_contestants
finalsvenue
venue
N/A New parameter, merge over
country country
(Infobox television season parameter)
Keep
num_tasks num_tasks Keep
runtime N/A Delete, unnecessary
num_episodes num_episodes
(Infobox television season parameter)
Keep
website website
(Infobox television season parameter)
Keep
winner-name winner Rename to winner
image N/A Delete (this one is for the winner image)
winner-origin N/A Delete, unnecessary
winner-song N/A Delete, unnecessary
winner-genre N/A Delete, unnecessary
winner-mentor
winner-coach
N/A Keep, rename to winner_mentor, winner_coach
runner-name runner_up Rename to runner_up
last prev_season
prev_series
(Infobox television season parameter)
Rename (but may not be required)
next next_season
next_series
(Infobox television season parameter)
Rename (but may not be required)
year
main
N/A Delete, unnecessary
Template updated with the new parameters, just need to convert old uses now. --Gonnym (talk) 09:25, 11 June 2020 (UTC)[reply]
Soon as my other bot run finishes I'll get on it. Primefac (talk) 14:20, 21 June 2020 (UTC)[reply]
@Primefac: Thank you! Let myself or Gonnym know if you have any questions. I hope my table above will be useful in figuring out what needs to be kept, replaced, or outright deleted. And as Gonnym said, the new parameters are all ready to go once the merge has been made. - Favre1fan93 (talk) 16:38, 21 June 2020 (UTC)[reply]
I'll have to re-think the usage of the bot, though... {{Infobox reality talent competition}} is an infobox proper, while {{Infobox reality competition season}} is designed as a child/subbox. Some might be easy enough to convert into an {{infobox television}} usage, such as at Singapore Idol, but in places like World Idol it will need merging into the main IB. Primefac (talk) 15:53, 23 June 2020 (UTC)[reply]
Correct. Whatever had {{Infobox reality talent competition}} will ultimately now need to have {{Infobox television season}} as the infobox proper, and the {{Infobox reality competition season}} as a child/subbox through |module1=. If I can help define or clarify anything for you to help you with the bot, let me know. - Favre1fan93 (talk) 02:19, 24 June 2020 (UTC)[reply]
 Doing... TheTVExpert (talk) 15:18, 30 June 2020 (UTC)[reply]

I've written some regex for AWB but my problem is that I don't know how (or even if it's possible) to set a whole row as a conditional check. Currently this fails if the template isn't written in this exact order. Any ideas? @Primefac: have any ideas?

Find: \{\{Infobox reality talent competition\n.*\|.*name.*=.*\n.*\|.*logo.*=\s?(.*)\n.*\|.*logo_alt.*=\s?(.*)\n.*\|.*first_aired.*=\s?(.*)\n.*\|.*last_aired.*=\s?(.*)\n.*\|.*judges.*=\s?(.*)\n.*\|.*coaches.*=\s?(.*)\n.*\|.*host.*=\s?(.*)\n.*\|.*cohost.*=\s?(.*)\n.*\|.*broadcaster.*=\s?(.*)\n.*\|.*competitors.*=\s?(.*)\n.*\|.*finalsvenue.*=\s?(.*)\n.*\|.*num_tasks.*=\s?(.*)\n.*\|.*image.*=\s?(.*)\n.*\|.*caption.*=\s?(.*)\n.*\|.*winner-name .*=\s?(.*)\n.*\|.*winner-origin.*=\s?(.*)\n\|winner-genre.*=\s?(.*)\n.*\|.*winner-song.*=\s?(.*)\n.*\|.*runner-name.*=\s?(.*)\n.*\|.*runner-image.*=\s?(.*)\n\}\}

Replace: {{Infobox television season\n| image = $1\n| image_alt = $2\n| module1 = {{Infobox reality competition season \n | host = $7\n | judges = $5\n | num_contestants = $10\n | winner = $15\n | runner_up = $19\n}}\n| network = $9\n| first_aired = $3\n| last_aired = $4\n}} --Gonnym (talk) 21:27, 7 October 2020 (UTC)[reply]

Oof, that's a bit nuts. I'll try to dig into that regex soon, but I'm starting to think that using an AWB module to save, store, and modify those parameters to convert the template use might be the best way forward. The other thing we should probably do is find out where the template is used alongside {{infobox television}}, since we shouldn't convert it to "season" if that's there (instead, just folding it in). Primefac (talk) 22:10, 7 October 2020 (UTC)[reply]
@Gonnym and Primefac: maybe an oversimplification, but since {{Infobox reality talent competition}} is now converted into a full wrapper, can't we just subst it? (after cleaning it up for subst, ofc)? ProcrastinatingReader (talk) 15:28, 17 October 2020 (UTC)[reply]
Template substitution isn't my strong side so if you know how to do it, then I'm all for it. --Gonnym (talk) 11:47, 20 October 2020 (UTC)[reply]
I know how to turn it into a subst-able wrapper, however I don't know how if it achieves the acceptable results here. Primefac has looked at specific cases above it seems, so he may be better placed than me to answer that part. But if it works, that makes achieving the merge easier than regex-hell. ProcrastinatingReader (talk) 23:27, 8 November 2020 (UTC)[reply]
In a word, yes; I think cleaning up post-merge will be easier than all of the complex silliness above. I'll put it on my list of things to do. Right after I make my list of things to do... Primefac (talk) 15:45, 10 November 2020 (UTC)[reply]
@Gonnym and Favre1fan93: I've made a substable wrapper in the sandbox based on your wrapper. Go to any transclusion, plug a /sandbox on the end (or change to {{Infobox reality talent competition/sandbox}} if it's using a redirect) and preview. This should be how it looked pre-wrapper. Then chuck a subst: in front and preview, and this is how it'd look being substed. By my eye, testing on a couple of pages, this all looks correct, however the winner's national origin isn't being mapped in the wrapper (Gonnym?). ProcrastinatingReader (talk) 21:24, 11 November 2020 (UTC)[reply]

Navigation templates

Link templates

  • None currently

Other

2020 February 1Football_squad_player ( links | transclusions | talk | doc | sandbox | testcases )

Meta

To convert

Templates for which the consensus is that they ought to be converted to some other format are put here until the conversion is completed.

To substitute

Templates for which the consensus is that all instances should be substituted (e.g. the template should be merged with the article or is a wrapper for a preferred template) are put here until the substitutions are completed. After this is done, the template is deleted from template space.

To orphan

These templates are to be deleted, but may still be in use on some pages. Somebody (it doesn't need to be an administrator, anyone can do it) should fix and/or remove significant usages from pages so that the templates can be deleted. Note that simple references to them from Talk: pages should not be removed. Add on bottom and remove from top of list (oldest is on top).

  • None currently

Ready for deletion

Templates for which consensus to delete has been reached, and for which orphaning has been completed, can be listed here for an administrator to delete. Remove from this list when an item has been deleted. See also {{Deleted template}}, an option to delete templates while retaining them for displaying old page revisions.

Leave a Reply