I would like the parent to rotate and translate with the child but scale the parent independently
If your overall goal is to have the child translate and rotate with its parent but scale independently, then one option is to use a Child Of constraint instead of parenting. This solution does not require any Python scripting.

Clear any parent the &quot;child&quot; object may already have with Alt+P.
Add the Child Of constraint. Once you assign the &quot;parent&quot; object, you can choose which components of its transform are inherited. In your specific case, you'll want to disable all three scale axes.