Skip to content

Conversation

@tlongwell-block
Copy link
Collaborator

Problem

The UI fails to connect when using an external goosed backend for debugging, timing out after 20 seconds even though the server is running.

Root Cause

The checkServerStatus() call happens before the API client is configured with authentication headers.

Solution

Configure the client with auth headers before checking status in connectToExternalBackend().

Testing

Start goosed: GOOSE_SERVER__SECRET_KEY=test GOOSE_PORT=3000 ./target/release/goosed agent
Connect UI: just debug-ui

@nacx
Copy link
Contributor

nacx commented Sep 18, 2025

Hi! I opened #4669 yesterday with the patch. I don't care what PR is merged (the code is yours anyway, as I mentioned in the PR description 😄 ). If you prefer to close that one and merge this, would you mind incorporating here the other changes to the doc and the Justfile I added there?


const isReady = await checkServerStatus();
if (!isReady) {
throw new Error(`External goosed server not accessible on port ${port}`);
Copy link
Collaborator

Choose a reason for hiding this comment

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

instead of duplicating this code, we can jsut delete the isReady check since that happens after we call this function anyway

@tlongwell-block
Copy link
Collaborator Author

tlongwell-block commented Sep 19, 2025

Closing this in favor of https://github.com/block/goose/pull/4669/files since it has the nice doc update and an identical bug fix #4669

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.

5 participants