Skip to content

Conversation

@ddbeck
Copy link
Collaborator

@ddbeck ddbeck commented Dec 13, 2024

Before this PR, we were silently ignoring all validation errors. 🤦

This fixes the issues in validate.ts and build.ts. It also fixes the individual validation errors.

One of these validation errors is a bit pedantic: some URLs get rejected for failing to match the uri string format. According to JSON Schema, a URI strictly follows RFC3986, which is ASCII only. Instead of rewriting those URIs, I chose to drop the uri format from the schema. Points in favor:

  • It's not especially helpful to consumers, since we're making stronger guarantees about those URLs than mere URI-ishness.
  • It's easier for authors to copy a link as it actually exists in the spec than to stop to %-encode those URLs.
  • We get to drop a dependency.

I don't think this is a breaking change—it's still a string, we're not changing the meaning or scope of those strings, and no one has complained up to now that we're producing non-RFC3986 strings already—but I'd welcome a review of that aspect in particular.

@github-actions github-actions bot added feature definition Creating or defining new features or groups of features. tools and infrastructure Project internal tooling, such as linters, GitHub Actions, or repo settings labels Dec 13, 2024
@ddbeck ddbeck requested a review from Elchi3 December 13, 2024 15:50
@ddbeck ddbeck mentioned this pull request Dec 13, 2024
@Elchi3 Elchi3 merged commit 87a0e12 into web-platform-dx:main Dec 16, 2024
3 checks passed
@ddbeck ddbeck deleted the unsilence-validations branch December 16, 2024 09:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature definition Creating or defining new features or groups of features. tools and infrastructure Project internal tooling, such as linters, GitHub Actions, or repo settings

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants