Skip to content

Commit

Permalink
Fix other instance of tomerfiliba-org#251, where IronPython pickle.du…
Browse files Browse the repository at this point in the history
…mps returns unicode instead of bytes.
  • Loading branch information
pilcru committed Feb 19, 2018
1 parent 6d652ff commit c30f9b4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion rpyc/core/protocol.py
Original file line number Diff line number Diff line change
Expand Up @@ -661,7 +661,7 @@ def _handle_ctxexit(self, obj, exc):
def _handle_pickle(self, obj, proto):
if not self._config["allow_pickle"]:
raise ValueError("pickling is disabled")
return pickle.dumps(obj, proto)
return bytes(pickle.dumps(obj, proto)) # Force type for IronPython bug #251
def _handle_buffiter(self, obj, count):
return tuple(itertools.islice(obj, count))
def _handle_oldslicing(self, obj, attempt, fallback, start, stop, args):
Expand Down

0 comments on commit c30f9b4

Please sign in to comment.