Skip to content

feat: lift worker transport evidence-verification rejection#21

Merged
govindkavaturi-art merged 1 commit intomainfrom
feat/lift-worker-evidence-rejection
Apr 18, 2026
Merged

feat: lift worker transport evidence-verification rejection#21
govindkavaturi-art merged 1 commit intomainfrom
feat/lift-worker-evidence-rejection

Conversation

@govindkavaturi-art
Copy link
Copy Markdown
Member

Summary

Unblocks worker-transport cues from using evidence-based verification modes (`require_external_id`, `require_result_url`, `require_artifacts`).

Preconditions (both now met)

Changes

File Change
`app/services/cue_service.py` Remove `_check_transport_verification_combo` + its two call sites (in `create_cue` and `update_cue`). Replace with info-level logging when a worker cue is configured with an evidence-requiring mode.
`tests/test_transport_verification_combo.py` Flip expected 400 → 201 on create, 400 → 200 on PATCH. Header comment documents history. Test class `TestWorkerEvidenceRejectedAtCreate` → `TestWorkerEvidenceAcceptedAtCreate`.
`README.md` Update transport-compat footnote: all modes accepted; upgrade hint for users on cueapi-worker < 0.3.0.
`CHANGELOG.md` Replace "### Restricted" entry with "### Removed" documenting the lift.

Test plan

  • 13/13 pass locally in `test_transport_verification_combo.py` (flipped assertions)
  • Full cueapi-core test suite via CI

Behavior change for end users

  • Workers on cueapi-worker >= 0.3.0: can now combine worker transport with any verification mode. Handlers write evidence to `$CUEAPI_OUTCOME_FILE`.
  • Workers on cueapi-worker < 0.3.0: evidence-requiring modes will land every execution in `verification_failed` because the daemon has no evidence channel. Operators should `pip install --upgrade cueapi-worker`.

🤖 Generated with Claude Code

cueapi-worker 0.3.0 (released 2026-04-17 to PyPI) closes the worker-
side evidence gap via CUEAPI_OUTCOME_FILE. The daemon reads the
handler's per-run temp file after exit and merges the evidence
fields into its outcome POST. All five verification modes now work
on both transports.

Changes:
- app/services/cue_service.py: remove _check_transport_verification_combo
  and the two calls in create_cue + update_cue. Replace with
  info-level logging when a worker cue is configured with an
  evidence-requiring mode (breadcrumb for operators still running
  older cueapi-worker).
- tests/test_transport_verification_combo.py: flip expected 400 → 201
  on create, 400 → 200 on PATCH. Header comment documents the
  history. Two test classes renamed from WorkerEvidenceRejected* to
  WorkerEvidenceAccepted* / PatchTransitions::test_patch_worker_to_evidence_mode_accepted.
- README.md: update transport-compatibility footnote to reflect the
  new accept-everything reality, with an upgrade hint for users on
  cueapi-worker < 0.3.0.
- CHANGELOG: replace the "Restricted" entry (worker+evidence
  rejection) with a "Removed" entry describing the lift.

Tests: 13/13 pass locally on the updated combo suite.

Preconditions met:
- cueapi-worker 0.3.0 published to PyPI (2026-04-17 22:04:39 UTC)
- cueapi-core #18 merged to main (verification_mode column
  + rule engine in place to read verification_mode and produce
  outcome_state transitions)

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@govindkavaturi-art govindkavaturi-art enabled auto-merge (squash) April 17, 2026 23:34
@github-actions
Copy link
Copy Markdown

Parity check

This PR modifies files tracked in parity-manifest.json:

  • app/services/cue_service.py

Please confirm one of the following in a reply or PR description update:

  1. The equivalent change has been applied to the private cueapi monorepo. Link the PR.
  2. This change is OSS-only and does not need porting. Briefly explain why (e.g. "fixes a bug that only exists in the OSS build").
  3. A follow-up issue has been filed to port the reverse direction. Link the issue.

This is a soft check — it does not block merge. The goal is visibility, not friction. See HOSTED_ONLY.md for the open-core policy.

Copy link
Copy Markdown
Collaborator

@argus-qa-ai argus-qa-ai left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Argus review — LGTM.

Preconditions confirmed met: cueapi-core #18 (verification_mode + rule engine) is on main, cueapi-worker 0.3.0 is on PyPI (2026-04-17).

Deletion is surgical — _check_transport_verification_combo, _EVIDENCE_REQUIRING_MODES, and _WORKER_COMPATIBLE_MODES fully removed with no orphaned callsites. Replaced with INFO-level logging breadcrumbs on both create and update paths — good for operators still on older workers. Tests correctly flipped from asserting 400 → 201/200 with history comment preserved. CHANGELOG and README accurate.

Minor note: in test assertion body['transport'] == 'worker' or body['callback']['transport'] == 'worker' — KeyError on the first branch would fall through to the second. Fine for test code, not a blocker.

All 5 CI checks green. Approved.

@govindkavaturi-art govindkavaturi-art merged commit 622edb8 into main Apr 18, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants