Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: prevent give_payment_note from affecting comment count #3588

Closed
kevcampb opened this issue Aug 9, 2018 · 7 comments

Comments

Projects
None yet
5 participants
@kevcampb
Copy link

commented Aug 9, 2018

The give plugin writes in to wp_comments with a comment_type of 'give_payment_note'

These database entires cause problems on the Wordpress Comments section on the admin site, as they appear in the total comment counts, but not show up due to the non-standard comment-type.

I cannot find any documentation on the purpose of these entries, so I'm unclear as to whether they can be deleted safely.

@ravinderk ravinderk self-assigned this Aug 9, 2018

@ravinderk

This comment has been minimized.

Copy link
Collaborator

commented Aug 9, 2018

@kevcampb
I am unable to reproduce this issue. Please check video for more details:

https://www.useloom.com/share/a3171a16174749a4ad73ed98fde140b4

@kevcampb

This comment has been minimized.

Copy link
Author

commented Aug 9, 2018

Ravinderk, thanks for taking the time to look at this.

The issue, which is clearly visible in your video, is that there are 2381 comments in total, but only 1 is shown. The others cannot be seem as they are not real comments.

There is a deeper issue here with using the wp_comments table in this way, and it seems likely this will conflict with other plugins or future updates to that table.

@ravinderk

This comment has been minimized.

Copy link
Collaborator

commented Aug 9, 2018

@kevcampb As I told you this is my dev environment and I also installed woocommerce on this. Those 2380 comments out 2381 comments is from Woocommerce.

image

@DevinWalker

This comment has been minimized.

Copy link
Member

commented Sep 14, 2018

Resolved via #3627

@mehul0810

This comment has been minimized.

Copy link
Contributor

commented Oct 22, 2018

@kevinwhoffman While testing this issue and discussion with @ravinderk, it seems that we don't have a filter to exclude the comments count of give_payment_note in wp_comment due to which we have created a separate comments table for Give. Now, after migration as we are not deleting the comments data from wp_comments and its metatable. Then, this issue will still exist for customers as the Give comments exist in wp_comments. I would suggest having a health check plugin to delete comments from wp_comments and wp_commentmeta so that support team can help customers delete the Give comments from the old tables after confirming successful migration. Hence, re-opening the issue

Let me know your thoughts.

@mehul0810 mehul0810 reopened this Oct 22, 2018

@impress-org impress-org deleted a comment from mehul0810 Oct 22, 2018

@impress-org impress-org deleted a comment from mehul0810 Oct 22, 2018

@mehul0810 mehul0810 referenced this issue Oct 22, 2018

Closed

chore: ensure quality of Give v2.3.0 #3737

16 of 16 tasks complete

@kevinwhoffman kevinwhoffman changed the title give_payment_note in wp_comments table fix: prevent give_payment_note from affecting comment count Oct 22, 2018

@kevinwhoffman

This comment has been minimized.

Copy link
Member

commented Oct 23, 2018

Slack Chat Summary

Participants: @DevinWalker @kevinwhoffman @ravinderk
Topic: Whether to remove old comments in 2.3.0 or later
Result: We agree to take care of removing those old comments in 2.3.0 rather than wait for a future release, which would require another DB upgrade and cause support issues in the meantime.

@ravinderk Please move forward with the fix to remove old comments only if we can be sure that the comments have been successfully migrated to the custom tables.

@ravinderk

This comment has been minimized.

Copy link
Collaborator

commented Oct 23, 2018

Closing this issue in favor of #3737 (comment)

@ravinderk ravinderk closed this Oct 23, 2018

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.