I am running php 5.5 on a Windows Server 2008. I am using the Laravel 4.0 framework for the application. I am connecting to a SQL SRV database via PDO, when executed via http there is no issue, connections are made data is called and updated without issue.
However when calling a command from Artisan (Laravel's CLI tool) I get the following error in the log:
log.ERROR: exception 'PDOException' with message 'could not find driver' in C:\inetpub\MBSWeb\postsrch\vendor\laravel\framework\src\Illuminate\Database\Connectors\Connector.php:47
Stack trace:
#0 C:\inetpub\MBSWeb\postsrch\vendor\laravel\framework\src\Illuminate\Database\Connectors\Connector.php(47): PDO->__construct('sqlsrv:Server=H...', 'xxxxxx', 'xxxxxx', Array)
#1 C:\inetpub\MBSWeb\postsrch\vendor\laravel\framework\src\Illuminate\Database\Connectors\SqlServerConnector.php(29): Illuminate\Database\Connectors\Connector->createConnection('sqlsrv:Server=H...', Array, Array)
#2 C:\inetpub\MBSWeb\postsrch\vendor\laravel\framework\src\Illuminate\Database\Connectors\ConnectionFactory.php(41): Illuminate\Database\Connectors\SqlServerConnector->connect(Array)
#3 C:\inetpub\MBSWeb\postsrch\vendor\laravel\framework\src\Illuminate\Database\DatabaseManager.php(128): Illuminate\Database\Connectors\ConnectionFactory->make(Array, 'sqlsrv')
#4 C:\inetpub\MBSWeb\postsrch\vendor\laravel\framework\src\Illuminate\Database\DatabaseManager.php(64): Illuminate\Database\DatabaseManager->makeConnection('sqlsrv')
#5 C:\inetpub\MBSWeb\postsrch\vendor\laravel\framework\src\Illuminate\Database\DatabaseManager.php(242): Illuminate\Database\DatabaseManager->connection()
#6 C:\inetpub\MBSWeb\postsrch\vendor\laravel\framework\src\Illuminate\Support\Facades\Facade.php(206): Illuminate\Database\DatabaseManager->__call('table', Array)
#7 C:\inetpub\MBSWeb\postsrch\vendor\laravel\framework\src\Illuminate\Support\Facades\Facade.php(206): Illuminate\Database\DatabaseManager->table('bb_job_details')
#8 C:\inetpub\MBSWeb\postsrch\app\models\Job.php(214): Illuminate\Support\Facades\Facade::__callStatic('table', Array)
#9 C:\inetpub\MBSWeb\postsrch\app\models\Job.php(214): Illuminate\Support\Facades\DB::table('bb_job_details')
#10 C:\inetpub\MBSWeb\postsrch\app\models\Cron.php(18): Job::getJobDetailsByStatus()
#11 C:\inetpub\MBSWeb\postsrch\app\controllers\ApplicantController.php(14): Cron::ChangePostingJobStatus()
#12 C:\inetpub\MBSWeb\postsrch\app\commands\GetApplicantsCommand.php(45): ApplicantController->index()
#13 C:\inetpub\MBSWeb\postsrch\vendor\laravel\framework\src\Illuminate\Console\Command.php(108): GetApplicantsCommand->fire()
#14 C:\inetpub\MBSWeb\postsrch\vendor\symfony\console\Symfony\Component\Console\Command\Command.php(244): Illuminate\Console\Command->execute(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#15 C:\inetpub\MBSWeb\postsrch\vendor\laravel\framework\src\Illuminate\Console\Command.php(96): Symfony\Component\Console\Command\Command->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#16 C:\inetpub\MBSWeb\postsrch\vendor\symfony\console\Symfony\Component\Console\Application.php(897): Illuminate\Console\Command->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#17 C:\inetpub\MBSWeb\postsrch\vendor\symfony\console\Symfony\Component\Console\Application.php(191): Symfony\Component\Console\Application->doRunCommand(Object(GetApplicantsCommand), Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#18 C:\inetpub\MBSWeb\postsrch\vendor\symfony\console\Symfony\Component\Console\Application.php(121): Symfony\Component\Console\Application->doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#19 C:\inetpub\MBSWeb\postsrch\artisan(59): Symfony\Component\Console\Application->run()
#20 {main} [] []
[2014-03-23 22:53:13] log.ERROR: exception 'Symfony\Component\Debug\Exception\FatalErrorException' with message 'Call to undefined function Symfony\Component\Console\mb_detect_encoding()' in C:\inetpub\MBSWeb\postsrch\vendor\symfony\console\Symfony\Component\Console\Application.php:721
Stack trace:
#0 [internal function]: Illuminate\Exception\Handler->handleShutdown()
#1 {main} [] []
The PDO SQLSRV lib is installed, see the below screenshot of the phpinfo(), and as I've already said I can connection without issue when using the application via http;
Why is the PDO connection working fine via http but not in CLI? Please note I'm using the exact same set of code, one is called from a Laravel controller, the other from a Laravel command.
php cli and php cgi use different php.ini files. Try php -i | grep pdo to see if pdo is installed for your cli, see php -i | grep "Loaded Configuration File"
The answer above is correct, but just to clarify:
Open your console and execute:
php -i | grep "Loaded Configuration File"
That will give you the folder directory where you php-cli.ini is (Laravel Commands use a different php.ini than the one used by HTTP requests)
Go to that file, and make sure it has this:
extension=php_pdo_mysql.dll
Restart your server and try again. That worked for me, hope it helps.
Related
I have installed fresh magento 2.41 in windows with xamp. I have followed this tutorial to install.
After installation I am receiving this error An error has happened during application run. See exception log for details. while I am accessing either homepage or admin page.
I am accessing the magento site from this url http://mystore.magento.com/. If I access from localhost/magento241 it's showing 404 not found.
I tried to clear cache but it didn't worked.
Log Files are here :
1 exception(s):
Exception #0 (Exception): Warning: Use of undefined constant SODIUM_CRYPTO_AEAD_CHACHA20POLY1305_IETF_NPUBBYTES - assumed 'SODIUM_CRYPTO_AEAD_CHACHA20POLY1305_IETF_NPUBBYTES' (this will throw an Error in a future version of PHP) in C:\xampp\htdocs\magento241\vendor\magento\framework\Encryption\Adapter\SodiumChachaIetf.php on line 40
Exception #0 (Exception): Warning: Use of undefined constant SODIUM_CRYPTO_AEAD_CHACHA20POLY1305_IETF_NPUBBYTES - assumed 'SODIUM_CRYPTO_AEAD_CHACHA20POLY1305_IETF_NPUBBYTES' (this will throw an Error in a future version of PHP) in C:\xampp\htdocs\magento241\vendor\magento\framework\Encryption\Adapter\SodiumChachaIetf.php on line 40
<pre>#1 Magento\Framework\Encryption\Adapter\SodiumChachaIetf->encrypt() called at [vendor\magento\framework\Encryption\Encryptor.php:399]
#2 Magento\Framework\Encryption\Encryptor->encryptWithFastestAvailableAlgorithm() called at [vendor\magento\module-config\App\Config\Type\System.php:339]
#3 Magento\Config\App\Config\Type\System->cacheData() called at [vendor\magento\framework\Cache\LockGuardedCacheLoader.php:137]
#4 Magento\Framework\Cache\LockGuardedCacheLoader->lockedLoadData() called at [vendor\magento\module-config\App\Config\Type\System.php:281]
#5 Magento\Config\App\Config\Type\System->loadDefaultScopeData() called at [vendor\magento\module-config\App\Config\Type\System.php:207]
#6 Magento\Config\App\Config\Type\System->getWithParts() called at [vendor\magento\module-config\App\Config\Type\System.php:181]
#7 Magento\Config\App\Config\Type\System->get() called at [vendor\magento\framework\App\Config.php:132]
#8 Magento\Framework\App\Config->get() called at [vendor\magento\module-backend\App\Config.php:51]
#9 Magento\Backend\App\Config->getValue() called at [vendor\magento\module-backend\App\Area\FrontNameResolver.php:109]
#10 Magento\Backend\App\Area\FrontNameResolver->getFrontName() called at [vendor\magento\module-backend\Helper\Data.php:209]
#11 Magento\Backend\Helper\Data->getAreaFrontName() called at [vendor\magento\module-backend\App\Request\PathInfoProcessor.php:50]
#12 Magento\Backend\App\Request\PathInfoProcessor->process() called at [generated\code\Magento\Backend\App\Request\PathInfoProcessor\Proxy.php:95]
#13 Magento\Backend\App\Request\PathInfoProcessor\Proxy->process() called at [vendor\magento\framework\App\Request\Http.php:148]
#14 Magento\Framework\App\Request\Http->getOriginalPathInfo() called at [vendor\magento\framework\App\Request\Http.php:163]
#15 Magento\Framework\App\Request\Http->getPathInfo() called at [vendor\magento\framework\App\Request\Http.php:213]
#16 Magento\Framework\App\Request\Http->getFrontName() called at [vendor\magento\framework\App\Http.php:111]
#17 Magento\Framework\App\Http->launch() called at [generated\code\Magento\Framework\App\Http\Interceptor.php:23]
#18 Magento\Framework\App\Http\Interceptor->launch() called at [vendor\magento\framework\App\Bootstrap.php:264]
#19 Magento\Framework\App\Bootstrap->run() called at [pub\index.php:30]
</pre>
https://drive.google.com/drive/folders/1OJaik33qhQL-X3X26LhFJBtUrk4bU5Cm?usp=sharing
Please make sure you have installed the sodium PHP extension.
You can check that with php -i | grep -i sodium
On Windows
Add "extension=sodium" to php.ini (no quotes)
Copy php/libsodium.dll to apache/bin/
Restart Apache
This works for me works on Windows.
I changed my php version from 8.0 to 8.1 on my linux (centOS) web hosting and had to add the following line to the relevant php.ini showing in phpinfo():
extension=php_sodium.dll
Once I did this the problem was solved!
During the process of updating to Laravel 7 I added a couple of extra packages into the composer.json file (under "require" and "require-dev" that are listed in the composer.json file of the Laravel 7 depository on Github but were not added/installed when I ran composer update with the Laravel version on composer.json updated.
I then ran php artisan vendor:list to list which providers still required publishing. The aforementioned packages were indeed listed, however, so was every other package that I have installed (a total of 16 providers and tags.) Rather than giving me the option of pressing 0-16 which provider/tag I wished to publish (zero for all), the operation simply aborted after listing them.
I then went though the new packages by specifying them specifically - for example php artisan vendor:publish --provider="Facade\Ignition\IgnitionServiceProvider" - and they were then published successfully.
I then ran php artisan vendor:publish again and, sure enough, everything I have ever published (including the new packages that were now successfully published) appeared on the list and the operation was aborted once again.
In order to get the php artisan vendor:publish command to work (without having to specify the provider specifically) I have:
Added --force
Emptied the cache php artisan cache:clear
Emptied the config php artisan config:clear
Added a couple of the packages to the list of providers in app.config to see if it would stop they would disappear from the vendor:publish list.
The command still will still not work...
EDIT
Below is the full aborted error response:
[2020-12-16 01:17:01] local.ERROR: Aborted. {"exception":"[object] (Symfony\Component\Console\Exception\MissingInputException(code: 0): Aborted. at C:\Users\james\Documents\outletdeviviendas\api\vendor\symfony\console\Helper\QuestionHelper.php:128)
[stacktrace]
#0 C:\Users\james\Documents\outletdeviviendas\api\vendor\symfony\console\Helper\QuestionHelper.php(67): Symfony\Component\Console\Helper\QuestionHelper->doAsk(Object(Illuminate\Console\OutputStyle), Object(Symfony\Component\Console\Question\ChoiceQuestion))
#1 C:\Users\james\Documents\outletdeviviendas\api\vendor\symfony\console\Helper\QuestionHelper.php(470): Symfony\Component\Console\Helper\QuestionHelper->Symfony\Component\Console\Helper\{closure}()
#2 C:\Users\james\Documents\outletdeviviendas\api\vendor\symfony\console\Helper\QuestionHelper.php(70): Symfony\Component\Console\Helper\QuestionHelper->validateAttempts(Object(Closure), Object(Illuminate\Console\OutputStyle), Object(Symfony\Component\Console\Question\ChoiceQuestion))
#3 C:\Users\james\Documents\outletdeviviendas\api\vendor\symfony\console\Style\SymfonyStyle.php(355): Symfony\Component\Console\Helper\QuestionHelper->ask(Object(Symfony\Component\Console\Input\ArgvInput), Object(Illuminate\Console\OutputStyle), Object(Symfony\Component\Console\Question\ChoiceQuestion))
#4 C:\Users\james\Documents\outletdeviviendas\api\vendor\laravel\framework\src\Illuminate\Console\Concerns\InteractsWithIO.php(211): Symfony\Component\Console\Style\SymfonyStyle->askQuestion(Object(Symfony\Component\Console\Question\ChoiceQuestion))
#5 C:\Users\james\Documents\outletdeviviendas\api\vendor\laravel\framework\src\Illuminate\Foundation\Console\VendorPublishCommand.php(111): Illuminate\Console\Command->choice(Object(Symfony\Component\Console\Question\ChoiceQuestion), Array)
#6 C:\Users\james\Documents\outletdeviviendas\api\vendor\laravel\framework\src\Illuminate\Foundation\Console\VendorPublishCommand.php(98): Illuminate\Foundation\Console\VendorPublishCommand->promptForProviderOrTag()
#7 C:\Users\james\Documents\outletdeviviendas\api\vendor\laravel\framework\src\Illuminate\Foundation\Console\VendorPublishCommand.php(73): Illuminate\Foundation\Console\VendorPublishCommand->determineWhatShouldBePublished()
#8 [internal function]: Illuminate\Foundation\Console\VendorPublishCommand->handle()
#9 C:\Users\james\Documents\outletdeviviendas\api\vendor\laravel\framework\src\Illuminate\Container\BoundMethod.php(37): call_user_func_array(Array, Array)
#10 C:\Users\james\Documents\outletdeviviendas\api\vendor\laravel\framework\src\Illuminate\Container\Util.php(37): Illuminate\Container\BoundMethod::Illuminate\Container\{closure}()
#11 C:\Users\james\Documents\outletdeviviendas\api\vendor\laravel\framework\src\Illuminate\Container\BoundMethod.php(95): Illuminate\Container\Util::unwrapIfClosure(Object(Closure))
#12 C:\Users\james\Documents\outletdeviviendas\api\vendor\laravel\framework\src\Illuminate\Container\BoundMethod.php(39): Illuminate\Container\BoundMethod::callBoundMethod(Object(Illuminate\Foundation\Application), Array, Object(Closure))
#13 C:\Users\james\Documents\outletdeviviendas\api\vendor\laravel\framework\src\Illuminate\Container\Container.php(592): Illuminate\Container\BoundMethod::call(Object(Illuminate\Foundation\Application), Array, Array, NULL)
#14 C:\Users\james\Documents\outletdeviviendas\api\vendor\laravel\framework\src\Illuminate\Console\Command.php(134): Illuminate\Container\Container->call(Array)
#15 C:\Users\james\Documents\outletdeviviendas\api\vendor\symfony\console\Command\Command.php(258): Illuminate\Console\Command->execute(Object(Symfony\Component\Console\Input\ArgvInput), Object(Illuminate\Console\OutputStyle))
#16 C:\Users\james\Documents\outletdeviviendas\api\vendor\laravel\framework\src\Illuminate\Console\Command.php(121): Symfony\Component\Console\Command\Command->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Illuminate\Console\OutputStyle))
#17 C:\Users\james\Documents\outletdeviviendas\api\vendor\symfony\console\Application.php(911): Illuminate\Console\Command->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#18 C:\Users\james\Documents\outletdeviviendas\api\vendor\symfony\console\Application.php(264): Symfony\Component\Console\Application->doRunCommand(Object(Illuminate\Foundation\Console\VendorPublishCommand), Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#19 C:\Users\james\Documents\outletdeviviendas\api\vendor\symfony\console\Application.php(140): Symfony\Component\Console\Application->doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#20 C:\Users\james\Documents\outletdeviviendas\api\vendor\laravel\framework\src\Illuminate\Console\Application.php(93): Symfony\Component\Console\Application->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#21 C:\Users\james\Documents\outletdeviviendas\api\vendor\laravel\framework\src\Illuminate\Foundation\Console\Kernel.php(129): Illuminate\Console\Application->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#22 C:\Users\james\Documents\outletdeviviendas\api\artisan(37): Illuminate\Foundation\Console\Kernel->handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#23 {main}
This problem do not specify what has gone wrong so its hard to tackle.It might be helpful if you posted your log file after the crash on vendor:publish but you can check the logs for detail error report it will surely help you. The logs are located in storage directory. If you want laravel to display complete error for you rather than the cryptic 'Whoops' message, make sure in your .env APP_ENV=local is in there and your APP_DEBUG=true or you can tweak it in your config/app.php like
'env' => env('APP_ENV', 'local'),
'debug' => env('APP_DEBUG', true),
Also try deleteing packages.php, services.php, config.php manually from bootstrap folder and then try composer dump-autoload or installing the packages again via composer install by deleting vendor folder.
You need to upgrade to Laravel 7 or above
Run The Following command to create a Laravel project version 7
composer create-project --prefer-dist laravel/laravel:^7.0 Project Name
Or if you would like to upgrade without installing a new application follow the steps
in the following link: https://laravel.com/docs/5.7/upgrade
I try to learn laravel and after creating a project with.
i created a new project by typing "laravel new projectname" in cmd, installing composer and node.js, changed in cmd to the project directory and installed composer there and tryed to run "php artisan serve" comand. i got the message "Laravel development server started: http://127.0.0.1:8000"
when i open http://127.0.0.1:8000 i get a 500 Error (not from the browser. the error is from laravel).
I have absolutly no idea what could be wrong. I went by 3 guides for starters and they did not have this problem.
Is there anything i can do ti fix this error?
thank you very much in advance
edit: here is the logfile from storage/logs
[2019-10-12 20:13:12] production.ERROR: No application encryption key has been specified. {"exception":"[object] (RuntimeException(code: 0): No application encryption key has been specified. at C:\\Users\\Rjinxil\\testproject\\vendor\\laravel\\framework\\src\\Illuminate\\Encryption\\EncryptionServiceProvider.php:44)
[stacktrace]
#0 C:\\Users\\Rjinxil\\testproject\\vendor\\laravel\\framework\\src\\Illuminate\\Support\\helpers.php(424): Illuminate\\Encryption\\EncryptionServiceProvider->Illuminate\\Encryption\\{closure}(NULL)
#1 C:\\Users\\Rjinxil\\testproject\\vendor\\laravel\\framework\\src\\Illuminate\\Encryption\\EncryptionServiceProvider.php(48): tap(NULL, Object(Closure))
#2 C:\\Users\\Rjinxil\\testproject\\vendor\\laravel\\framework\\src\\Illuminate\\Encryption\\EncryptionServiceProvider.php(24): Illuminate\\Encryption\\EncryptionServiceProvider->key(Array)
#3 C:\\Users\\Rjinxil\\testproject\\vendor\\laravel\\framework\\src\\Illuminate\\Container\\Container.php(800): Illuminate\\Encryption\\EncryptionServiceProvider->Illuminate\\Encryption\\{closure}(Object(Illuminate\\Foundation\\Application), Array)
#4 C:\\Users\\Rjinxil\\testproject\\vendor\\laravel\\framework\\src\\Illuminate\\Container\\Container.php(682): Illuminate\\Container\\Container->build(Object(Closure))
#5 C:\\Users\\Rjinxil\\testproject\\vendor\\laravel\\framework\\src\\Illuminate\\Container\\Container.php(630): Illuminate\\Container\\Container->resolve('encrypter', Array)
#6 C:\\Users\\Rjinxil\\testproject\\vendor\\laravel\\framework\\src\\Illuminate\\Foundation\\Application.php(768): Illuminate\\Container\\Container->make('encrypter', Array)
#7 C:\\Users\\Rjinxil\\testproject\\vendor\\laravel\\framework\\src\\Illuminate\\Container\\Container.php(946): Illuminate\\Foundation\\Application->make('encrypter')
#8 C:\\Users\\Rjinxil\\testproject\\vendor\\laravel\\framework\\src\\Illuminate\\Container\\Container.php(874): Illuminate\\Container\\Container->resolveClass(Object(ReflectionParameter))
#9 C:\\Users\\Rjinxil\\testproject\\vendor\\laravel\\framework\\src\\Illuminate\\Container\\Container.php(835): Illuminate\\Container\\Container->resolveDependencies(Array)
#10 C:\\Users\\Rjinxil\\testproject\\vendor\\laravel\\framework\\src\\Illuminate\\Container\\Container.php(682): Illuminate\\Container\\Container->build('App\\\\Http\\\\Middle...')
#11 C:\\Users\\Rjinxil\\testproject\\vendor\\laravel\\framework\\src\\Illuminate\\Container\\Container.php(630): Illuminate\\Container\\Container->resolve('App\\\\Http\\\\Middle...', Array)
#12 C:\\Users\\Rjinxil\\testproject\\vendor\\laravel\\framework\\src\\Illuminate\\Foundation\\Application.php(768): Illuminate\\Container\\Container->make('App\\\\Http\\\\Middle...', Array)
#13 C:\\Users\\Rjinxil\\testproject\\vendor\\laravel\\framework\\src\\Illuminate\\Foundation\\Http\\Kernel.php(215): Illuminate\\Foundation\\Application->make('App\\\\Http\\\\Middle...')
#14 C:\\Users\\Rjinxil\\testproject\\vendor\\laravel\\framework\\src\\Illuminate\\Foundation\\Http\\Kernel.php(189): Illuminate\\Foundation\\Http\\Kernel->terminateMiddleware(Object(Illuminate\\Http\\Request), Object(Illuminate\\Http\\Response))
#15 C:\\Users\\Rjinxil\\testproject\\public\\index.php(60): Illuminate\\Foundation\\Http\\Kernel->terminate(Object(Illuminate\\Http\\Request), Object(Illuminate\\Http\\Response))
#16 C:\\Users\\Rjinxil\\testproject\\server.php(21): require_once('C:\\\\Users\\\\Rjinxi...')
#17 {main}
"}
So close your terminal session and run this command in your CMD:
php artisan key:generate
in the project folder. Make sure you have .env file created. Then serve your application once again.
Try Below steps :
php artisan config:cache
php artisan cache:clear
php artisan key:generate
I am using pbmedia/laravel-ffmpeg as soon as I installed and added the providers and alias, it shows me the following error. This code was simply working on another machine
array_merge(): Argument #2 is not an array
I have tried the following things
Composer update/ and Fresh install
Cleaning the bootstrap/cache/
Checked the config file for laravel-ffmpeg it's there and fine
Publish the config file using the artisan CLI tool: php artisan vendor:publish --provider="Pbmedia\LaravelFFMpeg\FFMpegServiceProvider"
Here is the portion from laravel.log when I tried to run.
[2019-06-19 00:34:40] local.ERROR: ErrorException: array_merge(): Argument #2 is not an array in /Users/damanmokha/edetyv2/vendor/laravel/framework/src/Illuminate/Support/ServiceProvider.php:59
Stack trace:
#0 [internal function]: Illuminate\Foundation\Bootstrap\HandleExceptions->handleError(2, 'array_merge(): ...', '/Users/damanmok...', 59, Array)
#1 /Users/damanmokha/edetyv2/vendor/laravel/framework/src/Illuminate/Support/ServiceProvider.php(59): array_merge(Array, 1)
#2 /Users/damanmokha/edetyv2/vendor/pbmedia/laravel-ffmpeg/src/FFMpegServiceProvider.php(25): Illuminate\Support\ServiceProvider->mergeConfigFrom('/Users/damanmok...', 'laravel-ffmpeg')
#3 /Users/damanmokha/edetyv2/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(565): Pbmedia\LaravelFFMpeg\FFMpegServiceProvider->register()
#4 /Users/damanmokha/edetyv2/vendor/laravel/framework/src/Illuminate/Foundation/ProviderRepository.php(74): Illuminate\Foundation\Application->register(Object(Pbmedia\LaravelFFMpeg\FFMpegServiceProvider))
#5 /Users/damanmokha/edetyv2/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(540): Illuminate\Foundation\ProviderRepository->load(Array)
#6 /Users/damanmokha/edetyv2/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/RegisterProviders.php(17): Illuminate\Foundation\Application->registerConfiguredProviders()
#7 /Users/damanmokha/edetyv2/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(203): Illuminate\Foundation\Bootstrap\RegisterProviders->bootstrap(Object(Illuminate\Foundation\Application))
#8 /Users/damanmokha/edetyv2/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php(267): Illuminate\Foundation\Application->bootstrapWith(Array)
#9 /Users/damanmokha/edetyv2/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php(113): Illuminate\Foundation\Console\Kernel->bootstrap()
#10 /Users/damanmokha/edetyv2/artisan(35): Illuminate\Foundation\Console\Kernel->handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#11 {main}
if I don't add these providers it works fine, but then I am not able to use ffmpeg without that.
Laravel Version 5.3
pbmedia/laravel-ffmpeg 1.3
php version: 7.1
I have command log:demo and I successfully run it from ssh console with command: php artisan log:demo.
Now I need to create cron job and its ok but when cron starts a command I get in laravel.log:
> [2016-03-22 21:45:01] local.ERROR: exception 'ErrorException' with message 'Invalid argument supplied for foreach()' in /home/agroagro/public_html/vendor/symfony/console/Input/ArgvInput.php:283
Stack trace:
#0 /home/agroagro/public_html/vendor/symfony/console/Input/ArgvInput.php(283): Illuminate\Foundation\Bootstrap\HandleExceptions->handleError(2, 'Invalid argumen...', '/home/agroagro/...', 283, Array)
#1 /home/agroagro/public_html/vendor/symfony/console/Application.php(790): Symfony\Component\Console\Input\ArgvInput->hasParameterOption(Array)
#2 /home/agroagro/public_html/vendor/symfony/console/Application.php(117): Symfony\Component\Console\Application->configureIO(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#3 /home/agroagro/public_html/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php(107): Symfony\Component\Console\Application->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#4 /home/agroagro/public_html/artisan(35): Illuminate\Foundation\Console\Kernel->handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))
#5 {main}
Why does manually calling command work, but cron does not?
does the cron run with the same user and privileges as you do?
is the bash the same? check php version...
that was the problems on my server...