User talk:Furey/apply.c.c broken redirects

From NetHackWiki
Jump to navigation Jump to search

I favor mass deletion. It's unlikely any of these pages are doing useful work today. If it's possible to do a mass search for "What links here" and find any links first, that would be useful to know. Furey (talk) 01:08, 6 June 2024 (UTC)

As ever, I favor fixing over deleting - while in this case (and after some thought) I'm not entirely opposed to the latter, I consider the ".c.c" => ".c" fix to be the simpler option. That said, I'm also tempted to test something.
Looking forward to test results. Furey (talk) 02:25, 8 June 2024 (UTC)

Also suspecting "unables" was meant to be something else. --Umbire the Phantom (talk) 02:04, 8 June 2024 (UTC)

I'm also not entirely certain that it really encourages disregarding of broken redirects as stated, though I can at least easily grasp the logic behind the assertion - it's not that it's unreasonable, moreso that it might require the hypothetical user to be viewing it from exactly your vantage point to come to that conclusion, if this makes any sense? --Umbire the Phantom (talk) 02:12, 8 June 2024 (UTC)
BrokenRedirects.png

And as it turns out, any new broken redirects are listed above the existing suite of broken redirects from the bot move, which seems to be ordered by default in order of most recently created. While I obviously still would like to resolve those bot-move redirects, this at minimum seems to resolve the possibility of them obscuring the other broken ones, provided it's not specific to me. --Umbire the Phantom (talk) 02:34, 8 June 2024 (UTC)

Thanks for the screenshot. It did put the new one on top, this time. Like you, I'd like to resolve these broken pages and not have to work around their existence. Furey (talk) 02:49, 8 June 2024 (UTC)
Likewise. I'll see about passing this to some other admins and the like, if they have any input to contribute. --Umbire the Phantom (talk) 02:58, 8 June 2024 (UTC)

I believe mass-editing and mass-deleting these are roughly the same complexity; I honesty lean a bit towards deletion, but would be fine with either. I can look into building a mass-edit or mass-delete script, but as you might have guessed from my activity level of late, it could take a while. If anyone has any type of editing/deletion script (preferably Python) already written, modifying it to do this task would be much faster.

There is a MediaWiki extension that would make deletion a lot simpler, but paxed would have to install it, and enable it for admins. The "mass delete" (Special:Nuke) we have won't work - it only allows deleting recently created pages, as far as I can tell.

On a related note, that whole prettifying of the wiki-hosted 3.4.3 code (which is necessary for these redirects) completely broke referring to anything in there by line number, including via the refsrc template. Line number (rather than function name) is honestly the more common way to do source refs, given that functions can be dozens or hundreds of lines long. Right now, even the 3.4.3 examples on Template:refsrc are broken. What do people think of ditching the prettification (and never-going-to-be-finished annotation) entirely, and just reverting those source pages to their original state? -Ion frigate (talk) 03:00, 8 June 2024 (UTC)

instead of extension:DeleteBatch, maybe the php version at https://www.mediawiki.org/wiki/Manual:DeleteBatch.php would be less admin setup? Furey (talk) 03:12, 8 June 2024 (UTC)
My skillset does not include sql, but perusing the example on https://www.mediawiki.org/wiki/Manual:DeleteBatch.php , we just need a select where t.old_text = "REDIRECT" and t.old_text = ".c.c", to pick up the distinctive .c.c contents. Furey (talk) 03:31, 8 June 2024 (UTC)
Oh, no SQL queries needed. I just regex-ed the broken redirects page into a plain text file list here; the page renders horribly, but if you click "edit" the text is correct for a plain file list (one line per file) that you'd feed a script like that PHP version of DeleteBatch. But we'll still need someone with server-level access to actually do that.
And yes, that would delete every broken redirect, but as of right now, every broken redirect begins with Source:Ref/343, so we won't be losing anything valuable. -Ion frigate (talk) 04:28, 8 June 2024 (UTC)
Awesome. There are 2307 lines in this file and each one matches "Source:Ref/343/". This looks correct to me. (1) Double check with Umbire that they are okay with deletion. (2a) Proffer the list to dtype for DeleteBatch, or (2b) DIY. Wow, gonna get some cleanup on this wiki! Furey (talk) 05:17, 8 June 2024 (UTC)
Okay, I left a note at User talk:Dtype; if there's a better way to get in touch with him one of you may want to do it (my presence in the NetHack world is basically this wiki and very occasionally reddit). -Ion frigate (talk) 16:34, 8 June 2024 (UTC)
Absolutely fine with it. --Umbire the Phantom (talk) 05:23, 8 June 2024 (UTC)
I write refsrc's with line numbers every day, and they work in .h files, too. I would not mind ditching prettification. Furey (talk) 03:12, 8 June 2024 (UTC)
I've been working where I can on that, and I'm reasonably certain we don't even have to abandon annotating, sectioning the lines by function name or what-have-you in order to make them searchable by line number - I decided to take a stab for sake of reference in this discussion, and it's as simple as removing __MIXEDSYNTAXHIGHLIGHT__ from the source code articles in question (moving license template optional). --Umbire the Phantom (talk) 03:08, 8 June 2024 (UTC)
Yeah, that seems to work just fine, so indeed we don't have to remove all the formatting. Nice find! -Ion frigate (talk) 16:39, 8 June 2024 (UTC)
For what it's worth, and as food for thought, I wouldn't be opposed to function specific redirects in the far-off future, once we have the larger on-wiki source code problem solved (that problem being "only having up to 3.6.1" and "lacking other parts of earlier sources" among other things) - we'd probably be better off using the direct function names though, rather than what was attempted previously with the bot. --Umbire the Phantom (talk) 05:12, 9 June 2024 (UTC)