Skip to content

fix(voice): synchronize local model install state - #2763

Merged
wgqqqqq merged 2 commits into
GCWing:1.0.0-explorefrom
wgqqqqq:wgq/fix-voice-model-install-state
Sep 3, 2026
Merged

fix(voice): synchronize local model install state#2763
wgqqqqq merged 2 commits into
GCWing:1.0.0-explorefrom
wgqqqqq:wgq/fix-voice-model-install-state

Conversation

@wgqqqqq

@wgqqqqq wgqqqqq commented Sep 3, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • bind composer model capability state to the currently selected local model and ignore stale async status responses
  • report post-download processing as verifying instead of leaving the UI at downloading 100%
  • write and validate the install record inside staging before publishing the final model directory
  • add regressions for model-selection races and staged install publication

Root cause

The model payload was moved into its final directory before the install record and required-file hashes were finished. speech_list_models could therefore report the model as installed and enable Use while the active download task still emitted downloading at 100%. The composer also retained an unkeyed capability snapshot, so a response for the previous model could overwrite the selected model state.

Verification

  • cargo test -p bitfun-services-integrations --no-default-features --features speech --lib speech:: (6 passed)
  • pnpm --dir src/web-ui run test:run src/flow_chat/components/voice/useComposerVoiceInput.test.tsx (7 passed)
  • pnpm run check:web
  • git diff --check

Remote scenarios

Exercised on the local Desktop/service path. Remote Workspace, Remote Control, Peer Device Mode, and Detached Dispatch were not runtime-tested; the service-side state transition remains platform-neutral and does not change the transport contract.

AI-assisted change; fully tested with the focused checks above.

@wgqqqqq
wgqqqqq force-pushed the wgq/fix-voice-model-install-state branch from ff016b8 to 410dda9 Compare September 3, 2026 07:57
@wgqqqqq

wgqqqqq commented Sep 3, 2026

Copy link
Copy Markdown
Collaborator Author

Fixed the macOS CI failure in bb6e7a539. The test created lowercase and uppercase spellings of the same UUID path; on the default case-insensitive APFS volume those names alias the same directory, so deleting the valid stale staging directory also made the uppercase assertion disappear. The uppercase non-canonical fixture now uses a distinct UUID, preserving the cleanup-policy assertion across case-sensitive and case-insensitive filesystems.

Verified on macOS with:
cargo test -p bitfun-desktop packaged_frontend_cache_removes_only_stale_transaction_directories --lib

@wgqqqqq
wgqqqqq merged commit 68764db into GCWing:1.0.0-explore Sep 3, 2026
12 checks passed
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