We have moved our forum to GitHub Discussions. For questions about Phalcon v3/v4/v5 you can visit here and for Phalcon v6 here.

Phalcon 4 on PHP 7.4 error

Hi I have upgrade for Phlacon 4 on PHP 7.2 to Phlacon 4 on PHP 7.4 Now it seems like Phalcon crashes when I initialize a new model, it happens right after the initialize() function is executed on the model. This is on a Rest API project using Phalcon\Mvc\Micro and when try to post something to the API, I get a empty response. I do not get any errors.

I have created a simple test file to test in php command line to see if I can get some error.

<?php
$di = new Phalcon\Di\FactoryDefault();
class TestModel extends Phalcon\Mvc\Model {}
$x = new TestModel();
echo "hello";
?>

When I run this I get the following error: Segmentation fault (core dumped) and the script works on the older version of PHP

Phalcon version: 4.0.6 PHP version: 7.4.8

I can not find any know issues on Phalcon 4 on PHP 7.4

Please help. Let me know if you need more info.

edited Jul '20

Segmentation faults are never your fault (no pun intended). You should put this in as a bug on GitHub.



145.0k
Accepted
answer

There is a reported bug currently, check github issues, you need to recompile phalcon from source against php 7.4.8

Thanks, will check out github issues

There is a reported bug currently, check github issues, you need to recompile phalcon from source against php 7.4.8