TBD (notes to self) See Template talk:Death-date and age -J JMesserly (talk) 20:37, 26 February 2009 (UTC)[reply]
This template does formatting (df/mf) options, as a legacy feature to maintain its ability to fully replace {{birth date and age}}. As far as I'm concerned, the formatting is a separate feature entirely and I don't care if it is in or out. All I care about is the microformat emission. -J JMesserly (talk) 19:11, 27 February 2009 (UTC)[reply]
This template should maybe based upon the {{Birth date and age}} date so the logic only resides one place? I.e. Call Birth date and age with it's parameters from this template. Then we also make sure that the new template conform to the other template in every way. Nsaa (talk) 08:29, 21 March 2009 (UTC)[reply]
- Are you proposing the new templates be dumbed down to be compatible with the old template? The old templates:
- Don't support non gregorian dates,
- no microfomats emitted for death dates?
- No time zone support
- No BCE support
- I can go along with a merge that simply redirects to either code base, but the idea of a deep merge is untenable. You'd have to add numeric versions of these parameters, eg parameter 10 for gregorian year, parameter 11 for gregorian month, etc. If I have this wrong, then what new parameters do you propose that would be recognized by the old templates.
- Note that this is a comprehensive inquiry. What we decide should be applicable across the entire family of microformat date templates including
{{start date}}
, and {{end date}}
. With this merge also imply that plain text date templates such as {{marriage}}
have compatible numeric syntax introduced? -J JMesserly (talk) 17:41, 10 April 2009 (UTC)[reply]
I don't completely understand how or why this template is different from Template:Birth date and age, other than the hyphen that separates "birth" and "date." The templates documentation doesn't offer much explanation. Can somebody explain the difference and perhaps add it to the documentation? Or, is it perhaps a duplicate?
• Supāsaru 20:53, 16 December 2014 (UTC)[reply]
- @Supasaru: The hyphen-less template takes in the data in a different way (yyyy|mm|dd) from this template (date as text). They are serving the same purpose, but some work would be needed to convert the entered data to align these two templates. SFB 21:47, 26 March 2015 (UTC)[reply]
On 16 March 2025 @Gonnym: added BCE and Julian calendar support, at least according to the documentation. I would like to view the test cases that were used to verify this. Jc3s5h (talk) 23:16, 16 March 2025 (UTC)[reply]
I prepared some test cases at User:Jc3s5h/sandbox3. The test cases are based on Calendrical Calculations: The Ultimate Edition by Edward Reingold and Nachum Dershowitz (Cambridge University Press, 2018, Appendix C). The bce parameter does not appear to work.
If the bce parameter is supposed to apply to both the Julian date and the ISO 8601 date, there are a few days where there is a conflict. For example, December 31, 1 BC, Gregorian is the same day as January 2, AD 1, Julian. The same parameter can't serve for both. Jc3s5h (talk) 01:09, 17 March 2025 (UTC)[reply]
I added two more dates to the test cases. Now that the template explicitly supports BCE dates, one would also expect it to support the years CE 11 through CE 99. But the year 70 is interpreted as 1970. Jc3s5h (talk) 02:03, 17 March 2025 (UTC)[reply]
I have edited the talk page of an early editor of this template, J JMesserly, inquiring whether this template, and related templates, are worth saving. Reasons to question their worth are
- The coding style is very hard to understand, and seems only meaningful to the original editor.
- the method for implementing time zones is undocumented.
- The template does not appear to look up the offset from Greenwich on the date passed to the template.
- It's claimed that Julian dates are supported, but there is no documentation or example of how to use it.
- It's claimed that BCE dates are supported, but there is no documentation or example of how to use it.
Jc3s5h (talk) 12:57, 17 March 2025 (UTC)[reply]
- I don't have answers but I have wondered why a birth date and age would be needed with an ancient date. Another template is {{birth date and age}} which does not have time zones or Julian dates. It gives an error with ages above 150. It does that to guard against user error since the date is supposed to be the birth date of a still alive person. Johnuniq (talk) 23:19, 17 March 2025 (UTC)[reply]
- The point about people older than 150 years makes sense, but there are other members of this family of templates that could be used on people born more than 150 years ago, if only we knew how they were supposed to work, and if they did what they were supposed to. Jc3s5h (talk) 23:23, 17 March 2025 (UTC)[reply]
Jonesey95 uncovered a bug in this template while test the new Module:Person date. Mainly ages over 130 should produce an error message.
{{b-da|Dec 12, 1795}}
→ Dec 12, 1795 (1795-12-12) (age 229)
{{bda|1795|12|12}}
→ Error: Invalid birth date for calculating age
Not sure how/why this isn’t working but wanted to leave the message here… —Zackmann (Talk to me/What I been doing) 21:23, 18 September 2025 (UTC)[reply]
- That's a feature! Someone born in 1795 would be 230 years old. It's an invalid birth date for calculating age. Johnuniq (talk)
- @Johnuniq: I think you misread my comment. I was pointing out that {{bda}} handles the case of someone who is super old but this template {{b-da}} does NOT handle that case, I.e. does NOT produce an error message. —-Zackmann (Talk to me/What I been doing) 09:03, 22 September 2025 (UTC)[reply]
{{b-da|25 Dec 1965}}
is generating the following.
25 Dec 1965<span style="display:none"> (<span class="dtstart bday">1965-12-25</span>)</span> (age <span class="currentage"></span>59)
Note that the “59” is NOT within the span tags. Zackmann (Talk to me/What I been doing) 22:54, 18 September 2025 (UTC)[reply]
- @Johnuniq: the above seems to be an issue with Module:Age… Can you take a look? —Zackmann (Talk to me/What I been doing) 22:55, 18 September 2025 (UTC)[reply]
- That is not a bug but could be described as laziness, although efficient would be more accurate. The
currentage
span was agreed in April 2018 at Template talk:Age#Detecting if the 4/5/6 parameters are used. When Module:Age was used to implement {{age}}, I found that there were many cases where invalid dates had been used (preventing them was the main motivation for using the module). The purpose of the span was to allow searches to find where {{age}} had been used with no second date. That was often an error and Frietjes did a heap of cleaning up although I don't know exactly how. A strange issue is that I don't know how the example template above is calling Module:Age—something is invoking it but after a quick look, I can't see how. Johnuniq (talk) 01:09, 19 September 2025 (UTC)[reply]
- Johnuniq, a stripped down version is that
{{Age|1965|12|25 }}
is returning <span class="currentage"></span>59
with the age outside of the span tag, which is probably on Line 235? Frietjes (talk) 15:21, 22 September 2025 (UTC)[reply]
- @Frietjes: Thanks, I had looked at {{b-da}} but somehow missed the obvious fact that it is calling {{age}} which calls Module:Age. From memory, the module is the way it is because the code tries to be generic and is called from various places in the module. That makes putting the closing span in the right place tricky. I think I pointed this out years ago when it was implemented and someone (I think you) said it was ok the way it was because the only thing needed was that the text "currentage" be present in the result. The span is not intended to identify which text is the current age, just the fact that the age calculation was based on the current date because only the start date was entered. Johnuniq (talk) 06:05, 23 September 2025 (UTC)[reply]
- Johnuniq, yes, we were just using it as a marker so we could find cases where a current age was being displayed when an "age at time of signing" or "age at time of competition" was desired. Frietjes (talk) 14:37, 23 September 2025 (UTC)[reply]
So yet another issue has been raised in my work on Module:Person date. Compare the following:
{{birth date and age text|1990}}
→1990 (1990) (age 35)
{{birth date and age text|October 1990}}
→October 1990 (1990-10) (age 35)
{{birth year and age|1990}}
→1990 (age 34–35)
Now case 1 I’m not really concerned about because in that circumstance you should really be using {{birth year and age}}. But in case #2 (in which I am intentionally calling {{currentmonth}}), since the DAY of the month is not known, an age range of a year should be displayed.
—Zackmann (Talk to me/What I been doing) 09:11, 22 September 2025 (UTC)[reply]