GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — test(ci): register omitted V2 unit suites by kitlangton · Pull Request #45970 · anomalyco/opencode

test(ci): register omitted V2 unit suites #45970

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Sign up for GitHub

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
kitlangton merged 11 commits into v2 from register-ci-tests
Aug 28, 2026

Uh oh!

There was an error while loading. Please reload this page.

Merged

test(ci): register omitted V2 unit suites #45970

Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
11 commits
Select commit Hold shift + click to select a range
708a919
test(ci): register omitted V2 unit suites
kitlangton Aug 28, 2026
7f45f01
test(codegen): use native fixture paths
kitlangton Aug 28, 2026
f095b4e
test(codegen): preserve fixture LF checkouts
kitlangton Aug 28, 2026
85a1d59
test(server): close cancellation fixture connections
kitlangton Aug 28, 2026
49e320e
test(session-ui): bound boundary scan reads
kitlangton Aug 28, 2026
484a566
test(ci): probe native callback port retention
kitlangton Aug 28, 2026
96ee025
test(ci): trace actual callback cancellation
kitlangton Aug 28, 2026
bdc4198
test(ci): inspect callback rebind TCP state
kitlangton Aug 28, 2026
ae4495a
test(ci): isolate callback config and probe inherited sockets
kitlangton Aug 28, 2026
4167189
test(ci): remove callback diagnostics after isolation proof
kitlangton Aug 28, 2026
bde15e9
test(server): budget real OAuth bind retries
kitlangton Aug 28, 2026
File filter
Filter by extension

Clear filters
Conversations
Failed to load comments.
Loading

Uh oh!

There was an error while loading. Please reload this page.

Jump to
Jump to file
Failed to load files.
Loading

Uh oh!

There was an error while loading. Please reload this page.

Diff view
Diff view
Prev Previous commit
Next Next commit
test(ci): inspect callback rebind TCP state
  • Loading branch information

Uh oh!

There was an error while loading. Please reload this page.

@kitlangton
kitlangton committed Aug 28, 2026
commit bdc41989e6ed23e56442290c87effc12fe328cfd

There are no files selected for viewing

17 changes: 17 additions & 0 deletions 17 packages/server/test/fetch.test.ts
Show comments
View file
Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ function occupy(port: number, cancel = false) {
listening: item.server.listening,
})
})
if (cancel) traceTcp(port)
})
}),
}))
Expand Down Expand Up @@ -79,6 +80,22 @@ function occupy(port: number, cancel = false) {
})
}

function traceTcp(port: number) {
if (process.platform !== "win32") return
const child = Bun.spawn(["netstat", "-ano"], { stdout: "pipe", stderr: "ignore" })
void Promise.all([new Response(child.stdout).text(), child.exited]).then(([output, exitCode]) => {
const rows = output.split(/\r?\n/).flatMap((line) => {
const fields = line.trim().split(/\s+/)
if (fields[0] !== "TCP" || fields.length < 5) return []
const safe = /^(127\.0\.0\.1|\[::1\]|0\.0\.0\.0|\[::\]):\d+$/
if (!safe.test(fields[1]) || !safe.test(fields[2])) return []
if (!fields[1].endsWith(`:${port}`) && !fields[2].endsWith(`:${port}`)) return []
return [{ local: fields[1], peer: fields[2], state: fields[3], thisProcess: fields[4] === String(process.pid) }]
})
console.error("[DEBUG-ci-callback] fixture-tcp-after-stop", { port, exitCode, rows })
})
}

const ready = (handler: Handler) =>
Effect.promise(() => handler(new Request("http://opencode.local/api/model/default")))

Expand Down
14 changes: 8 additions & 6 deletions 14 script/probe-callback-port.ts
Show comments
View file
Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ const modes = [
"no-connection",
"force-first",
"fixed-force-first",
"listen-callback",
"response-connection-close",
"socket-reset-after-flush",
"socket-destroy-after-flush",
Expand Down Expand Up @@ -172,7 +173,7 @@ async function probe(mode: (typeof modes)[number]) {
used.add(state.port)
const second = await bind(servers[1].server, state.port, "::1", deadline.signal)
if (!second.ok) throw new Error(`IPv6 setup failed: ${JSON.stringify(second.error)}`)
const occupied = await bind(servers[2].server, state.port, "localhost", deadline.signal)
const occupied = await bind(servers[2].server, state.port, "localhost", deadline.signal, mode === "listen-callback")
log("occupied-bind", occupied)
if (occupied.ok || occupied.error.code !== "EADDRINUSE")
throw new Error("Expected localhost bind to fail with EADDRINUSE while both families are occupied")
Expand Down Expand Up @@ -216,7 +217,7 @@ async function probe(mode: (typeof modes)[number]) {
// These are production's nine 200ms retries, not a sleep-based proposed fix.
for (const attempt of [1, 2, 3, 4, 5, 6, 7, 8, 9]) {
await timers.setTimeout(200, undefined, { signal: deadline.signal })
const result = await bind(servers[2].server, state.port, "localhost", deadline.signal)
const result = await bind(servers[2].server, state.port, "localhost", deadline.signal, mode === "listen-callback")
const observation = { attempt, afterFetchMs: Math.round(performance.now() - state.fetchAt), ...result }
attempts.push(observation)
log("rebind", observation)
Expand Down Expand Up @@ -269,19 +270,20 @@ async function probe(mode: (typeof modes)[number]) {
}
}

async function bind(server: Server, port: number, host: string, signal: AbortSignal) {
async function bind(server: Server, port: number, host: string, signal: AbortSignal, callback = false) {
signal.throwIfAborted()
const result = Promise.withResolvers<{ ok: true } | { ok: false; error: ReturnType<typeof describe> }>()
const onError = (cause: unknown) => result.resolve({ ok: false, error: describe(cause) })
const onListening = () => result.resolve({ ok: true })
server.once("error", onError)
server.once("listening", onListening)
if (!callback) server.once("listening", onListening)
try {
server.listen(port, host)
if (callback) server.listen(port, host, onListening)
if (!callback) server.listen(port, host)
return await bounded(result.promise, AbortSignal.any([signal, AbortSignal.timeout(1000)]))
} finally {
server.off("error", onError)
server.off("listening", onListening)
if (!callback) server.off("listening", onListening)
}
}

Expand Down
Loading
Oops, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

Add this suggestion to a batch that can be applied as a single commit. This suggestion is invalid because no changes were made to the code. Suggestions cannot be applied while the pull request is closed. Suggestions cannot be applied while viewing a subset of changes. Only one suggestion per line can be applied in a batch. Add this suggestion to a batch that can be applied as a single commit. Applying suggestions on deleted lines is not supported. You must change the existing code in this line in order to create a valid suggestion. Outdated suggestions cannot be applied. This suggestion has been applied or marked resolved. Suggestions cannot be applied from pending reviews. Suggestions cannot be applied on multi-line comments. Suggestions cannot be applied while the pull request is queued to merge. Suggestion cannot be applied right now. Please check back later.
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.