From f106438b54369183afd99f5a41ef4535b24a08b2 Mon Sep 17 00:00:00 2001 From: Daniel Brown <ddb@star.sr.bham.ac.uk> Date: Fri, 15 Apr 2016 13:04:32 -0700 Subject: [PATCH] Better error messaging --- pykat/__init__.py | 2 +- pykat/finesse.py | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/pykat/__init__.py b/pykat/__init__.py index a0ed0d4..6b4a4ae 100644 --- a/pykat/__init__.py +++ b/pykat/__init__.py @@ -3,7 +3,7 @@ from __future__ import division from __future__ import print_function from __future__ import unicode_literals -__version__ = "1.0.1" +__version__ = "1.0.2" # This flag is used to switch on the gui features in pkat at import time USE_GUI = False diff --git a/pykat/finesse.py b/pykat/finesse.py index f728abe..d1b60c0 100644 --- a/pykat/finesse.py +++ b/pykat/finesse.py @@ -1433,7 +1433,8 @@ class kat(object): pipe_name = katfile.name + str(uuid.uuid4()) - cmd=[kat_exec, "--pykat=" + pipe_name] + #cmd=[kat_exec, "--pykat=" + pipe_name] + cmd=[kat_exec, "--perl1"] if self.__time_code: cmd.append('--perf-timing') @@ -1463,7 +1464,7 @@ class kat(object): fifo = None start = time.time() - duration = 5 # Duration for searching for open pipe + duration = 2 # Duration for searching for open pipe try: while fifo is None: @@ -1473,7 +1474,7 @@ class kat(object): fifo = open(pipe_name, "r") self.__looking = False else: - raise Exception("Could not connect to pykat pipe in {0} seconds. Ensure you are using Finesse >= v2.1 and Pykat >= v1.0.0.".format(duration)) + raise pkex.BasePyKatException("Could not connect to pykat pipe in {0} seconds. Ensure you are using Finesse >= v2.1 and Pykat >= v1.0.0.".format(duration)) except FileNotFoundError as ex: if self.verbose: if not self.__looking: -- GitLab