-
Notifications
You must be signed in to change notification settings - Fork 7.9k
Interface "DateTimeInterface" not found #8358
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Does this also happen with OPcache disabled? If not, please try running OPcache without JIT, with function JIT and with tracing JIT. Would the issue happen then in all 3 cases? |
Hi @cmb69 ,
I haven't tried. It's enabled on both prod and local.
I worry that issue will not be reproduced at all once I just restart the container. As I mentioned above, the same issue was happening on prod and that was temperamental, i.e. just restart of docker container helped to stop failures. Moreover not every deployment (starting containers with new version of images) caused such failures. |
Maybe related: #8164 |
I have dumped |
Was it generated while the issue was happening ? You can post it on gist.github.com or send it to my email. You may consider the filenames to be sensitive. You can redact them, but please let me know if the CarbonInterface.php file was listed in there. |
@arnaud-lb , yes, I added a dumping line on top of the I redacted a little bit to skip my project's files. Yes, One detail you could be interested in — the issue happened at |
Thank you. Could you also share the opcache section of phpinfo() ? Are you using opcache.preload ? See also @cmb69's comment: knowing this would help to narrow the issue |
@arnaud-lb , @cmb69 , here is an opcache section of |
Thank you @SCIF For now I haven't succeeded in reproducing the issue locally. If someone else wants to look at this, here is what I tried: https://github.com/arnaud-lb/issue-8358 |
Hi @arnaud-lb , Appreaciate your efforts! Just to clarify — the issue I experienced in prod in past was not caused by The way we deploy prod is next:
|
May be fixed by #8297 |
@SCIF, could you please check this? Either build from source, or wait for PHP 8.1.6RC1 which is supposed to released on April, 28th. |
@arnaud-lb , thanks for your work an proposed fix! Could you please respond a few questions related?
@cmb69 , unfortunately, I don't meet this bug often. I mean, that's the very first time I experienced it locally. And based on past experience I met it in prod, just restart of container (even don't need to rebuild it) will «fix» the issue. |
I managed to produce a similar behavior (class not found caused by a leaked error), but I'm not sure that #8063 is the actual cause of this issue so I don't want to close it yet.
That's unlikely to affect only one thread.
If the issue disappears after an |
Hi @arnaud-lb , Thanks for the explanation! |
A similar problem occurs with functions. Now in production, with some periodicity, we catch errors of the lack of standard functions, like: So far, we are solving by restarting the docker container. |
I am going to close this as it looks like a duplicate of #8164 which has been fixed. If not, please open a new issue. |
Description
composer.lock:
Sometimes I can see:

Obviously, there is an import. And yes, I double checked on the filesystem.
No idea how to reproduce. Looks like just one thread is buggy because the issue is intermittent. I experienced the same bug in prod (no XDebug comparing to my current setup) but that has fixed/doesn't fail anymore. These days it reproduces on local machine and I'm happy to help to debug/narrow down this therefore don't restart docker :).
A bit of info:
PHP Version
8.1.4
Operating System
Docker php:8.1-fpm-bullseye
The text was updated successfully, but these errors were encountered: