Upgrade 3.3 -> 4.0: Undefined index: psr3


(Andre Hohmann) #1

Good morning,

I tried to upgrade from 3.3 to 4.0.
At ./flow flow:cache:flush --force I get

$ ./flow flow:cache:flush --force
    PHP Notice:  Undefined index: psr3 in /var/www/vhosts/itoop.de/dev.itoop.de/Neos/Packages/Framework/Neos.Flow/Classes/Core/Booting/Scripts.php on line 249
    PHP Fatal error:  Uncaught Error: Class name must be a valid object or a string in /var/www/vhosts/itoop.de/dev.itoop.de/Neos/Packages/Framework/Neos.Flow/Classes/Core/Booting/Scripts.php:255
    Stack trace:
    #0 [internal function]: Neos\Flow\Core\Booting\Scripts::initializeSystemLogger(Object(Neos\Flow\Core\Bootstrap))
    #1 /var/www/vhosts/itoop.de/dev.itoop.de/Neos/Packages/Framework/Neos.Flow/Classes/Core/Booting/Step.php(52): call_user_func(Array, Object(Neos\Flow\Core\Bootstrap))
    #2 /var/www/vhosts/itoop.de/dev.itoop.de/Neos/Packages/Framework/Neos.Flow/Classes/Core/Booting/Sequence.php(107): Neos\Flow\Core\Booting\Step->__invoke(Object(Neos\Flow\Core\Bootstrap))
    #3 /var/www/vhosts/itoop.de/dev.itoop.de/Neos/Packages/Framework/Neos.Flow/Classes/Core/Booting/Sequence.php(111): Neos\Flow\Core\Booting\Sequence->invokeStep(Object(Neos\Flow\Core\Booting\Step), Object(Neos\Flow\Core\Bootstrap))
    #4 /var/www/vhosts/itoop.de/dev.itoop.de/Neos/Packages/Framework/Neos.Flow/Classes/Core/Booting/Sequence.php(111): Neos\Flow\Core\Booting\Seq in /var/www/vhosts/itoop.de/dev.itoop.de/Neos/Packages/Framework/Neos.Flow/Classes/Core/Booting/Scripts.php on line 255

In frontend I get

PHP Fatal error: Cannot inherit previously-inherited or override constant DIRECTORY_CLASSES from interface Neos\Flow\Package\PackageInterface in /var/www/vhosts/itoop.de/dev.itoop.de/Neos/Packages/Framework/Neos.Flow/Classes/Package/FlowPackageInterface.php on line 17

Packages/Framework/Neos.Flow/Classes/Core/Booting/Scripts.php

00310:             OpcodeCacheHelper::clearAllActive(FLOW_PATH_CONFIGURATION);

00311:             OpcodeCacheHelper::clearAllActive(FLOW_PATH_DATA);

00312:             self::executeCommand('neos.flow:core:compile', $settings);

00313:             if (isset($settings['persistence']['doctrine']['enable']) && $settings['persistence']['doctrine']['enable'] === true) {

00314:                 self::compileDoctrineProxies($bootstrap);

Any idea? Thank you.


Problems with Upgrade 3.3 -> 4.0
(Sebastian Helzle) #2

Hi Andre,

try deleting the Data/Temporary folder manually. I had the same issue.

Hope it helps


(Andre Hohmann) #3

Hi Sebastian,

I can flush the cache now also by CLI. But I get still this Exception:

$ ./flow flow:cache:flush --force
Force-flushed caches for "Development" context.
$ ./flow database:setcharset
PHP Fatal error:  Cannot inherit previously-inherited or override constant DIRECTORY_CLASSES from interface Neos\Flow\Package\PackageInterface in /var/www/vhosts/itoop.de/dev.itoop.de/Neos/Packages/Framework/Neos.Flow/Classes/Package/FlowPackageInterface.php on line 17

  Type: Neos\Flow\Core\Booting\Exception\SubProcessException
  Code: 1355480641
  File: Packages/Framework/Neos.Flow/Classes/Core/Booting/Scripts.php
  Line: 641

Open Data/Logs/Exceptions/20180504035513c1fc9f.txt for a full stack trace.


Exception #1355480641 in line 312 of /var/www/vhosts/itoop.de/dev.itoop.de/Neos/Packages/Framework/Neos.Flow/Classes/Core/Booting/Scripts.php: PHP Fatal error:  Cannot inherit previously-inherited or override constant DIRECTORY_CLASSES from interface Neos\Flow\Package\PackageInterface in /var/www/vhosts/itoop.de/dev.itoop.de/Neos/Packages/Framework/Neos.Flow/Classes/Package/FlowPackageInterface.php on line 17

Data/Logs/Exceptions/20180504035513c1fc9f.txt:

13 Neos\Flow\Core\Booting\Scripts::executeCommand("neos.flow:core:compile", array|17|)
12 Neos\Flow\Core\Booting\Scripts::initializeProxyClasses(Neos\Flow\Core\Bootstrap)
11 call_user_func(array|2|, Neos\Flow\Core\Bootstrap)
10 Neos\Flow\Core\Booting\Step::__invoke(Neos\Flow\Core\Bootstrap)
9 Neos\Flow\Core\Booting\Sequence::invokeStep(Neos\Flow\Core\Booting\Step, Neos\Flow\Core\Bootstrap)
8 Neos\Flow\Core\Booting\Sequence::invokeStep(Neos\Flow\Core\Booting\Step, Neos\Flow\Core\Bootstrap)
7 Neos\Flow\Core\Booting\Sequence::invokeStep(Neos\Flow\Core\Booting\Step, Neos\Flow\Core\Bootstrap)
6 Neos\Flow\Core\Booting\Sequence::invokeStep(Neos\Flow\Core\Booting\Step, Neos\Flow\Core\Bootstrap)
5 Neos\Flow\Core\Booting\Sequence::invoke(Neos\Flow\Core\Bootstrap)
4 Neos\Flow\Cli\CommandRequestHandler::boot("Runtime")
3 Neos\Flow\Cli\CommandRequestHandler::handleRequest()
2 Neos\Flow\Core\Bootstrap::run()
1 require("/var/www/vhosts/itoop.de/dev.itoop.de/Neos/Packages/Framework/Neos.Flow/Scripts/flow.php")


    [array] =>

(Christian Müller) #4

Can you try to run composer update again and see if that fixes it?


(Andre Hohmann) #5

Hi Christian,

I ran composer update again but I still get the same error again.


(Karsten Dambekalns) #6

How do the first lines of PackageInterface.php look? Does it actually define that constant?

Also, can you try removing the Packages/Framework and the install/update again?


(Andre Hohmann) #7

How do the first lines of PackageInterface.php look? Does it actually define that constant?

PackageInterface.php

Also, can you try removing the Packages/Framework and the install/update again?

I can finish the update now. But in frontend I get

An exception was thrown while Neos tried to render your page
Catchable Fatal Error: Object of class Neos\Fusion\FusionObjects\Helpers\FusionPathProxy could not be converted to string in /var/www/vhosts/itoop.de/dev.itoop.de/Neos/Data/Temporary/Development/Cache/Code/Fluid_TemplateCache/Frontend_Node_action_show_5a2134750feab9b388bd00685836cc7df6af2941.php line 547

page<Neos.Neos:Page>/
 body<Neos.Fusion:Template>/

For a full stacktrace, open Data/Logs/Exceptions/201806120628109203eb.txt

Frontend_Node_action_show_5a2134750feab9b388bd00685836cc7df6af2941.php


(Willi Zobel) #8

Another way to solve the psr3 issue is to edit the Scripts.php and change line 249 to

$psrLoggerFactoryName = 'legacy';

After run flow:cache:flush reset the line again to:

$psrLoggerFactoryName = $settings['log']['psr3']['loggerFactory'];