I am using PHP version 7.2.19 and Laravel 5.6.39. I am getting this scsuoft/laravel-exception-notification error when I run composer install.
When I check the link it is not available and I also try to delete the scsuoft file manually but when I run composer install again the file is automatically added and I keep getting the same error.
Also, if I try composer require jeremykenedy/laravel-exception-notifier
Try composer require jeremykenedy/laravel-exception-notifier. After some digging i found there's no scsuoft/laravel-exception-notification anywhere.
Related
I have PHP v7.4 on Ubuntu server. And I have an alternative PHP in the path /opt/php81/bin/
I need to start command composer update with PHP 8.1
I tried like that /opt/php81/bin/php composer update but I see the error
Could not open input file: composer
I tried that /opt/php81/bin/php composer update --working-dir=/var/www/user/data/www/myweb.site
and I see the same error.
I found that this solution works !
/opt/php81/bin/php /usr/local/bin/composer update --working-dir=/var/www/user/data/www/myweb.site
SOLUTION: laravel new project-name was actually giving me an error that i overlooked. I had the wrong version of php. It requires phpv7.1.3 or higher. If you don't have it it doesn't work.
Ran into one other problem:
i had a system environment variable that is pointing to an old version of php
Also laravel requires openssl extension and mbstring to turned on. UNCOMMENTED from php.ini
FOR NEWCOMERS: if you have just downloaded php and unzipped the file. It contains a file called
install.txt
that you HAVE to read. It explains everything.
I ran laravel new blog from their getting started page. When I tried to run php artisan serve, I got the following error:
Warning: require(C:\Projects\laravel-projects\blog/vendor/autoload.php): failed to open stream: No such file or directory in C:\Projects\laravel-projects\blog\artisan on line 18
The artisan file is pointing to
require __DIR__.'/vendor/autoload.php';
this directory does not exist. Even if I point it to the correct directory, it still wouldn't work because I don't have read permissions for that folder (so it gets denied).
What's going on, and how can I fix this?
EDIT: changed the url from the mentioned above to:
C:\Users\sarkis\AppData\Roaming\Composer\vendor\autoload.php
This worked perfectly for some reason.
And NOW. A NEW ERROR HAS APPEARED.
Fatal error: Uncaught Error: Class 'Illuminate\Foundation\Application' not found in C:\Projects\laravel-projects\blog\bootstrap\app.php:14
Stack trace:#0 C:\Projects\laravel-projects\blog\artisan(21): require_once() #1 {main} thrown in C:\Projects\laravel-projects\blog\bootstrap\app.php on line 14
found that i don't have the proper version of php required.
First Install Composer: composer install.
Then run a command in CMD prompt: composer dump-autoload.
Try running composer dump-autoload , after that run a composer install
If that doesn't work, try the composer update --no-scripts
I'm new to Laravel, and I got the same confusion with the command:
laravel new blog
There was no vendor folder.
But after I tried:
composer create-project --prefer-dist laravel/laravel blog
I found the vendor folder came up.
Don't know why either.
You could try install via Composer Create-Project:
composer create-project --prefer-dist laravel/laravel blog
When running laravel new project_name. It outputted the text php 7.1.3 or higher needs to be installed. Current version 5.6 does not match requirements. And it aborts without plainly giving you an error. Be sure to download php version 7.1.3 or higher. Also check if you have environment variables for earlier versions of php and delete those.
note: be sure to read install.txt from the php download
Check all your permissions to following folders and give 0777 permissions
storage 0777
vendor 0777
bootstrap/cache 0777
And then run again
php artisan serve
I tried to install CodeIgniter through composer using this:
composer require bcit-ci/CodeIgniter
And it installed successfully I got a warning, see screenshot
And then I tried to install with this:
composer require codeigniter/framework
and I got a fatal error, see screenshot here
I don't know what I am doing wrong.
See all screenshots here: http://imgur.com/a/zsnER
I just removed the cache of Composer and tried to install again and I got success.
this is weird that composer trying to install the very first package 1.0.0 , works perfectly at my side.
however , you will need to pass the package version statically as follows:
composer require codeigniter/framework:"3.1-stable"
this will often -till the answer date- install 3.1.0 version,
you may try to download the latest version :
composer require codeigniter/framework:"3.1.4"
I am getting following error when I open my site which is made using laravel 5
Fatal error: Class 'Illuminate\Foundation\Application' not found in C:\cms\bootstrap\app.php on line 14
I have tried removing vendor folder and composer.lock file and running composer install it's not working I tried running PHP artisan optimize but it shows error
Fatal error: Class'Illuminate\Foundation\Application' not found
Is there any way to solve this problem?
Edited:
This problem aroused as soon as I used the php artisan make:model Page command which did create the model but then the above error gets displayed when I access the site
Also If use the Laravel's Local Development Server no such problem arises only if I use wamp server
In my situation, I didn't have the full vendor dependencies in place (composer file was messed up during original install) - so running any artisan commands caused a failure.
I was able to use the --no-scripts flag to prevent artisan from executing before it was included. Once my dependencies were in place, everything worked as expected.
composer update --no-scripts
Just in case I trip over this error in 2 weeks again...
My case: Checkout an existing project via git and pull in all dependencies via composer. Came down to the same error listed within the title of this post.
Solution:
composer dump-autoload
composer install --no-scripts
make sure everything works now as expected (no errors!)
composer update
Something is clearly corrupt in your Laravel setup and it is very hard to track without more info about your environment. Usually these 2 commands help you resolve such issues
php artisan clear-compiled
composer dump-autoload
If nothing else helps then I recommend you to install fresh Laravel 5 app and copy your application logic over, it should take around 15 min or so.
Easy as this, that worked for my project
Delete /vendor folder
and execute composer install
then run project php artisan serve
In my case composer was not installed in that directory. So I run
composer install
then error resolved.
or you can try
composer update --no-scripts
cd bootstrap/cache/->rm -rf *.php
composer dump-autoload
I just fixed this problem (Different Case with same error),
The answer above I tried may not work because My case were different but produced the same error.
I think my vendor libraries were jumbled,
I get this error by:
1. Pull from remote git, master branch is codeigniter then I do composer update on master branch, I wanted to work on laravel branch then I checkout and do composer update so I get the error,
Fatal error: Class 'Illuminate\Foundation\Application' not found in
C:\cms\bootstrap\app.php on line 14
Solution:
I delete the project on local and do a clone again, after that I checkout to my laravel file work's branch and do composer update then it is fixed.
I had accidentally commented out:
require __DIR__.'/../bootstrap/autoload.php';
in
/public/index.php
When pasting in some debugging statements.
For latest laravel version also check your version because I was also
facing this error but after update latest php version, I got rid from
this error.
run composer require laravel/framework after composer install then php artisan key:generate its work for me in kali linux
I can't imagine that anyone else reading this is a stupid as I was but just in case...
I had accidentally removed "laravel/framework": "^5.6" from my composer.json when resolving merge conflicts.
please test below solution:
first open command prompt cmd ==> window+r and go to the location where laravel installed.
try composer require laravel/laravel
i was having same problem with this error.
It turn out my Kenel.php is having a wrong syntax when i try to comply with wrong php8 syntax
The line should be
protected $commands = [
//
];
instead of
protected array $commands = [
//
];
#kalhan-toress 's comment is what ACTUALLY WORKED FOR ME
remove /bootstrap/start.php,composer.lock, and the vendor and run composer install
In my case, the error was caused on initial deployment because I didn't have a .env file in that directory (because those don't belong on Github where the files were transferred from).
check your .env file i think you miss something. Maybe like this
if yes then need to add manually and composer update or install composer
So, I installed Laravel on a dev server (php5.5.3, standard installation, mcrypt installed), and I get the following error message:
Fatal error: Class 'Illuminate\Foundation\Application' not found in /[path_to_laravel_app]/bootstrap/start.php on line 14
Quite odd, and I haven't seen a solution to this file, although I've seen plenty of similar errors. Any advice welcome. Thanks!
/bootstrap/start.php is created after composer install by running Laravel's php artisan optimize. I've had a lot of issues on this during upgrades of Laravel, but removing /bootstrap/start.php, composer.lock, and the vendor directory and re-running composer install should fix this issue.
Run this command:
composer update --no-scripts
In my case I have added another required package(Guzzle) in the compser.json file separately(in the last line but it should be after the laravel package line) and updated the compsoser and came across this issue.
I have checked and my vendor/laravel folder has gone. That was preventing me to run any artisian command.
So "--no-scripts" worked for me as it prevents any scripts to be included before executing artisan.
You can use another method in case you are having issues.
Install another raw laravel and copy all the files from the vendor
file to your old repostory.
Change permission of storage and bootstrap folder to 775 or 777.
Delete everything in the session and view folder of storage/framework
Correct the composer.json. This might happen after you have added a new package configuration by dublicating the require tag.
Do not create yet another
require: {
..
}
use the previous defined one.
Then follow the accepted answer to re-install the packages.
Just Run the command
composer install --no-scripts
Or,
composer update --no-scripts
Double check your composer.json file. If you have error on "require": section this error will occur.
Just restore a previous version of composer.json file and run composer update.