[wp-trac] [WordPress Trac] #13459: Conflict between post and page slugs/permalinks when permalink setting is set to /%postname%/

WordPress Trac noreply at wordpress.org
Thu Mar 31 16:39:24 UTC 2022


#13459: Conflict between post and page slugs/permalinks when permalink setting is
set to /%postname%/
--------------------------+-----------------------------
 Reporter:  jamescollins  |       Owner:  (none)
     Type:  defect (bug)  |      Status:  assigned
 Priority:  normal        |   Milestone:  Future Release
Component:  Permalinks    |     Version:  2.9.2
 Severity:  normal        |  Resolution:
 Keywords:  has-patch     |     Focuses:
--------------------------+-----------------------------

Comment (by bobbingwide):

 I've written some round trip black box PHPUnit tests demonstrating two
 problems.

 See https://github.com/bobbingwide/dupes where you'll find the tests and
 notes on how to run them. They rely on `wp_remote_get()` actually
 requesting the content for the permalink and then seeing if it got what it
 was asking for.

 The tests currently produce two failures.

 1. The original problem, where the duplicate page is returned instead of
 the post.
 2. The inability to retrieve the post by its post ID, when there's a
 duplicate page.

 There are other failing scenarios for which I've not yet written tests.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/13459#comment:73>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list