aboutsummaryrefslogtreecommitdiffstats
path: root/mpm/python
diff options
context:
space:
mode:
authorJoerg Hofrichter <joerg.hofrichter@ni.com>2020-03-05 11:01:08 +0100
committeratrnati <54334261+atrnati@users.noreply.github.com>2020-03-05 12:07:25 -0600
commit9a45d4449fdac7b53ae5bc97b58cd09b42bfdd2a (patch)
treed079cd65f31b9ce5f472212fe1f3a99a19c7c8ee /mpm/python
parent5e7a2458a83f724eb5fb268dd0f670dcd4a18e66 (diff)
downloaduhd-9a45d4449fdac7b53ae5bc97b58cd09b42bfdd2a.tar.gz
uhd-9a45d4449fdac7b53ae5bc97b58cd09b42bfdd2a.tar.bz2
uhd-9a45d4449fdac7b53ae5bc97b58cd09b42bfdd2a.zip
mpm: rpc_server: set correct default unpacker params for msgpack 0.6.1
msgpack 0.6.1 suggests new default parameters which ensures compatibility with the upcoming msgpack 1.0 release which will have breaking changes. The parameter changes are described in https://github.com/msgpack/msgpack-python/blob/v0.6.1/README.rst The default parameters for msgpack 1.0 will be: - packer: use_bin_type=True - unpacker: raw=False The packer use_bin_type=True option is already set in the client (mpm_shell.py) but the unpacker option raw=False needs to be set in the server (rpc_server.py) This change allows the usage of a patched version of python3-mprpc 0.1.17 which removes passing the encoding option to the Packer and Unpacker Signed-off-by: Joerg Hofrichter <joerg.hofrichter@ni.com>
Diffstat (limited to 'mpm/python')
-rw-r--r--mpm/python/usrp_mpm/rpc_server.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/mpm/python/usrp_mpm/rpc_server.py b/mpm/python/usrp_mpm/rpc_server.py
index 29fdd185f..0471dde6f 100644
--- a/mpm/python/usrp_mpm/rpc_server.py
+++ b/mpm/python/usrp_mpm/rpc_server.py
@@ -96,7 +96,7 @@ class MPMServer(RPCServer):
# first the commands need to be registered
super(MPMServer, self).__init__(
pack_params={'use_bin_type': True},
- unpack_params={'max_buffer_size': 50000000},
+ unpack_params={'max_buffer_size': 50000000, 'raw': False},
)
self._state.system_ready.value = True
self.log.info("RPC server ready!")
@@ -477,7 +477,7 @@ class MPMServer(RPCServer):
# changes in future versions of RPCServer may cause issues.
super(MPMServer, self).__init__(
pack_params={'use_bin_type': True},
- unpack_params={'max_buffer_size': 50000000},
+ unpack_params={'max_buffer_size': 50000000, 'raw': False},
)
def reset_mgr(self):