Dashboard › publish › Distillation
21357c50-3563-4415-af8a-4327ba3c728d["lore_tm_v1_uLRlQtPTC__1NxUzeZ3i3CwAxvjHbyKPDkkWne9oaoM","lore_tm_v1_1zybF8LbDC3oJADDiiiPrD9QfzcqNSW7Q08IwtvEqpc"]
Date: Sep 8, 2026
src/modules/__tests__/update-issue.js imports vi, describe, test, expect, beforeAll, beforeEach, and it from vitest; imports fs; and requires { updateIssue, transformIssueBody } from ../update-issue.js.updateTargetsArgs test fixture supplies inputs: { repo: "sentry", version: "21.3.1" }, context runId: "1234", repo { owner: "getsentry", repo: "publish" }, issue number "211", mocked workflow-run URL https://github.com/getsentry/sentry/actions/runs/1234, mocked issue API methods get, update, removeLabel, and mocked Sentry Scope, NodeClient, and Session classes.update-issue.js tests set process.env.GITHUB_WORKSPACE = "."; spy on fs.existsSync; mock fs.promises.readFile to return {"published":{"lol":true,"hey":false,"github":true}}; and mock octokit.rest.issues.get to return a publish issue body for @BYK, default merge target, target checkboxes github, pypi, docker[release], and docker[latest].describe.each([false, true])("state file exists: %s", ...) tests updateIssue(updateTargetsArgs) for both missing and existing state files. In both cases, fs.existsSync must be called exactly once with "./__repo__/.craft-publish-21.3.1.json".updateIssue() must fetch issue "211" via { issue_number: "211", owner: "getsentry", repo: "publish" }, update it exactly once, and produce an updated body containing checked github and lol, unchecked pypi and hey.updateIssue() must not call octokit.rest.issues.update.updateIssue() must call octokit.rest.issues.removeLabel exactly once with { owner: "getsentry", repo: "publish", issue_number: "211", name: "accepted" }.removes accepted without parsed publish inputs calls updateIssue() with inputs: undefined; it expects no fs.existsSync, issue get, or issue update call, but expects removal of accepted from issue "211" in getsentry/publish.transformIssueBody() test uses published states { "npm[@sentry/node]": true, "aws-lambda": true, github: false, foo: true }. It must preserve non-target issue text, normalize target checkbox formatting, change npm[@sentry/node] to checked, retain aws-lambda checked, change github to unchecked, append checked foo, and preserve the explanatory footer: Targets marked with a checkbox have already been executed. Administrators can manually tick a checkbox to force craft to skip it..accepted matches. .github/workflows/publish.yml documents handling when accepted is added to a publish issue, gates on github.event.label.name == 'accepted', sets APPROVAL_ACTOR: ${{ github.actor }}, and at lines 107/215 removes accepted with body Approval is invalid or could not be verified. Re-add the accepted label to retry after resolving the issue...github/workflows/ci-poller.yml polls only issues with both ci-pending and accepted; it invokes node src/publish/current-accepted-event.js with APPROVAL_TOKEN="$GH_TOKEN" to obtain approval .actor and .eventId, exports them as EXPECTED_ACCEPTED_ACTOR and EXPECTED_ACCEPTED_EVENT_ID, and removes accepted if approval binding/validation/proof recording fails or changes during CI..github/workflows/ci-poller.yml handles CI failure by swapping ci-pending to ci-failed, removing accepted to stop polling, and instructing the author to fix CI and re-add accepted; its check-run failure comment states publishing is blocked and links https://github.com/${repo}/commit/${sha}/checks/, while commit-status failure comments list failed status contexts and the same retry instruction..github/workflows/auto-approve.yml auto-approval condition permits actors sentry-release-bot[bot] or getsantry[bot]; it runs gh issue edit "$ISSUE_URL" --add-label accepted.