From bdfb21f0171ffa175be5414b192e9b88f7775d04 Mon Sep 17 00:00:00 2001 From: Daniel Nephin Date: Tue, 15 Sep 2015 20:46:22 -0400 Subject: [PATCH] Fixes #189 - stacktrace when ctrl-c stops logs Signed-off-by: Daniel Nephin --- compose/cli/multiplexer.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/compose/cli/multiplexer.py b/compose/cli/multiplexer.py index b502c351b..4c73c6cdc 100644 --- a/compose/cli/multiplexer.py +++ b/compose/cli/multiplexer.py @@ -2,6 +2,8 @@ from __future__ import absolute_import from threading import Thread +from six.moves import _thread as thread + try: from Queue import Queue, Empty except ImportError: @@ -38,6 +40,9 @@ class Multiplexer(object): yield item except Empty: pass + # See https://github.com/docker/compose/issues/189 + except thread.error: + raise KeyboardInterrupt() def _init_readers(self): for iterator in self.iterators: