Error: Unknown User Permission when deploying profiles
When deploying profiles, you might receive the error below for one or more user permissions:
“![ERROR] [Profile <ProfileName>] Unknown user permission <PermissionName>”.
These kinds of errors are standard deployment errors returned by Salesforce and not by Copado. In general, these errors are returned when you try to deploy permissions that don’t exist in the destination organization. There could be two reasons for this:
- The org you are deploying from (source org) contains permissions related to features that don’t exist or have not been enabled in the org you are deploying to (destination org).
- In Copado, when you commit profiles in a user story, the feature branch is created out of the master branch, which is in turn created out of production. Therefore, it is possible that your feature branch might contain permissions related to features that don’t exist or have not been enabled in the destination org but exist in production, from where the feature branch was created.
EditBillingInfo and ManageSandboxes are the user permissions causing the errors.
You can also use a YAML file to avoid committing and replacing these user permissions. For more information on how to build YAML files check out the article Global Find and Replace Rules.
Please note that creating or editing rules and regex in this file is out of the scope of Copado Support. If you would like our Professional Services team to help you with this configuration, contact us at firstname.lastname@example.org.