File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed
Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -148,6 +148,7 @@ It is also possible to pack/unpack custom data types. Here is an example for
148148``object_pairs_hook `` callback may instead be used to receive a list of
149149key-value pairs.
150150
151+
151152Extended types
152153^^^^^^^^^^^^^^
153154
@@ -170,7 +171,7 @@ It is also possible to pack/unpack custom data types using the **ext** type.
170171 ... return ExtType(code, data)
171172 ...
172173 >>> data = array.array('d', [1.2, 3.4])
173- >>> packed = msgpack.packb(data, default=default)
174+ >>> packed = msgpack.packb(data, default=default, use_bin_type=True )
174175 >>> unpacked = msgpack.unpackb(packed, ext_hook=ext_hook)
175176 >>> data == unpacked
176177 True
294295MessagePack uses `pytest ` for testing.
295296Run test with following command:
296297
297- $ py. test
298+ $ pytest -v test
298299
299300
300301..
You can’t perform that action at this time.
0 commit comments