PipeReaderBlockingIO handle threading ImportError
authorZac Medico <zmedico@gentoo.org>
Fri, 28 Dec 2012 06:30:07 +0000 (22:30 -0800)
committerZac Medico <zmedico@gentoo.org>
Fri, 28 Dec 2012 06:30:07 +0000 (22:30 -0800)
pym/portage/tests/process/test_PopenProcessBlockingIO.py
pym/portage/util/_async/PipeReaderBlockingIO.py

index 9cdad326d7d4063b34fa8dfbc0aad8b4a390a6bd..9ee291a39efeddf79a6c1eef40e0d57457306a69 100644 (file)
@@ -6,6 +6,7 @@ import subprocess
 try:
        import threading
 except ImportError:
+       # dummy_threading will not suffice
        threading = None
 
 from portage import os
index 8ce2ec51bce73f465d2bf5bf089cf970830ae6ed..b06adf6edb9943eee6f68328285c41d8c12a07a5 100644 (file)
@@ -1,7 +1,11 @@
 # Copyright 2012 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
 
-import threading
+try:
+       import threading
+except ImportError:
+       # dummy_threading will not suffice
+       threading = None
 
 from portage import os
 from _emerge.AbstractPollTask import AbstractPollTask