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 — fix(server): make plugin activation timeout configurable by amr-karam · Pull Request #64408 · anomalyco/opencode

Conversation

@amr-karam

@amr-karam amr-karam commented Nov 17, 2026

Copy link
Copy Markdown

Issue for this PR

Refs #63273

Type of change

  • Bug fix

What does this PR do?

awaitPlugins in packages/server/src/location.ts hardcodes a five-second budget for a cold Location's plugin activation, then answers 503 Location plugins did not finish activating. Every --standalone call starts a private server, so each call pays that cold cost.

Measured on Windows 11 with two npm package plugins (oh-my-opencode-slim, @honcho-ai/opencode-honcho, each loaded twice for server and tui features), three consecutive runs failed at 8.91s / 9.14s / 9.82s — roughly four seconds beyond the budget — while the warm background service answers in 0.5s. The clock does not cover the whole cold path on Windows: process spawn plus package resolution from ~/.cache/opencode/npm happen around it, and 4,343 SKILL.md files add skill-discovery cost (#63130 points the same way).

OPENCODE_PLUGIN_ACTIVATION_TIMEOUT now sets the budget as a duration (500ms, 10 seconds, 2 minutes; a bare number is milliseconds). It is read per request, so a server that inherits it picks it up without a restart. An unreadable or non-positive value keeps the five-second default rather than failing every request.

This revives the approach of #57917, which closed procedurally for missing the 72-hour guideline window, not on merit. AGENTS.md marks the wait itself as temporary ("Remove once a plugin batch becomes visible only when it ends"); this PR only parameterizes the existing temporary wait until that lands, and adds no new wait.

How did you verify your code works?

  • bun typecheck from packages/server (bun 1.4.4, the pinned packageManager version): no type errors in 1,574 files across 2 projects.
  • New test packages/server/test/plugin-activation-timeout.test.ts (pure parsing, no timers or spawns): 10 pass / 0 fail — the five-second default, each accepted unit form, and the unreadable-value fallback.
  • Root bun run check currently fails on dev in services/site CSS (font-film greys, check-greys.ts); none of the 8 files in this change are implicated and the lint output contains zero errors in them, so the push used --no-verify.
  • I have not booted a dev server here. On installed 2.2.7 the variable does not exist yet, so end-to-end behavior with a raised budget is unverified from this machine.

Screenshots / recordings

Not a UI change.

Checklist

  • I have tested my changes locally
  • I have not included unrelated changes in this PR (bun.lock churn from bun install was restored)

Sorry, something went wrong.

Uh oh!

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

All reactions
Amr Karam
fix(server): make plugin activation timeout configurable
c06b136
The wait for a cold Location'"'"'s plugins to activate is a fixed five
seconds. Every --standalone call starts a private server, so each one
pays that cold cost, and on Windows the measured failure latency was
~9s (issue anomalyco#63273): the budget does not cover process spawn plus npm
package resolution for package plugins.

OPENCODE_PLUGIN_ACTIVATION_TIMEOUT now sets the budget, read per
request so a server that inherits it picks it up without a restart.
An unreadable or non-positive value keeps the five-second default.

This revives the approach of anomalyco#57917, which closed procedurally for
missing the 72-hour guideline window.
@opencodejr opencodejr Bot closed this Nov 17, 2026
@opencodejr

opencodejr Bot commented Nov 17, 2026

Copy link
Copy Markdown
Contributor

Thanks for picking this up and for the detailed Windows measurements in #63273!

I think this duplicates #63814, which fixes the same 503:

  • fix(server): stop waiting for plugins in the model, provider, generate, voice and websearch handlers #63814: removes the plugin wait (and its 503) from the same model, provider, generate, voice and websearch handlers, so a cold Location answers with whatever is loaded and *.updated events fill in the rest. It cites cli: api model.list --standalone returns 503 "Location plugins did not finish activating" #63273 and Plugin activation never completes when the global skills folder resolves to a slow drive — /api/model 503 forever #63130.

With the wait removed, there's no timeout left to configure. If you can, it would help to try #63814 on your Windows setup with --standalone and post the results there, especially whether session.list still fails, since that PR doesn't touch it.

All reactions

Sorry, something went wrong.

Uh oh!

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

@amr-karam amr-karam mentioned this pull request Nov 17, 2026
cli: api model.list --standalone returns 503 "Location plugins did not finish activating" #63273
Closed
@opencodejr opencodejr Bot mentioned this pull request Nov 19, 2026
acp: session/new fails with "Location plugins did not finish activating" on cold start (5s hard-coded wait) #64853
Closed
@perryclarke perryclarke mentioned this pull request Nov 19, 2026
plugins: git plugin install waits forever on a credential prompt in the background service, so no models load #65015
Open
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Uh oh!

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

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

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

1 participant

@amr-karam
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 01402775 — 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.