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

Check badge tables are setup #1434

Closed
pkevan opened this issue Dec 2, 2024 · 3 comments
Closed

Check badge tables are setup #1434

pkevan opened this issue Dec 2, 2024 · 3 comments

Comments

@pkevan
Copy link
Contributor

pkevan commented Dec 2, 2024

Describe the bug

Follow-up to #1428 - it seems like the tables needed to properly perform badge functionality aren't loaded on wordcamp sites, and you end up with a DB error, particularly when checking the existence of badges (which seems to stop removals).

The error returned mentions the table not being available:

XXX_XXX_groups_members' doesn't exist

Given our profile API code (https://meta.trac.wordpress.org/browser/sites/trunk/wordpress.org/public_html/wp-content/mu-plugins/pub/profile-helpers.php) relying on tables being available we should check the config to make sure it's working as expected.

@dd32
Copy link
Member

dd32 commented Dec 3, 2024

This is because WordCamp is using a partial w.org HyperDB config, and doesn't have access to the BuddyPress tables.

I agree, either it should gracefully handle the direct-db reliance being unavailable, or make it available.

I'm tending to lean towards just fixing the HyperDB situation, but it'd be reasonable to fix the db reliance issue too.

@pkevan
Copy link
Contributor Author

pkevan commented Dec 3, 2024

This is because WordCamp is using a partial w.org HyperDB config, and doesn't have access to the BuddyPress tables.

I agree, either it should gracefully handle the direct-db reliance being unavailable, or make it available.

I'm tending to lean towards just fixing the HyperDB situation, but it'd be reasonable to fix the db reliance issue too.

Yes, I spotted that, but wanted to note it for myself (so I didn't forget), and see if there was a reason for it.

I'm in favour of fixing it, since this always return false at the moment.

@pkevan
Copy link
Contributor Author

pkevan commented Dec 4, 2024

Config updated on production.

@pkevan pkevan closed this as completed Dec 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants