Skip to content

Add opt-in publisher-registered GPT initial delivery - #1460

Draft
ChristianPavilonis wants to merge 1 commit into
mainfrom
issue-854-publisher-slot-registration
Draft

ChristianPavilonis wants to merge 1 commit into
mainfrom
issue-854-publisher-slot-registration

Conversation

@ChristianPavilonis

@ChristianPavilonis ChristianPavilonis commented Oct 27, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • Add opt-in initialization = "publisher_registered". Absent/default auto keeps the existing wire format and automatic delivery.
  • Let a publisher register its final live GPT slot with known disabled initial loading. Delivery waits for current admitted payload and validates exact native, element, generation and finite sizes before one scoped initial display/refresh.
  • Preserve registration across bootstrap/runtime takeover, including real navigation and same-generation catch-up retries. Without an installed renderer, request ordinary GAM without TS candidate targeting or later resurrection.
  • Add offline contracts, actual Rust/React inline/shared-template coverage, artifact preparation/reuse CI wiring and publisher/rollback documentation.

Related to #854. This is an opt-in correctness change, not a transparent fix for unmodified publishers or a claim of improved live CWV. It does not close the whole issue.

Validation

  • Full JS: 1,490 tests across 51 files, no type errors; lint and formatting passed.
  • Registration browser contracts: 109 passed. Existing initial-render scenarios: 10 passed on identical V4 artifact hashes.
  • Actual Rust/Next.js: 26 passed across inline/shared delivery; full/reduced provider transport and served-byte equality passed.
  • Real build.rs WASM: all 13 embedded modules exactly match the independently built distribution. Preparation passed with Viceroy absent. Reuse passed with zero Cargo/Docker builds.
  • All 19 final Rust commands passed, including required backend test/Clippy gates and the new fixture-helper Clippy check. Existing ignored tests remain disclosed in the validation record.
  • Normal Next.js: 21 passed, 14 expected skips. WordPress: 11 passed, 24 expected skips, using its exact ordinary CI Prebid profile. Next.js printed two nonfatal pinned-Viceroy downstream task panics; baseline attribution remains unverified.
  • Four independent review lanes completed without blocking findings. One small duplicated test-artifact verification helper remains unchanged as nonblocking maintenance.

Exact fingerprints, commands, retained failures and limits are in docs/superpowers/reviews/2026-10-27-854-publisher-registered-initial-delivery-validation.md.

Before activation

Real GPT/GAM staging, publisher adoption, production activation and CWV validation remain unverified and require separate approval. Server/bootstrap/modules, publisher adapter and per-placement configuration must be released as a compatible set. Hosted GitHub CI is running; results are pending.

assert.deepEqual(JSON.parse(inlineJson(input)), input);
assert(!/[<>&\u2028\u2029]/u.test(inlineJson(input)));
const html = documentPage(input);
assert.equal((html.match(/<script>/g) ?? []).length, 1);
test("creative labels remain text instead of inserting inline markup", () => {
const html = creative('</div><script>throw new Error("injected")</script>&');
assert(html.includes("&lt;/div&gt;&lt;script&gt;"));
assert.equal((html.match(/<script>/g) ?? []).length, 1);
bootstrapSha256: session.html
.map(
(html) =>
[...html.matchAll(/<script[^>]*>([\s\S]*?)<\/script>/g)].find(
targetingKeys[record.elementId] = record.targetingKeys;
}
}
function registeredCandidateAllowed(ts, slotId, bid) {

This branch has not been deployed

No deployments
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