I have the account and contact object metadata files with the following sharing types:





When converting and deploying the source to a sandbox, I get the following deploy error:

Error deployablesource/objects/Contact.object Contact ReadWrite is not a valid sharing model for Contact when Account sharing model is Private

But why?

The sandbox and scratch org used to develop are on Summer '19.


1 Answer 1


Try to deploy the two sharing settings separately, with Account being first. I had a similar problem, and it turned out that a standard object that had no parent (Asset) was set to 'Controlled by Parent' in OWD settings.

If this does not work, manually edit the OWD settings for the target org. This incidentally will be blocking deployment of all changes to the said object, not just those related to sharing model.

And funny enough, nothing stops you from selecting this option...

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .