Skip to content

Delete unused Core Go code - #831

Merged
SaladDay merged 3 commits into
mainfrom
delete-unused-core-go-code
Oct 23, 2026
Merged

SaladDay merged 3 commits into
mainfrom
delete-unused-core-go-code

Conversation

@SaladDay

@SaladDay SaladDay commented Oct 23, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Pure deletion of Core Go code, fields, queries and doc text that nothing uses. Two commits: the Core workspace protocol change (workspacefs.Control.Observe) stands alone.

Removed:

  • responseHeadersWithErrors, microsandbox Labels.
  • Domain Reader interfaces used only in var _ assertions (adminaudit, agents, environmenttemplates, files, modelconfiguration, projects, writeaudit); the unused sessions reader families (Admin, Artifact, ExecutorCredential, Item, Subagent) and ListSessions, SessionStreamSnapshot, SessionEventCursor, ListSessionEvents, GetTurnDiagnosticsSnapshot, GetManagedSessionArchive, ListTurns and ArchivedCancellationReceipt from the interface sessions.Reader composes; deployment SampleHostHistory/NodeAllocations, vaults GetVault and skills Version interface methods.
  • Device WorkspaceID chain and the bootstrap workspace_id/protocol_version fields; the unread heartbeat ts, active_requests, daemon_version (Runtime protocol 0.22.0) and HeartbeatStatus.Liveness.
  • Write-only fields: NewAllocation.EnvironmentID, SweepResult times (and Sampler.now), EnrolledRuntimeBinding.SessionID, EnvironmentFileWrite.EnvironmentID/SessionID; TurnEvent moved into its integration test.
  • request_timeout provider observation category and diagnostic code, and the system provisioning step.
  • Migration 000004: drops view public_execution_turns and the request_timeout value of deployment_provider_error_code.
  • workspacefs.Control.Observe (own commit); the NFS Filesystem.Observe stays because Resolve calls it.
  • Doc fixes: Core errors anchor, IMPLEMENTATION.md limits/throttling links and the false web_search sentence.

Kept (production uses or tests are the only observation of persisted state): coreErrorResponse (type-assertion marker), Policy.Declarations (10+ execution and integration tests inject custom Harness declarations), Allocation.ObservationError/ComputeWakeRequested and EnvironmentRun.Turn (asserted by concurrency and diagnostic tests), StoredNode.ReadyGeneration (read in nodes.go), EnrollmentResponse.Connected/ProviderReady (read by deploy/node/node_install.py), provisioning step file (produced by runtime initialization), vaults.Reader.ListVaults/GetCredential/ListCredentials (called through the interface by pg tests / service).

Checks

  • go build ./..., go vet ./...: pass
  • go test: api, sessions, execution, deployment/..., vaults, skills, runtimegateway, runtimeobs, runtimedevice, runtimeenrollment, modelconfiguration, workspaces, workspacefs/..., sandbox/microsandbox, cmd/..., internal/agentdaemon/..., apps/daemon transport and cli: pass
  • DB: sessionpg (devices, file writes), modelconfigurationpg, and the 24 integration test files touched: pass
  • make check-sqlc, make check-openapi: pass
  • agents-client pnpm test, web typecheck, pnpm test:web: pass
  • website translations test: pass
  • deadcode on Core entry points: only coreErrorResponse remains, nothing newly exposed

View with [code]smith Autofix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.

@blacksmith-sh

This comment has been minimized.

@SaladDay
SaladDay force-pushed the delete-unused-core-go-code branch 3 times, most recently from 1aac926 to 5d73560 Compare October 23, 2026 18:56
- Delete Observe from workspacefs.Control; Core never called it through the interface.
- Keep the NFS Filesystem.Observe method, which Resolve calls directly.
- Drop the test fixtures' Observe methods.
- Update the workspace provider protocol and its Chinese translation.
- Remove the unreachable responseHeadersWithErrors and microsandbox Labels.
- Remove domain Reader interfaces used only in assertions, and narrow sessions.Reader and its families to the methods called through it.
- Remove interface methods never called through their interface in deployment, vaults and skills.
- Remove the device WorkspaceID chain, the bootstrap workspace_id and protocol_version fields, and the unread heartbeat ts, active_requests and daemon_version fields (Runtime protocol 0.22.0).
- Remove write-only fields: NewAllocation.EnvironmentID, SweepResult times, EnrolledRuntimeBinding.SessionID, EnvironmentFileWrite.EnvironmentID and SessionID; move TurnEvent into its only test.
- Remove the request_timeout provider observation category and the system provisioning step.
- Drop the public_execution_turns view and the request_timeout error-code constraint value in a forward migration.
- Correct the Core errors anchor and the Core implementation notes.
@SaladDay
SaladDay merged commit 32ca93d into main Oct 23, 2026
25 checks passed
@SaladDay
SaladDay deleted the delete-unused-core-go-code branch October 23, 2026 19:06
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.

1 participant