vuongxuongminh / laravel-async

Package provide simple way to run code asynchronously for your Laravel application.
MIT License
154 stars 26 forks source link

its not installing on laravel 8, getting error TypeError #20

Closed deepak-a-insnapsys closed 1 year ago

deepak-a-insnapsys commented 3 years ago

I'm using laravel 8 framework. I'm getting the following error while installation using this command "composer require vxm/laravel-async"

@php artisan ide-helper:generate

TypeError

Argument 1 passed to Spatie\Async\Pool::concurrency() must be of the type int, null given, called in /var/www/html/vendor/vxm/laravel-async/src/AsyncServiceProvider.php on line 72

at vendor/spatie/async/src/Pool.php:77 73▕ 74▕ return $this; 75▕ } 76▕ ➜ 77▕ public function concurrency(int $concurrency): self 78▕ { 79▕ $this->concurrency = $concurrency; 80▕ 81▕ return $this;

  +36 vendor frames 

37 artisan:37 Illuminate\Foundation\Console\Kernel::handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput)) Script @php artisan ide-helper:generate handling the post-update-cmd event returned with error code 1

Installation failed, reverting ./composer.json and ./composer.lock to their original content.

image

vuongxuongminh commented 3 years ago

What's Laravel version are you using? Please check in your config dir if have async.php file, delete it and try again.

deepak-a-insnapsys commented 3 years ago

I'm using laravel 8 image

I've checked the config directory but there is no async.php file.

Output of "composer require vxm/laravel-async"

Using version ^2.1 for vxm/laravel-async ./composer.json has been updated Running composer update vxm/laravel-async Loading composer repositories with package information Updating dependencies Lock file operations: 2 installs, 0 updates, 0 removals

Installation failed, reverting ./composer.json and ./composer.lock to their original content.

vuongxuongminh commented 1 year ago

Please try the latest version and make sure your PHP extensions have POSIX and PCNTL.