Make sure that Context traps and flags dictionaries have values 0 and 1
(as documented) rather than True and False.
This commit is contained in:
parent
8aca9d032e
commit
71f3b85497
|
@ -3613,10 +3613,10 @@ class Context(object):
|
||||||
if _ignored_flags is None:
|
if _ignored_flags is None:
|
||||||
_ignored_flags = []
|
_ignored_flags = []
|
||||||
if not isinstance(flags, dict):
|
if not isinstance(flags, dict):
|
||||||
flags = dict([(s,s in flags) for s in _signals])
|
flags = dict([(s, int(s in flags)) for s in _signals])
|
||||||
del s
|
del s
|
||||||
if traps is not None and not isinstance(traps, dict):
|
if traps is not None and not isinstance(traps, dict):
|
||||||
traps = dict([(s,s in traps) for s in _signals])
|
traps = dict([(s, int(s in traps)) for s in _signals])
|
||||||
del s
|
del s
|
||||||
for name, val in locals().items():
|
for name, val in locals().items():
|
||||||
if val is None:
|
if val is None:
|
||||||
|
|
Loading…
Reference in New Issue