* Support showing promo messages with no end date and no % discount
* Address PR feedback on promo message support
- Tighten promo JSDoc on the metadata contract, notification contribution,
and helpers to match repository JSDoc limits
- Document the positive/zero/negative discount cases so message-only promos
are not omitted by agent implementations
- Cover open-ended, message-only promos through the untyped _meta read and
the CAPI billing normalization
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: edb3b42a-1bec-45f8-9453-51ad10583f06
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: edb3b42a-1bec-45f8-9453-51ad10583f06
* sessions: move changes action to title bar
Keep the Create Pull Request split button available as a session-level action on the right side of the Agents window title bar instead of the Changes editor title.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* sessions: remove obsolete changes action styles
Remove editor-title selectors that became unreachable after moving the Create Pull Request action to the window title bar.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: sync workspace folders for existing sessions
Keep Editor Window Agent Host sessions aligned with multi-root workspace folder changes while preserving the primary directory. Apply provider updates before confirming AHP state, including Remote Development mapping and safe Claude/Codex runtime updates.\n\nCo-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: apply working directory snapshots before sends
Use ordinary optimistic directory actions with synchronous host reduction, then apply complete snapshots at each provider send boundary.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: use explicit working directory action imports
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: adapt multi-root sync to latest main
Use current Codex model identifiers and workspace metadata while preserving upstream provisional active-client synchronization.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: use SDK additional directories configuration
Adopt the supported Copilot SDK create/resume option for dynamic root refreshes and remove the temporary permission RPC workaround.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: address multi-root synchronization review
Gate dynamic directory actions on negotiated AHP support and promote provisional drafts when a workspace becomes multi-root before rebind.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: test immutable primary synchronization
Cover Editor-side primary retention and capability gating alongside the existing host rejection test.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: compare Copilot additional roots as a set
Avoid structural restarts when the same secondary directories arrive in a different order.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: reuse existing Copilot refresh flow
Apply root divergence through the existing MCP structural refresh path and remove unrelated active-turn hardening.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: retain Copilot refresh rationale
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: restore original Copilot refresh comment
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: retain Copilot send diagnostics
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: retain Copilot resume diagnostics
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: keep Copilot refresh control flow flat
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: preserve existing dispatch queue behavior
Remove the unrelated queue cleanup fix from the multi-root change.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: compare provisional secondary roots as a set
Keep the immutable primary positional while treating additional directory order as irrelevant.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: share working directory comparison
Compare optional immutable primaries positionally and additional roots as URI sets across providers and provisional sessions.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: honor immutable primary capability
Share working-directory comparison semantics and reject index-zero removal only for agents that advertise an immutable primary.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: require explicit working directory comparison mode
Make the immutable-primary flag mandatory and name it after the lists being compared so additional-directory tails cannot silently inherit primary semantics.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: align working directory primary flag naming
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: split working directory comparison by list shape
Replace the overloaded primary flag with areSessionWorkingDirectoriesEqual and areAdditionalWorkingDirectoriesEqual so each call site states which list it compares.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: derive session directory comparison from capability
Require an explicit immutable-primary argument so provider-agnostic callers read it from the advertised agent capability instead of assuming a pinned process root.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: document working directory synchronization
Explain what reconciliation compares, when it runs, and why the primary is excluded, plus the non-obvious guards in the synchronizer and desired-set computation.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: track working directory registrations in a DisposableMap
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: document working directory registration triggers
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: reuse toLocalResource for remote working directories
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: document why root state is not a reconcile trigger
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: stub working directory synchronizer in session handler tests
Also revert Remote working-directory conversion for session config resolution, which fixed a pre-existing issue unrelated to dynamic multi-root synchronization.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: revert Remote working directory translation
Remove the Remote URI translation layer so this change does not alter existing Remote behaviour; the underlying issue is documented for a separate fix.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: restore comments that remained accurate
Keep the original wording where behaviour did not change, and extend rather than replace it where multi-root added nuance.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: document provisional workspace folder reconciliation
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* sessions: track multiple pull requests
Retain a bounded, recency-ordered pull request history for agent-host sessions while preserving the newest pull request as the active projection for existing behavior. Add an accessible session-header dropdown with live PR, CI, and review status, legacy metadata migration, fixtures, and coverage.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* sessions: address multi-PR review feedback
Canonicalize pull request identities, keep open picker rows reactive without replacing focused controls, preserve keyboard activation, and ensure the concurrent metadata regression test is discovered.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* sessions: align pull request list titles
Use the largest pull request number to size a shared right-aligned number column so every title begins at the same position.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Show Current Turn Changes while a chat turn is active and reactively relabel the open multi-diff as Last Turn Changes when it completes.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* sessions: improve single-pane side pane layout
Balance Sessions and the side pane on first reveal, retain user sizing, and restore shared New/Existing visibility profiles across navigation, Quick Chat, submit, and reload.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* sessions: address single-pane layout review feedback
Preserve durable visibility profiles across transient hides, restore docked parts in the correct order, and align layout documentation with the shared-profile architecture.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* adding smoke tests and unit tests to pipeline
* making tests parallel
* fixing indentation
* adding test type
* building once and running the tests separately
* creating log and crashes folders
* moving the directory creation
* smoke-flaky: create .build/crashes,logs after checkout, not before
checkout: self (invoked inside product-build-*-compile.yml@self) wipes any
files created earlier in the job on hosted agents, so the previous
mkdir-first placement was silently undone by the time the non-production
artifact publish steps ran. Move the directory-creation step to run after
the compile template (which performs checkout) and mark it
condition: always() so it still runs if compile or a later step fails.
* adding fix for window build failure
* smoke-flaky win32: fix 7z archive/extract bugs
- Quote the wildcard source path in the workspace archive step: unquoted,
PowerShell expands \* against the filesystem before 7z.exe runs, which
overflows the command-line length and corrupts the trailing -xr!.git
switch ("Too short switch / r!").
- Stop sourcing exec.ps1 before extracting repo.zip in the Unit/Integration/
Smoke jobs' extract steps: those jobs use checkout: none, so exec.ps1
(which lives in the repo) does not exist until repo.zip is extracted.
Use a plain $LASTEXITCODE check instead.
* fix(pipelines): use absolute path to exec.ps1 in steps with overridden workingDirectory
The 'Archive packaged app' and 'Archive packaged server' steps set
workingDirectory to $(Agent.BuildDirectory) (the parent of the sources
folder), but still sourced exec.ps1 via a path relative to the sources
root, which only resolves when the working directory is the sources
folder itself. Use an absolute path built from $(Build.SourcesDirectory)
instead.
* kill lingering integration test processes
* removing duplication
* removing duplication
Avoid repeatedly rendering subagent titles and resetting toolbar state while virtualized chat rows rebuild historical tool activity. Terminal tools now skip unnecessary state observers, and focused regressions cover large histories and renderer recycling.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
`whenWorkbenchRestored()` can be answered by the pre-reload document, so the
'Extension Host Restart' tests continued while the window was still reloading.
The next test then dispatched its command palette keybinding into a tearing
down window, `openQuickAccessWithRetry` exhausted its retries and fell through
to `type()`, which failed with a misleading 'set value ... after 20 seconds'.
Add `Code#reloadWindow()` which stamps the current document, triggers the
reload and waits for a new document before awaiting the workbench restore.
* chat: fall back to latest Copilot process log
Include the newest Copilot process log when no recent log matches the Agent Host session ID, or when the export has no active session context. Search only the ten newest logs while allowing streamed scans up to 1 GiB per file. (Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* chat: address Copilot log export review
Apply the scan limits to the ten newest logs, avoid Copilot fallbacks for other local agents, and cap remote inline exports to prevent large renderer allocations. (Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Expand Agent Host file operation E2E coverage
Enable shell-backed Codex file scenarios and the five previously skipped Copilot variants with portable prompts, strict fixtures, and semantic AHP snapshots. Fix Codex command completion mapping when app-server drops item completion before the following response, and remove the resolved known-issue entries. (Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Clarify Agent Host E2E known issues
Keep the inventory focused on active gaps, remove resolved history and general test guidance, and align stale source comments with the current gates. (Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Address Codex completion feedback
Restrict turn-snapshot recovery to command executions with observed outcomes, preserve response ordering around command preflights, and scope snapshot relaxation to Codex shell completion status where direct assertions prove behavior. (Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agent host: integrate file coverage with main
Match strict tool-result assertions to each provider's file operation strategy and refresh generated Agent Host E2E coverage baselines. (Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agent host: address E2E review feedback
Match snapshot omissions against provider tool names before normalization and add a direct execution oracle for spaced-filename reads. (Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agent host: preserve E2E guidance after rebase
Retain newly landed prompt snapshot and cumulative-state assertion guidance while removing resolved file-operation gaps. (Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agent host: adapt E2E coverage to latest Codex
Preserve Codex tool lifecycles across steering, adapt the spaced-path execution oracle to Codex 0.146, and refresh generated coverage baselines. (Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agent host: refresh E2E coverage after conflict resolution
Regenerate the Agent Host E2E coverage summary after rebasing onto current main and validating the Codex steering lifecycle adaptation. (Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agent host: make Codex path oracle shell-neutral
Correlate the Codex shell lifecycle by tool-call id and validate the semantic read command without requiring platform-identical quoting. Refresh the E2E coverage baseline. (Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* sessions: Register user data sync utility channel
Ensure the Agents window exposes the renderer-owned user data sync utility channel to the shared process. (Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* sessions: Revert unrelated README change
Keep the PR scoped to the user data sync channel fix. (Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* chore: bump @github/copilot-sdk to 1.0.9-preview.3 and @github/copilot to 1.0.78
* Adapt agentHost to SDK 1.0.9-preview.3 type contract
SDK 1.0.9-preview.3 changed several session-events/rpc types consumed by
agentHost:
- Model dropped defaultReasoningEffort; pass undefined so the schema resolver
falls back (BYOK IByokLmModelInfo path is unaffected and keeps the field).
- Added factory permission kind; add 'factory' to the host permissionKind union.
- Added factory_completed system notification; handle it in the notification
switch with localized status messages.
- ShutdownData gained required fields; widen the test cast via unknown.
- PermissionPromptRequestPath dropped managedApprovalRequired; remove it from
the path promptRequest test literal (the permissionRequest still carries it,
which is what the host reads).
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Adapt customizations test to new builtin skill in CLI 1.0.78
CLI 1.0.78 ships an additional builtin skill (github-pr-media) alongside
customize-cloud-agent; generalize the test's builtInCustomizations filter to
strip any @github/copilot builtin skill dir so discovery assertions stay green.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Regenerate Copilot prompt snapshots for CLI 1.0.78
CLI 1.0.78 reworded its baked-in system prompt (consolidated tips_and_tricks/SQL/session-context guidance and added the github-pr-media builtin skill), so the committed AHP prompt baselines no longer matched the wire prompt and the copilotPromptsE2E integration test failed in product build 461312. Regenerated the baselines via AGENT_HOST_UPDATE_AHP_SNAPSHOTS=1; all 21 cases pass in replay mode.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: vs-code-engineering[bot] <122617954+vs-code-engineering[bot]@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Paul <8560030+pwang347@users.noreply.github.com>
* Add deletion actions to automation run history
* Address automation history deletion review feedback
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: lazily restore peer chats
Keep restored peer chats as state-manager-owned entries and materialize their SDK histories only when content is requested. Consolidate per-session resume, sequencing, and teardown coordination so distinct peers can resume concurrently without racing session disposal.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* agentHost: preserve peer restore failures
Propagate known peer-session resume failures so lazy chat hydration remains retryable instead of committing an empty history.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* test: increase agent host e2e coverage
Add coverage for server tools, customization discovery, persistence, peer chats, and changesets.
(Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* test: fix agent host e2e CI failures
Make persistence assertions path-identity safe on Windows, remove timing-based restart waits, wait deterministically for server tool advertisement, preserve teardown tracking through assertions, and clarify the addComment range contract.
(Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* fix: serialize agent session release and restore
Track in-flight provider releases so restoration cannot race provider shutdown. Strengthen persistence coverage to prove complete durable transcript reconstruction before restarting the host.
(Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* test: fix persistence oracle typing
Read optional response-part IDs through Reflect so both the TypeScript compiler and hygiene rules accept the durable reconstruction oracle.
(Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* test: stabilize server tool catalog assertion
Read the authoritative session snapshot with bounded retry so the test handles server-tool advertisement that occurs before or after the client begins observing actions.
(Written by Copilot)
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>