ApamaCommunity / pysys-vscode-extension

This is a vscode extension for the pysys framwork it enables the use of this testing framework in Visual Studio Code allowing the use of the UI to interact with and create tests for your software projects..
https://cariboujohn.github.io/pysys-vscode-extension/
4 stars 4 forks source link

Make Python/PySys detection more reliable #21

Open rsm31 opened 3 years ago

rsm31 commented 3 years ago

Hey John, here's my attempt to fix an issue (#22) I hit using the plugin with a remote WSL2 Ubuntu 18.04 environment, where it failed to find a Python installation despite there being at least two of them on the path. There were two different problems:

  1. All the Pythons I have print Python x.y.z in response to -V so we probably need to look for ython as well as ersion in the output.
  2. The get("interpreter_path","na") was returning an empty string rather than na. No idea why, but I bodged in a check for that anyway.

It seems to work for me now but given that my knowledge of TypeScript is near-zero and of VS Code extensions even less, I have probably missed the real problem and/or implemented the fix in a horrible way. Hopefully this is some use regardless.

Cheers,

Scott