actually fix the special case

This commit is contained in:
Benedikt Bartscher 2024-12-06 11:16:53 +01:00
parent 79f84fb0ae
commit b2d533a765
No known key found for this signature in database

View File

@ -1332,9 +1332,7 @@ class BaseState(Base, ABC, extra=pydantic.Extra.allow):
return
# For now, handle router_data updates as a special case if using redis.
# TODO: it would be better to check for the state manager instead of redis url
# however get_state_manager causes a circular import
if name == constants.ROUTER_DATA and get_config().redis_url:
if name == constants.ROUTER_DATA and self.parent_state is None:
self.dirty_vars.add(name)
self._mark_dirty()