This issue came out as part of the result of the selectively undeploying resources bug fix (#823).
Part of that fix included updating the resource processing in %Reload to first process document resources by depth order and then non-document resources after. That similar resource processing order should be changed for all lifecycle phases that use resource processing in this manner.