chore: generate

This commit is contained in:
opencode-agent[bot]
2026-05-09 13:11:45 +00:00
parent 28b03595bf
commit d01cb7f013
7 changed files with 8 additions and 20 deletions

View File

@@ -14,8 +14,9 @@ export const WorkspaceInfo = Schema.Struct({
}).annotate({ identifier: "Workspace" })
export type WorkspaceInfo = DeepMutable<Schema.Schema.Type<typeof WorkspaceInfo>>
export const WorkspaceListedInfo = Schema.Struct(Struct.omit(WorkspaceInfo.fields, ["id"]))
.annotate({ identifier: "WorkspaceListedInfo" })
export const WorkspaceListedInfo = Schema.Struct(Struct.omit(WorkspaceInfo.fields, ["id"])).annotate({
identifier: "WorkspaceListedInfo",
})
export type WorkspaceListedInfo = DeepMutable<Schema.Schema.Type<typeof WorkspaceListedInfo>>
export const WorkspaceAdapterEntry = Schema.Struct({

View File

@@ -8,7 +8,6 @@ import { waitGlobalBusEventPromise } from "./global-bus"
void Log.init({ print: false })
function app() {
return Server.Default().app
}

View File

@@ -41,8 +41,7 @@ export function coverageResult(scenario: Scenario): Result {
export function parseOptions(args: string[]): Options {
const mode = option(args, "--mode") ?? "effect"
if (mode !== "effect" && mode !== "coverage" && mode !== "auth")
throw new Error(`invalid --mode ${mode}`)
if (mode !== "effect" && mode !== "coverage" && mode !== "auth") throw new Error(`invalid --mode ${mode}`)
return {
mode,
include: option(args, "--include"),

View File

@@ -8,15 +8,7 @@ import { MessageID, PartID } from "../../../src/session/schema"
import { call, callAuthProbe } from "./backend"
import { original } from "./environment"
import { runtime } from "./runtime"
import type {
ActiveScenario,
Options,
ProjectOptions,
Result,
Scenario,
ScenarioContext,
SeededContext,
} from "./types"
import type { ActiveScenario, Options, ProjectOptions, Result, Scenario, ScenarioContext, SeededContext } from "./types"
export function runScenario(options: Options) {
return (scenario: Scenario) => {

View File

@@ -12,7 +12,6 @@ import * as Log from "@opencode-ai/core/util/log"
void Log.init({ print: false })
function app(input: { password?: string; username?: string }) {
const handler = HttpRouter.toWebHandler(
ExperimentalHttpApiServer.routes.pipe(

View File

@@ -421,9 +421,9 @@ describe("session HttpApi", () => {
directory: currentDir,
})
const headers = { "x-opencode-directory": tmp.path }
const sessions = (yield* json<Session.Info[]>(yield* request(`${SessionPaths.list}?${query}`, { headers }))).map(
(item) => item.id,
)
const sessions = (yield* json<Session.Info[]>(
yield* request(`${SessionPaths.list}?${query}`, { headers }),
)).map((item) => item.id)
expect(sessions).toContain(pathSession.id)
expect(sessions).not.toContain(pathlessSession.id)

View File

@@ -287,7 +287,6 @@ describe("HttpApi UI fallback", () => {
})
test("keeps matched API routes ahead of the UI fallback", async () => {
const response = await Server.Default().app.request("/session/nope")
expect(response.status).toBe(404)
@@ -344,7 +343,6 @@ describe("HttpApi UI fallback", () => {
})
test("allows web UI preflight without auth", async () => {
const response = await app({ password: "secret", username: "opencode" }).request("/", {
method: "OPTIONS",
headers: {