So I'm using faker to seed the database with data for testing. Right now, when I use 'created_at' => $this->faker->dateTimeBetween('-5 years', '-3 days')
it breaks and says
SQLSTATE[22007]: Invalid datetime format: 1292 Incorrect datetime value: '2018-03-25 02:45:11' for column
I've looked it up and as mentioned here,
This is most likely a timezone conversion error on the day of standard-time to daylight-time switchover. The hour from 0200 to just before 0300 does not exist.
Is there a way to prevent that from happening? For example, specifying that the dateTimeBetween can only select hours between 6 and 18?
Edit #1: This mostly happens when I try to seed with 10k+ data (for testing speed, cache, and other stuff).