Hello software maintainers.
While using a script that relies upon the "date" utility to reconstruct
historical calendar dates, I came across errors when submitting only
the first day of the month April for the years 1981, 1982, 1982 and
1984. I assume no April fools is intended here for public domain
software!
Here is a transcript of test dates that supposedly are not a radical
departure from mostly free human readable date strings I use in the
bash shell:
On a Lenovo x250:
ozoma@ozoma-ThinkPad-X250:$ date +%s --date="1980-04-01"
323384400
ozoma@ozoma-ThinkPad-X250:$ date +%s --date="1981-04-01"
date: invalid date ‘1981-04-01’
ozoma@ozoma-ThinkPad-X250:$ date +%s --date="1982-04-01"
date: invalid date ‘1982-04-01’
ozoma@ozoma-ThinkPad-X250:$ date +%s --date="1983-04-01"
date: invalid date ‘1983-04-01’
ozoma@ozoma-ThinkPad-X250:$ date +%s --date="1984-04-01"
date: invalid date ‘1984-04-01’
ozoma@ozoma-ThinkPad-X250:$ date +%s --date="1984-04-02"
449697600
ozoma@ozoma-ThinkPad-X250:$ date +%s --date="1985-04-01"
481147200
rc linux-image-unsigned-4.4.0-194-generic
4.4.0-194.226+8.0trisquel3 amd64 Linux-libre
kernel image for version 4.4.0
-------------------
I also observed the same results as described above on all other
systems and other laptops in my possession:
acer: 4.15.0-166.174+9.0trisquel9
asus: 4.4.0-197.229_8.0trisquel3
asus: 5.4.0-91.102+10.0trisquel9
----------------------
Hopefully my usage of the date utility is not in some way abnormal.
Regards.
Martins