Bug #10051
closedTweets and email notifications are not being generated from posts on OpenAtCUNY site
Added by scott voth over 6 years ago. Updated about 6 years ago.
0%
Description
Madeline Cohen reports that since mid June, no tweets or email notifications on her site. She is using JetPack. I became an admin and set up Jetpack and successfully connected to Twitter via Publicize.
I copied her last post to see if it was working now and received this: "Post published, sending emails to subscribers and sharing post on Twitter (@OPENatCUNY)."
But nothing was generated.
https://twitter.com/OPENatCUNY?lang=en
https://openatcuny.commons.gc.cuny.edu/
Files
2018-07-24_164854.jpg (61.1 KB) 2018-07-24_164854.jpg | Raymond Hoh, 2018-07-24 07:50 PM | ||
jetpack opan at cuny.jpg (47.7 KB) jetpack opan at cuny.jpg | scott voth, 2018-07-25 07:57 AM |
Related issues
Updated by Boone Gorges over 6 years ago
- Assignee set to Raymond Hoh
Ray, could you have a look? I have a feeling that there may be a connection between this problem at wp-content/mu-plugins/assets/jetpack.php, where I've blocked Jetpack's sync-via-cron tool. In theory, the sync should be happening anyway via one of the post-publish hooks, but it could be that this is getting blocked for some reason or other. Another possibility is that there's an xml-rpc issue.
Updated by Raymond Hoh over 6 years ago
- File 2018-07-24_164854.jpg 2018-07-24_164854.jpg added
- Status changed from New to Assigned
I checked the Jetpack Publicize settings for OPENatCUNY and it doesn't seem like they have set up Jetpack with a WordPress.com account, which is required for the Publicize feature to work correctly.
See attached screenshot:
Has Madeline ever set up a WordPress.com account and configured Jetpack for this feature to work before? If she did, this could be another case of #9974.
Updated by scott voth over 6 years ago
- File jetpack opan at cuny.jpg jetpack opan at cuny.jpg added
Interesting. Madeline said she set up the connection and when I looked at it, it was not connected. So I connected it and set up the sharing to her Twitter account. But now when you look at it is disconnected again. I just signed on and I see this:
Updated by scott voth over 6 years ago
Any update on this? Should we install a plugin like WP to Twitter (https://wordpress.org/plugins/wp-to-twitter/) if JetPack Publicize is not working?
For the second issue - I'm not actually sure what controls email notifications to members of a site. Is that part of WordPress core? Or Jetpack? Just wondering if the two issues are related.
Thanks!
Updated by Raymond Hoh over 6 years ago
Hi Scott,
About the screenshots, apologizes as it appears to be a Jetpack UX / UI problem here:
https://github.com/Automattic/jetpack/issues/6293#issuecomment-318388919
The site looks to be configured correctly, but the UX messaging is confusing.
Anyway, I took a look at Jetpack's debug screen at:
https://openatcuny.commons.gc.cuny.edu/wp-admin/admin.php?page=jetpack-debugger
And this info stuck out to me:
Sync Queue size: 1142 Sync Queue lag: 5 weeks, 6 days, 21 hours, 14 minutes, 25 seconds
This is roughly the same timespan that OPENatCUNY has experienced this problem.
Email notifications might be tied to Jetpack, but I'm not sure at the moment. If OPENatCUNY needs WP posts to sync to Twitter, then try the WP To Twitter plugin until we can sort this out.
Boone, I looked through the Jetpack codebase and it's a labyrinth of code. The Publicize feature is tied to Jetpack's Sync module, which relies on wp-cron:
https://github.com/Automattic/jetpack/blob/master/sync/class.jetpack-sync-actions.php#L24
After manually running Jetpack's incremental sync with Jetpack_Sync_Actions::do_cron_sync()
several times in wp-cli, the queue cleared itself, however I do not see the posts on OPENatCUNY's Twitter account...
How do you feel about removing the sync-on-cron code snippet in /wp-content/mu-plugins/assets/jetpack.php
, but limiting the schedules to every half hour or hour instead of the default of Jetpack's five minutes in /wp-content/mu-plugins/cavalcade.php
?
Updated by Raymond Hoh over 6 years ago
- Related to Bug #8930: Throttle Jetpack batch routines added
Updated by Raymond Hoh over 6 years ago
- Target version set to 1.13.7
Boone, I've added a commit based on what I mentioned above here - https://github.com/cuny-academic-commons/cac/commit/5553257e481153d066dfd9684e5515c57d6da06e. I've re-enabled the sync-on-cron, but limited the interval to every 30 minutes instead of every 5 minutes.
Let me know if we should deploy this as a hotfix so we can test.
Updated by Boone Gorges over 6 years ago
Yup, this looks fine, Ray - I'd say go ahead with it. You may have to manually schedule the sync cron jobs, I can't recall.
The previous problem with Jetpack sync was that the routines ran frequent as well as long. Your commit takes care of the frequency bit, and the fact that Cavalcade handles the sync in a separate process should mitigate the long-running bit. So let's give it a try as a hotfix.
Updated by Raymond Hoh over 6 years ago
I've been monitoring the Jetpack's Debugger results page located at openatcuny.commons.gc.cuny.edu/wp-admin/admin.php?page=jetpack-debugger
over the past two weeks and the "Sync Queue lag" is under 30 minutes, which matches the custom interval we set for sync-on-cron. So the frequency bit appears to be fixed.
However, OPENatCUNY hasn't made a post recently, so we can't tell if the Twitter Publicize feature is working yet. Let's leave this one open for now until a post is made on OPENatCUNY.
Updated by Boone Gorges over 6 years ago
- Target version changed from 1.13.7 to 1.13.8
Updated by scott voth over 6 years ago
Thanks Boone - Madeline has been asking for an update and this helps.
Updated by scott voth about 6 years ago
- Status changed from Assigned to Resolved
I heard from Madeline that the tweets and email notifications are working again.
Updated by Raymond Hoh about 6 years ago
Thanks Scott. Glad that it is working again!