Skip to content

Fix htmlIndexToVersioning() HTML title attribute handling#6745

Merged
timtebeek merged 1 commit intomainfrom
timtebeek/fix-6739
Feb 15, 2026
Merged

Fix htmlIndexToVersioning() HTML title attribute handling#6745
timtebeek merged 1 commit intomainfrom
timtebeek/fix-6739

Conversation

@timtebeek
Copy link
Copy Markdown
Member

@timtebeek timtebeek commented Feb 15, 2026

Summary

The method searched for "> to delimit the href attribute value, which overshoots when additional attributes follow (e.g., title="..."). This resulted in corrupted version strings like 1.0.0/" title="1.0.0 instead of 1.0.0/. Changed the search to look for the closing quote directly, which correctly terminates at the href attribute boundary regardless of other attributes.

Includes test case covering HTML with title attributes on anchor tags.

🤖 Generated with Claude Code

…ttributes

When parsing HTML directory listings, the method searched for "\">" to delimit the
href attribute value. This overshoots when anchor tags include additional attributes
like title="...", causing corrupted version strings such as "1.0.0/\" title=\"1.0.0"
instead of "1.0.0/". The fix changes the search to find the closing quote directly,
which correctly terminates at the href attribute boundary regardless of subsequent
attributes. Includes a test case covering this scenario.

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
@github-project-automation github-project-automation Bot moved this to In Progress in OpenRewrite Feb 15, 2026
@timtebeek timtebeek moved this from In Progress to Ready to Review in OpenRewrite Feb 15, 2026
@timtebeek timtebeek merged commit 0cee243 into main Feb 15, 2026
1 check passed
@timtebeek timtebeek deleted the timtebeek/fix-6739 branch February 15, 2026 15:13
@github-project-automation github-project-automation Bot moved this from Ready to Review to Done in OpenRewrite Feb 15, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

MavenPomDownloader.htmlIndexToVersioning() corrupts version strings when HTML contains title attributes

1 participant