Repository navigation
feat: key hold decisions by content hash - #1319
Zach Dunn (zachdunn) merged 7 commits into
Conversation
Release and re-hold append an override instead of writing ai.hold=approved. Readers share deriveHoldState, and a legacy approved row still counts as released. Co-authored-by: Zach Dunn <zachdunn@users.noreply.github.com>
🦋 Changeset detectedLatest commit: 32a4eb0 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
Important Review skippedAuto reviews are limited based on label configuration. 🏷️ Required labels (at least one): 2
🚫 Excluded labels (none allowed): 1
Please check the settings in the CodeRabbit UI or the
|
Co-authored-by: Zach Dunn <zachdunn@users.noreply.github.com>
A blob_hold row is the hold decision for a workspace and content hash. Approve and hold record that row with the override and do not write ai.hold. Co-authored-by: Zach Dunn <zachdunn@users.noreply.github.com>
|
No uploads on this PR yet This PR changes UI files (
Tips for agentsLabel each shot so reviewers know what they're seeing. Labels apply to every file in a call, so run one uploads put after.png --pr 1319 --meta path=/settings --state after --caption "Saved settings toast"
uploads put chat.png --pr 1319 --app ios --screen "Chat" --state afterNo CLI? With the Uploads MCP, call This comment updates with each upload, so you don't need to post the images yourself. A shot or two in the PR description is still welcome. Check what's attached with Workspace admins can turn this comment off in Settings → GitHub · docs |
Co-authored-by: Zach Dunn <zachdunn@users.noreply.github.com>
Co-authored-by: Zach Dunn <zachdunn@users.noreply.github.com>
list_held now describes sha. The docs catalog snapshot follows that description. Co-authored-by: Zach Dunn <zachdunn@users.noreply.github.com>
A key is held only when it has its own ai.hold row and the blob is not released. Approve and re-hold move every such key, and deleting a file drops it from the held list. Co-authored-by: Zach Dunn <zachdunn@users.noreply.github.com>
Depends on #1318. A hold belongs to one upload. A key is held only when it has its own
ai.holdrow and the blob is not released. Ablob_hold=heldrow does not hide a key the classifier never held, so the kill switch, an old CLI, andholdFlaggedUploads: falsestill mean the file is public. A release still follows the bytes: it applies to every key in the workspace that has a hold row for that hash, and approve or re-hold moves all of those copies.What it does / what it is not
blob_holdis the lookup for a hash. The held list and admin counts join it to keys that still have a content hash and their ownai.holdrow.ai.hold. If the override write fails, nothing is moved into the held bucket.GET …/files/reviewreturnssha. Approve and hold acceptexpected_shaand answer 409 on a mismatch. The file page,uploads approve, and MCP approve send that hash when they have one. Slack stays optional.How to try it
uploads meta getshowsai.hold=approvedafter a release. The stored row stayspending.uploads approve --allsends the hash from the held list.Technical notes
Approved rows with no content hash are skipped and left
approved. After the migration, that skip count is:When keys that share a hash mix
pendingandapproved, and a pending copy still sits in the held bucket, the migration does not mark that hash released. Restoring those bytes from SQL is not possible, so the pending copy stays held instead of 404ing as a release. A pending row with no hash stayspendingand stays off public surfaces. It is not on the held list.Test plan
list_heldapprove32a4eb0c