Skip to content

fix(local-model): show download preparation immediately - #386

Merged
Angnuo (angnuoli) merged 3 commits into
microsofthackathons:mainfrom
angnuoli:codex/local-model-immediate-download-dialog
Nov 16, 2026
Merged

Angnuo (angnuoli) merged 3 commits into
microsofthackathons:mainfrom
angnuoli:codex/local-model-immediate-download-dialog

Conversation

@angnuoli

@angnuoli Angnuo (angnuoli) commented Nov 16, 2026 •

Copy link
Copy Markdown
Collaborator

Description

Clicking Download for a local model previously left the catalog showing "Switching" while runtime installation and provider discovery completed. Open the progress dialog immediately and show the actual runtime-installation and download-check stages.

For an explicitly selected managed model, proceed from a validated provider installation receipt to targeted model preparation instead of running an additional full provider discovery scan. The captured first-use trace spent 11.8 seconds in that scan; total cold-install latency has not been remeasured.

Related Issue

None.

Changes

  • Show preparation progress before runtime installation or metadata requests finish, with Chinese and English stage labels.
  • Avoid duplicate state refreshes and full provider discovery on the exact managed-model path. Preserve generic installation verification, version checks, runtime-error handling, capability consent, and target-specific setup validation.
  • Normalize eleven pre-existing npm registry-related files with Prettier/Ruff (formatting only), and update two stale tests to check the current explicit-source policy and registry-wrapped build timing summary. These upstream failures blocked the CI gates before this change.
  • Prevent a late metadata response from starting a download after the dialog is dismissed, and cover pending installation, recovery, and selected-model failures.

Type of Change

  • Bug fix (non-breaking change that fixes an issue)

Testing

  • 147 focused main-process tests and 181 renderer/settings/model-picker tests passed locally.
  • Main-process TypeScript, test TypeScript, Vue type checks, and changed-file ESLint checks passed.
  • Full desktop test suite on the upstream-based branch: 2,678 Vitest tests passed, 53 skipped; runtime/resource Node tests also passed.
  • Full renderer test suite on the upstream-based branch: 1,156 tests passed, 2 skipped.
  • Desktop and renderer production build
  • Repository lint and formatting checks (existing lint and bundle-size warnings remain; no errors)
  • Full Python test suite in GitHub CI (583 tests, 6 skipped). The local full run had one Windows directory-rename access error; the affected 18-test module passed on rerun.
  • Ruff 0.16.3 lint and format checks
  • Manual cold-install timing repeated

Checklist

  • I have performed a self-review of my code.
  • I have added regression tests for the changed behavior.
  • Necessary implementation comments are included.
  • Documentation changes are not required for this UI and preparation-flow correction.

@angnuoli
Angnuo (angnuoli) merged commit b76640c into microsofthackathons:main Nov 16, 2026
4 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