Repository navigation
fix(op-bws-reconcile): pin stdin + check metadata-stamp return codes (#17142) - #18170
Merged
Merged
Conversation
…-stamp return codes (#17142)
|
Caution Review failedThe pull request is closed.
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. |
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.
What
Fixes the runner defect reported on #17142 (2026-12-01T08:23:36Z, found in the 02:05 CST reconcile pass on #13948): the seat-side reconcile runner reported BWS→OP copies as "read-back mismatch" when the copies had actually landed — the follow-up Sync-section
op item editcalls had silently failed.Changes (
scripts/fleet/op-bws-reconcile/op_bws_reconcile.pyonly)run()now passesstdin=subprocess.DEVNULLwhenever no explicit input is given, so a piped parent stdin can no longer makeop item edittreat the pipe as a JSON template and fail with[ERROR] invalid JSON provided. Calls with explicit input (op item create -, the bulkop item get -) keep the input pipe unchanged.op item editandbws secret editresults inapply_copies_to_opare now captured; a failed stamp is recorded as its own failure (metadata stamp (op item edit) rc=…/metadata stamp (bws secret edit) rc=…) instead of surfacing later as a false read-back mismatch.op item getreturn code is checked before parsing, so a failed read-back reports asread-back rc=…rather than crashing on empty output.Verification
py_compileclean.subprocess.run/runstubbed): (a)run()with no input passesstdin=DEVNULL, with input passesinput=and nostdinoverride; (b) an edit returning rc=1 produces exactlymetadata stamp (op item edit) rc=1and no read-back attempt; (c) the happy path (create rc=0, edit rc=0, read-back hash + Synclast-hashequal) still lands the copy. All pass.Refs #17142 (defect slice; W3
commandcode.api-keypropagation is unchanged and out of scope).🤖 Lane 0237-D (alpha DRIVE 2026-12-01), claim comment: #17142 (comment)
Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.