Bug #77854 [Com]: DateTime object comparison wrong
Edit report at https://bugs.php.net/bug.php?id=77854&edit=1
ID: 77854
Comment by: Stephan dot Hartmann at flyeralarm dot com
Reported by: Stephan dot Hartmann at flyeralarm dot com
Summary: DateTime object comparison wrong
Status: Open
Type: Bug
Package: Date/time related
Operating System: Ubuntu
PHP Version: 7.1.28
Block user comment: N
Private report: N
New Comment:
@derick@php.net sry, typo: should read Mar 09
Previous Comments:
------------------------------------------------------------------------
[2019-04-10 21:54:03] derick@php.net
(built: Mar 0 2019 03:44:52)
Mar 0? That's... peculiar.
------------------------------------------------------------------------
[2019-04-10 12:35:15] Stephan dot Hartmann at flyeralarm dot com
https://github.com/Talarion291/phpalpinebug
check this out for minimal example
------------------------------------------------------------------------
[2019-04-08 14:09:40] Stephan dot Hartmann at flyeralarm dot com
Using the php:7.1.27-cli-stretch image from dockerhub passes the testscript.
Using the php:7.1.28-cli-alpine image from dockerhub fails the testscript, hinting that the whole
php:7.1.*-cli-alpine images are affected.
------------------------------------------------------------------------
[2019-04-08 08:00:22] Stephan dot Hartmann at flyeralarm dot com
More precisely its the 4 week old PHP 7.1.27 (cli) (built: Mar 0 2019 03:44:52)
php 7.1-cli-alpine e6492c17926d 4 weeks ago 70MB
------------------------------------------------------------------------
[2019-04-08 07:42:43] Stephan dot Hartmann at flyeralarm dot com
After compiling 7.1.27 locally on my machine (Ubuntu 18.04.02) this minimal example passes, while on
the current "php:7.1-cli-alpine" docker image from docker hub this minimal example fails.
Please try to reproduce bug using said image.
Additionally using $date = new DateTime('2019-04-05 12:34:56.123456'); passes both times,
while using $date = new DateTime(); fails in docker image;
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
https://bugs.php.net/bug.php?id=77854
--
Edit this bug report at https://bugs.php.net/bug.php?id=77854&edit=1
Thread (10 messages)