David Anderson (@davidanderson)

Forum Replies Created

Viewing 11 replies - 1 through 11 (of 11 total)

  • David Anderson
    Participant

    @davidanderson

    After getting deep into the guts of Pagelines, I think this is now fixed… first of all, thanks very much Stephen for being willing to assist. It’s been very good of you.

    In case the autopsy helps anyone else, here we go…

    There was a transient that Pagelines uses – pagelines_sections_cache – that keeps a record of what different section types are registered with the Pagelines theme.

    I haven’t worked out why yet (and won’t try), but though this transient is meant to last 24 hours, it would get re-generated more frequently than that. That plays into what follows.

    Pagelines (in my view) runs some of its code much too early on the front-end, unconditionally – and sometimes it was re-generating the transient on requests that another of our plugins was picking up for API calls (i.e. calls that don’t generate a front-end page). On those requests, for performance, the pagelines-bbpress plugin was not active. As a result, the BBPress section type did not get registered with Pagelines. The transient got saved without knowledge of that section type.

    Thus, later, when the cached transient was getting used, no BBPress section type was known – so Pagelines would output nothing.

    And here’s the really annoying bit. What was the magical BBPress/Pagelines integration code that they used to sell in their store but now give away in the Pagelines-BBPress plugin? What is the wonderful code to get the two to work together? When you scrape away all the boilerplate to find the core code that does something, the whole of it is:

    function section_template() { 
                    while (have_posts()) :
                            the_post();
                            the_content();
                    endwhile;
            }

    Excuse me whilst I go and bang my head against a wall for a bit.

    David


    David Anderson
    Participant

    @davidanderson

    Hi Stephen,

    Does
    https://updraftplus.com/forums/topic/updraft-migration-issue/?theme_override=1
    work (leaving aside the ugliness of an unconfigured default setup for that theme) for you? I’ve not had a failure yet.

    David


    David Anderson
    Participant

    @davidanderson

    Hi Stephen,

    Unfortunately, it’s not the plugin re-activation that’s done anything – I can still reproduce the “it’s not there” as well as the “it is there”. (I got one just now).
    And also, I didn’t de-activate or re-activate using the control panel; I used a filter hook to remove entries from the “active_plugins” option when the URL began with /forums.

    I will keep seeing what I can find… I have hacked in a theme over-ride based on a URL parameter. So far, I have had zero failures with that – but only 1 failure on the current theme since I started trying, so not enough to tell me anything yet.

    David


    David Anderson
    Participant

    @davidanderson

    Hi Stephen,

    There’s no progress there – nothing’s yet been changed! i.e. I re-enabled the plugins after disabling them. And, whilst you couldn’t, I could see the page before disabling them. So, nothing seems to have changed yet – i.e. it’s still “now you see it, now you don’t…”

    David


    David Anderson
    Participant

    @davidanderson

    Hi,

    I’ve disabled all plugins except for BBPress and Pagelines-BBPress (which is required – otherwise you get an error that tells you it’s required…), and the fault was still reproducible.

    Now I’m looking at the theme…. but my forum is now working 100% of the time for me during testing, whether with changes or not – so I’ll have to wait for it to revert to broken behaviour again before I can get any further……

    David


    David Anderson
    Participant

    @davidanderson

    Hi Stephen,

    It’s not likely to be a recent update – I actually only started using bbPress a couple of weeks ago. I migrated from Mingle Forum.

    It’s also still working sometimes for me, and for others (who are still using the forum).

    I will try what you suggest and let you know what I find!

    Best wishes,
    David


    David Anderson
    Participant

    @davidanderson

    Yes, I am. If you don’t use the pagelines-bbpress plugin, then it prints a big banner telling you that it won’t display the forum until you do so!


    David Anderson
    Participant

    @davidanderson

    Hi,

    I would love to get some advice on where to dive into the code to look at this. Everything must be set up correctly – because otherwise, it would never work. What functions should I start looking at to see what isn’t getting called that should be?

    David


    David Anderson
    Participant

    @davidanderson

    P.S. Forgot to mention – CloudFlare doesn’t cache HTML in any case, unless explicitly configured to. I’ve not configured it to.


    David Anderson
    Participant

    @davidanderson

    Hi Stephen,

    Thanks for getting back. Too right that it’s weird! It’s definitely not a browser or CloudFlare or WP Super Cache cache issue – that was what I was investigating when I posted the Apache logs. You can see that successive log entries deliver different numbers of bytes, e.g.:

    1.2.3.4 - - [12/Aug/2014:20:02:36 -0400] "GET /forums/topic/updraft-migration-issue/ HTTP/1.1" 200 74091
    1.2.3.4 - - [12/Aug/2014:20:03:48 -0400] "GET /forums/topic/updraft-migration-issue/ HTTP/1.1" 200 39159

    74091 bytes corresponds to a page load when the forum appeared; 39159 corresponds to that portion being blank (when I hit “reload”, 10 seconds later). It goes back and forth like that with no apparent pattern – you can’t predict what’s next.

    Just to make sure I also tested with WP Super Cache deactivated (it had nothing in wp-content/cache for these pages anyway), and CloudFlare in developer (no cacheing) mode, and emptied the CloudFlare cache.

    Also, when the forum is produced by a shortcode, it works 100% of the time. No other pages on the site do this, or ever have done. The previous forum plugin (Mingle Forum) is both de-activated and removed, so it’s not that interfering.

    So, it seems certain to me that it’s something to do with permalink hierarchy.

    Any suggestions how I can debug this? I have 100% access to everything. But, I’m more of a back-end developer – stuff to do with permalinks and custom post types is stuff I’ve only dabbled in, and I’m not sure where to start diving in. It’s easily reproducible (just keep hitting reload enough times, and the behaviour will change).

    David


    David Anderson
    Participant

    @davidanderson

    P.S. A few consecutive Apache log lines – note how the number in bytes delivered changes:

    1.2.3.4 - - [12/Aug/2014:20:00:09 -0400] "GET /forums/topic/updraft-migration-issue/ HTTP/1.1" 200 74091
    1.2.3.4 - - [12/Aug/2014:20:00:15 -0400] "GET /forums/topic/updraft-migration-issue/ HTTP/1.1" 200 74091
    1.2.3.4 - - [12/Aug/2014:20:00:32 -0400] "GET /forums/topic/updraft-migration-issue/ HTTP/1.1" 200 74091
    1.2.3.4 - - [12/Aug/2014:20:01:07 -0400] "GET /forums/topic/updraft-migration-issue/ HTTP/1.1" 200 74091
    1.2.3.4 - - [12/Aug/2014:20:02:28 -0400] "GET /forums/topic/updraft-migration-issue/ HTTP/1.1" 200 39159
    1.2.3.4 - - [12/Aug/2014:20:02:36 -0400] "GET /forums/topic/updraft-migration-issue/ HTTP/1.1" 200 74091
    1.2.3.4 - - [12/Aug/2014:20:03:48 -0400] "GET /forums/topic/updraft-migration-issue/ HTTP/1.1" 200 39159
    1.2.3.4 - - [12/Aug/2014:20:04:30 -0400] "GET /forums/topic/updraft-migration-issue/ HTTP/1.1" 200 39159
    1.2.3.4 - - [12/Aug/2014:20:04:39 -0400] "GET /forums/topic/updraft-migration-issue/ HTTP/1.1" 200 39159
Viewing 11 replies - 1 through 11 (of 11 total)