ci: add reply-coverage guard for CarServer.Response#11
Merged
Conversation
scripts/upstream_coverage.py only enforces upstream subset ours, which is blind to server-to-app reply payloads since neither public repo declares them - that blind spot let GetChargeOnSolarFeatureResponse sit unmodelled with no CI failure. Add scripts/check_reply_coverage.py: it verifies every known Response.response_msg field number is either modelled in the oneof or reserved with a reason comment, and fails CI otherwise. Mark fields 12, 17 and 19 reserved with their exclusion reasons so the closed set is fully accounted for.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Intent
scripts/upstream_coverage.pyonly enforces upstream (subset) ours; it has no visibility into server->app reply payloads, since neither Tesla's public repo nor our upstream mirror declares them. That's the blind spot that letGetChargeOnSolarFeatureResponsesit unmodelled with a green CI, until command: fill in the CarServer.Response reply-payload oneof #10 filled in the rest of the reply oneof.scripts/check_reply_coverage.py: a CI gate that compilescar_server.prototo a descriptor set and checks a fixed, hand-maintained set of knownCarServer.Response.response_msgfield numbers - every one must be either present in the oneof orreservedwith a reason comment. A field that's neither, or areservedentry with no comment, fails the build with the offending field number named.ci.yml.reservedwith the same exclusion reasons already documented inAGENTS.md(12: namespace-publish decision pending; 17/19: app-only namespaces).reservedline or an oneof entry for a known field number reproduces the exact silent-omission bug this guard exists to catch.buf lint,buf breaking, the existing upstream coverage gate, both language builds, andtwine checkare all green against this branch.