Cleanup/scopes

Only merge this in if we are out of the clear with 3.5.1.