I have an unlocked package which deploy succesfully to scratch org or empty dev edition org.

The command is sfdx force:package:install --wait 10 --publishwait 10 --package ${packageName} -k ${packagePassword} -r -u ${sandboxOrgName}

However, if I deploy it to a sandbox org (which contains same meta-data as production), the deploying process will error and complain on some Apex compile failure

Those apex classes are not part of my package, but already exist in the org and compiling issue do exist (such as column missing in the test class, function parameter inconsistence).

It is good to be notified for these issues, but I wonder why unlocked package deployment checks all existing Apex status? Is it possible to passes by so the deployment can go?


It seems that this is, unfortunately, how it is now. As a walk around, I need to convert to meta-data api and deploy.

There is a thread discussing it: https://success.salesforce.com/_ui/core/chatter/groups/GroupProfilePage?g=0F93A000000Lg5U&fId=0D53A00004DOBuf

| improve this answer | |

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.