* Add a craft-raw decoder comparison example
* Clean up RAW decoder report test fixtures
* craft-raw: say the report hashes decoded samples and which revisions build it
The digest covers RawImage::data, after any decoder linearization, so the
README now says "decoded samples" and explains that two stored codes that
map to the same value give the same digest.
The copy-into-an-older-checkout instructions now name the first main
revision the example builds on (ecee6933, #1171): older revisions have no
Cfa origin fields.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
---------
Co-authored-by: FredApps <FredApps@users.noreply.github.com>
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
The DNG integration target also runs when JPEG XL decoding is disabled.
Gate the five JPEG XL cases and their fixture helpers on the jxl feature
so a DNG-only test run checks the codecs available in that build.
The full JPEG XL regressions remain enabled when jxl is selected.
Co-authored-by: pancake <pancake@nopcode.org>
* fix(mcp): validate JSON-RPC versions before dispatch
Reject malformed request envelopes before tool or lifecycle effects. Companion to storytold/gridcraft#4210 after the shared-server migration.
* test(mcp): cover invalid version markers across transports
Actual shared crate: baseline 18 passed and 3 new regressions failed; fixed 21 passed. Repository formatting and strict production Clippy pass.
craft-image-codecs reads and writes JPEG-LS since #1576, but the
format registry had no entry for it. A `.jls` name resolved to no
format, and a JPEG-LS file was reported as JPEG because both start
with `FF D8 FF`.
`Format::JpegLs` now has the `jls` extension, the `image/jls` media
type and the codec mapping, so its capabilities come from the codec.
A file that starts with `FF D8 FF` is JPEG-LS when its marker segments
lead to an SOF55 frame header (`FF F7`). The walk follows
`jpeg_frame_from` in craft-image-codecs, which a build without the
`raster-codecs` feature does not link, and reads at most the first
1 MiB. When the bytes end before any frame header, a `.jls` name gives
JPEG-LS and any other name gives JPEG.
craft-file-import routes `JpegLs` to its raster reader and lists `jls`
and `image/jls`, so a JPEG-LS file still imports as it did when it was
detected as JPEG.
Follows #1576.
The Linux leg restores the newest rolling cache entry of the workspace
crates (cache-workspace-crates), so a pull request rebuilds only the
crates its change reaches. Each main run saves an entry of its own and
cache-prune deletes the older ones; the midnight scheduled run builds from
source and starts the entry afresh.
gate.yml's cache-workspace-crates covers a whole call, so the macOS and
Windows legs move to a call of their own with dependency-only entries. A
select platforms job decides whether that call runs, since an empty leg
list would fail it.
To fit the 10 GB cache budget, the lint legs and the sonarcloud
instrumented build keep no cache.
Every workspace gate with `--all-features` has been failing since #2135 taught
craft-image-codecs to read JPEG XL behind a `jxl` feature. The capability test
asserted that JXL read is `Unsupported`, full stop. With that codec feature on,
`capabilities()` forwards the codec's own answer of `Available`. The assertion
then fails.
This crate cannot read that feature through `cfg!`. The feature belongs to a
dependency. A workspace build turns it on without this crate selecting
anything. An equality against either value is therefore wrong in some build.
The test now asks the codec the same question the code asks it. It compares
the two answers. A build whose codec reads JXL must report `Available`. One whose codec
does not must report `Unsupported`. The mapping has to exist either way. A missing
codec therefore fails an assertion of its own. The comparison is never quietly
skipped. Without `raster-codecs` there is no codec to ask. The answer is
`Unsupported`.
Verified at 1.100.0 on Linux. `cargo test -p craft-file-formats -p craft-image-codecs --all-features --locked` runs the case that was failing and passes. The same test passes with `-p craft-file-formats --all-features` and with `--no-default-features`. clippy with `--all-targets --all-features -D warnings` is clean. `cargo fmt --check` is clean. Making `capabilities()` ignore the codec's read flag fails the test. That is what the comparison is for. The HEIF and deep-EXR failures in that package need the pinned corpus. My checkout has not fetched it.