microsoft / microsoft/WinAppVSCE

Pin the bundled winappcli version (or detect version skew) instead of always downloading `latest`

Open
#250 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
TypeScript
Stars
13
Forks
3
Avg merge
6d 1h
Merged PRs (30d)
11

Description

Problem

scripts/download-cli.ps1 defaults to downloading the latest winappcli release, but the extension's command surface is written against a specific CLI version. Today that means the extension ships a 0.6.x CLI behind a UI designed for ~0.3.1 — the version skew is invisible and unbounded in both directions.

The reverse direction is the dangerous one: as we add flags for newer CLI features, an extension build paired with an older CLI will emit flags that don't exist and fail at runtime with a raw CLI parse error.

Why it matters now

The winapp run project-mode work adds --project, --configuration, --arch, --framework, --runtime, --property, --no-build, and --no-restore — all of which are 0.6.x-only. If a user's bundled CLI predates them, project mode fails with an unhelpful error and no indication that a version mismatch is the cause.

Options

  • Pin the tag in download-cli.ps1 to the version the extension was developed and tested against, and bump it deliberately alongside UI changes. npm run download-cli:latest stays available for local testing.
  • Probe winapp --version once at activation and degrade the UI (hide project-mode entries, disable new options) when the CLI is older than required — more forgiving for users who point the extension at their own CLI build, but more machinery.
  • Possibly both: pin for the shipped default, probe as a safety net.

Acceptance

Either the bundled CLI version is deterministic for a given extension version, or the extension detects a too-old CLI and reports it as a version mismatch rather than surfacing a raw argument-parsing failure.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with scripts/download-cli.ps1 and the extension activation path; compare the bundled download behavior with the CLI version used by the command surface. The issue notes that npm run download-cli:latest remains for local testing. Done when a shipped extension has a deterministic compatible CLI, or reports a clear version mismatch before unsupported arguments fail.

Written by the indexing model from the issue text.

Assessment

Tech stack
powershell, typescript, vscode
Domain
cli, devtools
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.