Repository navigation
WW-5866 Percent-encode WebJar file names in generated URLs - #2163
Open
ciphertrail-x wants to merge 1 commit into
Open
ciphertrail-x wants to merge 1 commit into
ciphertrail-x wants to merge 1 commit into
Conversation
Encode raw WebJar file path names as UTF-8 URL path segments while preserving separators and leaving classpath resource lookup unchanged. Add real-provider URL, component output, and resource-content regression coverage, including semicolons in resource names. Generated-by: OpenAI Codex
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.
Fixes WW-5866.
Percent-encode WebJar file names as UTF-8 when generating a URL. For example,
theme;dark.cssnow produces a URL ending intheme%3Bdark.css, while the classpath lookup still usestheme;dark.css. Directory separators and literal+characters are preserved.The regression tests cover URL generation, both writer and
varoutput, and classpath lookup. The semicolon test decodes the generated URI, passes the path to the Struts static content loader, and compares the response bytes with the CSS fixture. This test exercises the loader directly.On JDK 17 and Maven 3.10.0, the root
mvn -DskipAssembly verifyrun passed all 30 modules: 5,271 Surefire tests and 60 Failsafe tests, with zero failures, errors, or skips. An earlier rootmvn -DskipAssembly testrun stopped during Tiles compilation. The same failure reproduced on the unmodified base commit.Thanks to Yu Deshui (于得水) for reporting the issue. OpenAI Codex assisted with the implementation, tests, and documentation.