def add_role(self, uid, role, project_id=None):
        if not project_id:
            db.user_add_role(context.get_admin_context(), uid, role)
            return
        db.user_add_project_role(context.get_admin_context(),
                                 uid, project_id, role)
Does a single optimization pass.
dataset/ETHPy150Open nii-cloud/dodai-compute/nova/auth/dbdriver.py/DbDriver.add_role--crossover with--dataset/ETHPy150Open armon/pypred/pypred/optimizer.py/optimization_pass