Skip to content

feat(amazonq): add ITGen test-run and app-launch models (contract v0 draft) - #2967

Merged
pranav-firake merged 3 commits into
feature/ITGen-RIVfrom
xueningl/ITGen-RIV-hitl-contract-models
Oct 23, 2026
Merged

pranav-firake merged 3 commits into
feature/ITGen-RIVfrom
xueningl/ITGen-RIV-hitl-contract-models

Conversation

@xueningl-az

@xueningl-az xueningl-az commented Oct 23, 2026 •

Copy link
Copy Markdown
Contributor

Problem

The VS extension and the language server need a shared shape for the ITGen integration-test HITL payloads before the HITL handling is built. That means the test-run request and result summary, and the app-launch request and result. The contract is ITGen–IDE contract v0, schema 1.0 (https://chorus.aws.dev/doc/Mih152AhKXxa, §4–§6; Taskei P541522201 and P541522260). Replaces #2965: feature/* branches can't take new commits.

Solution

atxModels.ts gets TypeScript interfaces that match the VS extension's C# models. Nothing uses them yet.

  • AtxTestRunRequest: schemaVersion, runId, side, project, artifactId, tests.projectPath, limits.projectTimeoutSeconds. Only what the IDE can't work out itself. artifactId is the repo artifact that holds the generated test projects, re-downloaded per request. side decides where the app starts, so no source code is downloaded. ATX_TEST_RUN_BASE_URL_ENV (AB_BASE_URL) is set by the IDE on the port it picks.
  • AtxTestRunSummary: status, appUrl, startedAt/finishedAt, durationSeconds, counts, failingTests.
  • AtxAppLaunchRequest (one per attempt): side, project, attempt, app {webProject, healthCheckPaths?, startTimeoutSeconds?}. There's no host: the IDE picks it from the project type. This is a proposal, since v0 §6 defines only the result. There's no limit field, because the agent decides when to stop, as with LBV.
  • AtxAppLaunchResult: status (STARTED or APP_NOT_STARTED), appUrl, healthCheck {path, httpStatus}, error, logFile, durationSeconds.
  • isSupportedAtxTestRunSchemaVersion: accepts the same major version as ATX_TEST_RUN_SCHEMA_VERSION (1.x), and rejects other major versions and missing or malformed values.

This is a draft against contract v0, frozen 10/23, so names may still change.

Testing: new tests/atxModels.test.ts, with 10 tests:

  • the schema version check;
  • request/summary round-trips using a real Bob's Used Bookstore run;
  • app-launch request/result, including Bob's Bookstore's real first launch (HTTP 500 on the health check).

All 501 netTransform tests pass, and tsc and prettier are clean.

Matching VS extension change: https://github.com/Amazon-Q-Developer/aws-toolkit-visual-studio-staging/pull/2965

License

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

…t v0 draft)

TypeScript mirror of the VS extension's AtxTestRunRequest / AtxTestRunSummary
for the ITGen integration-test HITL payloads (ITGen–IDE contract v0, schema
1.0). Not wired into any handler yet.

- AtxTestRunRequest: top-level artifactId (repo artifact holding the generated
  test projects, re-downloaded per request) and localFolder; side decides
  where the app starts (original: upload copy, transformed: solution), so no
  source code is downloaded. ATX_TEST_RUN_BASE_URL_ENV = AB_BASE_URL is set by
  the IDE on the port it picks.
- AtxTestRunSummary: status, appUrl, startedAt/finishedAt, durationSeconds,
  counts, failingTests.
- isSupportedAtxTestRunSchemaVersion: accepts the same major version as
  ATX_TEST_RUN_SCHEMA_VERSION (1.x); rejects other majors and malformed values.
- Unit tests with a real Bob's Used Bookstore run reshaped to the contract.
…ct v0 draft)

TypeScript mirror of the VS extension's AtxAppLaunchRequest / AtxAppLaunchResult
for the integ-app-launch HITL (transformed-code run contract, Taskei P541522260,
merged into P541522201).

- AtxTestRunApp extracted so the test-run and app-launch requests share it.
- AtxAppLaunchRequest: side, project, attempt, app (proposal; contract v0 §6
  defines only the result). Like LBV's rounds, the number of attempts is the
  agent's decision, so there's no limit field.
- AtxAppLaunchResult: status STARTED | APP_NOT_STARTED, appUrl,
  healthCheck {path, httpStatus}, error, logFile, durationSeconds.
- Unit tests with Bob's Used Bookstore's real first launch.
@xueningl-az
xueningl-az requested a review from a team as a code owner October 23, 2026 00:33
@xueningl-az xueningl-az changed the title Xueningl/it gen riv hitl contract models feat(amazonq): add ITGen test-run and app-launch models (contract v0 draft) Oct 23, 2026
@codecov-commenter

Copy link
Copy Markdown

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

… fields the IDE needs

Mirror of the VS extension change (contract v0 review, 10/23):

- AtxTestRunRequest: schemaVersion, runId, side, project, artifactId,
  tests.projectPath, limits.projectTimeoutSeconds. Dropped round, localFolder,
  app, env and limits.maxResultZipMB.
- AtxAppLaunchRequest: app is now AtxAppLaunchApp {webProject,
  healthCheckPaths?, startTimeoutSeconds?}; dropped host.

@ashishrp-aws ashishrp-aws 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.

🤖 AI-assisted review at e522ee1.

Approving for feature/ITGen-RIV. These are type-only additions plus isSupportedAtxTestRunSchemaVersion. The interfaces match the C# models in VS staging #2965 field for field, including which fields are optional. The version check accepts only the same major version (^(\d+)\.\d+$) and rejects non-strings and malformed values, and the tests cover that. CI is green.

Non-blocking: see my note on #2965 about what the follow-up PRs that consume these should enforce (loopback-only appUrl/AB_BASE_URL, no extra credentials in the test process environment, ZIP extraction confined to the chosen folder).

@pranav-firake
pranav-firake merged commit 1e290ee into feature/ITGen-RIV Oct 23, 2026
5 checks passed
@pranav-firake
pranav-firake deleted the xueningl/ITGen-RIV-hitl-contract-models branch October 23, 2026 18:51
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.

4 participants