Hey all! I have a fix open for pulumi/pulumi issue 23817 (deletedWith resources silently getting orphaned when their target is replaced):
https://github.com/pulumi/pulumi/pull/23818. It follows the same pattern replaceWith already used in the step generator and includes a test suite for validation. It’s been open for about a month, just brought it up to date with master and all checks are green. Could an engine maintainer take a look when someone has time? Happy to answer any questions or rework anything.