Skip to content

Add V2 Project preparation and host debug sessions - #350

Open
David Negstad (danegsta) wants to merge 286 commits into
mainfrom
danegsta-v2-project-resource
Open

David Negstad (danegsta) wants to merge 286 commits into
mainfrom
danegsta-v2-project-resource

Conversation

@danegsta

@danegsta David Negstad (danegsta) commented Nov 4, 2026 •

Copy link
Copy Markdown
Member

V2 needs a project-level representation of user code that can run as a host process or in a container, with AppHost controlling startup through a debug adapter rather than the V1 IDE protocol. This PR adds Project preparation and host/container debug sessions, keeping application lifetime, adapter lifetime, and prepared execution context separate.

Approach

  • Prepare user code without automatically launching it. Project accepts exactly one immutable process or container template, an informational source root, and service-backed ports. It publishes evaluated application arguments/environment for AppHost. Process Projects prepare inputs without starting an application; container Projects create a reusable physical container running tail -f /dev/null. Readiness describes preparation and session coordination, not application health. Process environment suppression matches V1 Executable; explicitly declared container variables are retained, matching V1 Container.
  • Run caller-supplied adapters in the selected execution context. The process/container template determines adapter location; there is no separate placement field. Adapter configuration declares a required host directory, command/arguments, transport, and environment. Container Projects install that directory at /opt/dcp/debug-adapter or a caller-selected containerDirectory. {{adapterDirectory}} expands to the appropriate location. Optional executableFiles identifies regular files to mark executable in the streamed archive, including when copying Linux binaries from Windows; source files remain unchanged. A general physical-container CopyFiles API supports streamed directories, SHA256-verified tar sources, and inline archives, with a 10-minute runtime transfer limit and opt-in tar-source cleanup.
  • Expose authenticated native DAP over a WebSocket subresource. Debug connections require non-empty DCP_SECURE_TOKEN and/or DCP_DEBUG_SESSION_TOKEN configuration. Whenever the separate debug token is configured, the request must carry it in X-DCP-Debug-Session-Token, in addition to normal API bearer authentication. The header avoids upstream request-URI logging of query credentials. Host adapters support stdio, TCP-connect, and TCP-callback; container adapters support stdio and TCP-connect through Docker, Podman, and WSLC. TCP-connect sessions share a reference-counted provider; other supported modes use dedicated adapter executions.
  • Report observations without retaining DAP request history. Each bridge publishes current connection state and latched initialize/launch/attach, initialized/process, debuggee-exit, termination, and disconnection observations. Opaque launch configuration is forwarded rather than copied into status. Session readiness requires observed client initialization and the adapter initialized event while connected. Request correlation remains internal to bounded outstanding-request maps. disconnect stops further request forwarding without treating late traffic as failure or synthesizing responses; adapter responses/events continue draining within bounded shutdown.
  • Keep target ownership distinct from attachment and session closure. Identity-safe host target registrations survive session closure for Project observation and bounded cleanup. Targets reported as attach or attachForSuspendedLaunch are observed but not cleanup-owned, including on registration failure. Container PIDs never select host cleanup handles, and attached runtime-command completion does not prove in-container process termination. Failed provider cleanup remains explicitly unconfirmed and fences duplicate launches. Output buffering is bounded to 64 MiB per stream, with explicit overflow failure and cleanup.

Project reconciliation reuses existing V2 state, work-queue, create-recovery, finalizer, namespace-cleanup, and logging mechanisms. API-server-owned debug observations use isolated status writes; Project-specific serving lives in internal/projectdebug, and generic framing/correlation lives in internal/dap. Supporting changes include bounded initial image-identity inspection retries and precision-aware process identity comparison across API serialization.

Boundaries and follow-up work

Host/container terminals, runInTerminal, adapter-terminal execution, and container TCP-callback remain follow-up work. DCP does not acquire debug adapters, infer language-specific launch configuration, implement V1 IDE orchestration, create automatic source mounts, or recover debug executions across controller restarts.

Target cleanup is bounded best effort for reported, owned identities—not a guarantee that adapters report every target. Session closure alone does not establish target exit or cleanup. Session/execution records remain until Project deletion; pruning is deferred. Installation uses the DCP installation directory or the client's selected destination, without special inspection of existing container symlinks. Decisions and follow-up scope are recorded in plan/v2-project-debugging-plan.md.

Verification

  • The latest full native macOS test suite and repository-wide lint passed. Focused race coverage passed for Project preparation/lifecycle, DAP forwarding and shutdown, adapter/runtime boundaries, attached-target preservation, executable-file permissions, and copy deadlines.
  • Real API-server/storage and running-controller tests cover status-writer isolation, readiness loss, identity replacement, create recovery, provider sharing/fencing, target cleanup, declared container environment, and directory installation. Dedicated credential tests verify admission and absence of accepted/rejected tokens from verbose server, audit, and standard-library panic logs across successful and failing requests.
  • Docker, Podman, and WSLC command-stream tests use native subprocess stand-ins rather than real container runtimes. Real-container execution and cross-platform runtime validation remain CI work.
  • Delve E2E coverage includes initialization, launch, verified breakpoint/locals, continuation, and deletion while stopped. That scenario previously passed locally under explicit user authorization; it was not rerun locally for the latest changes.

Capture process output in the physical controller and publish immediate physical log-source snapshots through logical status. Reuse shared V2 streaming and owner-scoped system diagnostics, with direct file redirection for retained processes.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: aa4abbe1-3392-4398-9f96-566f68ce0fa9
Separate one-shot runtime execution ownership from logical container targeting. Reuse V2 state-driven reconciliation, captured logging, and ordered namespace cleanup, with real-API regression coverage for launch, cancellation, identity, and creation recovery.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 89db152a-aa9d-4e1d-9058-d4c0090c88d6
Port upstream watch-setup ordering and regression tests into internal/logstream, preserving the V1 API adapter and existing streaming handoff. Adopt Tilt v0.19.2 and namespace watcher hardening.

Co-authored-by: Copilot App <[email protected]>
Preserve the original physical source identity in a completed, unavailable descriptor so logical-only followers finish through the existing lifecycle callbacks. Cover physical deletion through an isolated real API server with no physical log request.

Co-authored-by: Copilot App <[email protected]>
Co-authored-by: Copilot App <[email protected]>

Copilot-Session: bbe01c56-5ae4-4f36-8134-93b3b2718fd2
Co-authored-by: Copilot App <[email protected]>
Copilot-Session: aa4abbe1-3392-4398-9f96-566f68ce0fa9
Use one filename contract for command and runtime captures, preserve V1 startup filenames and runtime capture suffixes, and capture physical image output with ordinary stdout/stderr source names.

Co-authored-by: Copilot App <[email protected]>
Project stable completed log-source identity on every missing-backing reconciliation, including persistence settlement, so logical-only followers finish and status-write conflicts cannot lose completion.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: aa4abbe1-3392-4398-9f96-566f68ce0fa9
Co-authored-by: Copilot App <[email protected]>

Copilot-Session: bbe01c56-5ae4-4f36-8134-93b3b2718fd2
Integrate the immediate process parent and Tilt v0.19.2 through the existing stack order.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 89db152a-aa9d-4e1d-9058-d4c0090c88d6
Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 89db152a-aa9d-4e1d-9058-d4c0090c88d6
Co-authored-by: Copilot App <[email protected]>
Copilot-Session: aa4abbe1-3392-4398-9f96-566f68ce0fa9

# Conflicts:
#	internal/logs/capture_file_test.go
Adapt exec output capture to ordinary stdout and stderr filenames alongside the shared V2 preflight validation.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 89db152a-aa9d-4e1d-9058-d4c0090c88d6
Inspect and adopt a matching owned physical process before rechecking creation prerequisites. Exclude mutable stop from immutable configuration comparison and forward it through runtime reconciliation. Cover lost successful-create responses in session and persistent modes through the real API.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: aa4abbe1-3392-4398-9f96-566f68ce0fa9
Preserve the shared real-client decoration hook while incorporating stable physical-child recovery before logical stop forwarding.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 89db152a-aa9d-4e1d-9058-d4c0090c88d6
Acquire exclusive runtime-name leases so one logical network cannot release another startup's claim. Exercise two same-owner logical networks in the shared real API/controller environment and verify reuse after settlement.

Co-authored-by: Copilot App <[email protected]>

Copilot-Session: bbe01c56-5ae4-4f36-8134-93b3b2718fd2
Finish physical and logical followers after confirmed runtime disappearance, wait for image log-writer release in its assertion, and remove unnecessary simulated image aliases. Cover failed pull diagnostics and stream closure at the production Docker/Podman adapter boundary.

Co-authored-by: Copilot App <[email protected]>
Co-authored-by: Copilot App <[email protected]>

Copilot-Session: bbe01c56-5ae4-4f36-8134-93b3b2718fd2
Co-authored-by: Copilot App <[email protected]>
Copilot-Session: aa4abbe1-3392-4398-9f96-566f68ce0fa9
Integrate validated immediate-parent capture completion, shared adapter regressions, and exclusive network startup leases through the existing stack.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 89db152a-aa9d-4e1d-9058-d4c0090c88d6
Isolate process lease keys, preserve runtime stop handling during persistence settlement, and select raw capture reader settings. Publish output completion after pipe drainage and retry capture disposal through existing cleanup helpers and reconciliation. Add focused regressions and remove the cleanup test's file-restoration race.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: aa4abbe1-3392-4398-9f96-566f68ce0fa9
Preserve the existing real-client test hooks while adding the parent process executor hook and shared raw capture handling.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 89db152a-aa9d-4e1d-9058-d4c0090c88d6
Treat loss of handed-off physical backing as terminal, preserve completed log-source identity, and release startup leases without recreating resources or reconstructing runtime ownership. Cover startup and ownership-recording loss, status conflicts, and namespace deletion.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: aa4abbe1-3392-4398-9f96-566f68ce0fa9
Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 89db152a-aa9d-4e1d-9058-d4c0090c88d6
…agation

Use operation-local ownership candidates from verified physical observations, settle retained startup before child deletion, and release canceled pre-handoff leases without runtime-name ownership discovery. Preserve namespace cleanup when termination prevents physical startup, including a committed Create with a lost response.

Surface terminal image failure while logical network dependencies remain unavailable and keep startup failure latched after dependency recovery.

Co-authored-by: Copilot App <[email protected]>

Copilot-Session: bbe01c56-5ae4-4f36-8134-93b3b2718fd2
Update every matching label entry in the shared setter while preserving unrelated labels and their ordering. Cover reserved ownership labels, caller immutability, and persistent-network reuse with duplicate lifecycle labels.

Co-authored-by: Copilot App <[email protected]>

Copilot-Session: bbe01c56-5ae4-4f36-8134-93b3b2718fd2
Forward lease options through WithResourceLease and opt V1 network creation into same-process exclusivity. Keep release within the callback scope instead of issuing redundant status-driven releases that can remove a later startup's lease.

Cover wrapper exclusivity and real-API V1/V2 creation serialization, shared runtime references, and retained workload registration.

Co-authored-by: Copilot App <[email protected]>

Copilot-Session: bbe01c56-5ae4-4f36-8134-93b3b2718fd2
Co-authored-by: Copilot App <[email protected]>
Copilot-Session: aa4abbe1-3392-4398-9f96-566f68ce0fa9

# Conflicts:
#	test/integration/standard_test_env.go
Unify exec tests on the shared DecorateAPIClient hook.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 89db152a-aa9d-4e1d-9058-d4c0090c88d6
Match the physical-container Unknown/missing projection without periodic requeue. Preserve event-driven observation of the pinned runtime ID and retry transient inspection failures.

Cover retry-policy parity, retained identity and details, same-name replacement isolation, and deletion without removing the replacement.

Co-authored-by: Copilot App <[email protected]>

Copilot-Session: bbe01c56-5ae4-4f36-8134-93b3b2718fd2

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

Unresolved defects can indefinitely block TCP output bridges and Project deletion, while successful image verification retains stale failure counts that prematurely exhaust retries.

3 open issues
2 files not reviewed
  • api/v2/zz_generated.deepcopy.go: Generated file
  • api/v2/zz_generated.model_name.go: Generated file
What changed in this PR

Adds V2 Project preparation and debug-session coordination for AppHost-controlled application launch, integrating with DCP’s existing controllers, logging, and cleanup mechanisms while separating application, adapter, and prepared-container lifetimes.

Changes:

  • Adds Project registration, preparation snapshots, target-process observation, and cleanup integration.
  • Introduces framed DAP forwarding, independent session status, bounded output buffering, and interactive container-exec input.
  • Expands integration coverage, adds CI-enabled Delve validation, and shares the bounded image-inspection retry policy.
File Description
test/​projectdebug/​main.go Adds a small breakpoint target for debugger validation.
test/​integration/​v2_project_recovery_test.go Tests create recovery, collisions, and missing backing resources.
test/​integration/​v2_project_protocol_test.go Tests independent protocol outcomes and shutdown interruption.
test/​integration/​v2_project_prepared_test.go Tests frozen environments and preparation without application launch.
test/​integration/​v2_project_debug_transport_test.go Tests adapter transport lifetimes and container contexts.
test/​integration/​v2_project_debug_config_test.go Tests adapter admission, immutability, and prerequisites.
test/​integration/​v2_image_inspection_test.go Tests bounded initial image verification retries.
test/​integration/​test_env_common.go Adds Project controller selection.
test/​integration/​standard_test_env.go Wires Project reconciliation and executor fault injection.
test/​integration/​advanced_test_env.go Adds Project reconciliation to advanced environments.
test/​delay/​delay.go Adds DAP and raw stdio test modes.
test/​delay/​delay_test.go Tests byte-preserving stdio echo.
test/​delay/​dap.go Implements a minimal test adapter.
test/​delay/​dap_test.go Tests adapter responses, process events, and disconnect.
scripts/​test-ci.ps1 Prepares Delve and enables Windows debugger validation.
README.md Documents debugger validation and opt-in behavior.
plan/​v2-resource-plan.md Documents Project lifecycle and inspection retry behavior.
pkg/​io/​buffered_pipe.go Adds nonblocking overflow-limited buffering.
pkg/​io/​buffered_pipe_test.go Tests overflow, closure, and reader notification.
Makefile Adds debugger prerequisites and CI enablement.
internal/​wslc/​containers.go Forwards stdin through interactive WSLC exec.
internal/​wslc/​containers_test.go Tests WSLC duplex exec streams.
internal/​testutil/​ctrlutil/​test_container_orchestrator.go Excludes live stdin from recorded invocation snapshots.
internal/​testutil/​ctrlutil/​test_container_orchestrator_test.go Tests caller ownership of exec input.
internal/​testutil/​commandstreams/​command_streams.go Adds shared subprocess stream checks.
internal/​testutil/​commandstreams/​command_streams_test.go Checks production dependency isolation from test helpers.
internal/​resourcecleanup/​resources.go Orders Project cleanup before physical dependencies.
internal/​resourcecleanup/​resources_test.go Verifies Project namespace-cleanup ordering.
internal/​projectdebug/​status.go Separates controller and API-owned debug status updates.
internal/​projectdebug/​status_test.go Tests status ownership, concurrency, and replacement safety.
internal/​projectdebug/​protocol.go Records initialize, launch, and attach outcomes.
internal/​projectdebug/​protocol_test.go Tests protocol history preservation and interruption.
internal/​projectdebug/​process.go Registers reported target identities and tracking uncertainty.
internal/​projectdebug/​process_test.go Tests identity deduplication and process-event handling.
internal/​projectdebug/​output.go Buffers adapter output independently of client forwarding.
internal/​projectdebug/​output_test.go Tests overflow, completion, and blocked forwarding.
internal/​projectdebug/​dap.go Adapts framed DAP to stream and WebSocket transports.
internal/​podman/​cli_orchestrator.go Forwards stdin through interactive Podman exec.
internal/​podman/​cli_orchestrator_test.go Tests Podman duplex exec streams.
internal/​logs/​v2resourcelogs/​resource_logstreamer.go Adds Project log snapshots and source validation.
internal/​logs/​v2resourcelogs/​project_logstreamer_test.go Tests Project log availability and completion.
internal/​docker/​cli_orchestrator.go Forwards stdin through interactive Docker exec.
internal/​docker/​cli_orchestrator_test.go Tests Docker duplex exec streams.
internal/​dcpctrl/​commands/​run_controllers.go Registers the production Project controller.
internal/​dap/​message.go Implements bounded DAP frame parsing and writing.
internal/​dap/​bridge.go Adds bidirectional correlation and bounded shutdown handling.
internal/​containers/​image_orchestrator.go Extracts the shared image-inspection retry policy.
internal/​containers/​image_orchestrator_test.go Tests retry-policy settings and independence.
internal/​containers/​container_orchestrator.go Adds caller-owned stdin to container exec options.
internal/​apiserver/​duplex_subresource_test.go Tests authenticated long-running WebSocket subresources.
internal/​apiserver/​apiserver.go Configures Project debug serving and logs.
go.mod Registers Delve and its tool dependencies.
controllers/​project_processes.go Observes registered targets and performs bounded cleanup.
controllers/​project_data.go Holds Project lifecycle state and projects status.
controllers/​physical_process_controller.go Forwards diagnostics to Project owners.
controllers/​physical_container_image_controller.go Adds bounded identity verification and Project diagnostics.
controllers/​physical_container_controller.go Forwards container diagnostics to Project owners.
controllers/​logical_ports.go Withdraws endpoints for prepared, non-serving Projects.
api/​v2/​zz_generated.model_name.go Adds generated Project and debug model names.
api/​v2/​project_types_test.go Tests Project validation and immutable templates.
api/​v2/​project_debug_types_test.go Tests adapter configuration, defaults, and immutability.
api/​v2/​groupversion_info.go Registers the V2 Project resource.

Review effort: Balanced

Comment thread controllers/project_data.go Resolved
Comment thread internal/projectdebug/output.go Resolved
Retain identity-bound runtime logs on Unknown transitions, refresh valid original backing observations without reopening lifecycle state, and complete followers only on confirmed absence. Cover existing followers, late readers, capture completion, and missing-backing status retries.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9
Follow logical-resource terminal handlers by retaining failure state and diagnostics across backing lookup changes. Cover missing and replaced backings and preserve follower completion through status conflicts without requiring a terminal-state transition.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9
Evaluate declared values before overlaying process overrides onto literal ambient values, using a focused merge function. Keep containers isolated from ambient environment and compare prepared slices element-wise so empty environments cannot starve finalizer removal. Cover Project/namespace deletion and wait for missing-backing status convergence in the CI regression.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9
Apply one bounded read-ahead buffer to stdio and TCP connections and start final-output draining on connection EOF independently of shared-provider exit. Replace setup-time resource rereads with Project and Namespace watch snapshots, retaining only watch-first startup identity verification. Cover slow-client EOF isolation, watch closure, subscription deletion, and watch-canceled container setup.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9
Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9

# Conflicts:
#	internal/logs/v2resourcelogs/resource_logstreamer.go
#	internal/podman/cli_orchestrator_test.go
#	internal/wslc/containers_test.go
Use shared logical backing patterns, project readiness through lifecycle conditions, report inspected container environment, and order bounded adapter and orphan-process cleanup. Reset image inspection failures after successful identity verification.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

A root-exit race can leave descendant processes alive while reporting cleanup complete, and acknowledged DAP disconnects can still be misreported as failures.

2 open issues
3 resolved since last review
2 files not reviewed
  • api/v2/zz_generated.deepcopy.go: Generated file
  • api/v2/zz_generated.model_name.go: Generated file

Review effort: Balanced

Comment thread controllers/project_processes.go Resolved
Comment thread internal/dap/bridge.go Resolved
Pass Project container runArgs through to the physical container, matching
LogicalContainer. Allocate host tcp-callback adapter listener ports through
the shared DCP port allocator so they cannot reuse recently allocated ports.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9
A client closing its stream after the adapter acknowledged its disconnect
request is normal protocol shutdown, even if the adapter connection stays
open. Earlier client loss still fails the session.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🔵 Needs a closer look

An upstream read error can be masked as EOF during writer closure, causing a reset TCP connection to be recorded as Exited rather than Failed before asynchronous cancellation occurs.

No open issues 🎉

1 previously missed issue

In code that hasn't changed since last review

Medium severity Preserve upstream read errors before closing the writer

internal/​projectdebug/​output.go:33

A non-EOF upstream read error becomes EOF when writer.Close() runs, so the bridge can return success before the asynchronous failure callback cancels the serving context. A reset TCP connection can therefore be recorded as an Exited session rather than Failed. Close the buffered reader with the upstream error before closing the writer so failure does not depend on callback scheduling.

2 resolved since last review
2 files not reviewed
  • api/v2/zz_generated.deepcopy.go: Generated file
  • api/v2/zz_generated.model_name.go: Generated file

Review effort: Balanced

@danegsta
David Negstad (danegsta) marked this pull request as ready for review November 12, 2026 01:33
Consolidate preparation and shutdown reasons while retaining detailed causes
in messages. Remember successful preparation across uncertain observations
to distinguish initial preparation failures from lost execution context.
Align namespace admission and paused reporting with logical controllers.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9
Require an adapter directory and derive execution placement from the Project
template. Add physical copy contexts for directories, verified tar files,
and inline archives, backed by a general runtime tar-copy API. Keep directory
packaging in the tar utilities and perform opted-in file cleanup best-effort
on successful copy, terminal failure, and settled stop or deletion.

Co-authored-by: Copilot App <[email protected]>
Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

A critical symlink-containment flaw permits escape from the installation directory, alongside unresolved worker leaks, unsafe host-directory deletion, and unbounded request-history growth.

4 open issues
2 files not reviewed
  • api/v2/zz_generated.deepcopy.go: Generated file
  • api/v2/zz_generated.model_name.go: Generated file

Review effort: Balanced

Comment thread pkg/io/tar_directory.go Resolved
Comment thread controllers/container_copy_files.go Resolved
Comment thread internal/projectdebug/protocol.go Resolved
Comment thread pkg/io/tar_archive.go Resolved
Replace retained request history with latched session observations and forward-only connection state. Preserve progress across status writers and report stream termination independently from adapter and target lifetime.

Validate composed symlinks, preserve directory archive sources during cleanup, and release temporary context-reader workers promptly.

Co-authored-by: Copilot App <[email protected]>

Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9
Require DCP_SECURE_TOKEN or DCP_DEBUG_SESSION_TOKEN configuration, validating the separate debug token through the X-DCP-Debug-Session-Token header before session creation or adapter launch.

Cover admission combinations and verify credentials remain absent from verbose server, audit, and panic logs. Update integration clients and document the connection contract.

Co-authored-by: Copilot App <[email protected]>

Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9
Increase archive-transfer limits to ten minutes, exclude attached debug targets from Project cleanup, and expose executableFiles declarations for directory copies and container adapters.

Add focused regressions for transfer deadlines, attached target survival and registration failure, executable paths and modes, and Project-to-physical copy handoff.

Co-authored-by: Copilot App <[email protected]>

Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9
Discard further requests after disconnect without failing shutdown or synthesizing replies. Restrict Project environment prefix suppression to process templates, matching V1 container behavior.

Add regressions for late requests and explicit container variables, and update the debugging contract.

Co-authored-by: Copilot App <[email protected]>

Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9
Add cancellable executor exit observation that shares owned-process waits and safely polls adopted identities. Scope PhysicalProcess watches to resource and process identity, preserve retryable inspection failures, and cancel observation when tracking ends.

Cover prompt adopted completion, watcher recovery and cancellation, concurrent owned observers, and preserved exit-code callbacks.

Co-authored-by: Copilot App <[email protected]>

Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9
Use standard test contexts, explicit cancellation, and deterministic synchronization for buffered pipes, debounce cancellation, process completion, and initialization-lock tests. Inject cleanup verification failures instead of waiting for context expiry, and allocate free listener ports for tunnel idempotency.

Co-authored-by: Copilot App <[email protected]>

Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9
Replace short HTTP retry deadlines with synchronized acquisition tests for host and container providers. Verify cancellation preserves the fence and ready replacement releases waiting acquisition while retaining HTTP cleanup coverage.

Co-authored-by: Copilot App <[email protected]>

Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9
Apply one timing policy to scheduling, debounce, and retry eligibility while preserving production defaults. Configure faster V2 integration-test intervals without shortening test context deadlines, and retain a slow monitoring fallback for exit-notification coverage.

Verify policy isolation and delayed delivery, synchronize backing-deletion assertions, and document the test timing profile.

Co-authored-by: Copilot App <[email protected]>

Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9
Rewrite existing debounce tests with deterministic timing and invocation assertions without increasing test count. Derive controller idle observation from two test-profile scheduling/debounce cycles rather than a fixed ten-second wait.

Co-authored-by: Copilot App <[email protected]>

Copilot-Session: 754d257d-9693-4e17-91ef-e520d4a620d9
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