diff options
Diffstat (limited to 'lib/sqlalchemy/event/base.py')
-rw-r--r-- | lib/sqlalchemy/event/base.py | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/sqlalchemy/event/base.py b/lib/sqlalchemy/event/base.py index c16f6870b..83b34a17f 100644 --- a/lib/sqlalchemy/event/base.py +++ b/lib/sqlalchemy/event/base.py @@ -108,10 +108,12 @@ class _Dispatch(_DispatchCommon[_ET]): """ - # In one ORM edge case, an attribute is added to _Dispatch, - # so __dict__ is used in just that case and potentially others. + # "active_history" is an ORM case we add here. ideally a better + # system would be in place for ad-hoc attributes. __slots__ = "_parent", "_instance_cls", "__dict__", "_empty_listeners" + _active_history: bool + _empty_listener_reg: MutableMapping[ Type[_ET], Dict[str, _EmptyListener[_ET]] ] = weakref.WeakKeyDictionary() |