Module:Resolve category redirect

@Tom.Reding: should Module:Navseasoncats use Module:Resolve category redirect instead of function rtarget?

Module:Resolve category redirect is a fork (made by me) of the clever code you wrote in function rtarget. However, Module:Resolve category redirect has now diverged a little, with some tweaks I made to reject incompatible characters. Also, the code uses a list of redirects to ((Category redirect)), which may need maintenance.

Wouldn't it be better to have the code in just one place? I know it's a bit cheeky of me to suggest that my fork should usurp its parent, but I don't think that two versions of the same code is a great idea. Module:Resolve category redirect has kinda take off, and is no longer the wee niche tool I thought it would be. BrownHairedGirl (talk) • (contribs) 17:58, 18 June 2023 (UTC)[reply]

@BrownHairedGirl: yes, it should! I can do that soon.   ~ Tom.Reding (talkdgaf)  13:23, 2 July 2023 (UTC)[reply]
@BrownHairedGirl: on closer inspection, function rtarget performs NSC-specific operations in its for-loop that are incompatible with Module:Resolve category redirect's current functionality - like evaluating ((Title year)) in ((Category redirect))'s parameter, and adding it to a NSC tracking category if that fails. Currently, there's no way to do this with Module:Resolve category redirect. RCR would have to return a pass/fail flag to be useful in this way, to tell the caller whether it's returning the passed cat because of a failure, or because there's no redirect to follow, and it would have to do this without interfering with RCR's current usage.   ~ Tom.Reding (talkdgaf)  13:42, 3 July 2023 (UTC)[reply]
Thanks for the diligent scrutiny, @Tom.Reding. I hadn't considered that issue, and parts of it probably relate to functionality which I removed when creating Module:Resolve category redirect. So, my bad for not recalling that.
Also, I recently added to RCR some code to ignore titles with templates in them, so that's a further divergence.
Note that RCR doesn't handle ((title year)) and ((title decade)), causing problems kindly spotted by the wonderful @Fayenatic london. So I did an AWB run to replace them with actual numbers. Obviously, new uses of those templates will be created in good faith, so it might be helpful to add that functionality to RCR, if either of us ever has the energy.
Credit where credit's due – it was Frietjes. (here) – Fayenatic London 16:00, 3 July 2023 (UTC)[reply]
Ah. Sorry @Frietjes. And thanks to @Fayenatic london for the correction. BrownHairedGirl (talk) • (contribs) 19:49, 9 July 2023 (UTC)[reply]
However, one aspect that should always remain common to the two modules is the list of redirects to ((Category redirect)). Would it be a good idea to move that to a shared module, to a avoid having two copies of it? Or would it be better to just add a wee comment to each module noting that the two should always be in sync? BrownHairedGirl (talk) • (contribs) 14:05, 3 July 2023 (UTC)[reply]
@BrownHairedGirl: done! I created a shard module, Module:Template redirect regex, as a general repository for redirect regexes, should it be useful for other templates, and updated the NSC & RCR sandboxes to use it, for inspection/comment before publishing live. Both templates' testcases look good.   ~ Tom.Reding (talkdgaf)  19:11, 9 July 2023 (UTC)[reply]
Great work yet again, @Tom.Reding. The testcases all look fine to me and I like the way that you have made it a general repository for redirect regexes.
Please feel free to go live. BrownHairedGirl (talk) • (contribs) 20:13, 9 July 2023 (UTC)[reply]
 Done!   ~ Tom.Reding (talkdgaf)  14:56, 16 July 2023 (UTC)[reply]

Displaying only the next and previous year

((2021 wildfires)) includes two links to the next and previous year, without the current year:

◀ 2020 2022 ▶

Can ((navseasoncats)) display links in this format, or is there another template that does this? Jarble (talk) 17:20, 11 October 2023 (UTC)[reply]

Why would you only want two links in a cat as opposed to the current work which shows multiple other years? Also, I have removed the links to the templates - we should not link other templates in templates - and have replaced them with article links. Primefac (talk) 08:49, 12 October 2023 (UTC)[reply]

Requested move 22 October 2023

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: moved to Template:Category series navigation. This option has at least some level of support from most participants here and is the clear consensus choice. (closed by non-admin page mover) Elli (talk | contribs) 03:37, 31 October 2023 (UTC)[reply]


– The current name for this category is too specific. Its documentation says it "is intended to be a minimal-input, near-universal template for automatically navigating most sequential categories", and only two of the 15 examples immediately following are are for seasons. Thus, the current name violates TMP, which says "[t]emplate function should be clear from the template name". Of course, the proposed name is longer, but we can use/create redirects as needed .
Two other notes. There is also the (current) name of Template:Irregular chronology category navigation, which was previously called Template:Irregular navseasoncats before a WP:BOLDMOVE. There was a previous discussion at Template talk:Navseasoncats/Archive 1#Requested move 25 May 2019, which resulted in no consensus. However, the proposed name at that discussion was overly broad which resulted in a smattering of different suggestions.
Pinging participants of that earlier discussion: @Amakuru, BD2412, Fayenatic london, Gonnym, Marcocapelle, Steel1943, and Tom.Reding.
HouseBlastertalk 00:09, 22 October 2023 (UTC)[reply]
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.