If redirect support is enabled, you cannot edit a redirect because infinite loop is detected

Created on 11 June 2024, 5 months ago

Problem/Motivation

I can create a redirect from a non existing path, but I cannot edit and I get the error "You are attempting to redirect the page to itself. This will result in an infinite loop."

This is a bug introduced with https://www.drupal.org/project/subpathauto/issues/3175637 🐛 Redirects are not taken into account in ::processInbound() Fixed

Steps to reproduce

- Enable Redirect module
- Enable Subpath with default config (redirect_support: true)
- create a node with alias /about-us
- create a redirect from a /non-existing-about-us to /about-us
- try to edit, than save... you cannot do it because of path validation detects an infinite loop.

As a side effect, if you have caches enabled (e.g. prod environments), when the redirect is created it does not work and the result is a 404 page (but a cache flush seems to solve this issue)

🐛 Bug report
Status

Active

Version

1.3

Component

Code

Created by

🇮🇹Italy p4trizio Como

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024