The website encountered an unexpected error.

Getting a “The website encountered an unexpected error. Please try again later.” message after submit a contact form. When I look at the Reports > Recent log message, I have got this message : SymfonyComponentDependencyInjectionExceptionServiceNotFoundException: You have requested a non-existent service “smtp.logger.channel”. in DrupalComponentDependencyInjectionContainer->get() (line[…]