fix(proxy): route VS Code through selected profile model - #555
Merged
vadimvlasenko merged 1 commit intoSep 18, 2026
Conversation
Collaborator
|
@nadavsinai-philips , could you pls fix CI and we'll proceed with review? |
Collaborator
|
@nadavsinai-philips could you pls rebase? we'll proceed with merge after that |
nadavsinai-philips
force-pushed
the
users/nadav/fix-vscode-profile-model-routing
branch
from
September 18, 2026 13:29
d65947a to
dbf51b3
Compare
vadimvlasenko
added a commit
that referenced
this pull request
Sep 22, 2026
Reconciles with PR #555 (main), which independently fixed VS Code Copilot BYOK to register a profile-pinned model's real gateway id instead of the static catalog's dated one. That fix predates this branch's full rework of the same connector (tenant-catalog capability table replacing the static list entirely), so it conflicted on buildManagedModels/mergeManagedProviders/writeVsCodeLanguageModelsConfig signatures. Resolution: resolveManagedModels(proxyUrl, gatewayKey, profileModel) now does both jobs with one mechanism — resolve every capability-table family against the live tenant catalog as before, then, when a profileModel is set and resolves against that same catalog, narrow the result to just that one entry. This subsumes #555's "wrong id" fix (every entry already carries the tenant's real id) while preserving its "show just the pinned model" behavior, using the general resolver instead of #555's static-list-only prefix/date-suffix heuristic. .gitignore: took main's shape-based `**/*.local.*` rule over this branch's narrower filename-list fix — strictly more general, no Philips scrub involved. Added profileModel-pinning test coverage in vscode.test.ts (new interaction, not covered by either side). Verified: typecheck, full unit (4184) + cli (279) suites, lint, build, license-check all clean — matches this repo's actual CI gate (`npm run ci`) exactly. --no-verify: the pre-commit hook additionally ran the `agent` vitest project (triggered because tests/integration/agent-*.test.ts came in staged from main's own unrelated PR #565/#568) and timed out on two PTY-driven tests (agent-assistant.test.ts, agent-skills.test.ts) waiting on a live Claude Code CLI trust-dialog prompt. Reproduced standalone, unrelated to this merge's changes, pre-existing on main, and not part of the `agent` project being outside `npm run ci`'s scope. Skipped only after confirming with the user. Generated with AI Co-Authored-By: codemie-ai <[email protected]>
vadimvlasenko
added a commit
that referenced
this pull request
Sep 22, 2026
Reconciles with PR #555 (main), which independently fixed VS Code Copilot BYOK to register a profile-pinned model's real gateway id instead of the static catalog's dated one. That fix predates this branch's full rework of the same connector (tenant-catalog capability table replacing the static list entirely), so it conflicted on buildManagedModels/mergeManagedProviders/writeVsCodeLanguageModelsConfig signatures. Resolution: resolveManagedModels(proxyUrl, gatewayKey, profileModel) now does both jobs with one mechanism — resolve every capability-table family against the live tenant catalog as before, then, when a profileModel is set and resolves against that same catalog, narrow the result to just that one entry. This subsumes #555's "wrong id" fix (every entry already carries the tenant's real id) while preserving its "show just the pinned model" behavior, using the general resolver instead of #555's static-list-only prefix/date-suffix heuristic. .gitignore: took main's shape-based `**/*.local.*` rule over this branch's narrower filename-list fix — strictly more general, no Philips scrub involved. Added profileModel-pinning test coverage in vscode.test.ts (new interaction, not covered by either side). Verified: typecheck, full unit (4184) + cli (279) suites, lint, build, license-check all clean — matches this repo's actual CI gate (`npm run ci`) exactly. --no-verify: the pre-commit hook additionally ran the `agent` vitest project (triggered because tests/integration/agent-*.test.ts came in staged from main's own unrelated PR #565/#568) and timed out on two PTY-driven tests (agent-assistant.test.ts, agent-skills.test.ts) waiting on a live Claude Code CLI trust-dialog prompt. Reproduced standalone, unrelated to this merge's changes, pre-existing on main, and not part of the `agent` project being outside `npm run ci`'s scope. Skipped only after confirming with the user. Generated with AI Co-Authored-By: codemie-ai <[email protected]>
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.
Makes proxy connect --vscode and --vscode-insiders register the active profile's model ID when it maps to a supported VS Code capability template. This prevents a provider-qualified CodeMie ID such as openai.gpt-5.6-sol from being overwritten with the incompatible dated catalog ID. Retains the static catalog fallback for profile-less or unrecognized models. Also makes Node types explicit for stable typecheck. Validated by the required hook: lint, 319 focused proxy tests, typecheck, and secret scan.