do we really need to run this in the scope of rails? only class_attributes require rails here afaik