Opened 2 years ago

Closed 6 months ago

#6200 closed defect (bug) (fixed) page displays blank

Reported by: yoga1103's profile yoga1103 Owned by: dd32's profile dd32
Milestone: Priority: normal
Component: Profiles Keywords: close


These pages:

don't display any content, they return just a blank page.

checked on Ubuntu desktop Firefox (85.0) browser and android chrome browser. Both the times blank page.

Change History (4)

#1 @dd32
2 years ago

  • Component changed from General to Profiles

This is caused by a conflict between Gutenberg and BuddyPress.

The bp-default theme directory is registered on the plugins_loaded hook ( plugins_loaded => bp_loaded => bp_register_theme_directory => register_theme_directory() ).

Gutenberg has decided that it should run code upon plugin inclusion, instead of waiting for plugins_loaded like a good plugin, one of which is wp_is_block_theme() which has to create a WP_Theme object, before the BuddyPress theme is registered.

 /// This is the point where the `bp-default` theme isn't yet registered, because BuddyPress hasn't loaded.

This should probably be called a Gutenberg bug, but I guess BuddyPress could also consider loading earlier.. but.. it shouldn't have to.

Last edited 2 years ago by dd32 (previous) (diff)

#2 @dd32
2 years ago

  • Keywords close added
  • Owner set to dd32
  • Status changed from new to accepted

This is temporarily fixed. I've added a mu-plugin that takes care of it for now.

 * Plugin Name: Meta#6200: Temporary for BuddyPress+Gutenberg+bp-default
 * Plugin URI:

 * Register the BuddyPress theme directory early, because Gutenberg.
 * @see
function register_bp_default_early() {
        // BuddyPress is a network plugin, which are loaded prior to muplugins_loaded firing.
        if ( ! function_exists( 'buddypress' ) ) {

        // If we don't need the bp-default theme, no need to do anything.
        if ( 'bp-default' !== get_template() ) {

        // Gutenberg should be within the per-site plugin list.
        // If Gutenberg is network-activated, this will fail and cause the same problem that we're trying to fix.
        if ( in_array( 'gutenberg/gutenberg.php', (array) get_option( 'active_plugins', [] ) ) ) {
                register_theme_directory( buddypress()->old_themes_dir );
add_action( 'muplugins_loaded', 'register_bp_default_early' );

Leaving this open to track the removal of it / fix in Gutenberg / BuddyPress.

#3 @tellyworth
17 months ago

Is there an update on this? Can we close as fixed?

#4 @dd32
6 months ago

  • Resolution set to fixed
  • Status changed from accepted to closed

I've removed the hotfix added above and nothing imploded, I'm marking this as fixed.

Note: See TracTickets for help on using tickets.