Weaving Tangled Webs

This is why things are more difficult than they might be . . . a story of why I have no idea about anything or maybe it’s a parable of complexity and human frailty.

In the beginning, we created a WordPress Multisite install and turned on BuddyPress. To make the groups works correctly we network activated bbPress.

As a result, anyone logged into their accounts who visited any other rampages site became a Participant of that site (a bbPress user role that allows forum participation). People got very nervous about people being in their user roles. Other people became very unhappy their My Sites list had too many sites.

I had to figure out two things as a result. First, I needed to stop auto-Participant association. I eventually found a way to do that but I still had to deal with the stuff that already happened. The right way to do it was to delete the users who were participants across the multisite. But . . . at that time we couldn’t access our database through anything but php myadmin and it wouldn’t run because the database was too big. So I had to treat the problem and strip the sites from the displayed list.

Fast forward a year or so. At this point, we were able to turn off bbPress at the network level because we didn’t really have any group action and the limited bbPress needs we had could be bettered addressed by activating it on individual sites. I tested turning it off and saw no drama so I did that.

Wait six to nine days . . .

Issues filter up about the Mother Blog failing in two ways.1 It wasn’t creating categories quite right and it was adding the mother blog admin user as a user on the child associated blog under the user role ‘None’.

My internal monologue says I’m screwed. Mark, who was with us for 3 months, built that plugin and it was beyond my skill level. So I’m not sure I can fix it. We’ve also used this plugin a bunch of times so if things go bad there is a huge amount of work to double check and possibly re-do.

I can’t duplicate either error on my local testing install. I decide to focus on the category issue anyway because that one is essential to function. I spend some time just looking at the plugin code and thinking dark thoughts about my own incompetence. I do some things. I try to isolate variables. Time passes. Many other things occur. Other ships are kept afloat.

I talk to the group about how things are failing with this plugin. Stan says all is good for him. The plugin is working fine. He used it yesterday. This conversation leads to the realization that including spaces/hyphens in the main category was the issue. I would swear I tested this but I may not have or I may have in combination with something else that broke it. Why this is different between the two installs is still a puzzle to me. In any case, this let me narrow down my chase to how the plugin was dealing with spaces in categories and if that differed between main categories and sub-categories. It did. So I added $string = str_replace(‘ ‘, ‘-‘, $string); and things now seem to work.

Now, what’s up with the users getting made? Where does the role none come from? Google wandering proves relatively fruitless. Time passes.

I began pursuing the stuff I should have done in the beginning around messing with the databases directly. This makes me nervous on a variety of levels . . . and requires setting up a number of things that don’t work out of the box in our new environment. While trying to get this setup, it occurs to me . . . I might network activate bbPress and see if the user role None becomes Participant.

It does. The filter works again. I curse myself. Things that seemed to be associated with the Mother Blog plugin, because of the timing, actually had no connection whatsoever.

I then revisit the bbPress code and modified it so it works (see below). It was so simple. I have no idea why I couldn’t make this work instantly when I looked at it initially. Insanity. Staggering incompetence.

$add_to_site = bbp_allow_global_access() && $user_role != false;

Not a huge change from . . .

$add_to_site = bbp_allow_global_access() && $blog_role != false;

Man.

via GIPHY

This whole thing played out over at least a year. The attention in short bursts and I learn completely different things between all this stuff. I forget many things as well.2 They come back easier in round two (three, six) but it takes a while to get up to speed again.

It gets harder and harder to un-do things the more time passes, to stop supporting things once they get rolling. It’s also getting more interesting as we get more and more people in the system. Complexities evolve even in fairly standard actions. Overhead adds up. We had around 1,000 new sites in the last week or so.

In retrospect, I wish I’d have done certain things differently. What I’m trying to figure out now is how to see that more clearly in the moment and how to deal with radical changes in my own competency. At times I simply can’t do, or don’t realize what’s possible, in the exact moment of need/choice. It’s then a matter of dealing with the choice of the moment later on . . . not pretty.

Maybe this is just navel gazing . .


1 Consider the previous paragraph foreshadowing . . . and foreshadowing, like hindsight, is 20/20.

2 I don’t un-learn them but they are forgotten.

2 thoughts on “Weaving Tangled Webs

  1. I certainly appreciate the post-mortem on those issues, great to hear you got them resolved. Never would have thought about the BBPress piece as related.

Comments are closed.