Open forabi opened 7 months ago
Actually it seems to happen for any months I tried, wouldn't it make sense for the result to normalized in days?
Hi!
You're right, it's a normalization thing.
This is covered in the docs as expected behaviour. Units like "month" are ambiguous. It's impossible to know if you wanted to count it as months or days without a bit more information, so it defaults to what is safe.
To achieve what you want, you can pass the result through .normalize()
, using the 2nd argument to specify the original reference date. Bit verbose, but that's how it works at the moment.