-
-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Uncaught Error: Access to undeclared static property: Phalcon\\Di::$_default #12803
Comments
@mohamedziada Could you please provide script / steps to reproduce? |
Something similar in #12056 |
If @mohamedziada used Windows - yes |
Can you reproduce with OPcache disabled? Do you use ApcMetaData? |
ownCloud users are experiencing similar issue with PHP 7 on linux (openSUSE) too : EDIT: in case of ownCloud, the issue seems to appear when there are some aborted requests/connections. We could also try a similar test case like suggested in the ownCloud thread: |
@hakimio but this test case doesn't have phalcon calls so how it's phalcon issue? |
@Jurigag you put your Phalcon calls in your index.php and it tries to simulate cancelled requests. Edit: inside your index.php, could be sth simple like the following:
|
I just never had this problem on debian 7/ubuntu 14 and php 7/5.6, this is really weird. For sure it's somehow OS/apache related, never had this on php-fpm. |
This never happens on PHP 5.6. It's only PHP 7 issue. I guess, that's because they made some major changes to the way GC and static properties work in PHP 7. It's easy to just blame the OS without investigating the issue. |
Im not blaming the OS, im blaming apache. The similar thing that in all those issues people use mod_php - i think somehow mod_php + phalcon is problem, maybe OS related too. The best will be if someone can do some vagrantbox/docker to reproduce issue. Maybe @sjinks could then do some digging to figure this out. |
@sergeyklay I use CentOS 7.3.1611 with compile Apache and PHP and Phalcon as above
is not a good solutions as i use Phalcon for speed not to sleep :) public/index.php
https://gist.github.com/mohamedziada/b347247f40bd8f54e8e7717132c4965c |
The sleep() call was just for a simple test case. Solution is to run php-cgi with fcgi+apache or nginx, |
no effect still the same error |
What??? Do you actually understand what I am saying? |
@hakimio yes i try sleep() ; for test |
@hakimio you can explain to me, maybe i understand wrong |
Ok, can you provide some virtual machine or docker image which can reproduce the issue? |
@hakimio this is wt i do now, Virtual Machine (vagrant) and will test, but it may takes time from me, cuz i am not in my office next a few days |
I got the same issue after upgrading to PHP 7.1.1 and phalcon 3.1.2. |
@salva-flores as already mentioned in many places, use php-fpm/fcgi |
Close in favor of #12056 |
It works fine with PHP 5.6 but when I upgrade to PHP7 this error happens
Details
The text was updated successfully, but these errors were encountered: