Published
Feb 15, 2022
Updated
Feb 15, 2022
When developing with Drupal you will sometime get the error
The website encountered an unexpected error. Please try again later.
If you are working in the theme layer and in particular directly on a file in the theme you are developing you should still be able to visit the recent log messages in the report section of the admin. /admin/reports/dblog
If you can still access the logs it is generally good news as it mean that it is a theme layer issue and two you'll get the message in the details of each log message.
If you can't access the log message page you can check the apache log on the server.