function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Brian11Brian11 

Errors when packaging a new version

This is the error that I currently get

ERROR:  Target object does not have a valid lookup or master-detail reference to the parent object.

Is there a way to get a much more detail error?
SandhyaSandhya (Salesforce Developers) 
Hi,

Check if the user which is being used to do the deployment has the "Marketing User" checkbox set to true. Which solved the issue for some.

https://developer.salesforce.com/forums/?id=9060G000000MSGLQA4

Please mark it as solved if my reply was helpful, it will make it available
for others as a proper solution.

Best Regards,
​Sandhya
 
Brian11Brian11
Hi Sandhya,

That didnt work for me.
It turns out the problem was that I created a custom button action on the Contact Object to create Tax record. Salesforce doesnt like that. Not sure what the solution is for that. Do you have any thought?

I had to remove the action and then the new version packaged was successful.

Details:
Created a Contact Action 
action type: Action create record
target object: taxes


 
Roshan ChauhanRoshan Chauhan
Use <targetParentField>What</targetParentField>