diff options
author | jason kirtland <jek@discorporate.us> | 2013-07-03 11:01:53 +0200 |
---|---|---|
committer | jason kirtland <jek@discorporate.us> | 2013-07-03 11:01:53 +0200 |
commit | b66e4e9acf6017b3af20fc56666461f01fd4e003 (patch) | |
tree | b2cf14bb58d98f806097e3b48c5feaf0bfe9798d /CHANGES | |
parent | 60fc2947f0b208299c8dd7125431ba70d3b57e04 (diff) | |
download | blinker-b66e4e9acf6017b3af20fc56666461f01fd4e003.tar.gz |
blinker.signal() and blinker.Namespace no longer use weak references.
In the original implementation, I was uneasy about releasing a library
that held an unbounded, module-level cache, so it was built using a
weak value mapping. In practice, users making tons of signals are
using Signal() directly, and the weak referencing violates the
principle of least surprise in code like `signal('foo').connect(...)`.
Previous code is available as WeakNamespace for the time being. The
implementation is trivial and will likely be dropped in the future
unless use cases are voiced.
Diffstat (limited to 'CHANGES')
-rw-r--r-- | CHANGES | 8 |
1 files changed, 7 insertions, 1 deletions
@@ -6,7 +6,13 @@ Blinker Changelog Version 1.3 ----------- -Unreleased +- The global signal stash behind blinker.signal() is now backed by a + regular name-to-Signal dictionary. Previously, weak references were + held in the mapping and ephermal usage in code like + ``signal('foo').connect(...)`` could have surprising program behavior + depending on import order of modules. +- blinker.Namespace is now built on a regular dict. Use + blinker.WeakNamespace for the older, weak-referencing behavior. Version 1.2 |