Skip to content

Handle denied engine preference storage - #330

Open
dajiaohuang wants to merge 1 commit into
Anil-matcha:mainfrom
dajiaohuang:fix/engine-preference-storage-denied
Open

dajiaohuang wants to merge 1 commit into
Anil-matcha:mainfrom
dajiaohuang:fix/engine-preference-storage-denied

Conversation

@dajiaohuang

@dajiaohuang dajiaohuang commented Nov 14, 2026 •

Copy link
Copy Markdown

When the browser denies access to the localStorage property, the engine preference cache's default argument throws before its error handler runs. Chat and engine settings read this cache while rendering, and cache writes can similarly interrupt new-thread handling. Resolve the default storage inside the existing error handlers, retaining explicit injected storage and null behavior.

Validation: the engine selection Node suite reproduced the throwing getter failure before the fix and passed all nine tests afterward, including normal injected storage; focused ESLint and git diff --check passed. Independent exact-head helper review also checked explicit null, injected storage and operation failures. The actual EngineSettings component rendered and completed its synthetic loading state in headless Chrome with a throwing storage getter and a normal-storage control, with mocked APIs. Actual browser policy, mounted chat, desktop and CI were not tested.

@dajiaohuang
dajiaohuang marked this pull request as ready for review November 14, 2026 11:01
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.

1 participant