Skip to:
Content
Pages
Categories
Search
Top
Bottom

Unable to Delete, Edit or Close *Some* Topics


  • jemar707
    Participant

    @jemar707

    Unable to Delete, Edit or Close *Some* Topics

    During cleanup, I came across topics that I was trying to close and wouldn’t close. This happens both in the front end and back end. In the backend, the message ‘Topic…has been closed successfully’ is displayed; however, the topic remains open. In troubleshooting, I tried to edit the topics. When I update the topic, it just reverts changes. I have found about 40 topics that have this behavior, but other topics close just fine. I am doing a massive cleanup and have about 4800 more topics to review and potentially close, but presume I will run into more as I go along.

    Steps I took to troubleshoot further: deactivated all plugins except, bbpress; switched to default WP theme, reset permalink, ran repair tools and turned on debug. The same behavior exists and debug is not throwing any errors.

    I looked at underlying records for some of these problematic topics in the database and the post status is published, comment status is closed in wp_posts. Not sure if this information helps, but I also took a look at the wp_postmeta and found that there are ~4 entries for _bbp_status with meta value published on each of these topics and 25+ entries for _sticky_post with meta value 0. I thought the _sticky_post meta was interesting because these topics were not sticky.

    I’m using WP 4.9.2 and bbpress 2.5.14

    Probably more info than needed —- but I really need to close these topics if anyone can help.

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

  • Robin W
    Moderator

    @robin-w

    no that’s as good amount of information

    for one of these topics that won’t close, can you give us the full post and postmeta entries. (you can blank any sensitive content)


    jemar707
    Participant

    @jemar707

    For one of the posts, I dumped the entries to a csv file. What’s the best way to attach/post here? Not exactly conducive to copy/paste, lol. But I could…


    jemar707
    Participant

    @jemar707

    Here are links to the 2 files if that’s ok:

    wp_posts

    wp_postmeta


    Robin W
    Moderator

    @robin-w

    hmm – I can’t see anything obvious here, the fact that sticky topic is 0 says that it is not sticky.

    In any case you can just delete a sticky topic, so that shouldn’t stop it.

    However since I cannot see why there should be 4 entries, then try just deleting the sticky topic entries in postmeta and try and close again.

    If not come back and I’ll take a look at what the bbpres close function does tomorrow


    jemar707
    Participant

    @jemar707

    I deleted the extra entries. Tried to close, and it was a no go. Checked DB and it added an additional entry, presumably because I just tried to close it.


    Robin W
    Moderator

    @robin-w

    don’t know what is happening

    I’ve just looked at the core close topic code, and it just changes post_status to closed, although it goes via a whole bunch of code in a topic hander function which I haven’t been through line by line.

    Suggest you try just changing the status directly in the db, and see if that fixes. You can always change it back !


    jemar707
    Participant

    @jemar707

    Yes, that forced it to close. I can’t see manually doing that for many more. 40 or so, yeah no biggie. But as I move forward, that just can’t seem like any fun.

    I tested to see if I could do anything with the topic now – and sure enough, it’s stuck closed. Almost seems like it is locked for editing.


    Robin W
    Moderator

    @robin-w

    hmm…

    not sure what to suggest next.

    I could code a quick ‘close topic’ shortcode, but that would be beyond free – contact me via my website if interested

    http://www.rewweb.co.uk


    jemar707
    Participant

    @jemar707

    I will keep at it for now and see if I find any trend in these topics that won’t close. In the meantime I am running queries in the DB to isolate the bad guys.

Viewing 9 replies - 1 through 9 (of 9 total)
  • You must be logged in to reply to this topic.
Skip to toolbar