首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >Typo3缓存刷新异常-如何调试

Typo3缓存刷新异常-如何调试
EN

Stack Overflow用户
提问于 2020-11-06 16:21:23
回答 2查看 169关注 0票数 0

我在服务器上有一个停靠的TYPO3实例,并尝试手动刷新typo3缓存。因此,我使用以下命令在我的docker容器中执行此操作:

代码语言:javascript
复制
vendor/.bin/typo3cms cache:flush

但是,它会失败并返回以下错误:

代码语言:javascript
复制
[ TYPO3\CMS\Core\Error\Exception ]
Warning: rename(): The first argument to copy() function cannot be a directory in /home/app/vendor/typo3/cms/typo3/sysext/core/Classes/Utility/GeneralUtility.php line 2432

我如何调试它并找出问题所在?

使用-vvv进行完整堆栈跟踪

代码语言:javascript
复制
  [ TYPO3\CMS\Core\Error\Exception ]
  Warning: rename(): The first argument to copy() function cannot be a directory in /home/app/vendor/typo3/cms/typo3/sysext/core/Classes/Utili
  ty/GeneralUtility.php line 2432


Exception code: 1

Exception trace:
#0 ()
   vendor/helhum/typo3-console/Classes/Console/Error/ErrorHandler.php:86
#1 Helhum\Typo3Console\Error\ErrorHandler->handleError()
#2 rename()
   typo3/sysext/core/Classes/Utility/GeneralUtility.php:2432
#3 TYPO3\CMS\Core\Utility\GeneralUtility::flushDirectory()
   vendor/helhum/typo3-console/Classes/Compatibility/TYPO3v87/Service/CacheLowLevelCleaner.php:31
#4 Helhum\Typo3Console\TYPO3v87\Service\CacheLowLevelCleaner->forceFlushCachesFiles()
   vendor/helhum/typo3-console/Classes/Console/Command/Cache/CacheFlushCommand.php:69
#5 Helhum\Typo3Console\Command\Cache\CacheFlushCommand->execute()
   vendor/symfony/console/Command/Command.php:255
#6 Symfony\Component\Console\Command\Command->run()
   vendor/symfony/console/Application.php:1000
#7 Symfony\Component\Console\Application->doRunCommand()
   vendor/helhum/typo3-console/Classes/Console/Mvc/Cli/Symfony/Application.php:169
#8 Helhum\Typo3Console\Mvc\Cli\Symfony\Application->doRunCommand()
   vendor/symfony/console/Application.php:271
#9 Symfony\Component\Console\Application->doRun()
   vendor/symfony/console/Application.php:147
#10 Symfony\Component\Console\Application->run()
   vendor/helhum/typo3-console/Classes/Console/Core/Kernel.php:148
#11 Helhum\Typo3Console\Core\Kernel->handle()
   vendor/helhum/typo3-console/Scripts/typo3-console.php:30
#12 {closure}()
   vendor/helhum/typo3-console/Scripts/typo3-console.php:32
#13 require()
   vendor/helhum/typo3-console/typo3cms:3

cache:flush [--files-only]
EN

回答 2

Stack Overflow用户

回答已采纳

发布于 2020-11-06 18:48:12

这是一个已知问题,已通过version 5.8.6 of the TYPO3 Console修复。

票数 2
EN

Stack Overflow用户

发布于 2020-11-07 03:55:24

好吧,问题是:如何调试它。即使现在解决了问题,这也可能会有所帮助:

你得到了异常跟踪。您在GeneralUtility.php的2432行设置了一个断点。

如果您已经设置了xdebug,那么您只需要使用适当的选项启动命令行命令,例如使用-e来生成调试信息。

您还可以查看DDEV。我最后一次尝试它时,它很好地运行了调试器,请参阅https://ddev.readthedocs.io/en/stable/users/step-debugging/

我通常将xdebug与PhpStorm结合使用。

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/64711066

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档