def _manual_review( self, command: offchain.Command ) -> typing.Tuple[ActionResult, offchain.PaymentCommand]: command = typing.cast(offchain.PaymentCommand, command) op_kyc_data = command.opponent_actor_obj().kyc_data ret = self.manual_review_result.get(op_kyc_data.given_name, ActionResult.PASS) return (ret, self._kyc_data_result("review", ret, command))
def _evaluate_kyc_data(self, command: offchain.Command) -> typing.Tuple[ActionResultType, offchain.Command]: command = typing.cast(offchain.PaymentCommand, command) op_kyc_data = command.opponent_actor_obj().kyc_data assert op_kyc_data is not None ret = self.evaluate_kyc_data_result.get(str(op_kyc_data.given_name), ActionResult.PASS) if ret == ActionResult.SOFT_MATCH: return (ret, command.new_command(status=offchain.Status.soft_match)) return (ret, self._kyc_data_result("evaluate key data", ret, command))