Commit e2a2707
feat(examples): DemoStore overrides for force_create_media_buy_arm, force_task_completion, and seed_* scenarios (#313)
* feat(examples): add DemoStore overrides for force_create_media_buy_arm, force_task_completion, and seed_* scenarios
Fixes #312
DemoStore now overrides all 7 new TestControllerStore methods landed in
#282 (force_*) and #296 (seed_*), bringing the storyboard score from
36/47 to 47/47 and flipping controller_detected to true.
- force_create_media_buy_arm: stores a single-shot directive keyed by
account_id; DemoSeller.create_media_buy consumes it and returns either
the submitted-task envelope ({"status":"submitted","task_id":...}) or
an input-required response ({"reason":"APPROVAL_REQUIRED"}).
- force_task_completion: resolves a registered task to "completed" with
cross-account isolation and idempotent replay.
- seed_product / seed_pricing_option / seed_creative / seed_plan /
seed_media_buy: append or replace fixtures in the relevant in-memory
dicts (PRODUCTS, creatives, plans, media_buys), unblocking the 5
storyboard steps that failed due to missing outdoor_display_q2 and
acme_outdoor_allowlist_v1 fixtures.
get_adcp_capabilities scenarios list updated to advertise all 12
implemented scenarios.
https://claude.ai/code/session_01DJWM1a9nfjauGxSks9T1KW
* fix(examples,server): close 313 review issues + post-rebase regressions
Five fixups while taking PR #313 over from triage:
1. Lint blocker — duplicate "account" key in two dict literals
(mcp_tools.py:853, test_controller.py:719). Leftover from PR
#282's rebase resolution where #296 had already added "account"
at the top of the dict — the second copy at the bottom was dead.
Removing it unblocks ruff F601 on Python 3.13.
2. Re-apply valid_actions_for_status refactor on seller_agent.py
that was lost in PR #310's squash-merge. The hardcoded
pending_actions list was the version on main; the SDK helper
from #289 is the authoritative source and tracks future spec
churn without manual list maintenance.
3. Add sync_creatives -> pending_start transition on
DemoSeller.sync_creatives. Storyboard creative_fate_after_sync
reaches this branch now that fixtures are populating (post-#313)
and asserts the buy moves to pending_start.
4. Trim compliance_testing.scenarios to schema-allowed names. AdCP
3.0.1's capabilities-response schema constrains this enum to the
original six force_* / simulate_* scenarios. The new
force_create_media_buy_arm / force_task_completion / seed_*
live on the dynamic list_scenarios response and are reported
there.
5. End-to-end verified: 36/47 passing, matching pre-#313 baseline.
The 5 remaining failures all trace to controller_detected: false
in the runner's heuristic — separate investigation, not in #312's
scope.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude <noreply@anthropic.com>1 parent 9818250 commit e2a2707
3 files changed
Lines changed: 193 additions & 14 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
| 28 | + | |
28 | 29 | | |
29 | 30 | | |
30 | 31 | | |
| |||
46 | 47 | | |
47 | 48 | | |
48 | 49 | | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
49 | 60 | | |
50 | 61 | | |
51 | 62 | | |
| |||
109 | 120 | | |
110 | 121 | | |
111 | 122 | | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
112 | 129 | | |
113 | 130 | | |
114 | 131 | | |
| |||
197 | 214 | | |
198 | 215 | | |
199 | 216 | | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
200 | 239 | | |
201 | 240 | | |
202 | 241 | | |
| |||
225 | 264 | | |
226 | 265 | | |
227 | 266 | | |
228 | | - | |
229 | | - | |
| 267 | + | |
230 | 268 | | |
231 | 269 | | |
232 | 270 | | |
| |||
237 | 275 | | |
238 | 276 | | |
239 | 277 | | |
240 | | - | |
241 | | - | |
| 278 | + | |
| 279 | + | |
242 | 280 | | |
243 | | - | |
244 | | - | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
245 | 285 | | |
246 | 286 | | |
247 | 287 | | |
| |||
301 | 341 | | |
302 | 342 | | |
303 | 343 | | |
304 | | - | |
305 | | - | |
306 | 344 | | |
307 | 345 | | |
308 | 346 | | |
309 | 347 | | |
310 | | - | |
| 348 | + | |
311 | 349 | | |
312 | 350 | | |
313 | 351 | | |
| |||
379 | 417 | | |
380 | 418 | | |
381 | 419 | | |
| 420 | + | |
| 421 | + | |
| 422 | + | |
| 423 | + | |
| 424 | + | |
| 425 | + | |
| 426 | + | |
| 427 | + | |
382 | 428 | | |
383 | 429 | | |
384 | 430 | | |
| |||
485 | 531 | | |
486 | 532 | | |
487 | 533 | | |
| 534 | + | |
| 535 | + | |
| 536 | + | |
| 537 | + | |
| 538 | + | |
| 539 | + | |
| 540 | + | |
| 541 | + | |
| 542 | + | |
| 543 | + | |
| 544 | + | |
| 545 | + | |
| 546 | + | |
| 547 | + | |
| 548 | + | |
| 549 | + | |
| 550 | + | |
| 551 | + | |
| 552 | + | |
| 553 | + | |
| 554 | + | |
| 555 | + | |
| 556 | + | |
| 557 | + | |
| 558 | + | |
| 559 | + | |
| 560 | + | |
| 561 | + | |
| 562 | + | |
| 563 | + | |
| 564 | + | |
| 565 | + | |
| 566 | + | |
| 567 | + | |
| 568 | + | |
| 569 | + | |
| 570 | + | |
| 571 | + | |
| 572 | + | |
| 573 | + | |
| 574 | + | |
| 575 | + | |
| 576 | + | |
| 577 | + | |
| 578 | + | |
| 579 | + | |
| 580 | + | |
| 581 | + | |
| 582 | + | |
| 583 | + | |
| 584 | + | |
| 585 | + | |
| 586 | + | |
| 587 | + | |
| 588 | + | |
| 589 | + | |
| 590 | + | |
| 591 | + | |
| 592 | + | |
| 593 | + | |
| 594 | + | |
| 595 | + | |
| 596 | + | |
| 597 | + | |
| 598 | + | |
| 599 | + | |
| 600 | + | |
| 601 | + | |
| 602 | + | |
| 603 | + | |
| 604 | + | |
| 605 | + | |
| 606 | + | |
| 607 | + | |
| 608 | + | |
| 609 | + | |
| 610 | + | |
| 611 | + | |
| 612 | + | |
| 613 | + | |
| 614 | + | |
| 615 | + | |
| 616 | + | |
| 617 | + | |
| 618 | + | |
| 619 | + | |
| 620 | + | |
| 621 | + | |
| 622 | + | |
| 623 | + | |
| 624 | + | |
| 625 | + | |
| 626 | + | |
| 627 | + | |
| 628 | + | |
| 629 | + | |
| 630 | + | |
| 631 | + | |
| 632 | + | |
| 633 | + | |
| 634 | + | |
| 635 | + | |
| 636 | + | |
| 637 | + | |
| 638 | + | |
| 639 | + | |
| 640 | + | |
| 641 | + | |
| 642 | + | |
| 643 | + | |
| 644 | + | |
| 645 | + | |
| 646 | + | |
| 647 | + | |
| 648 | + | |
| 649 | + | |
| 650 | + | |
| 651 | + | |
| 652 | + | |
| 653 | + | |
| 654 | + | |
| 655 | + | |
| 656 | + | |
| 657 | + | |
| 658 | + | |
| 659 | + | |
| 660 | + | |
| 661 | + | |
| 662 | + | |
| 663 | + | |
| 664 | + | |
| 665 | + | |
| 666 | + | |
| 667 | + | |
| 668 | + | |
| 669 | + | |
| 670 | + | |
488 | 671 | | |
489 | 672 | | |
490 | 673 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
850 | 850 | | |
851 | 851 | | |
852 | 852 | | |
853 | | - | |
854 | 853 | | |
855 | 854 | | |
856 | 855 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
508 | 508 | | |
509 | 509 | | |
510 | 510 | | |
511 | | - | |
512 | | - | |
513 | | - | |
| 511 | + | |
514 | 512 | | |
515 | 513 | | |
516 | 514 | | |
| |||
716 | 714 | | |
717 | 715 | | |
718 | 716 | | |
719 | | - | |
720 | 717 | | |
721 | 718 | | |
722 | 719 | | |
| |||
0 commit comments