diff --git a/opaque_keys/edx/django/models.py b/opaque_keys/edx/django/models.py
index <HASH>..<HASH> 100644
--- a/opaque_keys/edx/django/models.py
+++ b/opaque_keys/edx/django/models.py
@@ -105,7 +105,7 @@ class OpaqueKeyField(CreatorMixin, CharField):
             return None
 
         error_message = f"{value} is not an instance of str or {self.KEY_CLASS}"
-        assert isinstance(value, (str,) if self.KEY_CLASS is None else (str, self.KEY_CLASS), error_message)
+        assert isinstance(value, (str,) if self.KEY_CLASS is None else (str, self.KEY_CLASS)), error_message
         if value == '':
             # handle empty string for models being created w/o fields populated
             return None
chore: pylint balks at concatenating None to type in isistance() arg 

 Move improperly placed parenthesis in modified is instance call