Deluge Logical Operator Python