Skip to content

Simplify URL parsing detection in metadata#719

Merged
ryanfowler merged 1 commit into
mainfrom
cli-url-parsing
Jun 6, 2026
Merged

Simplify URL parsing detection in metadata#719
ryanfowler merged 1 commit into
mainfrom
cli-url-parsing

Conversation

@ryanfowler

Copy link
Copy Markdown
Owner

Summary

  • Replace the raw contains("://") check with explicit authority-scheme detection.
  • Keep schemeless host parsing as a separate path so example.com, localhost:3000, and IP literals still work.
  • Add regression tests for explicit schemes, schemeless defaults, invalid inputs, and :// appearing in paths or queries.

Testing

  • Unit tests added around normalize_url and the explicit-scheme detector.
  • Local validation passed with cargo fmt, cargo clippy --locked --all-targets --all-features -- -D warnings, cargo test --all-features, and the serialized integration test suite.

@ryanfowler ryanfowler enabled auto-merge June 6, 2026 23:06
@ryanfowler ryanfowler merged commit 7515efd into main Jun 6, 2026
4 checks passed
@ryanfowler ryanfowler deleted the cli-url-parsing branch June 6, 2026 23:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant