Saving seems to be a hit and miss currently (Sass and NGINX)

This topic contains 16 replies, has 2 voices, and was last updated by  Sebastian 1 month, 2 weeks ago.

Author Posts

adkoen

Hi,
Latest version 5.7.0.5
Working with Sass and it normally autosaves. But sometimes it does, sometimes it doesn’t.
When viewing the generated css sometimes parts are visible, other times some parts dissapear.
All caching has been turned off.
Any idea?
thanks,
Koen.


Sebastian

Hey Koen,

I noticed this too yesterday and I’m currently working on it. Are you running Microthemer on an nginx server by any chance?

Cheers,
Sebastian


adkoen

Yes, I do work on an nginx server.


Sebastian

Ah, thanks for confirming. Do you use Kinsta by any chance?


adkoen

Nope. I’m with Gridpane currently.
https://gridpane.com/


Sebastian

OK, so it’s likely a general issue with nginx. Right now I know that something is causing MT’s request to load active-styles.css?reload=[timestamp] to return 502 errors intermittently. Sometimes the file doesn’t load at all. Sometimes only part of the file loads. I’ll update you when I know more.


adkoen

OK, I can wait a day or two if needed. Otherwise I have to do this another way 🙂


Sebastian

Got it. I’m not working on anything else until I get this sorted so hopefully a fix will be ready soon.


adkoen

I just want to say don’t worry about me! I’ll be fine if it’s not working right away 🙂


Sebastian

Hey Koen,

I’ve been dealing with my nginx hosting support for a couple of days now, and I think we’ve finally had a break. They are still investigating exactly what’s going on, but it seems that disabling the following setting in nginx.conf solves the issue:

open_file_cache off;

About that setting: https://easyengine.io/tutorials/nginx/open-file-cache/

Could you see if Gridpane can do this for you?

Cheers,
Sebastian


adkoen

Unfortunately this setting is already disabled on my server.


Sebastian

How frustrating. OK, there must some other differences in our configuration. Kinsta would not share their nginx.conf file with me. The only changes they made to fix the issue were the following:

open_file_cache off;
open_file_cache_errors off;

They supplied the second setting just now. I don’t suppose it will do anything if the first is set to off, but worth a try just in case.

I’ve also released a new version of Microthemer (5.8.0.0) which addressed some PHP warnings. Again, I doubt it will solve the issue for you but worth a try.

I will see if I can find any open_file_cache related nginx settings. Failing that, I will try out a client side SASS compiler, but this will likely take a week to integrate. And will be experimental.

Cheers,
Sebastian


adkoen

Don’t do this just for me Sebastian. Really. I moved back to Cloudways and all is working like a sunshine for the site I’m working on. I don’t have time anymore today as I’m wrapping things up. I’ll make sure to give that setting and the new version a try tomorrow. I’ll update here.
Take your time, no need to rush things just for me. Do something else if you need to, please 🙂


Sebastian

Hey Koen,

I appreciate you giving me some slack. But I always prioritise bugs above anything else I’m working on. It’s just my approach to development!

Cheers,
Sebastian


adkoen

Yes, but this seems to be quite a bug. I find your way of doing things a great approach to development, but in the case of … no need to worry about me 🙂


Sebastian

I appreciate that Koen 🙂


Sebastian

OK, so six weeks later and the new client-side SASS feature is available as a beta. Basic integration did indeed take one week. It took an extra week to support SASS @imports. But the main challenge was making the compilation process so fast that it adds almost an imperceptible number of milliseconds to the user workflow, even on large projects. It took 2/3 weeks to write a selective compile manager to make that possible. And a further 2 weeks to test and tweak.

Learn more about the beta here: https://themeover.com/forum/topic/new-ultra-fast-sass-beta-testers-needed/

This feature should significantly speed up your workflow, as well as solve the NGINX issue 🙂

Cheers,
Sebastian

P.S. the reason I spent so long on this is because near instant SASS compilation is necessary for using SASS to deliver Microthemer GUI variables and presets (mixins), a dream I’ve had for a while.

You must login or register to reply to this topic.