2

From the VSCode console, I've created a new project with the command: sfdx force:project:create -n Integration --manifest

I then authorize a sandbox org with the command: sfdx force:auth:web:login -r https://MySandboxURL -a Integration

After being prompted to close my browser, in VSCode I expand the manifest folder and right-click on the package.xml file. This is where the problem is... I don't see any SFDX related options in the context menu that appears. There's no Retrieve or Deploy Source in Manifest to from or to Org options.

I've tried repeating all of the steps and I've tried reinstalling all of the Salesforce extensions in VSCode without any luck. What am I missing? How can I pull source from this sandbox?

3

Activation event for Salesforce official extension is it looks for the file sfdx-project.json file in the workspace.Hence make sure you have the sfdx-project.json in the project workspace root folder.

Also make sure you have .sfdx folder and also have sfdx-config.json file with defaultusername set .

Also try to reload the project using the reload command in command Palette.If issue still persists feel free to post what your project structure looks like.

Also yes I created another extension because official extension has few issues that they are trying to figure still

1.Performance issues for saving single files .You can easily compare that what I have today is atleast 2X faster than what you get from official extension .

This is because they use Metadata api even for single file deploy which as per salesforce has performance issues and they plan to fix it in upcoming release .

2.The package.xml generation is easier using change sets or unmanaged package container and official extension does not offer good GUI to generate them .

3.Official extension uses apex lang server for auto completion that almost consumes lot of my CPU .I would rather not have autocomplete than an extension trying to consume my whole CPU .

4.Official salesforce extension does not manage conflict with server for Non scratch orgs like sandboxes .Its in their roadmap .

5.Salesforce recommends using the new source format which i too recommend however if you are finding issues with that format the extension i have supports both DX typed source format and traditional source format .

Overall the idea of me building an extension was not to replace salesforce official extension instead supplement it with some missing capabilities till salesforce figures all of them .

2

I'm pretty certain this is simply a feature that doesn't exist yet. I would recommend Mohith Shrivastava's extension that adds some of these missing features (plus cool things like deploy-on-save). You can find this directly from VS Code's extension search or clicking on the link in the README file.

  • 1
    It does exist in beta. – Jayant Das Feb 17 at 19:09
  • @JayantDas I'm not referring to the CLI feature, but rather the Salesforce Extensions bundle. Yes, you can deploy against any org (and it works quite well), but there's no GUI for it in the official bundle, which is the purpose of the question. – sfdcfox Feb 17 at 19:12
  • 1
    Actually there is a GUI available, refer this. I have been using this of late for my DE orgs. – Jayant Das Feb 17 at 19:13
  • 2
    @JayantDas Huh. I actually don't have the options on my package.xml, either. I'll have to dig deeper in to this, although I still say Mohith's extension has been a massive time saver, since I don't even have to remember to deploy. – sfdcfox Feb 17 at 19:49
  • 1
    The odd thing is, these context menu links showed up previously for me. Also missing is the context menu options to retrieve and deploy when I right-click on individual classes or other files within my project. I GREATLY miss being able to retrieve and deploy specific files this way. – SF1Dev Feb 17 at 21:48
1

This issue was happening because my project was missing a properly configured sfdx-config.json file in the .sfdx folder.

If you successfully follow the documentation for creating and configuring your project here: https://forcedotcom.github.io/salesforcedx-vscode/articles/user-guide/org-development-model then the sfdx-config.json file should be generated right after you perform the "SFDX: Authorize an Org" step detailed in that documentation.

In my case though, executing that step seemed to work however upon closer examination it did not completely work as the Output window in VSCode shows the error "ERROR: grant type not supported."

I believe this to be due to a configuration issue in my org since I have found that in other Sandbox orgs I have access to, this whole process works great.

Even in an org in which I get the "ERROR: grant type not supported." error, if I manually create the sfdx-config.json file in the .sfdx folder, the SFDX: Retrieve Source in Manifest from Org and the SFDX: Deploy Source in Manifest to Org options reappear in the Explorer's right-click context menus, they just don't actually function due to the grant type configuration issue in my org.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.