Serhiy Storchaka added the comment: See issue27362 for more general approach. ---------- _______________________________________ Python tracker <report at bugs.python.org> <http://bugs.python.org/issue20774> _______________________________________