summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormartinko2014-01-13 14:17:37 +0000
committermartinko2014-01-13 14:17:37 +0000
commit1d5ac6451ca8ac6a10fb7d74fab42fdd3e2fd7ff (patch)
tree12ee3eecbbcedf6c0e8d92188b1deda53ff710b9
parent7bf9aba30603cf7eda81c5477f12b34239e4dfc1 (diff)
pgq.localconsumer: added file path check on config load
-rw-r--r--python/pgq/localconsumer.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/python/pgq/localconsumer.py b/python/pgq/localconsumer.py
index e551536f..45336276 100644
--- a/python/pgq/localconsumer.py
+++ b/python/pgq/localconsumer.py
@@ -41,6 +41,8 @@ class LocalConsumer(BaseConsumer):
super(LocalConsumer, self).reload()
self.local_tracking_file = self.cf.getfile('local_tracking_file')
+ if not os.path.exists(os.path.dirname(self.local_tracking_file)):
+ raise skytools.UsageError ("path does not exist: %s" % self.local_tracking_file)
def init_optparse(self, parser = None):
p = super(LocalConsumer, self).init_optparse(parser)