Jump to content

Help talk:CS1 errors

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia

How to find "Script warning: One or more {{cite journal}} templates have maintenance messages;" errors

[edit]

I'm editing Atomic clock which at the moment has 212 references. Before saving my edits, I preview the article and the above message is displayed. I know such nits are common and may be preexisting and not in anything I added. The question is "which one of the 212 references needs fixing?"

To see it yourself, start at https://en.wikipedia.org/w/index.php?title=Atomic_clock&action=edit&oldid=1241897325 and hit "Show preview".

I suppose best would be an #anchor that was linked to directly. Second, a pattern I could search for. But "warning", "maintenance", "template", "{{cite" and "help" all fail to turn up anything.

Then there's the "messages may be hidden" postamble. Does that mean hidden in the public rendered version (reasonable for minor things), or hidden in the preview I'm looking at this instant? The latter seems stupid and useless. Editing and reloading custom CSS styles is a giant PITA that risks losing my in-progress Wikipedia edits.

After much effort, I asked the browser for an unstyled render and found appended to reference #4 ("First accuracy evaluation of NIST-F2" the text " {{cite journal}}: Empty citation (help): CS1 maint: DOI inactive as of June 2024 (link)". It turned out someone omitted the final digit 4 from the doi:10.1088/0026-1394/51/3/174.

An easy fix, made infuriating by the difficulty of finding the freaking error message. It should not require such an epic struggle.

There really should be a clickable link, or a documented searchable text string (like "CS1 maint:") to enable an editor to easily find the offending citation template. 97.102.205.224 (talk) 09:43, 6 September 2024 (UTC)[reply]

I clicked and looked, before I realized you found it, and you know the search string now. The doc pages of templates are open to editing by all, and you are welcome to add appropriate text to the doc page of the type you suggest to aid other editors in finding the problem more quickly than you were able to, and it would be appreciated. Mathglot (talk) 10:34, 6 September 2024 (UTC)[reply]
@Mathglot: I can propose an {{edit semi-protected}} for the documentation, but the way I did it depends on my using Firefox; other browsers don't have View > Page Style > No Style menu options in the base browser. You need to enable developer extensions, add a plug-in, or enter some esoteric javascript incantation. (I think viewing the HTML source and searching that would work, but it's pretty cluttered and hard to read.) 97.102.205.224 (talk) 12:33, 6 September 2024 (UTC)[reply]
First this is not an error, this is a maintenance message. This is hidden by default because broken DOIs are common and do not usually required any action from the reader or most editors (bots handle this usually). That's why it's flagged as maintenance, and not error.
Second, there is a searchable string, and that searchable string is indeed "CS1: maint". If you followed the help link in the preview message, you'd know this. To enable it, you must be a logged in editor with a custom .css file in your userspace. Headbomb {t · c · p · b} 14:45, 6 September 2024 (UTC)[reply]
@Headbomb: Um, you'll find the string is actually "CS1 maint:" (notice the location of the colon). Second, that information does not appear anywhere on the linked help page. Please go and search yourself if you doubt me! You can find mention of Category:CS1 maint: archived copy as title, but that's not described as text that appears in the maintenance message.
Seriously, "If you... you'd know this" comes across as pretty impatient, and it's not justified. Reading the linked help was the first thing I did, and the help page was spectacularly useless; thus my plaint on this, the corresponding talk page.
I fail to see the point of having the visibility of the header not linked the visibility of the messages, but that's a larger-scale issue; in the short term the confusingness can be mitigated with better documentation. Just for example, "hidden by default" would be much clearer than "may be hidden", as it gives the reader some clue about "depending on what?"
I'll try to come up with a proposed edit to fix it, it's just going to be pretty involved so I've been putting it off. 97.102.205.224 (talk) 05:50, 7 September 2024 (UTC)[reply]

If you click the help link, you are taken to Help:CS1_errors#Controlling_error_message_display, which I will partly reproduce and bold/embiggen here:

Preview messages

This is only a preview; your changes have not yet been saved! → Go to editing area Script warning: One or more {{cite book}} templates have maintenance messages; messages may be hidden (help).

Error and maintenance messages

By default, Citation Style 1 and Citation Style 2 error messages are visible to all readers and maintenance messages are hidden from all readers.

To display maintenance messages in the rendered article, include the following text in your common CSS page (common.css) or your specific skin's CSS page and (skin.css). (Note to new editors: those CSS pages are specific to you, and control your view of pages, by adding to your user account's CSS code. If you have not yet created such a page, then clicking one of the .css links above will yield a page that starts "Wikipedia does not have a user page with this exact name." Click the "Start the User:username/filename page" link, paste the text below, save the page, follow the instructions at the bottom of the new page on bypassing your browser's cache, and finally, in order to see the previously hidden maintenance messages, refresh the page you were editing earlier.)

.mw-parser-output span.cs1-maint {display: inline;} /* display Citation Style 1 maintenance messages */

After (error and/maintenance) messages are displayed, it might still not be easy to find them in a large article with a lot of citations. Messages can then be found by searching (with Ctrl-F) for "(help)" or "cs1".

Headbomb {t · c · p · b} 11:04, 7 September 2024 (UTC)[reply]

Check |url= value suggestion

[edit]

The suggested IDN Conversion Tool Verisign at #Check |url== value has a limitation as mentioned Only enter the domain in the tool and not the full url. But i found another site where it is more convenient and it support for whole url, also that site has other features like url encoding/percent encoding etc. (non-promotional) punycoder. So might add that their instead of Verisign.––kemel49(connect)(contri) 17:09, 6 January 2025 (UTC)[reply]

[edit]

What's the correct recourse for the 'External link in |<param>=' warning when citing a page whose title contains a URL for whatever reason. Is the intention that the URL be omitted or that the warning remain and generate noise?. The current suggestions are only to move the URL to a different tag (e.g. where the editor has placed it in the title field in error). DDFoster96 (talk) 21:34, 7 February 2025 (UTC)[reply]

It this a hypothetical or have you got a real-life issue? Link to it so we can all know what it is you're talking about?
Trappist the monk (talk) 21:48, 7 February 2025 (UTC)[reply]

Semi-protected edit request on 19 February 2025

[edit]

The wikipedia interface to edit CSS files has the following warning when using the suggested message display snippet: Warning: Element (span.cs1-maint) is overqualified, just use .cs1-maint without element name.


Change span.cs1-maint to .cs1-maint

Change span.cs1-hidden-error to .cs1-hidden-error JamesLear314 (talk) 06:40, 19 February 2025 (UTC)[reply]

 Done ~ Rusty meow ~ 19:34, 23 February 2025 (UTC)[reply]
@JamesLear314 and Rusty Cat: The new version without span fails to display the messages for me on Drosophila connectome in all three tested browsers so I'm reverting the edit. PrimeHunter (talk) 23:14, 27 February 2025 (UTC)[reply]
@PrimeHunter: It does not display indeed. Personally, I use
.mw-parser-output .cs1-maint, /* display Citation Style 1 maintenance messages */
.mw-parser-output .cs1-hidden-error, /* display hidden Citation Style 1 error messages */
.mw-parser-output .harv-error { /* display Module:Footnotes errors */
    display: inline !important; 
}
and it works fine (albeit with a warning about using !important), but if I remove !important the messages do not show. ~ Rusty meow ~ 00:14, 28 February 2025 (UTC)[reply]

Last name error

[edit]

I'm seeing an error message because an author has the last name of bureau:

Davies, Roger L.; Kuntschner, Harald; Emsellem, Eric; Bacon, R.; Bureau, M.; Carollo, C. Marcella; Copin, Y.; Miller, Bryan W.; Monnet, G.; Peletier, Reynier F.; Verolme, E. K.; de Zeeuw, P. Tim (February 2001). "Galaxy Mapping with the SAURON Integral-Field Spectrograph: The Star Formation History of NGC 4365". The Astrophysical Journal. 548 (1): L33 – L36. arXiv:astro-ph/0011254. Bibcode:2001ApJ...548L..33D. doi:10.1086/318930. {{cite journal}}: |last5= has generic name (help)

Is there a work-around? – Praemonitus (talk) 16:19, 14 March 2025 (UTC)[reply]

|last5=((Bureau))Help:Citation Style 1 § Accept-this-as-written markup
Trappist the monk (talk) 16:23, 14 March 2025 (UTC)[reply]
Oh okay. I just found I could use a Unicode character to remediate it, but your approach is probably more kosher. Thanks. Praemonitus (talk) 16:28, 14 March 2025 (UTC)[reply]

ISBN checksum error

[edit]

Hi everyone!

Recently, on ICD-11, I cited this book.

The page lists three ISBNs for it:

  • 9789290612487 (‎PDF)‎
  • 9789290612483 (‎Paperback)‎
  • 9789290613053 (‎Hardbound)‎

I linked to the ebook, so I figured I had to use the first one, the PDF ISBN. However, when I copy-pasted it into Cite book, this happened:

WHO Western Pacific Region (2007). WHO International Standard Terminologies on Traditional Medicine in the Western Pacific Region. ISBN 9789290612487. {{cite book}}: Check |isbn= value: checksum (help)

This checksum error does not occur with the other two ISBNs.

Did the WHO use an erroneous ISBN here? Or is this a mistake on the Wikipedia side?

- Manifestation (talk) 17:03, 11 April 2025 (UTC)[reply]

Your paperback and pdf isbns are identical except for the checksum. The '7' checksum appears to be correct for the 10-digit form:
{{isbn|9290612487}}ISBN 9290612487
looks to me like WHO incorrectly stated the ISBN as ISBN 978 92 9061 248 7 Parameter error in {{ISBN}}: checksum on the reverse of the title page.
You can remove the 978 prefix and write |isbn=92-9061-248-7 or you can write |isbn=((978-92-9061-248-7)) which will suppress the error message and add the article to Category:CS1 maint: ignored ISBN errors.
Trappist the monk (talk) 18:01, 11 April 2025 (UTC)[reply]
Ok thanks! I've used the 10-digit number, which seems to be recognized by all the big sites (e.g. Google, Worldcat).
Btw... I don't think the template should throw a maintenance message when a misprinted ISBN is used with "(())". A maintenance message implies that something needs to be maintained, i.e. fixed. But if a printed book uses an incorrect ISBN, and if that book was never re-printed with the correct ISBN, then us Wikipedians have nothing to fix.
Instead of this maint. category, perhaps there should just be a category called Category:Articles citing books with incorrect ISBNs, emphasizing that these erroneous ISBNs are not to be fixed. At least not by us. Cheers, Manifestation (talk) 19:33, 12 April 2025 (UTC)[reply]