ENG-3924: Add info-level execution logs for paused privacy request status transitions#8251
Draft
eastandwestwind wants to merge 11 commits into
Draft
ENG-3924: Add info-level execution logs for paused privacy request status transitions#8251eastandwestwind wants to merge 11 commits into
eastandwestwind wants to merge 11 commits into
Conversation
8 code paths transition a privacy request's status without creating an ExecutionLog entry, making it impossible to troubleshoot stuck requests in the UI. This adds an "info" ExecutionLogStatus and logs all status transitions: requires_input (manual webhooks), paused (webhook halt, batch email), awaiting_access_review, resumed from webhook, and pre-approval not eligible. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Contributor
|
The latest updates on your projects. Learn more about Vercel for GitHub. 2 Skipped Deployments
|
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…ional Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Remove info logs from requires_input, pre_approval_not_eligible, resumed, and awaiting_access_review transitions — those statuses are already self-explanatory. Keep info logs only for paused transitions where the reason (webhook halt vs batch email) is not obvious from status alone. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
When a privacy request task dies at the worker level (OOM kill, hard timeout, broker disconnect), no execution log is created. The on_failure callback on DatabaseTask catches these failures, writes an error execution log with the failure reason, and marks the request as errored. Skips if the in-task BaseException handler already handled the error. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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.
Ticket ENG-3924
Description Of Changes
When a privacy request is paused, the status alone doesn't explain why. It could be a webhook halt, a batch email send, or an access review. This adds info-level execution logs for pause transitions so the reason is visible in the Admin UI's Activity tab.
Adds an
infostatus toExecutionLogStatusand creates execution log entries at the 3 pause transition points where the reason isn't obvious from status alone.Code Changes
info = "info"toExecutionLogStatusenum (no migration needed — string column)add_info_execution_log()method onPrivacyRequestmodelrequest_runner_service.py— request paused by webhook halt instruction (main execution path)request_runner_service.py— request paused by webhook inrun_webhooks_and_report_statusemail_batch_service.py— request paused after batch email sendINFOto frontendExecutionLogStatusenum with blue tag colorSteps to Confirm
{"halt": true}Pre-Merge Checklist
CHANGELOG.mdupdated