'Laravel: Where does report() store the error messages?

According to the Laravel handling error documentation I've put this code snippet in one of my functions:

try {
    // Send an email...
} catch (Throwable $e) {
    report($e);
 
    return false;
}

Now I want to check out the error messages but I have no idea where they are stored.
I've tried both storage/logs/laravel.log and var/log/apache2/error.log but I found nothing.

Where does report() store the error message ?



Solution 1:[1]

It depends on your config/logging.php.

By default it should be the stack channel.
If your channel is set up to daily it willl create a file per day (e.g: laravel-2022-05-16.log
Otherwise you can leave the single channel it will put everything in storage/logs/laravel.log

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 ml59