Template talk:Random item

Auto-detect range
Wouldn't it be easier to auto-detect the number of parameters rather than requiring its manual entry? (not watching, please )  czar  02:34, 28 December 2019 (UTC)

Requested move 2 March 2022

 * The following is a closed discussion of a requested move. Please do not modify it. Subsequent comments should be made in a new section on the talk page. Editors desiring to contest the closing decision should consider a move review after discussing it on the closer's talk page. No further edits should be made to this discussion. 

The result of the move request was: Not moved. (non-admin closure) Turnagra (talk) 08:57, 2 April 2022 (UTC)

Template:Random item → Template:Random – Random item invokes Module:Random, whereas {{}}, which is a shortcut redirect to Random number, does not invoke it. Per numerous past moves, this template must be moved to match the name of module it invokes. ---CX Zoom(he/him) (let's talk&#124;contribs) 07:44, 2 March 2022 (UTC) — Relisting. 🐶 EpicPupper (he/him &#124; talk) 18:49, 9 March 2022 (UTC)


 * Oppose. While Random item invokes the module, it specifically invokes the item function. Module:Random also has a number function which Random number could be changed to use (haven't tested so no idea what the difference is). I would however support making Random either a template disambiguation page or a wrapper of the module that also accepts the function as a parameter. Gonnym (talk) 09:22, 4 March 2022 (UTC)

The discussion above is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.
 * Oppose per Gonnym; convert random into a templatedabpage and list the two templates and module -- 65.92.246.142 (talk) 22:35, 13 March 2022 (UTC)
 * I do support this proposal but the module name & template name would still continue to be different, despite of consensus in the past that they should be named similar, wherever possible. ---CX Zoom(he/him) (let's talk&#124;contribs) 10:11, 14 March 2022 (UTC)

Splitting Template:Random image
Currently Template:Random image redirects here. I plan to turn that into a separate template is basically the same but properly records file usage with MediaWiki. This will allow bots and other tools to know that all the images are being used on that page and not just the one that happens to be showing at the current moment. My main motivation is that commons:User:KrinkleBot will be able to autoprotect all images when they're being seleted randomly like was done in Today's featured article/September 19, 2022.

The necessary Lua code is in the sandbox and you can see that it works as expected in my sandbox and with this Quarry. All of the images are registered as being used (e.g. if you look at the file description page on Commons they'll show up), but no image is ever displayed. Legoktm (talk) 19:34, 15 October 2022 (UTC)