Files
Copilot 99bd642db9 fix(web): admin digest post returns real GitHub Issue outcome instead of silent no-op (#5180)
* Initial plan

* fix(web): digest post returns real GitHub Issue URL instead of false ok:true

The admin digest "post" action was returning `{ ok: true, action: "digest-skipped" }`
without posting anything or marking the draft as posted. This caused the draft to
reappear in Pending forever — a false success receipt.

Fix: digest drafts are now posted as new GitHub Issues (using the existing
MAINTAINER_GITHUB_PAT + REST API). The response includes the real issue
`number` and `url`; `draft.posted` is set to true and the draft is stored back.
GitHub API failures propagate as 502 errors, never as ok:true.

Tests: two new source-contract tests in public-api-security.test.ts pin both
paths — happy path (real url/number returned) and error path (502, not ok:true).

Closes #5178

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
2026-08-03 05:48:30 -07:00
..