Template talk:Infobox darmstadtium

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia
WikiProject iconElements Template‑class
WikiProject iconThis template is supported by WikiProject Elements, which gives a central approach to the chemical elements and their isotopes on Wikipedia. Please participate by editing this template, or visit the project page for more details.
TemplateThis template does not require a rating on Wikipedia's content assessment scale.

Duplicate reference defininition[edit]

A few weeks ago, this article started causing a duplicate reference definitio error. It looks like the error is coming out of the {{infobox darmstadtium}} template. People are doing all kinds of crazy metaprogramming in templates, and as far as I know there are no tools for diagnosing any errors -- even for visualizing the different includes and parameters that are being passed around.

Is there any way to diagnose the problem? -- Mikeblas (talk) 17:20, 9 February 2019 (UTC)[reply]

re Mikeblas. I have removed the duplicate. Cause was: recently, |electron configuration= was moved to centralised data for reuse throughout enwiki. The Haire ref was moved with it. That ref also remained in this infobox (unused), causing the warning.
Having refs named in infoboxes is tricky, but I think it is important enough to do so. When used also in the article body, best is to copy/paste the named ref exactly (to prevent spelling differences). Does this answer your question? -DePiep (talk) 14:29, 10 February 2019 (UTC)[reply]
I'm glad you've made a fix. Thanks! Thing is, my question still remains: I dug through the reference definitions and was hard-pressed to understand where the duplicate reference definition came from. -- Mikeblas (talk) 15:30, 10 February 2019 (UTC)[reply]
Yes, very hard to get it. Nicely, wiki software recognises similar named references. But is also accepts these named refs whan defined repeatedly. So I practice: make sure all same-named same-references are copypasted (=spelled the same for wiki software) between infobox, centralised data and article bodytext. This is not the diagnoose tool you ask for, but a solution it is. May be more difficult in other situations (these element infoboxes are ~easy to check).
One other solution: put the ref in a single template (like {{CIAAW2016}}). Guarantees code copy always. -DePiep (talk) 16:01, 10 February 2019 (UTC)[reply]