Skip to content

chore(api): update Proto Rig API - #886

Open
rl-block wants to merge 1 commit into
mainfrom
feat/update-proto-rig-api
Open

chore(api): update Proto Rig API#886
rl-block wants to merge 1 commit into
mainfrom
feat/update-proto-rig-api

Conversation

@rl-block

@rl-block rl-block commented Aug 7, 2026

Copy link
Copy Markdown
Contributor

Reviewable diff: +31/-8 across 2 files (excludes generated, test, and story files).

Summary

Proto Fleet's vendored miner contract now tracks miner-firmware commit 5fbc89f08df97ff4dab19f0ae122d1c72d6b581c and includes the authoritative hashboard identity observation schema. The REST contract and fake-rig behavior remain unchanged because MDK-API.json is byte-identical to the previous snapshot; the TypeScript client diff is deterministic formatting from the currently pinned generator.

How it works

The repository keeps miner-hosted contracts in proto-rig-api/ so open-source consumers do not need access to the private firmware repository. This update copies the new identity schema from the firmware RPC source, records the exact firmware and hashboard revisions, and regenerates the ProtoOS client from the unchanged OpenAPI document. Because the REST surface did not change, no simulator handlers or response models need updating.

Diagrams

flowchart LR
    FW["miner-firmware @ 5fbc89f"] --> GRPC["Vendored gRPC references"]
    FW --> OPENAPI["MDK-API.json (byte-identical)"]
    GRPC --> REF["Proto Fleet API reference"]
    OPENAPI --> CLIENT["Generated ProtoOS client"]
    OPENAPI --> SIM["fake-proto-rig contract"]
Loading

Areas of the code involved

Area / package / file What changed Why it matters for review
proto-rig-api/grpc/mdk_hashboard_identity_v1.proto Vendors slot-state and serial-number observations Confirm the schema is an exact source copy and preserves field numbering/reservations
proto-rig-api/VERSION.md Advances firmware provenance and records the added contract Confirms the snapshot can be reproduced from the private source revision
client/src/protoOS/api/generatedApi.ts Regenerated from the unchanged OpenAPI spec Generated — skip; changes are deterministic formatting only

Key technical decisions & trade-offs

  • Keep the new gRPC schema reference-only instead of adding it to Proto Fleet code generation, matching the existing boundary for miner-hosted RPC contracts.
  • Leave fake-proto-rig behavior unchanged instead of speculating about a REST representation that MDK-API.json does not expose.
  • Commit the pinned generator's deterministic output instead of hand-restoring stale generated formatting.

Testing & validation

  • Verified every existing vendored gRPC/hashboard proto and MDK-API.json byte-for-byte against the source checkout.
  • Ran npm run generate-api-types twice and confirmed stable output.
  • Ran npm run lint.
  • Ran npm run build:protoOS.
  • Ran npm test -- --run src/protoOS/store/utils/errorTransformer.test.ts (8 tests passed).
  • Ran buf format --diff and buf build for the new schema.
  • Pre-push client typecheck passed.

Full E2E and plugin contract suites were not run because neither the REST schema nor simulator behavior changed.

Post-Deploy Monitoring & Validation

No additional operational monitoring required — this updates a reference-only contract and generated formatting without changing the runtime REST API or simulator behavior.


Compound Engineering

@rl-block
rl-block requested a review from a team as a code owner August 7, 2026 16:40
@github-actions github-actions Bot added documentation Improvements or additions to documentation javascript Pull requests that update javascript code client shared review-policy: needs-review Managed by the Review Policy workflow. labels Aug 7, 2026
@github-actions

github-actions Bot commented Aug 7, 2026

Copy link
Copy Markdown

🔐 Codex Security Review

Note: This is an automated security-focused code review generated by Codex.
It should be used as a supplementary check alongside human review.
False positives are possible - use your judgment.

Scope summary

  • Reviewed pull request diff only (c01c380cf620974128223eb09b7f7df11920697e...5e57721725f738d44dc5fcf37df9d20f8c4a60e5, exact PR three-dot diff)
  • Model: gpt-5.6-sol

💡 Click "edited" above to see previous reviews for this PR.


Review Summary

Overall Risk: NONE

Findings

No security, correctness, or reliability issues were identified in the changed hunks.

Notes

The new protobuf file is reference-only and additive. The OpenAPI specification is unchanged, and the generated TypeScript client changes are formatting-only. The client passed a standalone TypeScript syntax/type check.


Generated by Codex Security Review |
Triggered by: @rl-block |
Review workflow run

@rl-block rl-block changed the title chore(api): update Proto Rig API snapshot chore(api): update Proto Rig API Aug 7, 2026
Comment thread proto-rig-api/VERSION.md

## Files Extracted

### gRPC Proto Files (from `crates/rpc/protos/`)

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does fleet communicate with the FW over grpc? If not, can these grpc related files be removed?

@github-actions github-actions Bot added review-policy: human-approved Managed by the Review Policy workflow. and removed review-policy: needs-review Managed by the Review Policy workflow. labels Aug 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

client documentation Improvements or additions to documentation javascript Pull requests that update javascript code review-policy: human-approved Managed by the Review Policy workflow. shared

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants