7.1.x FIX: Rank URL mapping specificity by literal token count before wildcard captures#15645
Open
codeconsole wants to merge 1 commit into
Open
7.1.x FIX: Rank URL mapping specificity by literal token count before wildcard captures#15645codeconsole wants to merge 1 commit into
codeconsole wants to merge 1 commit into
Conversation
🚨 TestLens detected 2 failed tests 🚨Here is what you can do:
Test Summary
🏷️ Commit: af941f4 Test FailuresGroovyChangeLogSpec > outputs a warning message by calling the warn method (:grails-data-hibernate5-dbmigration:test in CI - Groovy Joint Validation Build / build_grails)GroovyChangeLogSpec > updates a database with Groovy Change (:grails-data-hibernate5-dbmigration:test in CI - Groovy Joint Validation Build / build_grails)Muted TestsSelect tests to mute in this pull request:
Reuse successful test results:
Click the checkbox to trigger a rerun:
Learn more about TestLens at testlens.app. |
Contributor
|
@codeconsole looks like this broke some tests. if you can fix them, I'm happy to follow-up with a review. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When wildcard validation is enabled, AbstractGrailsControllerUrlMappings now sorts validated wildcard matches first by literal URL-token count (more literals = more specific) and only then by non-routing capture count. Previously a generic pattern like /$id/$action/$imageId could win over a more specific route such as /list/$stage/$sort because both had the same wildcard-capture status, causing the wrong controller/action to be resolved regardless of declaration order. Adds two WildcardActionValidationSpec cases covering both declaration orders.