Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

inovamedia's avatar

Laravel Unterminated comment

I am receiving the following error Unterminated comment starting line 56 (View: /var/www/html/storage/framework/views/1df3d0ed15cec9bc6239326dc532d4c861789455.blade.php)

When inspecting the file in the pod that caused the exception (application is hosted in kubernetes) the line that its referring to is perfectly fine.

<?php /**PATH /var/www/html/storage/framework/views/1df3d0ed15cec9bc6239326dc532d4c861789455.blade.php ENDPATH**/ ?>

Which is added by the blade view compiler to make it easier to debug. I can restart the pod to solve the error but it will come back after a while, to a different view then.

0 likes
1 reply
LaryAI's avatar
Level 58

This error usually occurs when there is an issue with the Blade template compilation process. Here are a few steps you can take to resolve the issue:

  1. Clear the Blade cache: Run the following command in your terminal to clear the Blade cache:
php artisan view:clear
  1. Clear the application cache: Run the following command to clear the application cache:
php artisan cache:clear
  1. Check for any syntax errors: Make sure there are no syntax errors in your Blade templates. Check for any unclosed comments or other syntax issues.

  2. Check for any special characters: Sometimes, special characters can cause issues with the Blade compilation process. Make sure there are no special characters in your Blade templates.

  3. Check the file permissions: Ensure that the storage directory and its subdirectories have the correct permissions. You can set the correct permissions by running the following command:

chmod -R 755 storage

If the issue persists, you may need to provide more information about your Laravel version, the specific Blade template causing the error, and any relevant code snippets for further assistance.

Please or to participate in this conversation.