Php artisan package discover ansi

Saved searches

Use saved searches to filter your results more quickly

You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

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

Comments

We have a specific session driver and when we try to add this package, we have this below error.

Читайте также:  Сложить две переменные php

In the boot method of the FormBuilderServiceProvider class, when you call «$form = $this->app[‘form’];»,
the system makes an error because our specific session driver is not boot before.

**************** COMMAND LOG composer update ************
@commandLog: composer update
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 1 install, 0 updates, 0 removals

  • Installing kris/laravel-form-builder (1.15.1): Loading from cache
    Writing lock file
    Generating optimized autoload files

Illuminate\Foundation\ComposerScripts::postAutoloadDump
@php artisan package:discover

Driver [app_database] not supported.

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

The text was updated successfully, but these errors were encountered:

Hum I think it is a custom session driver.
I got the same issue, to solve this, just add this to your composer.json

and add the reference of the provider
Kris\LaravelFormBuilder\FormBuilderServiceProvider::class
at the end of the providers arrays in your app.php

Thank you Kris for your support and your awsome package!

Thank you Splashdown! It works!!

tengo este problema ayuda .

Illuminate\Foundation\ComposerScripts::postAutoloadDump
@php artisan package:discover —ansi

 InvalidArgumentException : Please provide a valid cache path. at C:\Users\pablo vaccotti\Desktop\redSocial\vendor\laravel\framework\src\Illuminate\View\Compilers\Compiler.php:36 32| */ 33| public function __construct(Filesystem $files, $cachePath) 34| < 35| if (! $cachePath) < >36| throw new InvalidArgumentException('Please provide a valid cache path.'); 37| > 38| 39| $this->files = $files; 40| $this->cachePath = $cachePath; Exception trace: 1 Illuminate\View\Compilers\Compiler::__construct(Object(Illuminate\Filesystem\Filesystem)) C:\Users\pablo vaccotti\Desktop\redSocial\vendor\laravel\framework\src\Illuminate\View\ViewServiceProvider.php:141 2 Illuminate\View\ViewServiceProvider::Illuminate\View\(Object(Illuminate\Foundation\Application), []) C:\Users\pablo vaccotti\Desktop\redSocial\vendor\laravel\framework\src\Illuminate\Container\Container.php:799 Please use the argument -v to see more details. Script @php artisan package:discover --ansi handling the post-autoload-dump event returned with error code 1 

Seems like your config is missing a cache path? Or it doesn’t exist, or it’s not readable/writable. Only you can debug that.

Источник

Saved searches

Use saved searches to filter your results more quickly

You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

php artisan package:discover error #1775

php artisan package:discover error #1775

Comments

working fine in my local dev env, I am facing problems with V8 when trying to deploy to Ubuntu servers. I tried to remove the generated config but the effect is the same.

`> @php artisan package:discover —ansi

Symfony\Component\Debug\Exception\FatalThrowableError : Class name must be a valid object or a string

at /home/forge/atl.bfd.space/vendor/spatie/laravel-medialibrary/src/MediaLibraryServiceProvider.php:23
19| $this->registerPublishables();
20|
21| $mediaClass = config(‘media-library.media_model’);
22|

23| $mediaClass::observe(new MediaObserver());
24|
25| $this->loadViewsFrom(DIR.’/../resources/views’, ‘media-library’);
26| >
27|

1 Spatie\MediaLibrary\MediaLibraryServiceProvider::boot()
/home/forge/atl.bfd.space/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php:32

2 call_user_func_array()
/home/forge/atl.bfd.space/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php:32

Please use the argument -v to see more details.
Script @php artisan package:discover —ansi handling the post-autoload-dump event returned with error code 1`

Any idea how to face this?

The text was updated successfully, but these errors were encountered:

Источник

Saved searches

Use saved searches to filter your results more quickly

You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

5.8 Script @php artisan package:discover —ansi handling the post-autoload-dump event returned with error code 1 #50

5.8 Script @php artisan package:discover —ansi handling the post-autoload-dump event returned with error code 1 #50

Comments

EBUG [9485c7aa] Command: cd /var/www/html/mcms/releases/20190328173840 && /usr/bin/env composer install —no-dev —quiet —prefer-dist —optimize-autoloader

DEBUG [9485c7aa] Script @php artisan package:discover —ansi handling the post-autoload-dump event returned with error code 1

trying to figure why it keeps failing

The text was updated successfully, but these errors were encountered:

Hi, I got a solution : this issue was due to one of my config/ files that was empty (caused by error when uploading files to server), especially the auth.php which was there but empty (0 octets).

I figure that by running php artisan clear and i got error in the ServiceProvider at line 72 where merging config arrays $this->app[‘config’]->set($key, array_merge(require $path, $config));

So, simple solution : upload again your app files and make sure everything is place 🙂

Hi, I got a solution: this issue was due to one of my config/database.php that were empty (caused by an error when the composer updated).

I figure that by running php artisan clear and I got an error in the Database [] not configure DatabaseManage.php at line 252

So, simple solution: upload again your config/database.php files and make sure everything is place 🙂

Hi, I got a solution : this issue was due to one of my config/ files that was empty (caused by error when uploading files to server), especially the auth.php which was there but empty (0 octets).

I figure that by running php artisan clear and i got error in the ServiceProvider at line 72 where merging config arrays $this->app[‘config’]->set($key, array_merge(require $path, $config));

So, simple solution : upload again your app files and make sure everything is place 🙂

I figured out the problem is one of my configs. missing return or using a class that not exists. or something else.

Check configs and be sure that every thing is normal at there

Seems unrelated to capistrano-laravel, so I’m closing this issue.

Источник

Laravel 8 – Windows – package discover post-autoload-dump event returned with error code 255

I just created a Laravel project in my windows with this command :

composer create-project --prefer-dist laravel/laravel test-windows "8.*" 

But I got some errors about requirements missing during the installation of dependencies :

 Problem 1 - laravel/framework[v8.65.0, . 8.x-dev] require league/flysystem ^1.1 -> satisfiable by league/flysystem[1.1.0, . 1.x-dev]. - league/flysystem[1.1.0, . 1.x-dev] require ext-fileinfo * -> it is missing from your system. Install or enable PHP's fileinfo extension. - Root composer.json requires laravel/framework ^8.65 -> satisfiable by laravel/framework[v8.65.0, . 8.x-dev]. To enable extensions, verify that they are enabled in your .ini files: - C:\Program Files\PHP\v7.4\php.ini You can also run `php --ini` inside terminal to see which files are used by PHP in CLI mode. 
composer install --ignore-platform-reqs 

So all dependencies are now installed successfully but in the end, I have another problem :

82 package suggestions were added by new dependencies, use `composer suggest` to see details. Generating optimized autoload files Illuminate\Foundation\ComposerScripts::postAutoloadDump @php artisan package:discover --ansi Script @php artisan package:discover --ansi handling the post-autoload-dump event returned with error code 255 

And now I can’t start the project or do anything else. I’m stuck, I found a lot of things for Laravel 6 or 7 but I’m currently using Laravel 8.

  • OS: Windows 10
  • Composer: version 2.0.8
  • PHP: version 7.4.1
  • Laravel (in composer.json): version ^8.65

EDIT: @apokryfos advice me to install ext-fileinfo in my php.ini. So I tried to find a way to do this, but when I’m trying to edit the php.ini file and save it, I got an error by Windows «You don’t have the autorisation to do this». I’ll try to reinstall PHP because I have PHP v7.4 and it’s normally installed by default starting with PHP 5.3.0. So I think my PHP has a problem in local in my computer.

EDIT 2: I tried to reinstall PHP v7.4 but it doesn’t change anything.

Solution

I found how to edit my php.ini in my Windows as administrator, following this link :

  1. Press the Windows logo (bottom left)
  2. Type Notepad in the search field
  3. Click right on the Notepad and select Run as administrator
  4. From Notepad, click on File > Open and paste C:\Program Files\PHP\v7.4\php.ini
  5. I added the line extension=php_fileinfo.dll
  6. Save

Now, all works fine and I can use composer install

This Answer collected from stackoverflow, is licensed under cc by-sa 2.5 , cc by-sa 3.0 and cc by-sa 4.0

Источник

Оцените статью