From 4b9628eac051c9c15eed9962bd88ab4111d67598 Mon Sep 17 00:00:00 2001 From: derAnfaenger Date: Thu, 25 May 2017 02:06:43 +0200 Subject: [PATCH] bots: Make test-bots independent from current working path. --- contrib_bots/run.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib_bots/run.py b/contrib_bots/run.py index 21d1093..ba35062 100755 --- a/contrib_bots/run.py +++ b/contrib_bots/run.py @@ -23,7 +23,7 @@ def get_lib_module(bots_fn): print('Please use a .py extension for library files.') sys.exit(1) base_bots_fn = os.path.basename(os.path.splitext(bots_fn)[0]) - sys.path.append('bots/{}'.format(base_bots_fn)) + sys.path.append(os.path.dirname(bots_fn)) module_name = base_bots_fn module = importlib.import_module(module_name) return module