After a quick investigation, I figured out that the file
contained PHP exception with stack trace to help me understand the issue:
Fatal error: Maximum execution time of 30 seconds exceeded in /var/www/html/mage2/vendor/oyejorge/less.php/lib/Less/Visitor/processExtends.php on line 159
All this means is – Magento tried to compile less files on server side, but it couldn’t finish the task in 30 seconds.
We need to increase max_execution_time in php.ini file. Since I’m using Vagrant based VM with PHP-FPM, this is how I managed to fix it:
#SSH into VM vagrant ssh # open up php.ini file sudo nano /etc/php5/fpm/php.ini # increase the value of max_execution_time parameter and save changes max_execution_time = 300 (30 is by default) # restart PHP-FPM sudo service php5-fpm stop sudo service php5-fpm start
If you have your own environment, simply find on Google where your php.ini file is and increase max_execution_time as I did above.
That’s all there is to it. Reload the homepage, and wait for a few seconds. With this settings in place, PHP will have enough time to compile LESS files and browsers will fully render Luma theme.