max execution time reached instead of throwing error

I have an application in Laravel 10. this application hosted in Apache (not using php artisan serve). every time there is an error, the page loading untill it reach max_execution_time, and there’s nothing usefull showing on that page. this made it hard to debug what causing the error?
anybody know how to fix this? I am sorry if I posted it in wrong forum

enter image description here