Die Installation von Laravel, Composer verursacht einen Fehler in PackageManifest und wird behoben

Ich verwende eine etwas ältere Version von Laravel und wenn ich "Composer Install" mache, erhalte ich eine Fehlermeldung mit "PHP Artisan Package: Discover". Bei der Prüfung stellte ich fest, dass der Komponist das Format "vendor / composer / install.json" in Version 2.0 und höher geändert hatte, was zu einem Fehler führte. Viele Leute werden wahrscheinlich stolpern, also lassen Sie es als Memo.

Fehler- und Stapelverfolgung

php artisan package:discover

production.ERROR: Undefined index: name {"exception":"[object](ErrorException(code: 0): Undefined index: name at /var/www/php/vendor/laravel/framework/src/Illuminate/Foundation/PackageManifest.php:131)
[stacktrace]
#0 /var/www/php/vendor/laravel/framework/src/Illuminate/Foundation/PackageManifest.php(131): Illuminate\\Foundation\\Bootstrap\\HandleExceptions->handleError(8, 'Undefined index...', '/var/www/php/ve...', 131, Array)
#1 /var/www/php/vendor/laravel/framework/src/Illuminate/Support/Collection.php(685): Illuminate\\Foundation\\PackageManifest->Illuminate\\Foundation\\{closure}(Array, 'packages')
#2 /var/www/php/vendor/laravel/framework/src/Illuminate/Foundation/PackageManifest.php(132): Illuminate\\Support\\Collection->mapWithKeys(Object(Closure))
#3 /var/www/php/vendor/laravel/framework/src/Illuminate/Foundation/PackageManifest.php(106): Illuminate\\Foundation\\PackageManifest->build()
#4 /var/www/php/vendor/laravel/framework/src/Illuminate/Foundation/PackageManifest.php(89): Illuminate\\Foundation\\PackageManifest->getManifest()
#5 /var/www/php/vendor/laravel/framework/src/Illuminate/Foundation/PackageManifest.php(78): Illuminate\\Foundation\\PackageManifest->config('aliases')
#6 /var/www/php/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/RegisterFacades.php(26): Illuminate\\Foundation\\PackageManifest->aliases()
#7 /var/www/php/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(219): Illuminate\\Foundation\\Bootstrap\\RegisterFacades->bootstrap(Object(Illuminate\\Foundation\\Application))
#8 /var/www/php/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php(320): Illuminate\\Foundation\\Application->bootstrapWith(Array)
#9 /var/www/php/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php(129): Illuminate\\Foundation\\Console\\Kernel->bootstrap()
#10 /var/www/php/artisan(37): Illuminate\\Foundation\\Console\\Kernel->handle(Object(Symfony\\Component\\Console\\Input\\ArgvInput), Object(Symfony\\Component\\Console\\Output\\ConsoleOutput))
#11 {main}
"} 

Ursache

Entsprechendes Problem

[5.8] Backport support for Composer 2.x #32328 [6.x] Add support for the new composer installed.json format #32310

Feste Version von Laravel

Lösungen

Der Fehler wird durch Aktualisierung auf die obige Version oder höher behoben. Oder verwenden Sie die Composer 1.x-Serie.

Recommended Posts

Die Installation von Laravel, Composer verursacht einen Fehler in PackageManifest und wird behoben
Composer-Installationsfehler
Bei der Bundle-Installation tritt ein Fehler auf, nachdem die Datenbank auf MySQL gesetzt wurde
Ich sehe keinen Fehler bei der Installation des Rails-Bundles ... der Lösung