Skip to content

Commit 1f814a4

Browse files
committed
Explicitly raise an error if a component view's property can't be set.
1 parent ef7953f commit 1f814a4

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

django_unicorn/components.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -542,10 +542,8 @@ def _set_property(self, name, value):
542542

543543
if hasattr(self, updated_function_name):
544544
getattr(self, updated_function_name)(value)
545-
except AttributeError:
546-
logger.error(
547-
f"'{name}' attribute on '{self.component_name}' component could not be set. Is it a @property without a setter?"
548-
)
545+
except AttributeError as e:
546+
raise
549547

550548
@timed
551549
def _methods(self) -> Dict[str, Callable]:

0 commit comments

Comments
 (0)