mix rma.sync_agentcore_model (ReqManagedAgents v0.10.0)

Copy Markdown View Source

Maintainer task: mirrors the bedrock-agentcore and bedrock-agentcore-control botocore service-2.json models from boto/botocore into $RMA_CORPUS_DIR/agentcore/model/, and pins the upstream commit plus per-file SHA256 in $RMA_CORPUS_DIR/agentcore/manifest.json.

Not shipped in the hex package (lib/mix is excluded from package.files) and not exercised by CI — only changeset/2 is unit-tested. Requires RMA_CORPUS_DIR (the private conformance corpus checkout):

RMA_CORPUS_DIR=/path/to/corpus mix rma.sync_agentcore_model

Exit codes: 0 = model already up to date; 2 = model was updated (drift signal for a maintainer CI job); 1 = task failure. Requires OTP 25+ (verified TLS via :public_key.cacerts_get/0). Set GITHUB_TOKEN for API rate-limit headroom.

Summary

Functions

Compares fetched upstream content against a locally recorded manifest and reports which paths are new, changed (SHA256 mismatch), or gone. Pure — does no I/O, so it's unit-testable without network access.

Functions

changeset(fetched, local)

@spec changeset(%{optional(String.t()) => binary()}, map()) :: %{
  added: [String.t()],
  changed: [String.t()],
  removed: [String.t()]
}

Compares fetched upstream content against a locally recorded manifest and reports which paths are new, changed (SHA256 mismatch), or gone. Pure — does no I/O, so it's unit-testable without network access.