Add assert to catch incorrect attributes