From 5f86ae16412745e2fa93c40c8c9003a35dabdf68 Mon Sep 17 00:00:00 2001 From: Romain Fihue Date: Tue, 13 Feb 2018 08:21:20 +0100 Subject: [PATCH] BaseEntity: remote property was not usable. Before, we could set a remote property (Boolean) but it was rewriten in BaseEntity's inherits_from with the result of a comparison of a Boolean and a NoneType. Thus, we could only set remote to True, because 'False or None' evaluates to None, which is the default value. Now, we can set the remote property to False and use the functionality it unveils within ClusterShell. --- lib/MilkCheck/Engine/BaseEntity.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/MilkCheck/Engine/BaseEntity.py b/lib/MilkCheck/Engine/BaseEntity.py index 1747882..3f54af4 100755 --- a/lib/MilkCheck/Engine/BaseEntity.py +++ b/lib/MilkCheck/Engine/BaseEntity.py @@ -693,7 +693,8 @@ def inherits_from(self, entity): if self.target is None: self.target = entity.target self.mode = self.mode or entity.mode - self.remote = self.remote and entity.remote + if self.remote is None: + self.remote = entity.remote if self.desc is None: self.desc = entity.desc self.delay = self.delay or entity.delay