Freelancer at self-employed
Member Since 5 Years Ago
Vancouver, BC
3,090 experience to go until the next level!
In case you were wondering, you earn Laracasts experience when you:
Earned once you have completed your first Laracasts lesson.
Earned once you have earned your first 1000 experience points.
Earned when you have been with Laracasts for 1 year.
Earned when you have been with Laracasts for 2 years.
Earned when you have been with Laracasts for 3 years.
Earned when you have been with Laracasts for 4 years.
Earned when you have been with Laracasts for 5 years.
Earned when at least one Laracasts series has been fully completed.
Earned after your first post on the Laracasts forum.
Earned once 100 Laracasts lessons have been completed.
Earned once you receive your first "Best Reply" award on the Laracasts forum.
Earned if you are a paying Laracasts subscriber.
Earned if you have a lifetime subscription to Laracasts.
Earned if you share a link to Laracasts on social media. Please email [email protected] with your username and post URL to be awarded this badge.
Earned once you have achieved 500 forum replies.
Earned once your experience points passes 100,000.
Earned once your experience points hits 10,000.
Earned once 1000 Laracasts lessons have been completed.
Earned once your "Best Reply" award count is 100 or more.
Earned once your experience points passes 1 million.
Earned once your experience points ranks in the top 50 of all Laracasts users.
Earned once your experience points ranks in the top 10 of all Laracasts users.
Awarded Best Reply on Getting "ModelFactory Class Is Not PSR-4 Compatible Skipping" When Running Composer Dump-autoload
As it turns out, my namespacing was incorrect.
Replied to Getting "ModelFactory Class Is Not PSR-4 Compatible Skipping" When Running Composer Dump-autoload
As it turns out, my namespacing was incorrect.
Started a new Conversation Getting "ModelFactory Class Is Not PSR-4 Compatible Skipping" When Running Composer Dump-autoload
So I am almost done the forum series on this website. I upgraded Laravel from 5.8 to Laravel 8 using Laravel Shift. Now I notice I can't seed data to the database anymore when I run Laravel's new seeding command ie
$thread = App\Thread::factory()->count(3)->create();
I get the following error
`` Class 'Database/Factories/ThreadFactory' not found in /home/vagrant/Code/intransportal/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Factories/Factory.php on line 670
After googling around I realize the my model factories have to be PSR-4 autoloaded. After checking composer.json and running composer dump-autoload
composer tells me
Class Database\Factories\App\ChannelFactory located in ./database/factories/ChannelFactory.php does not comply with psr-4 autoloading standard. Skipping. Class Database\Factories\App\CityFactory located in ./database/factories/CityFactory.php does not comply with psr-4 autoloading standard. Skipping. Class Database\Factories\App\CountryFactory located in ./database/factories/CountryFactory.php does not comply with psr-4 autoloading standard. Skipping. Class Database\Factories\App\ModeFactory located in ./database/factories/ModeFactory.php does not comply with psr-4 autoloading standard. Skipping. Class Database\Factories\App\ReplyFactory located in ./database/factories/ReplyFactory.php does not comply with psr-4 autoloading standard. Skipping.
What gives?