Bug #41

Custom autoloaders are registered too late

Added by Robert Lemke over 8 years ago. Updated almost 5 years ago.

Status:Closed Start date:
Priority:Should have Due date:
Assigned To:Robert Lemke % Done:

0%

Category:Package
Target version:TYPO3 Flow Base Distribution - 0.1
PHP Version: Complexity:
Has patch: Affected Flow version:

Description

Currently custom autoloaders are registered by some PHP code contained in the ComponentsConfiguration.php file. This file is included while the Package Manager configures and registers the components from the Classes directory. After that step, the component types are registered.

Due to this order, it might be that an interface of a package is required which is not yet loaded. If that interface can only be loaded by the custom autoloader, but that autloader is not yet registered (because the components of that package are not registered) PHP throws a fatal error.

The solution is to move autoloader registration to an earlier stage, before any component is registered or configured.

History

#1 Updated by Robert Lemke over 8 years ago

  • Status changed from New to Closed
  • Sprint set to fixed
(In r178)
  • Core: Added support for "PackageConfiguration.php". Autoloaders should now be registered in the PackageConfiguration.php instead of the ComponentsConfiguration.php.
  • PHPUnit: Renamed ComponentsConfiguration.php to PackageConfiguration.php
  • phpCR: Renamed ComponentsConfiguration.php to PackageConfiguration.php and fixed the path name
  • Core: Fixed #41: Custom autoloaders are registered too late

Also available in: Atom PDF