API Version Considerations in Community Deployments

We just went through a deployment of a big update to Communities. There was some heartburn prior to the launch that it would fail because our prior environment was a preview sandbox and thus on a higher API version than prod. Documentation says "You can’t deploy to a target org that’s using an earlier release version."

This is one that was challenging since there is very little information out there, so I hope this helps someone.

We tested this by deploying from a higher sandbox to a lower one and it went fine. There were no errors or warnings. 

In the end we found that this a problem only when (1) deploying from a preview sandbox to a production org on the lower version, and (2) when the Site.com was included in the deployment. When the Site.com is included, you get a deployment error:

 Sorry, your target org is running on an earlier version of Salesforce and can't accept the current file. Please wait for your target org to be updated and try again.

We also received this error on the Network:

 Image optimization is available only for sites that use Salesforce's CDN for Digital Experiences.

This one is also related to the version as the CDN is a feature of Winter '24.

The solution to this is very easy -- don't deploy the Site.com and the Network. In most cases, those will pre-exist in your target org and will not have changed. If they need to be deployed, you will need to find a workaround to push them from an org on the lower version.


Popular posts from this blog

Setting a DateTime to a Weekday in a Formula

"Disjunctions not supported" - Why Custom Metadata and Flow Don't Mix

Update Knowledge Articles in Bulk