I’ve been having a similar problem for the past few weeks. I am on a litespeed server. I also get the “Recently an error occurred while creating the CSS / JS minify cache: No sources” message.
Minified files are not generated. They do not exist at all in the cache/minify/000000 folder. Clicking on the minified files included in the page source results in a HTTP/1.0 400 Bad Request.
Looking at minify.log in the cache/log folder I can see that the css file locations are incorrect. I am seeing errors like this over and over again:
“/home/hosting/public_html/mydomain/wp-content/plugins/home/hosting/public_html/mydomain/wp-admin/css/login.min.css” doesn’t exist
You can see that part of the file address is doubled. Is this the same with anybody else?
I have been in contact with W3TC support over the past few weeks, and their support guy Willie Jackson told me that the problem was with my server, not the plugin.
Here is the code he showed me as evidence:
$_SERVER[‘SCRIPT_FILENAME’] has value
“/home/hosting/public_html/mydomain/wp-content/plugins/w3-total-cache/pub/minify.php\nify.php\inify.php”
“/home/hosting/public_html/mydomain/wp-content/plugins/w3-total-cache/pub/minify.phpnify.phpinify.php”
from time to time. looks like some unstable or buggy version used.
If the problem is with my server, I wonder why none of my other extensions are having problems though. Autoptimize is able to do minification without any issues. Based on what I’ve seen in this forum, it seems like this minify problem isn’t isolated to just me and my server.
I asked, since quite a few people seemed to have the same problem, if they would attempt to update the plugin to address the issue. He reiterated that the problem appeared to be with my server, but if I could link to others who had the same issue they would investigate. So I linked to this thread as well as a few others I found in this forum that appeared to be related to this problem:
https://www.ads-software.com/support/topic/again-error-occurred-while-creating-the-css-js-minify-cache-no-sources
https://www.ads-software.com/support/topic/minify-css-error
https://www.ads-software.com/support/topic/error-occurred-while-creating-the-css-js-minify-cache-no-sources-to-serve
https://www.ads-software.com/support/topic/recently-an-error-occurred-while-creating-the-css-js-minify-cache-no-sources-2
I would urge others with this issue to contact W3TC support as well. You can do it through the admin page of the plugin itself, or at this link: https://www.w3-edge.com/contact/
If enough people contact them about it, assuming our problems are indeed related, maybe they will be motivated to address the issue.
In the meantime, the Autoptimize extension is working fine. So you can turn off minify in W3TC and just use Autoptimize until the problem is fixed.