diff --git a/platypush/config/__init__.py b/platypush/config/__init__.py index 67541f1761..d2de1fdef1 100644 --- a/platypush/config/__init__.py +++ b/platypush/config/__init__.py @@ -498,8 +498,7 @@ class Config: return cfg @classmethod - @property - def workdir(cls) -> str: + def get_workdir(cls) -> str: """ :return: The path of the configured working directory. """ diff --git a/platypush/plugins/xmpp/__init__.py b/platypush/plugins/xmpp/__init__.py index 2d8ecc9de0..a7de007667 100644 --- a/platypush/plugins/xmpp/__init__.py +++ b/platypush/plugins/xmpp/__init__.py @@ -117,7 +117,7 @@ class XmppPlugin(AsyncRunnablePlugin, XmppBasePlugin): auto_accept_invites=auto_accept_invites, restore_state=restore_state, state_file=os.path.expanduser( - state_file or os.path.join(Config.workdir, 'xmpp', 'state.json') + state_file or os.path.join(Config.get_workdir(), 'xmpp', 'state.json') ), ) self._loaded_state = SerializedState() diff --git a/platypush/utils/__init__.py b/platypush/utils/__init__.py index 20763fc907..7f16cce826 100644 --- a/platypush/utils/__init__.py +++ b/platypush/utils/__init__.py @@ -523,7 +523,7 @@ def get_or_generate_jwt_rsa_key_pair(): """ from platypush.config import Config - key_dir = os.path.join(Config.workdir, 'jwt') + key_dir = os.path.join(Config.get_workdir(), 'jwt') priv_key_file = os.path.join(key_dir, 'id_rsa') pub_key_file = priv_key_file + '.pub'