Skip to content

Why is Pyright authored in TS? #2529

Answered by jakebailey
mheiber asked this question in Q&A
Discussion options

You must be logged in to vote

@erictraut will probably give a more historical answer, but a current main benefit for end-users is that this allows us to ship pyright/Pylance in places that already support JS:

  • VS Code is an Electron app, so we can run python analysis without even having python installed, as you can just reuse the same executable as a node executable by setting an environment variable. This means we can analyze code on remote machines without Python, or on newfangled platforms like macOS arm64 when Python hadn't been compiled there yet, or similar, so long as VS Code is there.
  • VS Code in the browser with Pylance on vscode.dev or github.dev is much the same; we're in the browser which is JS, or you have…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@erictraut
Comment options

Answer selected by mheiber
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants