Project

General

Profile

Actions

Bug #12471

closed

forum notificaiton not sent

Added by Matt Gold over 4 years ago. Updated over 4 years ago.

Status:
Resolved
Priority name:
Normal
Assignee:
Category name:
Email Notifications
Target version:
Start date:
2020-02-25
Due date:
% Done:

0%

Estimated time:
Deployment actions:

Description

Hi Ray,

I don't think an email notification was sent for this post -- https://commons.gc.cuny.edu/groups/ma-in-digital-humanities-cuny-graduate-center/forum/topic/program-party-this-thursday-feb-27th-7pm-10pm-in-5307/ -- and I'm wondering whether the queue is backed up. can you please take a look? thank you


Files


Related issues

Related to CUNY Academic Commons - Bug #12483: post errorResolved2020-02-27

Actions
Actions #1

Updated by Raymond Hoh over 4 years ago

Hi Matt,

The item doesn't appear to be in the email queue. I also tried to find the corresponding activity stream item for this post and it isn't available.

If the activity stream item isn't available, then the email cannot be queued up for sending.

Is there a particular way that the forum post was created?

I also tried to edit the forum post so the activity item can be generated, but bbPress 2.6 changed the way edits can create activity items.

(Boone - a change was made in bbPress so that if post revisions are disabled, then edits cannot generate an activity item. See https://bbpress.trac.wordpress.org/changeset/6696. On our install, revisions for forum posts are disabled.)

If this forum post is important to be sent, I can force it to create an activity item and thus, an email. Let me know.

Actions #2

Updated by Matt Gold over 4 years ago

it's okay -- I'll post a reply with the info. thank you

Actions #3

Updated by Matt Gold over 4 years ago

I posted a comment that contained the original and reached the error message in the attached (and the same happened here -- https://commons.gc.cuny.edu/groups/ms-program-in-data-analysis-and-visualization/forum/topic/program-party-this-thursday-feb-27th-7-pm-10-pm-in-5307/ )

We really do need this to go out, so if you could force an activity item on both posts, I would appreciate it.

again please note that this is in two gropus -- the MA in DH and MS in DAta Analaysis and vis

Actions #4

Updated by Raymond Hoh over 4 years ago

Hi Matt,

Are you encountering the same "critical error" message while attempting to make any forum post or just in those two groups?

I just tested posting a forum topic and reply in my test group on production and was not able to duplicate the issue. The forum posts also triggered email notifications.

I did see a fatal error in the error logs that might be related to this issue. I pushed a hotfix on production here - https://redmine.gc.cuny.edu/issues/12131#change-49628, but am not sure if this will address this problem.

Can you try again? If successful, you can just delete the other forum post. If you are still encountering the same problem, I can scan the logs to see if there are any other clues.

Actions #5

Updated by Boone Gorges over 4 years ago

Actions #6

Updated by Boone Gorges over 4 years ago

Ray, did your hotfix include an uncommitted change in wp-content/plugins/cac-bp-custom-includes/forums.php? This code is network-activated, so it must be sensitive to cases where bbPress is not present. I've added a function_exists() check near the beginning of the CAC_BBP_Allow_Edits_For_Activity::allow_revisions() method. Can you please confirm that this is an OK approach? And then please be sure that this change is committed to the 1.16.x and master branches so that it can be tracked properly.

Actions #7

Updated by Raymond Hoh over 4 years ago

My apologies, Boone! Yes, the function_exists() check works fine.

Was coding last night and added some code to production to bring back forum post edits to allow activity item creation or updating.

A change was made in bbPress 2.6 to disallow activity publishing if forum revisions are disabled. However, the post_type_supports( BBP_POST_TYPE, 'revisions' ) check will always fail even if revisions are enabled due to a bbPress post type override.

See https://bbpress.trac.wordpress.org/ticket/3328

My goal was to run the code so the activity items could be created as per Matt's issue with the two forum posts above. Then, remove the snippet so I could investigate the issue a bit further. However, I felt sleepy and forgot to remove the snippet before I took a nap!

I've just committed the hotfix here - https://github.com/cuny-academic-commons/cac/commit/2920657ab64689cbe0eb6d608c19b69fdde3b107

Again, my sincere (sleepy) apologies!

Matt, can you confirm that you received an email notification for those two posts?

Actions #8

Updated by Boone Gorges over 4 years ago

Thanks for having the closer look, Ray!

Actions #9

Updated by Boone Gorges over 4 years ago

  • Status changed from Assigned to Resolved
  • Target version set to 1.16.7

Marking resolved on the basis of the above.

Actions

Also available in: Atom PDF