Site logo

Archived topic

Website cannot write style.min.css

18 replies · Started by Neil on December 27, 2020

Viewing posts 1–15 of 19

Hi,

My website, https://evafogelman.earthstage.pw/ cannot find this file: my-site/app/uploads/generatepress/style.min.css

When I regenerate CSS on a fresh install of Dispatch, I get a green check, but when I go the front page, I get an error reported by the plugin, Query Monitor. - see screenshot.

Then, when I flush the cache, some styles are lost. When I regenerate again, the styles return as does the error.

I recursively reset all plugins, everything in the /app to be owned by my user:www-data

Still getting three PHP warnings.

I am using a Bedrock install and have commented out these directives:

Image: Screenshot of PHP warning

I can install dispatch on a fresh build if it helps. The file is regenerated fine on my local build. I am using a VM locally. Both PHP 7.4.3 Apache 2.4.41

Hi Tom,

I set my application.php with these custom settings:

(removed by Neil)

I checked that /web/app/uploads/generatepress/style.min.css is [myuser]:www-data and the file is mod 644.

I use the customize to change the color of a button on the front page and in the customizer the color is stored. But after publishing it the front page is still getting the color from my child theme where I copied over the site styles provided by dispatch. I removed those styles from the UI of the customizer and just get them from my child theme where I add my own custom styles at the bottom of the file.

It is looking for the style of the button color from /web/app/uploads/generatepress/style.min.css but the file is not getting updated.

I am willing to re-install if you want a better test case. My local, using a VM with the same or very similar php-apache environment updates style.min.css when I change a value in the Customizer.

Are there any other related errors in your error_log or debug.log files?

Thanks for reporting back! :)

Hi Tom,

no errors sent to the error.log or debug.log since 12/27 -

PHP Warning: ftp_chmod() expects parameter 1 to be resource, null given in /var/www/wordpress/evafogelman.earthstage.pw/web/wp/wp-admin/includes/class-wp-filesystem-ftpext.php

I will try to reinstall since I haven't begun working on staging yet.

I will let you know.

Thank you!

Hi Tom,

I did a clean install with a fresh database and have no other plugins activated. I observe that the generatepress directory is created but the style.min.css is not being written.

Does this fresh install have anything in the error_log?

Hi Tom,

I am attaching the error.log. Just pasting it in I see.

I made it private.

Hard to sort through there, but it seems as if the file isn't being successfully uploaded, likely due to server permissions.

Are you using a specific program to host your sites locally? XAMPP? WAMP? Flywheel? Or is it a custom setup?

My local setup is DrupalVM by Jeff Geerling that I set up for Wordpress Bedrock. My local version generates style.min.css as expected.

I can fully report on the condition of the staging server and I have recursively set the ownership of the /web directory to [myuser]:www-data

I am new to debugging. Did my error.log not provide enough info as compared to a debug log?

I can follow this article if it will help you sort this out.

https://wpcontentplugins.com/development/how-to-enable-wordpress-debug-mode-2-methods/

From what I can gather from the logs, your server isn't writing the file to the server, however, it's missing any checks we've added to return inline CSS if the file isn't writeable. So the code thinks the folder is writeable, but it's not.

Ideally, I need to be able to reproduce the server environment so I can dig through the code and find the point of failure. I'll do my best to do so.

For now, you'll need to use the inline CSS option in Customize > General.

Thanks for your help!

Thank you for looking into this. I am willing to provide you with any other information you may need. I now plan to take the minified css from my local and use it on staging instead of using inline. I have seen that it works and I can live without generated minified css for now, making all my changes and manually and updating the minified file.

I have learned a great deal reading the support forum here and am looking forward to working with your theme and plugin.

I am also impressed with your professionalism and courtesy. Thank you so much!

I have a private question about my server.

This archived topic is closed to new replies.