Skip to content

feat(phase7a): stamp DISPOSITION_DEFERRED on batch submit#553

Merged
Muizzkolapo merged 6 commits into
integration/batch-online-unificationfrom
unify/phase-7a-deferred
May 17, 2026
Merged

feat(phase7a): stamp DISPOSITION_DEFERRED on batch submit#553
Muizzkolapo merged 6 commits into
integration/batch-online-unificationfrom
unify/phase-7a-deferred

Conversation

@Muizzkolapo
Copy link
Copy Markdown
Owner

Summary

  • Add storage_backend parameter to BatchSubmissionService
  • After successful batch submission, stamp DISPOSITION_DEFERRED for all INCLUDED records via new _stamp_deferred() method
  • Both callers (initial_pipeline._process_batch_mode, pipeline._handle_batch_generation) pass storage_backend
  • Skipped/filtered/failed records do NOT receive DEFERRED
  • Reason field includes batch_id for traceability

Verification

  • 3 new tests in tests/unit/unification/test_phase7a_deferred_disposition.py — all pass
  • Full suite: 6913 passed, 0 failed
  • ruff format --check and ruff check clean

Muizzkolapo and others added 6 commits May 17, 2026 20:47
Large workflows render too small to read because the mermaid SVG was
constrained to max-width: 100% with no way to zoom in. Add interactive
pan/zoom: mouse wheel to zoom, click-drag to pan, and control buttons
(zoom in, zoom out, fit-to-view, reset). Auto-fits on first render.
…tion' into integration/batch-online-unification
…bmit

U-3.3: After batch submission, DISPOSITION_DEFERRED must be stamped
for every record sent to the provider. Currently no dispositions are
written at submit time — only on retrieve.

All 3 tests fail — proving the gap exists.
U-3.3: After successful batch submission, every INCLUDED record now
gets DISPOSITION_DEFERRED written to the storage backend. Records
that were filtered/skipped during preparation do not receive DEFERRED.

Implementation:
- Add storage_backend parameter to BatchSubmissionService
- _stamp_deferred() iterates context_map for INCLUDED records
- Both callers (initial_pipeline, workflow/pipeline) pass backend
- Reason includes batch_id for traceability

This enables operators to query the disposition table for in-flight
batch records and lets Phase 7b clear DEFERRED on retrieve.
_stamp_deferred now uses _safe_set_disposition (matching all other
callers) so a storage failure won't crash batch submission. Removed
unused prepare_result parameter from test helper.
Verify that SKIPPED, FILTERED, and FAILED records do NOT receive
DISPOSITION_DEFERRED — only INCLUDED records are stamped. Tests
_stamp_deferred directly with a hand-crafted context_map containing
all four FilterStatus values.
@Muizzkolapo Muizzkolapo merged commit 8666c07 into integration/batch-online-unification May 17, 2026
1 check passed
@github-actions github-actions Bot locked and limited conversation to collaborators May 17, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant