Skip to content

[AI-7080] Report snapshot inputs that changed since launch - #25182

Draft
luisorofino wants to merge 3 commits into
loa/prd-as-snapshot-inputfrom
loa/snapshot-divergence-notice
Draft

luisorofino wants to merge 3 commits into
loa/prd-as-snapshot-inputfrom
loa/snapshot-divergence-notice

Conversation

@luisorofino

@luisorofino luisorofino commented Sep 10, 2026 •

Copy link
Copy Markdown
Contributor

This is PR 3 of 3 in a stacked series:

  1. [AI-7080] Add snapshot flow inputs #25180 — add the snapshot input mode and the per-run capture behind it
  2. [AI-7080] Give agents the PRD as a path #25181 — declare the built-in PRD input as a snapshot and point the openmetrics prompts at the file
  3. [AI-7080] Report snapshot inputs that changed since launch #25182 — tell the user when a resumed run's input file has changed since launch <- you are here

What does this PR do?

Adds an on_input_diverged callback, fired by the orchestrator when a resumed run keeps a snapshot copy whose source file has changed since launch. The execution screen subscribes through the existing callback-to-message bridge and shows a one-line notice naming the affected inputs.

The callback fires from inside the capture that makes the reuse decision, so what the user is told is what actually happened. An earlier draft had the TUI re-derive divergence by re-reading the manifest itself; that was a second implementation of the same question and could disagree with the first. Delete the snapshot file but leave the manifest, and the capture re-captures the current file while the TUI would have announced the opposite.

The notice deliberately carries no border or padding and summarizes past three names. It shares a fixed-height body with the pipeline graph, and that body hides its overflow, so every row the notice takes is a row the graph loses with no scrollbar to recover it. Measured on an 80x24 terminal, an unbounded boxed banner drove the pipeline to zero height; the shipped version costs it two rows.

Motivation

AI-7080.

Reusing the captured snapshot is what makes a resumed run reproducible, but doing it silently is confusing in the one case where the user can tell the difference: they edited the PRD between runs and expect the new version to take effect. Naming the input and saying which version won removes the surprise without changing the behavior.

A callback rather than a TUI-local check also means a future non-TUI runner — a CLI entry point, for example — can surface the same information by subscribing, with no new logic.

Review checklist (to be filled by reviewers)

  • Feature or bugfix MUST have appropriate tests (unit, integration, e2e)
  • Add qa/required if this PR needs QA validation, or qa/skip-qa if it does not. Exactly one of the two is required.
  • If you need to backport this PR to another branch, you can add the backport/<branch-name> label to the PR and it will automatically open a backport PR once this one is merged

@luisorofino luisorofino added the qa/skip-qa Automatically skip this PR for the next QA label Sep 10, 2026
@dd-octo-sts dd-octo-sts Bot added the ddev label Sep 10, 2026
@datadog-prod-us1-6

datadog-prod-us1-6 Bot commented Sep 10, 2026 •

Copy link
Copy Markdown

Tests  Code Coverage

✅ All CI checks and tests passed.

🎉 All green!

🧪 All tests passed
❄️ No new flaky tests detected

🎯 Code Coverage (details)
• Patch Coverage: 96.72%
• Overall Coverage: 89.86% (+0.01%)

This comment will be updated automatically if new data arrives.
🔗 Commit SHA: bbcedaa | Docs | View more details | Give us feedback!

@cit-pr-commenter-54b7da

cit-pr-commenter-54b7da Bot commented Sep 10, 2026 •

Copy link
Copy Markdown

evalya-impact-summary

evalya impact analysis
Impact analysis: 0 selected, 0 skipped (of 0 test tasks)
Publish tasks:   2 (always emitted)
Diff (241 files):
  .gitignore
  ddev/hatch.toml
  ddev/pyproject.toml
  ddev/src/ddev/ai/__init__.py
  ddev/src/ddev/ai/agent/__init__.py
  ddev/src/ddev/ai/agent/anthropic_agent.py
  ddev/src/ddev/ai/agent/anthropic_provider.py
  ddev/src/ddev/ai/agent/base.py
  ddev/src/ddev/ai/agent/build.py
  ddev/src/ddev/ai/agent/exceptions.py
  ddev/src/ddev/ai/agent/provider.py
  ddev/src/ddev/ai/agent/registry.py
  ddev/src/ddev/ai/agent/scope.py
  ddev/src/ddev/ai/agent/types.py
  ddev/src/ddev/ai/callbacks/__init__.py
  ddev/src/ddev/ai/callbacks/callbacks.py
  ddev/src/ddev/ai/config/__init__.py
  ddev/src/ddev/ai/config/classify.py
  ddev/src/ddev/ai/config/dependency_graph.py
  ddev/src/ddev/ai/config/engine.py
  ... and 221 more

Debug a specific task: evalya plan impact --path <path> --task <task>

Learn more about CI impact filtering

@luisorofino luisorofino changed the title Report snapshot inputs that changed since launch [AI-7080] Report snapshot inputs that changed since launch Sep 10, 2026
@luisorofino

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector chatgpt-codex-connector 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.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: c3c14fcccc

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

@luisorofino
luisorofino force-pushed the loa/snapshot-divergence-notice branch from c3c14fc to 5986233 Compare September 10, 2026 14:07
@luisorofino
luisorofino marked this pull request as ready for review September 10, 2026 14:54
@luisorofino
luisorofino requested a review from a team as a code owner September 10, 2026 14:54

@chatgpt-codex-connector chatgpt-codex-connector 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.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 478c69fa4e

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

@luisorofino
luisorofino force-pushed the loa/snapshot-divergence-notice branch from 78f8cc8 to d21620c Compare September 14, 2026 08:23
@luisorofino
luisorofino force-pushed the loa/snapshot-divergence-notice branch from d21620c to cd3fead Compare September 18, 2026 10:31
@luisorofino
luisorofino force-pushed the loa/snapshot-divergence-notice branch from cd3fead to 9799f7c Compare September 18, 2026 10:44
A resumed run keeps the snapshot it started with, even when the file it was
launched from has since been edited, moved, or deleted. That decision was silent.

The orchestrator now reports it through a new `on_input_diverged` callback, fired
from the capture that makes the decision, so there is a single source of truth and
a future non-TUI runner can surface it too. The execution screen subscribes and
shows a one-line notice naming the affected inputs.

The notice shares a fixed-height body with the pipeline graph, and that body hides
its overflow, so every row the notice takes is a row the graph loses. It therefore
summarizes past three names and carries no border or padding: an unbounded, boxed
banner drove the pipeline to zero height on an 80x24 terminal.
@luisorofino
luisorofino force-pushed the loa/snapshot-divergence-notice branch from 9799f7c to bbcedaa Compare September 18, 2026 11:03
@luisorofino
luisorofino marked this pull request as draft September 18, 2026 14:42
@chouetz chouetz added the internal Identify a non-fork PR label Oct 2, 2026

@AAraKKe AAraKKe left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

note: Reviewed the capture-to-callback-to-TUI notice wiring against the PRD-path branch. The notice follows the capture's reuse decision, and the earlier combined-name-width and captured-path assertion findings are fixed at this head. The four focused orchestrator/notice tests passed, including multiple inputs and maximum-length names. No new correctness findings in this PR's delta; the snapshot capture requests are on #25180.

@dd-octo-sts

dd-octo-sts Bot commented Nov 7, 2026

Copy link
Copy Markdown
Contributor

This pull request has been automatically marked as stale because it has not had activity in the past 15 days.

It will be closed in 30 days if no further activity occurs. If this pull request is still relevant, adding a comment or pushing new commits will keep it open. Also, you can always reopen the pull request if you missed the window.

Thank you for your contributions!

@dd-octo-sts dd-octo-sts Bot added the stale label Nov 7, 2026
@dd-octo-sts

dd-octo-sts Bot commented Nov 7, 2026

Copy link
Copy Markdown
Contributor

Validation Report

All 22 validations passed.

Show details
Validation Description Status
agent-reqs Verify check versions match the Agent requirements file ✅
ci Validate CI configuration and code coverage settings ✅
codeowners Validate every integration has a CODEOWNERS entry ✅
config Validate default configuration files against spec.yaml ✅
dep Verify dependency pins are consistent and Agent-compatible ✅
http Validate integrations use the HTTP wrapper correctly ✅
imports Validate check imports do not use deprecated modules ✅
integration-style Validate check code style conventions ✅
jmx-metrics Validate JMX metrics definition files and config ✅
labeler Validate PR labeler config matches integration directories ✅
legacy-signature Validate no integration uses the legacy Agent check signature ✅
license-headers Validate Python files have proper license headers ✅
licenses Validate third-party license attribution list ✅
metadata Validate metadata.csv metric definitions ✅
models Validate configuration data models match spec.yaml ✅
openmetrics Validate OpenMetrics integrations disable the metric limit ✅
package Validate Python package metadata, naming, and wheel contents ✅
pr-description Validate the pull request checklist and visible description length ✅
qa-label Validate the pull request declares whether it needs QA for the next Agent release ✅
readmes Validate README files have required sections ✅
saved-views Validate saved view JSON file structure and fields ✅
version Validate version consistency between package and changelog ✅

View full run

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

ddev internal Identify a non-fork PR qa/skip-qa Automatically skip this PR for the next QA stale team/agent-integrations

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants