From 56b48a81b701b017b83874472aa8a9154d61ba9d Mon Sep 17 00:00:00 2001 From: Fabio Manganiello Date: Tue, 18 Dec 2018 22:16:15 +0100 Subject: [PATCH] Reverted the new config file path expansion logic as it breaks include directives --- platypush/config/__init__.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/platypush/config/__init__.py b/platypush/config/__init__.py index e590ad77..c205403f 100644 --- a/platypush/config/__init__.py +++ b/platypush/config/__init__.py @@ -116,7 +116,10 @@ class Config(object): def _read_config_file(self, cfgfile): - cfgfile = os.path.abspath(os.path.expanduser(cfgfile)) + if not os.path.isabs(cfgfile): + cfgfile = os.path.join(os.path.expanduser( + os.path.dirname(self._cfgfile)), cfgfile) + config = {} with open(cfgfile, 'r') as fp: