mirror of
https://github.com/trustgraph-ai/trustgraph.git
synced 2026-05-18 11:55:12 +02:00
tg-dump-msgpack previously output Python 'representation', now does JSON. (#233)
This commit is contained in:
parent
cff90cada1
commit
9942f63773
1 changed files with 2 additions and 1 deletions
|
|
@ -9,6 +9,7 @@ diagnostic utility.
|
||||||
import msgpack
|
import msgpack
|
||||||
import sys
|
import sys
|
||||||
import argparse
|
import argparse
|
||||||
|
import json
|
||||||
|
|
||||||
def dump(input_file, action):
|
def dump(input_file, action):
|
||||||
|
|
||||||
|
|
@ -17,7 +18,7 @@ def dump(input_file, action):
|
||||||
unpacker = msgpack.Unpacker(f, raw=False)
|
unpacker = msgpack.Unpacker(f, raw=False)
|
||||||
|
|
||||||
for unpacked in unpacker:
|
for unpacked in unpacker:
|
||||||
print(unpacked)
|
print(json.dumps(unpacked))
|
||||||
|
|
||||||
def summary(input_file, action):
|
def summary(input_file, action):
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue