date: day of month is incorrect for some months
I noticed that day of month is incorrect for some months:
$ for month in {01..12}; do cargo run -q date -d "1999-$month-01" +%d; done
31
31
28
01
01
01
01
01
01
01
31
30
Hi @cakebaker it's working fine, am i missing something?
for month in {01..12}; do cargo run -q date -d "1999-$month-01" +%d; done
01
01
01
01
01
01
01
01
01
01
01
01
btw, can i pick TODOs form date ?
@Agent-Hellboy what system do you run? I can reproduce on a Debian:
for month in {01..12}; do cargo run -q date -d "1999-$month-01" +%d; done
31
31
28
01
01
01
01
01
01
01
31
30
btw, can i pick TODOs form date ?
Sure, please note that some of the functionality is in https://github.com/uutils/parse_datetime
I haven't looked into the issue. @Agent-Hellboy if you want to take this one, pay attention to the timezone handling during date time formatting.
I haven't looked into the issue. @Agent-Hellboy if you want to take this one, pay attention to the timezone handling during date time formatting.
okay, should i create a new feature-flag named jiff inside the https://github.com/uutils/parse_datetime for all APIs used within the uu_date? and yes i will pay attention to timezone handling.
@Agent-Hellboy what system do you run? I can reproduce on a Debian:
ohh, I am on ubnutu only. is rustc 1.89.0-nightly (4d051fb30 2025-05-18) affecting in any way , recommend one is 1.85`
This issue is due to faulty handling of DST, so @Agent-Hellboy won't see the issue since there is no DST in India.
The issue is fixed by using the master branch of parse_datetime which uses jiff instead of chrono.
Closing this issue, it has been fixed in the meantime.