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

System Environment Check #902

Closed
ntotten opened this issue Jan 25, 2019 · 7 comments
Closed

System Environment Check #902

ntotten opened this issue Jan 25, 2019 · 7 comments
Labels
area:setup Spec Details of a feature for feedback type:feedback Feedback for new features

Comments

@ntotten
Copy link
Contributor

ntotten commented Jan 25, 2019

Currently, when a user tries to run the Salesforce extensions and is missing one of the prerequisites on their computer we simply show an error message. This experience is causing confusion to developers and we should do a better job informing them of system setup problems.

The proposed solution is for the extensions to perform a "system" check in the background after the extension is activated. Any feature of an extension that requires a system dependency will be activated only after the system checks succeeds.

In the event the system check fails we will show the user a custom webview providing them with specific setup instructions tailored to their operating system. The webview will have a button that allows the user to rerun the system check. If the test passes then the extension will fully activate, if it fails the webview will be updated to show the reason why it failed.

We can use this method to check for things like:

  • If JRE is installed
  • Is the version of JRE supported
  • Is JRE correctly configured in the path
  • Is the Salesforce CLI installed and correctly configured

This experience will dramatically help new users successfully install and use the extensions

WID-123455

@toanshulverma
Copy link

How about allowing these settings to be configured within settings file. Instead of current way, where it assumes that the installation path are added to environment settings?

For instance, if developer is not able to update PATH within environment settings, there is currently no way for SFDX extensions to use a custom path. If we can specify custom path in settings, then this could work.

@smaddox-sf smaddox-sf added the Spec Details of a feature for feedback label Jun 2, 2020
@chexxor
Copy link

chexxor commented Aug 24, 2020

Would you accept a PR which adds a means of specifying the absolute path to the sfdx executable using a VS Code setting and/or an environment variable?

@chexxor
Copy link

chexxor commented Aug 25, 2020

Looks like we would need to change sfdxCommandBuilder to get the 'sfdx' string from a configuration variable.

I imagine some people might want to set this value from an environment variable in the terminal which executes the sfdx commands, so we might want to abstract it out to a module of its own. I don't know if maintainers would prefer to avoid env vars, though, or would like to avoid a configuration class for this module. Looks like that "salesforcedx-utils-vscode" module doesn't have a configuration module yet, so we could make one.

@smaddox-sf
Copy link
Contributor

Hi @chexxor - Your proposed PR doesn't seem to address creating a system environment check (which is the topic of this issue). As for specifying the path, are you referring to the path to the CLI? We have an existing environment variable for that - https://developer.salesforce.com/tools/vscode/en/troubleshooting/#set-salesforce-cli-path-windows

@chexxor
Copy link

chexxor commented Aug 25, 2020

Hi @smaddox-sf, thanks for the link!

This was the most relevant issue I could find about configuring the PATH environment variable. I was interested in configuring the PATH within this VS Code extension to ensure it uses a specific version of sfdx, leaving me free to use a different sfdx in different situations. This extension (or one in the greater umbrella project) already has a similar configuration variable named salesforcedx-vscode-apex for defining the location of the JVM, which also has a dedicated environment which you could use to accomplish the same thing.

Sorry to accidentally hijack this issue -- let me know if you're like me to create a different one for this!

@chexxor
Copy link

chexxor commented Aug 25, 2020

I created a new issue @smaddox-sf: #2446

I hope this doesn't side-track the original topic of the issue. Feel free to delete my comments to clear up this issue! Let me know if you need help!

@diyer
Copy link
Collaborator

diyer commented Feb 26, 2024

Closing this one as we have some system requirements checks in place when installing extensions. Please file a new bug for new issues seen.
cc: @AnanyaJha

@diyer diyer closed this as completed Feb 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:setup Spec Details of a feature for feedback type:feedback Feedback for new features
Projects
None yet
Development

No branches or pull requests

5 participants