Support preview API version of salesforce

Issue #2313 resolved
Valentin Pichavant created an issue

Hello,

In order to adapt the code and test it on a newer version of Salesforce, we do create scratch orgs using the release version set as a preview.

When doing that, the plugin is not working anymore forcing us to use sfdx-cli.

It would be nice when a new version of the salesforce API becomes available as a preview to be supported in the plugin :)

For example, now the release is v56.0, the preview is available in v57.0.

Thanks a lot!

Comments (6)

  1. Scott Wells repo owner

    Hi. The API version itself won’t be bumped until everyone has access to the new platform version. That’s because each platform release, there are backward-incompatible changes in the SOAP APIs used by IC2 to communicate with the Salesforce servers, and switching early can break things for the majority of users who are still on the released version.

    Having said that, IC2 does allow you to specify a scratch org as being against the Preview release:

    and when you select that (within the preview window, of course), the resulting scratch org is in fact for the newer version. You can see that clearly in the generated OST for that project which reflects the newer API version (Winter '23 OST on the left and Spring '23 OST on the right):

    You can then set the API version in your sfdx-project.json, package.xml, and various meta.xml files as appropriate to the newer version and completely work against the newer release except for any brand new features that require explicit enhancement work, e.g., when the new switch statement was introduced. Those enhancements will be available in IC2 the Monday after the new platform release has completed in all orgs, in this case, February 13, 2023.

  2. Scott Wells repo owner

    Resolving as this should already be available as described. If you're seeing specific issues as indicated in your original screenshot, I'm happy to help diagnose those, though I'd strongly recommend that you completely uninstall and reinstall the CLI since the displayed issue is coming directly from the Salesforce CLI and not IC2 itself.

  3. Valentin Pichavant reporter

    Hi Scott,

    Thanks for your answer, I have created an org in preview using sfdx cli, and added it as a connection, the plugin does see that the API version is 57.0:

    But when I try to generate the offline symbol on this one, or push any change, it fails (for instance here the generate offline symbol):

    From what I see in your comment it should work or did I miss something?

    Thanks a lot!

  4. Scott Wells repo owner

    Hi. Yes, that’s unexpected. I’m actively working against multiple preview orgs now as are a number of other IC2 users. Do you mind enabling debug logging for Salesforce DX and reproducing the problem so that I can see more about what might be going on? Also, have you uninstalled/reinstalled the CLI? That’s actually quite an important step as the CLI can get into a weird state where a full uninstall/reinstall is the only solution. It happened to me (again) just two weeks ago and I actively worked with the Salesforce CLI team to try to remedy it in place, but ultimately a full uninstall/reinstall was required to get back into a proper working state.

  5. Valentin Pichavant reporter

    After checking with the team, it seems that the previous version did fix it, thanks!

  6. Log in to comment