Fix UserNotFound exception for expiring groups
Without this patch, if this exception is reached, it won't be properly formed and will result in a log message like this: Failed to insert replacement values into translated message Could not find user: %(user_id)s. (Original: 'Could not find user: %(user_id)s.'): 'user_id' This patch adds the right parameters to ensure the exception properly logs the user ID and the translation doesn't fail. Change-Id: I3229d9a237633cda8f6a25f396a75b8310757d9d
This commit is contained in:
parent
241fa9fe12
commit
2d26a87229
@ -230,7 +230,7 @@ class ShadowUsers(base.ShadowUsersDriverBase):
|
||||
if not user:
|
||||
# Note(knikolla): This shouldn't really ever happen, since
|
||||
# this requires the user to already be logged in.
|
||||
raise exception.UserNotFound()
|
||||
raise exception.UserNotFound(user_id=user_id)
|
||||
return user
|
||||
|
||||
with sql.session_for_write() as session:
|
||||
|
Loading…
x
Reference in New Issue
Block a user