问题描述
在php从5.6更新到7之后,Symfony 3引发此异常:
After a php update from 5.6 to 7, Symfony 3 raise this exception:
Symfony 3是否与PHP 7不兼容?相同的代码在php 5.6上工作
is Symfony 3 incompatible with PHP 7? same code work on php 5.6
composer show -i输出:
composer show -i output:
doctrine/annotations v1.2.7 Docblock Annotations Parser
doctrine/cache v1.6.0 Caching library offering an o...
doctrine/collections v1.3.0 Collections Abstraction library
doctrine/common v2.6.1 Common Library for Doctrine p...
doctrine/dbal v2.5.3 Database Abstraction Layer
doctrine/doctrine-bundle 1.6.1 Symfony DoctrineBundle
doctrine/doctrine-cache-bundle 1.2.2 Symfony Bundle for Doctrine C...
doctrine/inflector v1.1.0 Common String Manipulations w...
doctrine/instantiator 1.0.5 A small, lightweight utility ...
doctrine/lexer v1.0.1 Base library for a lexer that...
doctrine/orm v2.5.3 Object-Relational-Mapper for PHP
incenteev/composer-parameter-handler v2.1.2 Composer script handling your...
jdorn/sql-formatter v1.2.17 a PHP SQL highlighting library
kriswallsmith/assetic v1.3.2 Asset Management for PHP
monolog/monolog 1.17.2 Sends your logs to files, soc...
paragonie/random_compat v1.2.2 PHP 5.x polyfill for random_b...
psr/log 1.0.0 Common interface for logging ...
sensio/distribution-bundle v5.0.3 Base bundle for Symfony Distr...
sensio/framework-extra-bundle v3.0.12 This bundle provides a way to...
sensio/generator-bundle v3.0.3 This bundle generates code fo...
sensiolabs/security-checker v3.0.2 A security checker for your c...
swiftmailer/swiftmailer v5.4.1 Swiftmailer, free feature-ric...
symfony/assetic-bundle v2.7.1 Integrates Assetic into Symfony2
symfony/monolog-bundle v2.8.2 Symfony MonologBundle
symfony/phpunit-bridge v2.8.1 Symfony PHPUnit Bridge
symfony/polyfill-intl-icu v1.1.1 Symfony polyfill for intl's I...
symfony/polyfill-mbstring v1.1.1 Symfony polyfill for the Mbst...
symfony/polyfill-php56 v1.1.1 Symfony polyfill backporting ...
symfony/polyfill-php70 v1.1.1 Symfony polyfill backporting ...
symfony/polyfill-util v1.1.1 Symfony utilities for portabi...
symfony/swiftmailer-bundle v2.3.9 Symfony SwiftmailerBundle
symfony/symfony v3.0.3 The Symfony PHP framework
twig/twig v1.24.0 Twig, the flexible, fast, and...
php.ini
[opcache]
opcache.enable=1
opcache.memory_consumption=128
opcache.interned_strings_buffer=16
opcache.max_accelerated_files=6000
opcache.use_cwd=1
opcache.validate_timestamps=1
opcache.save_comments=1
opcache.fast_shutdown=1
推荐答案
重新启动httpd服务可以清除此错误.
Restarting the httpd services can clear this error.
遇到错误后无法重现该错误,但是这可能是PHP崩溃,进而导致不完整状态,使错误消息卡在httpd服务的缓冲区响应中,然后为每个错误提供服务从那时起,一直到对该服务上正在服务的任何虚拟主机的单个请求,直到该服务被终止.
Have not been able to reproduce the error after experiencing it but it could be a PHP crash that in turn causes an incomplete state that makes the error message get stuck in the buffer response of the httpd service, it is then served for every single request to any vhost being served on that service from then on until the service is killed.
信贷 Scott Flacks 发表评论.
这篇关于PHP 7,Symfony 3:致命错误1抽象方法,因此必须声明为抽象或实现其余方法的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!