chaoss / website

(Some of the) Content of http://chaoss.community website.
MIT License
34 stars 84 forks source link

GH Modules Sometimes Update Automatically, Sometimes They Don't #817

Closed ElizabethN closed 11 months ago

ElizabethN commented 1 year ago

We have noticed in the past that sometimes our WP pages update automatically when the corresponding files are updated on GH, like they should. But sometimes you have to go into WP and manually update the page in order for it to grab the updated GH content.

I've been curious about this for a while, but today I noticed that when I changed 4 metric files in ONE PR, 3 of those files updated automatically and 1 of them did not 🤯. This is kind of a placeholder for me as I dig a little deeper into this. It's personal now! 😆 💪

ElizabethN commented 1 year ago

Also, earlier this morning none of those files updated automatically with PRs and I had to update the WP site manually to grab the changes. It's confounding!

ElizabethN commented 1 year ago

@klumb do you think this could be caused by a caching setting somewhere in WP?

klumb commented 1 year ago

Yes, this is all caching-related. Some of it may be on the website side, and some of it may be on the client side (your browser).

It is working as it is intended at the website level, so I would be leary of changing any settings.

I would try clearing the cache in your browser first. Especially if you have visited those pages recently.

If you are in a hurry, you can clear the cache on the website (sometimes you need to do this a couple of times). However, it should appear on the website within in a day or two at the most, without clearing the cache.

klumb commented 1 year ago

If you are wondering if it is occurring on your side, try opening it in a different browser (preferably using a privacy mode).

Or you can reach out to someone else and ask them if they can see the change. I have run into several incidents where I can see the change but someone else cannot. That is due to browser caching.

ElizabethN commented 1 year ago

Yes the incident this morning happened when others couldn't see the change either, and the changes were pretty time sensitive. Is there a way to force-refresh immediately for pages that pull from GitHub? Or a way to signify to the browser there's a need to clear the cache and pull in new content?

ElizabethN commented 1 year ago

I'm just thinking about those visiting the site who wouldn't necessarily think to clear their local cache

klumb commented 1 year ago

For time-sensitive things I would always clear the website cache. But I generally do that manually.

klumb commented 1 year ago

I don't know if there is a way to automate that for GitHub pages specifically (and I kind of doubt it). But, I will take a look.

klumb commented 1 year ago

Any time I make a change on GitHub for the website, I preview the website to see the change. If you are logged on to the website as an admin, clearing the website cache is as easy as clicking a mouse button. Are you familiar with how to clear it on the website?

klumb commented 1 year ago

I think that clearing the cache on the website side will often trigger browser refreshes as well. Sometimes you need to clear it a couple of times to see the change.

klumb commented 1 year ago

Do you want to do a quick zoom meeting?

klumb commented 1 year ago

On the browser side, the cache is created when they visit the pages. So if they don't visit the site often you shouldn't have to worry about them clearing their cache. And it will clear on its own in time.

klumb commented 1 year ago

Checking the cache settings, the crawler runs every two hours. So 2-3 hours is how long a change would likely take if it is not instantaneous.

klumb commented 1 year ago

We could probably block the metric pages from being cached, but that would likely affect load times and resources used to view the pages.

ElizabethN commented 11 months ago

I think this has been fixed by @klumb so I'm going to close this. We can reopen if it happens again.