Jump to content

Wikipedia:Date formattings/script/MOSNUM dates/bugs

From Wikipedia, the free encyclopedia

This is an old revision of this page, as edited by Ohconfucius (talk | contribs) at 10:30, 22 February 2014 (→‎Not working: gremlins). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.

Untitled

August, 2007 – July, 2008. Is it possible to get it to remove the commas where there's no date? Tony (talk) 04:26, 11 August 2012 (UTC)[reply]

<ref>[http://www.usatoday.com/news/world/2008-09-10-Haiti-floods_N.htm UN seeks almost $108 million for Haiti floods]. USA Today (9 October 2010)</ref> 

Incomplete conversion of abbreviated date strings

at Beedi

$amount

Comma between date and an unrelated number

USS_Edwin_A._Howard_(DE-346)

Comma removal from an unrelated term and publication year

Billaea

Protection

protected string not restored

may

'may' not always month name

B-2 may cost

spurious comma

[2]

 Done -- Ohconfucius ping / poke 03:15, 8 December 2012 (UTC)[reply]

cricket

capitalisation of "dec"

[3] "January - 1 May 1944" becomes " – 1 January May 1944"

Question

Hi again! Just wondering why the script updates the date within {{use mdy dates}} and {{use dmy dates}}. I would think it would be more beneficial to indicate that the original decision for the article's date format, not the most recent time someone updated the article. Thanks! GoingBatty (talk) 01:52, 4 June 2013 (UTC)[reply]

  • These were not designed to be historic markers at the outset, but I guess it could change. Didn't think the original date is all that important since many are changed per WP:TIES – luckily there are next to no contested alignments.

    Because of the Wiki contribution model, articles get changed, updated, added to. The thought process up to now is that the tags are changed each time the articles are swept. If a long time has elapsed since it was processed, there are greater chances of format drift needing to be corrected. Hasn't happened yet, but the plan is that, once an automated system gets under way, the 'older' articles can be cleaned up systematically in equally neat batches. -- Ohc ¡digame!¿que pasa? 02:09, 4 June 2013 (UTC)[reply]

That's an excellent point - thanks for the explanation! GoingBatty (talk) 02:23, 4 June 2013 (UTC)[reply]

Bug report

Hi again! On "And I Love Her", your ALL dates to dmy script doesn't change |date= 9/27/11 - could it be the space between the equal sign and the date? Thanks! GoingBatty (talk) 14:36, 6 July 2013 (UTC)[reply]

Also, on Riddick (film), your ALL dates to mdy script doesn't change |accessdate=8.9.12 - is this by design, since it could be 8 September or August 9? Thanks! GoingBatty (talk) 14:50, 6 July 2013 (UTC)[reply]

  • I seem to recall thinking there was too strong a possibility of false positives with slash dates when the year is stated as two-digit number. The rule as written only converts dates with 4-digit years. You need to click on the separate 'US slash dates' button to convert those. Same goes for the second case, which is worse because it's genuinely ambiguous. -- Ohc ¡digame!¿que pasa? 14:56, 6 July 2013 (UTC)[reply]

Bug report

On the Windows 8 article, the ALL dates to mdy script changes:

(2013-03-26). Retrieved on 2013-07-17.

to

(March 26, 2013). Retrieved on 2013-07-17.

Why doesn't it fix both dates? Thanks! GoingBatty (talk) 23:15, 17 July 2013 (UTC)[reply]

Dates not changed

There appears to be a problem with the script when there are two dates that need to be converted in a reference. The script converts the first date only. You can get it to convert both by running the script a second time on the article. I am using all dates to DMY format option. You can see this on this edit that saved without realising one of the dates was not converted. Keith D (talk) 18:59, 12 August 2013 (UTC)[reply]

Not loading in toolbox

I no longer see the links in my Toolbox for your MOSNUM dates scripts in Firefox 22 and IE10, although I can still see your Fix sources links. I haven't changed User:GoingBatty/vector.js, and tried clearing my cache, upgrading to FF 23, and rebooting. Any ideas? Thanks! GoingBatty (talk) 02:05, 16 August 2013 (UTC)[reply]

I have the same problem and looked yesterday. I think the problem is this change. Keith D (talk) 18:24, 16 August 2013 (UTC)[reply]
May be worth giving Ohconfucius a ping. Keith D (talk) 20:42, 17 August 2013 (UTC)[reply]
Others have already contacted Ohconfucius here and here. User talk:Ohconfucius says he's on a short wikibreak. GoingBatty (talk) 21:12, 17 August 2013 (UTC)[reply]
I have looked at the change and looks like the brackets are unbalanced. I have inserted a bracket in the script and the entries now appear in my toolbox again. Hope this fixes the problem, if not will have to wait until Ohconfucius is back. Keith D (talk) 23:41, 17 August 2013 (UTC)[reply]
Good job! It's fixed. ;) Teammm talk
email
01:54, 18 August 2013 (UTC)[reply]

Firefox Update

It seems that the recent Firefox browser update 23.0.1 has stopped me from being able to use the script. Just letting you know. Teammm talk
email
13:37, 17 August 2013 (UTC)[reply]

It's not caused by the Firefox update, as I have the same issue with FF 22 and IE 10 - see section above. GoingBatty (talk) 14:31, 17 August 2013 (UTC)[reply]
I know, I saw it. Thank you. Teammm talk
email

Bug report - "All dates to mdy" adding $1

@Ohconfucius: - Could you please double check this edit? I believe it's now adding a $1 when running the "All dates to mdy" script (e.g. Try Adam Sandler or DC Universe Animated Original Movies. Thanks! GoingBatty (talk) 00:15, 9 September 2013 (UTC)[reply]

Suggestion to expand All dates to mdy script

Hi Ohconfucius! You may want to expand your All dates to mdy script so it fixes creative formats such as "27th May, 2014" - see History of Firefox#Version 30. Thanks! GoingBatty (talk) 23:12, 25 September 2013 (UTC)[reply]

All dates vs. body dates

Could you please clarify the difference between the "all dates" vs "body dates" scripts? The documentation states that the "all dates" script changes "dates in the body of the text as well as in the reference sections", so I thought that the "body dates" scripts did NOT change the dates in the reference sections. However, when I ran the "Body dates to mdy" script on United States federal government shutdown of 2013, it wanted to change the body dates and reference dates. Thanks! GoingBatty (talk) 13:15, 1 October 2013 (UTC)[reply]

Talkback

Hello, Date formattings. You have new messages at Wikipedia:Gadget/proposals#Please make the MOSNUM dates script into a gadget.
You can remove this notice at any time by removing the {{Talkback}} or {{Tb}} template.

If you reply, then please reply there instead of here. Thank you! —Unforgettableid (talk) 01:59, 28 November 2013 (UTC)[reply]

Suggestion to fix more CS1 errors

Would it be possible to expand your wonderful script to detect or fix more Category:CS1 errors: dates issues? I have some examples at User:GoingBatty/CS1 errors dates. Thanks! GoingBatty (talk) 04:29, 2 December 2013 (UTC)[reply]

  • As you know, I already have a MOSNUM script that mostly works on dates. I ran it on your examples and you can see what it does there. This work will have to be shared between the MOSNUM and SOURCES scripts. The problem is to determine the boundary between these scripts. I'll do some thinking to see where these rules can properly fit. Regards, -- Ohc ¡digame! 05:35, 2 December 2013 (UTC)[reply]
    • I've now incorporated most of the changes, split between the two scripts. Those that involve manipulating dates will be found in the MOSNUM script whilst those more general fixes or those involving only formatting are in the sources script. See how you get along with them being where they are. Regards, -- Ohc ¡digame! 07:46, 2 December 2013 (UTC)[reply]
    • Thinking out loud here, I think the removal of the {{Start date}} template might work outside of citation templates, but the harm done is minimal as there is possibility under Lua for metadata to be gathered from infoboxes. As to the removal of parentheses, I'm tempted to broaden it for all parameters as I don't really see where such can be useful. What do you think? -- Ohc ¡digame! 14:41, 2 December 2013 (UTC)[reply]
      • Thanks so much for updating your scripts! I think there are people passionate about having {{Start date}} in infoboxes, so you might get some feedback if you start removing them. I can't think of a reason why any citation parameter would need to start and end with parentheses. Thanks! GoingBatty (talk) 01:11, 6 December 2013 (UTC)[reply]
        • At last count, there was one metadata-gatherer, his loyal supporter and his trusty steed ;-). Unfortunately, hundreds of infobox templates have instructions to place them inserted by the former. But the advance has been stopped dead in its tracks at least for the moment. I'm looking forward to them realising at last that the less cumbersome methods of gathering can be had through Lua without those ugly templates that people don't understand. -- Ohc ¡digame! 01:46, 6 December 2013 (UTC)[reply]

Rotten Tomatoes score

Would you be interested in expanding your ALL dates to mdy script so that it would add |mdy=y to {{Rotten Tomatoes score}}? See 20 Feet from Stardom as an example where this would be useful. Thanks! GoingBatty (talk) 03:04, 21 December 2013 (UTC)[reply]

cite journal / contribution=

Happy New Year... just made a fix to my scripts due to a new one with {{cite journal}} this. You might need to test and adjust your script accordingly. Dl2000 (talk) 16:12, 1 January 2014 (UTC)[reply]

Bug report - removes pp-move template

Hi Ohconfucius! When I run the All dates to dmy script on Upendra, the script wants to remove {{pp-move|expiry=2014-07-13 17:51:53|small=yes}}. Is this by intent, or is this a bug? Thanks! GoingBatty (talk) 18:32, 13 January 2014 (UTC)[reply]

Hmmm - Maybe I was reviewing this edit, and then decided to edit the article, but instead clicked the "undo" link. If then I clicked on the All dates to dmy script, it would have appeared that your script was removing the template, whereas instead it would have been my error. Thank you for confirming your script is working as designed! GoingBatty (talk) 04:16, 14 January 2014 (UTC)[reply]
Phew!!! <wiping the sweat off my brow> Thanks for fessing up! -- Ohc ¡digame! 04:59, 14 January 2014 (UTC)[reply]

Potential unwanted DEFAULTSORT refactoring

Might want to test the script regarding {{DEFAULTSORT: - for some reason, the DEFAULTSORT on Composed upon Westminster Bridge, September 3, 1802 has a tendency to be hit with a refactor, possibly due to embedded punctuations and the like. Dl2000 (talk) 15:33, 1 February 2014 (UTC)[reply]

Possible bug

I clicked on "Body dates to mdy" with this edit, and it caught only the one dmy date. I did "ISO to mdy" tried again in a second edit, and it caught all of the ISO dates. Not sure what that was about. – Muboshgu (talk) 15:12, 3 February 2014 (UTC)[reply]

No, my bad. "ISO to mdy" doesn't seem to work. – Muboshgu (talk) 15:47, 3 February 2014 (UTC)[reply]
  • Hi, from your two diffs, the script seems to be working according to design. The "Body dates to mdy" button ensures consistency by removing all instances of dmy dates anywhere in the article in favour of mdy. But because some editors prefer their reference dates in yyyy-mm-dd format, the "Body dates to mdy" button respects this preference by not flipping yyyy-mm-dd dates within references. Editors who deliberately want to convert all dates into mdy should click the two buttons as you did. The short cut for that is to click on the "all dates to mdy" button. I don't understand what you said about the "ISO to mdy" button not working, unless you made these changes manually. The "ISO to mdy" button will take all yyyy-mm-dd dates, mainly in the reference section, and convert them into mdy dates. You will find a more detailed description of the script actions at the documentation page. -- Ohc ¡digame! 16:07, 3 February 2014 (UTC)[reply]

Template - Vgrelease new

Hello, could you make the script work with the Template:Vgrelease new template please. - X201 (talk) 10:40, 12 February 2014 (UTC)[reply]

Thanks. - X201 (talk) 16:56, 12 February 2014 (UTC)[reply]

Not working

This tool does not seem to be working for some reason on this page. I'm trying to convert all dates to the dmy format but no matter how many times I try, I see no difference between the changes. I've tried clicking "ALL dates to dmy" and "Body dates to dmy" multiple times, but none of them has so far worked. Smtchahal (talk) 14:10, 21 February 2014 (UTC)[reply]

  • I loaded your vector file into mine to test. I have the sidebar buttons noted on the left side, and both of the two buttons you refer to in the script seem to work. So the problem at your end is not related to loading the script, nor to problems with the script itself. Another user had similar issues last week, and apparently solved it by going over to monobook skin. I don't understand why one should work but not the other. But by all means try if that works. -- Ohc ¡digame! 15:47, 21 February 2014 (UTC)[reply]
  • It worked for me on Highway (2014 Hindi film) - are you having an issue just with that article or with every article? Good luck! GoingBatty (talk) 17:10, 21 February 2014 (UTC)[reply]
    • Good point, Batty. Smtchahal, you are suggesting that you have the buttons but they don't work for Highway. The script has not changed since 13 February. It seems that you installed the script on 20 February, and your contributions show no edit summary generated by the script, so I assume the script hasn't worked for you at all.

      As I said, I loaded your vector.js, so I'm using effectively what you're using. I have the buttons, and it executes and seems to work correctly. When you click the button, do you get an edit summary and a diff? And if you don't get a diff, what do you see when you click on the 'Show changes' button? -- Ohc ¡digame! 02:03, 22 February 2014 (UTC)[reply]

I do see the script buttons as shown in the screenshot in this script's documentation, and I do see an automatically generated edit summary ("date formats per [[WP:MOSNUM]] by [[WP:MOSNUMscript|script]]") when I click one of those, but I see "no difference" between the revisions. Clicking Show changes doesn't help either. Also, I tried the same thing with my sandbox without any success. Smtchahal (talk) 06:50, 22 February 2014 (UTC)[reply]
I'm not sure what did it, but I moved the script from my /vector.js to /monobook.js, then reverted it, using quotation marks instead of apostrophes, and it worked. Smtchahal (talk) 07:47, 22 February 2014 (UTC)[reply]
I'm pleased to hear you succeeded through perseverance. I really can't explain the phenomenon and would put it down to "gremlins". Hope you find the script useful. Regards, -- Ohc ¡digame! 10:30, 22 February 2014 (UTC)[reply]