Skip to content

Publish pyright-typeserver to npm - #11713

Merged
Rich Chiodo (rchiodo) merged 1 commit into
microsoft:mainfrom
rchiodo:rchiodo-publish-typeserver-package-1cf
Sep 3, 2026
Merged

Rich Chiodo (rchiodo) merged 1 commit into
microsoft:mainfrom
rchiodo:rchiodo-publish-typeserver-package-1cf

Conversation

@rchiodo

@rchiodo Rich Chiodo (rchiodo) commented Sep 3, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

  • pack pyright-typeserver alongside pyright in the npm release artifact
  • validate aligned release versions and the pyright-typeserver executable
  • recover both tarballs for npm-only flows and attach both to draft GitHub releases
  • submit both packages through the existing ESRP npm folder publication
  • preserve npmOnly, npmValidateOnly, and registryValidationOnly behavior

Resolves #11712

@bschnurr

Copy link
Copy Markdown
Member

🔒 Automated review in progress — Bill Schnurr (@bschnurr) is auto-reviewing this PR.

@rchiodo
Rich Chiodo (rchiodo) merged commit c773932 into microsoft:main Sep 3, 2026
7 checks passed
node -e "const actual=require('./node_modules/pyright/package.json').version; const expected=process.env.RELEASE_TAG; if(expected && actual!==expected){console.error('Expected package version '+expected+', got '+actual); process.exit(1)}"
yarn add --dev $(Pipeline.Workspace)/$(ARTIFACT_NAME_PACKAGE)/$(PACKAGE_NAME) $(Pipeline.Workspace)/$(ARTIFACT_NAME_PACKAGE)/$(TYPESERVER_PACKAGE_NAME)
node -e "const pyright=require('./node_modules/pyright/package.json').version; const typeserver=require('./node_modules/pyright-typeserver/package.json').version; const expected=process.env.RELEASE_TAG; if(pyright!==typeserver){console.error('Package versions do not match: pyright '+pyright+', pyright-typeserver '+typeserver); process.exit(1)} if(expected && pyright!==expected){console.error('Expected package version '+expected+', got '+pyright); process.exit(1)}"
test -x node_modules/.bin/pyright-typeserver

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Warning · Non-blocking recommendation

test -x verifies only that the generated shim has its executable bit; it can still pass when the shim references a missing or unloadable bundle. Add a bounded smoke test that invokes the installed pyright-typeserver executable and verifies it starts successfully.

@bschnurr

Copy link
Copy Markdown
Member

Result: ⚠️ partially-verified

Verification details

Verification: Isolated verification observed failures that were not classified as caused by this PR: Source executable-mode assertion. The relevant tests could not be fully run in the isolated environment; this review is not fully verified.

Summary: Static release wiring passed: package versions align at 1.1.413, the launcher exists, and all seven artifact references are present. The PR adds pipeline validation for aligned versions and the installed executable. Archive creation and installation could not run because the image lacks pnpm, npm, and Corepack. Confidence is therefore limited to configuration-level verification.

Test runs: 1 passed, 1 failed, 4 not run

  • ⚠️ Not run | Repository and test discovery | git status --short && git --no-pager diff --name-status HEAD^ HEAD && git --no-pager diff --stat HEAD^ HEAD && printf '\nPackage scripts and dependency state:\n' && node -e "for (const p of ['package.json','packages/pyright/package.json','packages/pyright-typeserver/package.json']) { const j=require('./'+p); console.log(p, JSON.stringify({name:j.name,version:j.version,scripts:j.scripts,bin:j.bin,files:j.files},null,2)); }" && if [ -d node_modules ] && [ -d packages/pyright/node_modules ] && [ -d packages/pyright-typeserver/node_modules ]; then echo 'DEPENDENCIES_PRESENT=yes'; else echo 'DEPENDENCIES_PRESENT=no'; fi && printf '\nChanged test-like files:\n' && git --no-pager diff --name-only HEAD^ HEAD | grep -Ei '(^|/)(test|tests|tests)/|.(test|spec).' || true
  • ⚠️ Not run | Pack pyright-typeserver with pnpm | pnpm pack --pack-destination .
  • ⚠️ Not run | Offline dependency bootstrap | corepack pnpm install --offline --frozen-lockfile
  • ⚠️ Not run | Pack pyright-typeserver with npm | npm pack --pack-destination .
  • ❌ Failed | unrelated to this PR | Source executable-mode assertion | python3 release-wiring assertions including os.access(bin_target, os.X_OK)
  • ✅ Passed | Release artifact wiring consistency | python3 release-wiring assertions for versions, launcher, and pipeline references
⚠️ Repository and test discovery diagnostic output
fatal: not a git repository (or any parent up to mount point /)
⚠️ Pack pyright-typeserver with pnpm diagnostic output
/bin/sh: 1: pnpm: not found
⚠️ Offline dependency bootstrap diagnostic output
/bin/sh: 1: corepack: not found
⚠️ Pack pyright-typeserver with npm diagnostic output
/bin/sh: 1: npm: not found
❌ Source executable-mode assertion diagnostic output
AssertionError: packages/pyright-typeserver/pyright-typeserver.js is not executable

@bschnurr Bill Schnurr (bschnurr) added the review-auto:approved Automated review: no blocking findings (approval posted). label Sep 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

review-auto:approved Automated review: no blocking findings (approval posted).

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Publish the documented pyright-typeserver package to npm

2 participants