Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 17 additions & 17 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
# Changelog

## [Unreleased]
## [0.3.0] - 2026-11-13

### Added

- `castor qa:earl` runs the W3C test suites and writes the EARL conformance report
consolidated by the W3C JSON-LD implementation report. The W3C manifests are now kept
with the downloaded test suites.
- `BENCHMARKS.md` documents the benchmark figures and what each of them measures.
`castor qa:bench:validators` now also runs the worker benchmark, which audits a stream
of distinct documents and is the figure to quote for a crawler.
- The blocks of a document that share an identifier (a JSON-LD `@id`, a microdata
`itemid`) describe one node for Google, whatever their format, with the union of their
properties. The audit now merges them into one item, validated as a whole: a property one
Expand All @@ -20,9 +14,25 @@
`Merge`, `AuditOptions::VALIDATOR_MERGE`), since Google keeps them all. The merge is on
by default; pass `mergeNodesSharingAnIdentifier: false` to `Validator::audit()`, or
`--no-merge` to `castor validate` and `castor check`, to audit every block on its own.
- `castor qa:earl` runs the W3C test suites and writes the EARL conformance report
consolidated by the W3C JSON-LD implementation report. The W3C manifests are now kept
with the downloaded test suites.
- `BENCHMARKS.md` documents the benchmark figures and what each of them measures.
`castor qa:bench:validators` now also runs the worker benchmark, which audits a stream
of distinct documents and is the figure to quote for a crawler.

### Fixed

- Framing in JSON-LD 1.1 mode dropped a property whose only value was a node reduced
to a pruned blank node identifier (W3C test `frame#tp046`): the empty node object is
now kept, as `{}`.
- Microdata: a top-level item (an `itemscope` without `itemprop`) placed inside another
item's element was dropped, as was the `content` attribute of any element but `<meta>`
(`<link itemprop="name" content="...">`, which has no `href`). Both are common on real
pages, and Google reads them.
- The W3C manifest entries that reuse the input of another entry with a different
expected output (`compact#ta038`, `frame#tp020`, `#tp021`, `#tp046` and `#tp049`)
are now run. Every test that applies to a JSON-LD 1.1 processor passes.
- Google validator: the address sub-properties of an event location (`streetAddress`,
`addressRegion`...) are no longer reported when missing: the documentation only shows
them in an example, and Google does not report them.
Expand All @@ -36,16 +46,6 @@
validated as a rich result of its own, as Google reports it, when its type is one Google
documents on its own; the types Google only documents as parts of another one
(`Comment`, `Answer`, `AggregateRating`, `ImageObject`...) are left alone.
- Microdata: a top-level item (an `itemscope` without `itemprop`) placed inside another
item's element was dropped, as was the `content` attribute of any element but `<meta>`
(`<link itemprop="name" content="...">`, which has no `href`). Both are common on real
pages, and Google reads them.
- Framing in JSON-LD 1.1 mode dropped a property whose only value was a node reduced
to a pruned blank node identifier (W3C test `frame#tp046`): the empty node object is
now kept, as `{}`.
- The W3C manifest entries that reuse the input of another entry with a different
expected output (`compact#ta038`, `frame#tp020`, `#tp021`, `#tp046` and `#tp049`)
are now run. Every test that applies to a JSON-LD 1.1 processor passes.

## [0.2.0] - 2026-11-12

Expand Down
16 changes: 8 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,15 +63,15 @@ millions of pages a crawler visits. This library brings that check into PHP:

How it compares with what you would use otherwise to *validate* structured data:

| | [Rich Results Test](https://search.google.com/test/rich-results) | [humanmade/schema-org-validator](https://github.com/humanmade/schema-org-validator) | jolicode/structured-data |
| | [Rich Results Test](https://search.google.com/test/rich-results) | [Schema Markup Validator](https://validator.schema.org/) | jolicode/structured-data |
| --- | --- | --- | --- |
| Runs | in a browser, no API | in PHP | in PHP |
| Input | a public URL, or pasted code | a JSON-LD document | an HTML page (JSON-LD, microdata, RDFa) or a JSON-LD document |
| JSON-LD | fully processed | read as written: names are resolved, contexts are not | expanded with the W3C JSON-LD 1.1 algorithms before validation |
| Google rules | the reference | 23 profiles transcribed by hand | 36 types generated from a crawl of the documentation, drift-checked weekly |
| Validation issues location | highlighted in the tool | a JSON pointer | a path in the document, and the position of the block in the HTML |
| Remote `@context` | fetched by Google | not loaded | can be loaded. By default, denied unless allow-listed |
| License | - | GPL-2.0 | MIT |
| Runs | in a browser, no API | in a browser, no API | in PHP |
| Input | a public URL, or pasted code | a public URL, or pasted code | an HTML page (JSON-LD, microdata, RDFa) or a JSON-LD document |
| JSON-LD | fully processed | fully processed | expanded with the W3C JSON-LD 1.1 algorithms before validation |
| Google rules | the reference | none: checks the schema.org vocabulary only | 36 types generated from a crawl of the documentation, drift-checked weekly |
| Validation issues location | highlighted in the tool | highlighted in the tool | a path in the document, and the position of the block in the HTML |
| Remote `@context` | fetched by Google | fetched by Google | can be loaded. By default, denied unless allow-listed |
| License | - | - | MIT |

The other PHP libraries in this space do a different job, and combine well with this one.
[spatie/schema-org](https://github.com/spatie/schema-org) writes JSON-LD; this library
Expand Down
Loading