Skip to content

v0.3.0

Choose a tag to compare

@github-actions github-actions released this 22 Sep 05:10
· 20 commits to main since this release

The digest is computed here now, not just accepted

advertised_tool_digest() is exported. The package accepted a digest and
computed none, so "the same tool" got whatever each caller had invented -- and
the attribute exists to be compared ACROSS services.

from prism_opentelemetry import advertised_tool_digest

advertised_tool_digest(name="search", description="Search the docs", parameters=schema)

The reference's canonicalisation, exactly: name, description and parameters, map
keys sorted at every depth, LISTS LEFT ALONE because required: ["b","a"] is a
different schema from required: ["a","b"], sha256 over the compact JSON.

separators=(",", ":") and ensure_ascii=False are both load-bearing: Python's
defaults put a space after every separator and escape non-ASCII, and either
alone yields different BYTES, and so a different digest, from the same tool in
the other two languages.

AN ABSENT PARAMETER MAP IS {}. The reference shipped a version hashing [] there
and could not reproduce its own digests in any other language; fixed in prism
0.124.1. This port was right the whole time and had no way to say so.

Verified by execution: prism-parity's otel-0021..0023 run one fixture through
all three languages and compare the bytes.