Repository navigation
fix(app): splash time-out with a Reload button, and no requests for an empty directory (Refs #1534) - #2205
Merged
Conversation
…n empty directory Two client-side gaps from #1534, both independent of the /api/reference 500. - adopt() splash: the overlay faded only on app-ready, so a stalled chat app left "Getting Amico ready..." on screen forever. After 30 s without app-ready the overlay now says "Amico is taking longer than expected to start." and shows a Reload button. Reload reloads the iframe, resets the text and arms the time-out again. A late app-ready still fades the splash and hides the message. - child-store: child("") and peek("") logged "No directory provided" and carried on, turning the instance queries on and asking the server for directory=/. An empty directory now gets a store but no bootstrap, no instance queries and no MCP enable. Tests first: 3 splash tests and 2 child-store tests failed before the change. The 500 itself does not reproduce on engine 1.18.30, so this does not close the issue. Refs #1534 Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Contributor
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Related Issue
Refs #1534 (the
/api/reference500 itself does not reproduce on the current engine, so this PR does not close the issue)Description
Two client-side gaps from #1534. Both are independent of the 500.
1. Splash time-out (
extension/src/chat_panel.ts). Theadopt()overlay faded only whenapp-readyarrived. If the chat app stalled, the user saw "Getting Amico ready…" forever. After 30 s withoutapp-readythe overlay now shows "Amico is taking longer than expected to start." and a Reload button. Reload reloads the iframe, resets the text and arms the time-out again. A lateapp-readystill fades the splash and hides the message.2. Directory guard (
overlay/.../global-sync/child-store.ts).child("")andpeek("")logged "No directory provided" and carried on. They turned the instance queries on and asked the server fordirectory=/. An empty directory now gets a store but no bootstrap, no instance queries and no MCP enable. A real directory behaves as before.Changes:
chat_panel.ts,child-store.ts, two new test files, and the overlay manifest (refresh_manifest.mjs).Type of Change
Verification
pnpm -r run buildexits 0pnpm -r run testexits 0 (orpnpm -r run typecheckif tests aren't relevant)pnpm -r run typecheckpasses. The new splash tests (test/chat_panel_splash_timeout.test.ts) run the overlay's own script against a small fake DOM under fake timers. 3 of the 7 failed before the change, and all pass now. The new child-store tests (3) ran with Bun in WSL: 2 failed before the change and all pass now. The 5 upstreamchild-store.test.tstests also pass.drift_gate.mjspasses.Manual Testing Notes
auth.json, and with a server password and Basic auth./api/referencereturned 200 withdata: []for no directory,directory=/, a real directory and a missing directory. The issue is from September (extension 0.3.7), and the engine has been rebased since. I did not test on Windows or macOS. The reporter's server log, platform and engine version are still needed.packages/opencode.child-store-empty-directory.test.tsruns withbun test --conditions=solid --preload ./happydom.tsin the app package. I ran it by hand.iframe.srcto its own value reloads the iframe in browsers, but I did not check it in the webview.app-readystill works.🤖 Generated with Claude Code