You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
DateInterval d property is 0 instead of real value 28 #18183
DateTimeInterface::diff the date 2025-02-28 23:00:00 UTC (2025-03-01 00:00:00 Europe/Budapest) is used instead of the real time before php version 8.1..
Why it happens to your php version 8.3.19 is hard to say. Please, Can you test what the timezone_version_get() function returns?
These versions have long been out of bugfix support, the lowest bugfix-supported version is 8.3.x. Given that this works in those versions I'm closing this as invalid.
Activity
bdtarcsa commentedon Mar 29, 2025
Anyway, it is working well in 8.1.25
ndossche commentedon Mar 29, 2025
It works on my machine and on 3v4l: https://3v4l.org/EXC9L
Is this maybe timezone related?
bdtarcsa commentedon Mar 29, 2025
I do not know. Maybe. Based on DateTime object the timezone is Europe/Budapest:
object(DateTime)#6 (3) {
["date"]=>
string(26) "2025-03-01 00:00:00.000000"
["timezone_type"]=>
int(3)
["timezone"]=>
string(15) "Europe/Budapest"
}
object(DateTime)#7 (3) {
["date"]=>
string(26) "2025-03-29 00:00:00.000000"
["timezone_type"]=>
int(3)
["timezone"]=>
string(15) "Europe/Budapest"
}
hormus commentedon Apr 1, 2025
DateTimeInterface::diff the date 2025-02-28 23:00:00 UTC (2025-03-01 00:00:00 Europe/Budapest) is used instead of the real time before php version 8.1..
Why it happens to your php version 8.3.19 is hard to say. Please, Can you test what the timezone_version_get() function returns?
bdtarcsa commentedon Apr 10, 2025
The timezone_version_get() function returns with this:
2025.2
bdtarcsa commentedon Apr 10, 2025
Sorry, I was looking at the wrong version number of PHP.
Correct version numbers are 8.0.30 and 7.4.33.
As I can see in the snipett the result is the same what I detected.
On my dev machine the PHP version is 8.1.25 and timezone version is 2023.3 and there is no problem.
And as I said earlier there was no problem in November for example or in last 8 years. Interesting.
carlosbuenosvinos commentedon Apr 13, 2025
I don't see the issue. As @nielsdos mentions, checking all PHP versions, behaviour is consistent.
ndossche commentedon Apr 13, 2025
These versions have long been out of bugfix support, the lowest bugfix-supported version is 8.3.x. Given that this works in those versions I'm closing this as invalid.