I am using this module (which I love, BTW!) on a Drupal 9.2.10 install (PHP 7.4.26 ) and I have noticed an issue.
Scheduled alerts don't seem to either appear or disappear automatically. I have observed that I have to open and re-save an alert (no need to make any changes) and then it works. It seems that I have to do this either after the start time to get the alert to appear, or after the end time to get it to disappear. I have been careful to double check the times I am using (including am/pm designations) as well as the system's time zone to rule out any use or system errors.
I have tested this with the latest Chrome and Safari browsers and my experience has been the same.
Please let me know if you would like any more information. Manual alerts work perfectly.
Comment | File | Size | Author |
---|---|---|---|
#7 | sitewide_alert-scheduled_alerts_not_dissapearing-3263520-7.patch | 559 bytes | ChrisSnyder |
Comments
Comment #2
ChrisSnyderRobert, I have a couple of questions that may help me reproduce your issue and understand what is going on.
Comment #3
robert_t_taylor CreditAttribution: robert_t_taylor as a volunteer and commentedThanks for the quick response. I'll answer each question in turn:
Comment #4
ChrisSnyderRobert, can you try to set the "Browser and proxy cache maximum age" setting, found on /admin/config/development/performance to 1 minute and confirm if the issue is still happening? This will help confirm if you are having the same issue as #3189144: Scheduling fails with Drupal page cache and cache.page.max_age set to 0
Comment #5
robert_t_taylor CreditAttribution: robert_t_taylor as a volunteer and commentedOK, that seems to work correctly for me now. Another mentioned that it seems to take longer on mobile (Android and iPhone). I am going to try a bit more testing.
Thanks for your responsiveness!
Comment #6
robert_t_taylor CreditAttribution: robert_t_taylor as a volunteer and commentedAfter a bit more testing, it looks like it is still acting a bit wonky.
I set an alert (warning) to appear at 8:58 am today and expire at 9:03 am today. While it did appear at the scheduled time, it is still rendering on desktop and mobile. Reloading the page does not help.
Some observations this morning. In Chrome Inspector's Network tab I can see the Cache-Control: max-age=60 header when I load the page. When "load" fires (init.js) I see the Cache-Control: max-age=15 header. However, if I view the response the expired alert is still present in the JSON payload and each time "load" fires it remains.
Comment #7
ChrisSnyderI have been digging into your issue and have not found a definitive cause. I have a suspicion that there is an off-by-one issue when checking the expiration time. Can you apply the following patch and see if this corrects your issue?
Comment #8
SocialNicheGuru CreditAttribution: SocialNicheGuru commentedComment #9
robert_t_taylor CreditAttribution: robert_t_taylor as a volunteer and commentedHey, ChrisSnyder, sorry for the delay in providing feedback on this issue. I believe off-by-one was the issue. I have tested this patch successfully on desktop and mobile (Chrome and Safari) and had a coworker test for me as well.
Thanks for hanging in there with me; much appreciated.
Comment #11
ChrisSnyderComment #12
ChrisSnyder