Hash one stage's complete key record into a sha256: cache key.
The canonical text is a JSON array of the key-format tag, the stage, its
version and the toolchain and input records as entry lists sorted by name, so
member order never changes the key and no two different records share a text
(JSON escapes every separator). The format tag is part of the hash: changing
how keys are composed changes every key, which invalidates every existing
entry without touching a file. The digest is the engine's FIPS 180-4 SHA-256,
identical in a browser and in Node.
Hash one stage's complete key record into a
sha256:cache key.The canonical text is a JSON array of the key-format tag, the stage, its version and the toolchain and input records as entry lists sorted by name, so member order never changes the key and no two different records share a text (JSON escapes every separator). The format tag is part of the hash: changing how keys are composed changes every key, which invalidates every existing entry without touching a file. The digest is the engine's FIPS 180-4 SHA-256, identical in a browser and in Node.