• Resolved widecast

    (@widecast)


    Hello,

    I can’t definitely pinpoint my issue to Custom Post Type UI but I did notice that the issue appears to have started all of a sudden on February 1st, the same day that the new version of the plugin was released.

    Basically, my site is losing the permalink settings associated with my CPT that I created within the plugin, resulting in 404 errors for the posts and its associated custom taxonomies.

    I checked the “rewrite_rules” entry in the database and can confirm that the rules for my CPT are indeed missing. If I visit the WordPress permalink options page, the links work properly again and I can confirm that the rules are re-added to the database.

    The problem is recurring. A few hours later, the 404 returns.

    Any chance the latest plugin update could be the culprit? If not, any other ideas what can cause this type of recurring issue?

    Thanks so much!

    David

Viewing 15 replies - 1 through 15 (of 16 total)
  • Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    Not sure what may be going on there. None of the changes involved with 1.5.2 should be affecting this at all.

    The changes revolved around javascript used on the slug field, array indexes that are possibly populated during updates, and then text shown in the plugin pages itself. Nothing that would be involved with registration or settings saving.

    Do you know if you were upgrading from something before 1.5.1 to 1.5.2? Perhaps something else from a lower version is somehow participating?

    Thread Starter widecast

    (@widecast)

    I was upgrading from 1.5.1.

    Thank you for confirming that the update isn’t the likely cause of this behavior.

    I will keep troubleshooting until I hopefully solve this.

    Thanks, Michael!

    Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    Welcome.

    I have the same 404 issue.

    I have Custom Post Type UI 0.8.2 installed, and attempting to Update to 1.5.2. (On latest WP 4.7.2)

    When I rollback CPTUI to 0.8.2, everything works again.

    Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    @lentinidesignkeith that’s quite the jump, to be honest. In 1.0.0, we changed how the settings were saved, and I recall permalink issues being a case. Often they were resolved simply by visiting your permalinks settings and hitting save.

    Thank you. I will try that, and check the site again later. I haven’t tried it yet, due to concerns about @widecast’s observation that “The problem is recurring. A few hours later, the 404 returns.”

    P.s. I inherited this (non-maintained) site a couple weeks ago with the task of updating WP and plugins, hence some big version jumps.

    Michael Beckwith – FYI – Thanks for this thread and your quick response!

    Resolution:
    1. Updated CPT to custom-post-type-ui.1.5.2
    2. Test – 404 error Reproduced
    3. Saved WP Admin > Settings > Permalinks
    4. Test – 404 error FIXED

    I’ll re-test periodically for @widecast‘s observation that “The problem is recurring. A few hours later, the 404 returns.”

    Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    My hunch for the original thread topic is that something else is causing the issues, especially for an upgrade from 1.5.1 to 1.5.2, for what it’s worth.

    Good to see the legacy CPTUI installs being upgraded finally though, I’m happy about that.

    Thread Starter widecast

    (@widecast)

    @tw2113 The issue has returned once again after almost 24 hours. Due to its intermittent nature, troubleshooting has been tricky.

    I tried disabling and re-enabling the Yoast SEO plugin and that resolved the issue (most likely temporarily). I don’t know if disabling the plugin may have simply flushed the permalinks, though.

    Any chance you can take a look at my installation and see if anything stands out?

    Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    I know it’s a long shot, but my biggest question is if it occurs at all with just CPTUI activated, and if not, then which other plugin would be a potential cause. If it does occur with CPTUI alone active, then I’m left extremely curious why. As stated above, the changes involved between 1.5.1 and 1.5.2 shouldn’t be touching permalinks at all.

    Worst case downgrade back to 1.5.1 and see if it still occurs with that version as well.

    Honestly not wanting to log in myself at this point, because I’m doubtful I’d find much at all.

    Thread Starter widecast

    (@widecast)

    Unfortunately, because this is a production site, I can’t disable all the plugins aside from CPTUI for extended periods of time.

    I can try rolling back to 1.5.1 to rule that out.

    If I find anything noteworthy, I’ll report back. Thanks!

    Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    Recalling any other changes that were made at the time would help rule out things too. Like if you also updated XYZ plugins as well at the same time.

    Thread Starter widecast

    (@widecast)

    Yes, absolutely. I’ve been analyzing the last modified time stamp on the various plugins to try and get a better idea of what may have changed around that time.

    I did migrate the entire site from HTTP to HTTPS around then as well. Can you imagine this interfering with either CPTUI or CPT permalinks in general?

    Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    I could imagine it having an issue with permalink/rewrite rules one time, but not consistently like you’ve experienced.

    CPTUI itself doesn’t store urls at all, so I’m confident it’s not an issue on that topic.

    Just to be certain, here’s a list of moments that CPTUI will flush rewrite rules:

    1. upon deactivation
    2. If converting from pre-1.0.0 settings.
    3. When deleting a post type.
    4. When updating a post type.
    5. When deleting a taxonomy.
    6. When updating a taxonomy.
    7. When importing settings of either post types or taxonomies.

    Any other time, it shouldn’t be touching the setting.

    Thread Starter widecast

    (@widecast)

    I am starting to suspect either a bug in Yoast SEO or some sort of conflict between Yoast SEO and CPTUI that may be causing this.

    During one of my site’s 404 moments, when I disable Yoast SEO, the 404 disappears. Upon its reactivation, the 404 returns until I visit the permalink options page.

    I have updated the Yoast SEO GitHub page with my findings.

    I did notice that the Yoast SEO changelog mentions this:

    4.2.1

    Release Date: February 2nd, 2017

    Bugfixes
    Fixes a fatal error “Call to undefined method yoast_i18n::set_api_url()”. This error occurred with certain other plugins that also include the i18n-module.

    Does CPTUI include an i18n-module?

    • This reply was modified 8 years, 1 month ago by widecast.
Viewing 15 replies - 1 through 15 (of 16 total)
  • The topic ‘404 on CPT pages’ is closed to new replies.