Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 5932723

Browse files
committed
ReqRep pattern will only accept OK and ERR events.
This mostly for pretty symmetry with the ReqStream.
1 parent a100a5a commit 5932723

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

zerorpc/patterns.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ def process_call(self, context, channel, req_event, functor):
3434
channel.emit_event(rep_event)
3535

3636
def accept_answer(self, event):
37-
return True
37+
return event.name in ('OK', 'ERR')
3838

3939
def process_answer(self, context, channel, req_event, rep_event,
4040
handle_remote_error):

0 commit comments

Comments
 (0)