Jump to content
 







Main menu
   


Navigation  



Main page
Contents
Current events
Random article
About Wikipedia
Contact us
Donate
 




Contribute  



Help
Learn to edit
Community portal
Recent changes
Upload file
 








Search  

































Create account

Log in
 









Create account
 Log in
 




Pages for logged out editors learn more  



Contributions
Talk
 



















Contents

   



(Top)
 


1 Year  
8 comments  













Module talk:Arbcom election banner




Page contents not supported in other languages.  









Module
Talk
 

















Read
Edit
View history
 








Tools
   


Actions  



Read
Edit
View history
 




General  



What links here
Related changes
Upload file
Special pages
Permanent link
Page information
Get shortened URL
Download QR code
 




Print/export  



Printable version
 
















Appearance
   

 






From Wikipedia, the free encyclopedia
 


This is an old revision of this page, as edited by 2d37 (talk | contribs)at03:53, 7 October 2023 (Year: Reply). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.
(diff)  Previous revision | Latest revision (diff) | Newer revision  (diff)

Year

@Xaosflux: I note that Special:Diff/1042160676, updating the year in the name of the category for voter guides from 2020 to 2021, has made the previous years' ACE templates also now point to Category:Wikipedia Arbitration Committee Elections 2021 voter guides. More generally, I wonder, is there a reason that year is always the current year, rather than being taken as a parameter so that the ACE templates wouldn't need to specify so many link targets?2d37 (talk) 22:49, 3 September 2021 (UTC)[reply]

@2d37: because no one built and implemented that parameter - feel free to mock up a change if you would like, getting ready for this year is more important that making old years work for me right now though. — xaosflux Talk 23:08, 3 September 2021 (UTC)[reply]
@Xaosflux: Changes are in Module:Arbcom election banner/sandbox (and Module:Arbcom election banner/sandbox/doc) for review when there's time (perhaps after the election). I addressed both sentences of my original comment, which may constitute doing too much at once (although I hope the edit history is broken into small enough 'commits' for easy review). I've checked that the existing uses of the module appear to continue to work with the sandbox version, with no changes needed to the existing uses. —2d37 (talk) 02:32, 20 September 2021 (UTC)[reply]
@2d37: thank you for the ping, I wonder if @Mr. Stradivarius: would be able to go over this? — xaosflux Talk 09:40, 20 September 2021 (UTC)[reply]
@2d37 and Xaosflux: Thank you for the update to the sandbox! I've made a couple of tweaks to it. First, I switched from and/or-style syntax to if/else-style syntax in getYearAndName - there was nothing wrong with the logic itself, but I think the if/else style is easier to read, especially when you have to raise errors. I also tweaked the code that handles date arguments to avoid the and/or style when raising errors there as well. I'm not so sure about the naming of the new |root= parameter - I think this may be clearer as "basepage", or something else that makes it clearer that we are talking about a page. Other than that, this seems good to go. Feel free to use or ignore my suggestions and code as you see fit, and feel free to deploy this to the main module. Best — Mr. Stradivarius ♪ talk ♪ 13:35, 20 September 2021 (UTC)[reply]

I switched from and/or-style syntax to if/else-style syntax in getYearAndName

I initially wrote getYearAndName with an ifelse chain and changed it to andor conditionals because I thought it was too verbose; I don't object to its being changed back to ifelse.

the new |root= parameter - I think this may be clearer as "basepage"

I'll rename |root=to|rootpagename= for clarity. It was originally |base=, but I realized that it's meant to be the ROOTPAGENAME, not the BASEPAGENAME. It shouldn't normally need to be used anyway.
2d37 (talk) 01:53, 21 September 2021 (UTC)[reply]
Hey 2d37, thanks for making this fix! I just stumbled upon this error recently as well and pushed a naive fix (which I've now reverted). It looks like your much more elegant solution didn't make it from the sandbox to the main version; would you be able to take a look and see if it could be implemented? Thanks! — Frostly (talk) 03:27, 4 October 2023 (UTC)[reply]
Thanks for your interest in getting those changes applied. I can try to forward-port those changes some time this month (after the present weekend, at the earliest), but I'm not sure I would be better at doing so than anyone with the relevant Lua knowledge, now that more than two years have passed since I wrote that code. :-) Feel free not to wait for me if I take too long. —2d37 (talk) 03:53, 7 October 2023 (UTC)[reply]

Retrieved from "https://en.wikipedia.org/w/index.php?title=Module_talk:Arbcom_election_banner&oldid=1178987554"





This page was last edited on 7 October 2023, at 03:53 (UTC).

This version of the page has been revised. Besides normal editing, the reason for revision may have been that this version contains factual inaccuracies, vandalism, or material not compatible with the Creative Commons Attribution-ShareAlike License.



Privacy policy

About Wikipedia

Disclaimers

Contact Wikipedia

Code of Conduct

Developers

Statistics

Cookie statement

Mobile view



Wikimedia Foundation
Powered by MediaWiki