Skip to content

fix(server): preserve valid creatives in lenient legacy batches on next - #1842

Merged
bokelley merged 2 commits into
nextfrom
claude/issue-1839-mixed-creative-projection-next
Nov 3, 2026
Merged

bokelley merged 2 commits into
nextfrom
claude/issue-1839-mixed-creative-projection-next

Conversation

@bokelley

@bokelley bokelley commented Nov 3, 2026 •

Copy link
Copy Markdown
Contributor

Forward-port the stable SDK fix from #1841 so explicit lenient legacy sync_creatives batches retain valid siblings on the SDK 10 beta line. A batch containing two supported creatives and one unprojectable format now returns two successful rows and one ordered UNSUPPORTED_FEATURE failure. Strict and omitted validation modes remain atomic.

The port preserves original request idempotency, assignment safety, managed task persistence/webhooks, and the documented pre-dispatch boundaries for destructive reconciliation, filtering, and custom asynchronous completion. It retains next's mutation-outcome tracking and account-feed response projection. The source commit carries cherry picked from commit 2bd7751cb1312efda5aefc4a11fecdfab0933c9e.

A separate compatibility commit gives three existing JOSE boundaries explicit return types. joserfc 1.8 now uses Python 3.11 Self and includes cryptographic hardening, while this SDK still checks its Python 3.10 public contract. Runtime algorithms, dependency ranges, and type-check requirements remain unchanged, so fresh installations retain those upstream fixes.

Validation:

  • All 35 mixed-batch regressions pass on the port.
  • JOSE 1.7.7: the affected files pass mypy, and the existing signing/governance suite passes 1,876 tests (2 skips). Final checks use the fresh JOSE 1.8.0 environment.
  • Final JOSE 1.8.0 environment: make lint, make typecheck-all (1,701 source files, 77 adopter fixtures, pyright 66 fixtures, no-ignore contract), and make validate-generated pass.
  • Final full make test passes on exact head 8f53b65ac10cd67d35d85f420f4c5f70f0f4d430: 21,645 passed, 2,847 skipped, 10 deselected, 1 existing expected failure, 92.04% coverage (80% required), 48m18.52s. All 35 new mixed-batch cases pass, with no expected failures. The working tree remained clean.
  • Independent protocol review approves the exact head: 35 mixed-batch cases, 101 mutation-outcome/account-feed/crypto cases, and affected-file mypy pass under JOSE 1.8.0. The review verified managed completion order, idempotency scope, and the preserved next behavior.
  • GitHub CI passes on the same exact head, including all Python and PostgreSQL matrix jobs. Every required local gate has also passed; final automated review remains before merge.
  • The stable source passed 18,863 tests with 92.16% coverage, installed-wheel checks, and independent protocol review before merging in fix(server): preserve valid creatives in lenient legacy batches #1841; those results do not substitute for the pending next checks.

This changes no package versions or release metadata. SDK 10 remains on its beta channel. Publication is coordinated separately after the stable 9.x release and this branch's required gates.

Refs #1839.

Honor explicit lenient processing for legacy creative format projection: dispatch supported siblings and return ordered per-creative failures for unprojectable formats. Preserve strict atomic rejection, original idempotency identity, rejected-assignment safety, and SDK-managed task completion results.

Materialize SDK-owned failures before mutation and preserve accepted typed rows, including schema-valid assignment error keys. Unsafe destructive/filter/external-async combinations fail before dispatch and are documented.

Validated with 18,863 passing repository tests and 92.16% coverage, 110 focused tests, all GitHub checks, installed-wheel probes, and independent protocol and Ladon approvals.

Fixes #1839.

(cherry picked from commit 2bd7751)
@bokelley
bokelley marked this pull request as ready for review November 3, 2026 13:41

@aao-secretariat aao-secretariat Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Ladon verdict: Approve

Approve.

Clean forward-port of #1841 (lenient legacy sync_creatives partial admission) to the SDK 10 beta line, plus three JOSE type-boundary annotations. No Critical/High/Medium findings.

Checked:

  • No findings of any severity surfaced by the reviewer.
  • high_risk: true but all reasons are (added)/(modified) on sensitive paths with no medium-or-higher concern — presumed safe per the high-risk heuristic; no (deleted) entries.
  • gated_paths: false, so the gated-paths hard gate (row 2) does not apply despite review_decision being unknown.
  • No no-auto-approve team match.
  • Version-translation pathway for 3.0/3.1 is covered with tests (568-line test file exercises strict/lenient, delete_missing, creative_ids, assignments, nested-wrap idempotency, pre-validation-hook keys, managed completion).
  • No credentials in ctx_metadata, no generated-code hand-edits, no import-layering break, additive private surface so no semver signal required.

No decision-table row 1–8 fired; falls through to row 9 → approve.

@bokelley
bokelley merged commit a541585 into next Nov 3, 2026
42 checks passed
@bokelley
bokelley deleted the claude/issue-1839-mixed-creative-projection-next branch November 3, 2026 13:47
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.

1 participant