Rebased and these fixes were needed to build + pass tests locally again