From 84682187d898bde8a2bd0830eba58cba97a311ea Mon Sep 17 00:00:00 2001 From: Tyler Hobbs Date: Wed, 28 May 2014 18:37:22 -0500 Subject: [PATCH] Fix is_shutdown check when running in executor --- CHANGELOG.rst | 9 +++++++++ cassandra/cluster.py | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index d6a97667..b42f9bad 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -1,3 +1,12 @@ +2.0.1 +===== +May 28, 2014 + +Bug Fixes +--------- +* Fix check for Cluster.is_shutdown in in @run_in_executor + decorator + 2.0.0 ===== May 28, 2014 diff --git a/cassandra/cluster.py b/cassandra/cluster.py index b6b3d5c6..d3989d7a 100644 --- a/cassandra/cluster.py +++ b/cassandra/cluster.py @@ -130,7 +130,7 @@ def run_in_executor(f): @wraps(f) def new_f(self, *args, **kwargs): - if self._is_shutdown: + if self.is_shutdown: return try: future = self.executor.submit(f, self, *args, **kwargs)