Skip to content

release(v0.39.1): SEP-2787 reference impl follows spec into camelCase#150

Merged
vaaraio merged 1 commit into
mainfrom
release/v0.39.1
May 27, 2026
Merged

release(v0.39.1): SEP-2787 reference impl follows spec into camelCase#150
vaaraio merged 1 commit into
mainfrom
release/v0.39.1

Conversation

@vaaraio
Copy link
Copy Markdown
Owner

@vaaraio vaaraio commented May 27, 2026

Summary

  • SEP-2787 reference implementation follows the spec into MCP camelCase. soup-oss adopted camelCase across the envelope in modelcontextprotocol/modelcontextprotocol@48c739b1; this patch updates vaara.attestation.sep2787 to emit matching JSON keys.
  • Python dataclass attributes stay snake_case (Pythonic). The rename is at the serialisation boundary only, so user code is unchanged.
  • New issuer_to_dict helper replaces dataclasses.asdict() so the issuer block sorts and renames deterministically.
  • docs/sep2787-overt-mapping.md field-by-field table updated.

Field renames at the JSON boundary

Snake (was) Camel (now)
planner_declared plannerDeclared
issuer_asserted issuerAsserted
payload_derived payloadDerived
tool_calls toolCalls
server_fingerprint serverFingerprint
secret_version secretVersion
exp_seconds expSeconds
requested_capability requestedCapability
projection_digest projectionDigest

Provenance tags

  • sep2787-ref-v0 (commit 3d7af54): snake_case envelope, historical proposed-shape artefact. Preserved unchanged.
  • sep2787-ref-v1 (new, this release): camelCase envelope. Pinned for cross-repo citation against modelcontextprotocol/modelcontextprotocol#2787 and the v0 test vector PR (vaaraio/modelcontextprotocol#2789, head 2a9360f).

Test plan

  • pytest tests/test_attestation_sep2787.py — 28/28 pass
  • ruff check src/vaara/attestation/ tests/test_attestation_sep2787.py — clean
  • pyproject.toml 0.39.0 → 0.39.1
  • src/vaara/__init__.py 0.39.0 → 0.39.1
  • clients/ts/package.json 0.39.0 → 0.39.1
  • CHANGELOG entry under ## [0.39.1] - 2026-05-27

Summary by CodeRabbit

Version 0.39.1

  • Updates
    • JSON serialization output format updated to use camelCase field names (e.g., plannerDeclared, issuerAsserted, payloadDerived, toolCalls, serverFingerprint) instead of previous snake_case convention.
    • Reference implementation documentation updated with new field naming conventions.
    • Test coverage updated to validate camelCase output format.

Review Change Stack

The SEP-2787 draft envelope adopted MCP camelCase convention in
soup-oss/modelcontextprotocol@48c739b1. Vaara's proposed-shape
reference implementation now emits camelCase JSON keys on the
serialisation boundary while keeping Python dataclass attributes in
snake_case, so user code is unchanged.

`Attestation.to_dict()` and the JCS-canonical signing payload emit
`plannerDeclared`, `issuerAsserted`, `payloadDerived`, `toolCalls`,
`serverFingerprint`, `secretVersion`, `expSeconds`,
`requestedCapability`, `projectionDigest`. New `issuer_to_dict` helper
replaces the prior `asdict()` call so the issuer block sorts and
renames deterministically without leaking Python-internal names.

`docs/sep2787-overt-mapping.md` updated. CHANGELOG entry under 0.39.1.
pyproject.toml, src/vaara/__init__.py, and clients/ts/package.json all
bumped. 28 attestation tests pass; ruff clean.

The v0 test vector PR (vaaraio/modelcontextprotocol#2789, head
2a9360f, cited in modelcontextprotocol/modelcontextprotocol#2787) was
regenerated with the same renames separately on 2026-05-27.
@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 27, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 8b117d58-b1f1-43a3-9664-9883a08d49e1

📥 Commits

Reviewing files that changed from the base of the PR and between a144455 and 4c9679c.

📒 Files selected for processing (10)
  • CHANGELOG.md
  • clients/ts/package.json
  • docs/sep2787-overt-mapping.md
  • pyproject.toml
  • src/vaara/__init__.py
  • src/vaara/attestation/_sep2787_emit.py
  • src/vaara/attestation/_sep2787_types.py
  • src/vaara/attestation/_sep2787_verifier.py
  • src/vaara/attestation/sep2787.py
  • tests/test_attestation_sep2787.py

📝 Walkthrough

Walkthrough

This PR converts the SEP-2787 attestation envelope JSON serialization from snake_case to camelCase field names. The core schema serialization functions are updated, the signing and verification logic is integrated with the new schema, documentation is synchronized, tests are updated to validate the change, and version numbers are bumped to 0.39.1.

Changes

SEP-2787 camelCase Envelope Schema and Integration

Layer / File(s) Summary
Attestation serialization to camelCase
src/vaara/attestation/_sep2787_types.py
Attestation.to_dict(), planner_to_dict(), issuer_to_dict(), and args_to_dict() are updated to emit camelCase JSON keys (plannerDeclared, issuerAsserted, payloadDerived, toolCalls, serverFingerprint, requestedCapability, expSeconds, secretVersion, projectionDigest). The issuer_to_dict() helper replaces direct asdict() calls for deterministic issuer block conversion.
Signing payload and verification integration
src/vaara/attestation/_sep2787_emit.py, src/vaara/attestation/_sep2787_verifier.py
_signing_payload() constructs the JCS canonical envelope body using camelCase field names and calls issuer_to_dict() for issuer conversion. Validation error messages now reference camelCase field paths (plannerDeclared.intent, plannerDeclared.toolCalls). Verifier documentation is updated to use camelCase argument commitment field names (argsRef, argsProjection).
Documentation and mapping updates
docs/sep2787-overt-mapping.md, src/vaara/attestation/sep2787.py
Module-level documentation switches to camelCase envelope field naming. The OVERT 1.0 ↔ SEP-2787 mapping table is updated with camelCase JSON key paths and field identifiers.
Test updates for camelCase assertions
tests/test_attestation_sep2787.py
test_to_dict_round_trip_shape is updated to assert camelCase keys in Attestation.to_dict() output and validates nested field structures with updated key paths.
Version number updates
CHANGELOG.md, clients/ts/package.json, pyproject.toml, src/vaara/__init__.py
Project version bumped from 0.39.0 to 0.39.1. Release notes document the SEP-2787 camelCase JSON serialization changes, the new issuer_to_dict helper, and reference tags for camelCase and snake_case envelope versions.

🎯 2 (Simple) | ⏱️ ~10 minutes

A rabbit hops through the schema with glee,
camelCase keys flow naturally,
issuer blocks converted with care,
documents updated everywhere,
version bumped, the spec now fair! 🐰✨

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately summarizes the main change: converting SEP-2787 reference implementation output to camelCase JSON keys to match the specification.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch release/v0.39.1

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@vaaraio vaaraio merged commit a61e87c into main May 27, 2026
12 checks passed
@vaaraio vaaraio deleted the release/v0.39.1 branch May 27, 2026 17:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant