0

i've tried to composer update --ignore-platform-reqs laravel project in docker but there is

Script @php artisan package:discover --ansi handling the post-autoload-dump event returned with error code 255

error.

Solutions from here

Script @php artisan package:discover handling the post-autoload-dump event returned with error code 255

didn't help me, cuz there is already ok with handler.php

composer diagnose returns

Checking composer.json: WARNING
require.laravel/ui : exact version constraints (2.4) should be avoided if the package follows semantic versioning
Checking platform settings: OK
Checking git settings: OK
Checking http connectivity to packagist: OK
Checking https connectivity to packagist: OK
Checking github.com rate limit: OK
Checking disk free space: OK
Checking pubkeys:
Tags Public Key Fingerprint: 57815BA2 7E54DC31 7ECC7CC5 573090D0  87719BA6 8F3BB723 4E5D42D0 84A14642
Dev Public Key Fingerprint: 4AC45767 E5EC2265 2F0C1167 CBBB8A2B  0C708369 153E328C AD90147D AFE50952
OK
Checking composer version: OK
Composer version: 2.3.7
PHP version: 8.0.2
PHP binary path: /usr/local/bin/php
OpenSSL version: OpenSSL 1.1.1d  10 Sep 2019
cURL version: 7.64.0 libz 1.2.11 ssl OpenSSL/1.1.1d
zip: extension not loaded, unzip present, 7-Zip not available
ichwillkin
  • 1
  • 1
  • 2
  • Run the command with -vvv for verbose output. Then find the culprit. Exit status 255 most often is a failure exit condition with PHP itself, e.g. uncaught exception or fatal error. Make the platform packages clear and correct, otherwise if you run incompatible PHP code, you may run into such errors. – hakre Jun 25 '22 at 00:41

1 Answers1

0

The problem might be that you are using Laravel 5.x and your hosting provider is set with php 8.x

Keep in mind that the location of PHP could change on ever hosting provider, anyway you can find the bin dir creating a php file on your public dir with echo phpinfo(); and then use ctrl+f to find bindir= on your browser.