Merge "Fix _validate_switch_role throwing incorrect error message"