我有一个在本地服务器上运行没有问题的工作项目(并且还在线运行)。在作曲家更新后,我在 prod 环境中不断收到以下错误(感兴趣的是, dev 环境正常工作):
Warning: require() [function.require]: Unable to access
[...]/vendor/symfony/monolog-bundle/Symfony/Bundle/MonologBundle/MonologBundle.php in
[...]/vendor/symfony/symfony/src/Symfony/Component/ClassLoader/XcacheClassLoader.php
on line 105
Warning: require([...]/vendor/symfony/monolog-bundle/Symfony/Bundle/MonologBundle/MonologBundle.php)
[function.require]: failed to open stream: No such file or directory in
[...]/vendor/symfony/symfony/src/Symfony/Component/ClassLoader/XcacheClassLoader.php
on line 105
Fatal error: require() [function.require]: Failed opening required
'[...]/vendor/symfony/monolog-bundle/Symfony/Bundle/MonologBundle/MonologBundle.php'
(include_path='.') in
[...]/vendor/symfony/symfony/src/Symfony/Component/ClassLoader/XcacheClassLoader.php
on line 105
我无法找到问题所在。作曲家生成的autoload_psr4.php
文件看起来不错:
<?php
// autoload_psr4.php @generated by Composer
$vendorDir = dirname(dirname(__FILE__));
$baseDir = dirname($vendorDir);
return array(
'Symfony\\Bundle\\MonologBundle\\' => array($vendorDir . '/symfony/monolog-bundle'),
'Monolog\\' => array($vendorDir . '/monolog/monolog/src/Monolog'),
);
可以在[...]/vendor/symfony/monolog-bundle/MonologBundle.php
中找到丢失的文件。
我尝试多次更新作曲家/清除缓存,但没有成功。我身边有问题,还是作曲家或者xcache搞砸了?
否则,我可以以某种方式关闭xcache吗?至少在问题解决之前。