Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use new environment variable parser #362

Merged
merged 137 commits into from
Dec 8, 2017

Conversation

DonJayamanne
Copy link

No description provided.

octref and others added 30 commits November 3, 2017 13:11
* 'master' of https://github.com/Microsoft/vscode-python:
  Fixes #56 list all environments (#219)
  Fixes #57 Disable activation on debugging (#220)
  Fixes #26 Do not run linters when linters are disabled (#222)
* upstream/master:
  Fix typo in README.md (#252)
  Disable linter without workspaces (#241)
* FixCodeExecInLinters:
  fix code review comments
* upstream/master:
  Fix linters to make use of the new python code execution framework (#360)
  Update the versioning scheme (#356)
  Make npm happy in regards to line endings (#357)
* master:
  Fix linters to make use of the new python code execution framework (#360)
  Update the versioning scheme (#356)
  Make npm happy in regards to line endings (#357)
* upstream/master:
  Ensure python path is not set if already set in user settings (#369)
  Use 'an' rather than 'a' before vowel words (#373)
* master:
  Ensure python path is not set if already set in user settings (#369)
  Use 'an' rather than 'a' before vowel words (#373)
@DonJayamanne DonJayamanne changed the title WIP - Use new environment variable parser Use new environment variable parser Dec 8, 2017
@DonJayamanne
Copy link
Author

@brettcannon @MikhailArkhipov could one of you please review this PR.
please assign this PR to your self, so that both don't end up reviewing this.
Thanks

@DonJayamanne
Copy link
Author

@brettcannon , never mind will get Mikhail, forgot its friday.

@@ -120,10 +125,10 @@ export class LocalDebugClient extends DebugClient {
proc.on('error', error => {
// If debug server has started, then don't display errors.
// The debug adapter will get this info from the debugger (e.g. ptvsd lib).
if (!this.debugServer && this.debugServer.IsRunning) {
if (!this.debugServer && this.debugServer!.IsRunning) {

Choose a reason for hiding this comment

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

Not sure I understand the syntax. debugServer is undefined and it is also IsRunning? Should it be !this.debugServer || !this.debugServer!.IsRunning ?

Copy link
Author

Choose a reason for hiding this comment

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

👍

@@ -37,7 +37,7 @@ export class EnvironmentVariablesService implements IEnvironmentVariablesService
if (!target) {
return;
}
const pathVariable = this.isWidows ? WINDOWS_PATH_VARIABLE_NAME : NON_WINDOWS_PATH_VARIABLE_NAME;
const pathVariable = this.isWindows ? WINDOWS_PATH_VARIABLE_NAME : NON_WINDOWS_PATH_VARIABLE_NAME;

Choose a reason for hiding this comment

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

Might be worth making a small helper like getPathVeriableName()

Copy link
Author

Choose a reason for hiding this comment

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

Agreed, now i can create the PathUtils class I've always wanted (to translate HOME and other environment varaibels and back)... for prettier displays of paths..

@@ -193,12 +198,32 @@ export class LocalDebugClient extends DebugClient {
this.pyProc = proc;
resolve();
}, error => {
if (!this.debugServer && this.debugServer.IsRunning) {
if (!this.debugServer && this.debugServer!.IsRunning) {

Choose a reason for hiding this comment

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

Also may be worth encapsulating the condition into a small helper function.

Copy link
Author

Choose a reason for hiding this comment

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

👍

@DonJayamanne
Copy link
Author

👍

@DonJayamanne DonJayamanne merged commit 25805cb into microsoft:master Dec 8, 2017
@DonJayamanne DonJayamanne deleted the UseNewEnvVarsParser branch December 12, 2017 21:21
DonJayamanne added a commit that referenced this pull request Dec 14, 2017
* upstream/master:
  Use new environment variable parser (#362)
@lock lock bot locked as resolved and limited conversation to collaborators Jul 31, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants