mirror of https://github.com/m-labs/artiq.git
rpctool: use pprint
This commit is contained in:
parent
abbf5eb059
commit
324cafae3d
|
@ -4,6 +4,7 @@ import argparse
|
||||||
import textwrap
|
import textwrap
|
||||||
import sys
|
import sys
|
||||||
import numpy as np # Needed to use numpy in RPC call arguments on cmd line
|
import numpy as np # Needed to use numpy in RPC call arguments on cmd line
|
||||||
|
import pprint
|
||||||
|
|
||||||
from artiq.protocols.pc_rpc import Client
|
from artiq.protocols.pc_rpc import Client
|
||||||
|
|
||||||
|
@ -77,7 +78,7 @@ def call_method(remote, method_name, args):
|
||||||
method = getattr(remote, method_name)
|
method = getattr(remote, method_name)
|
||||||
ret = method(*[eval(arg) for arg in args])
|
ret = method(*[eval(arg) for arg in args])
|
||||||
if ret is not None:
|
if ret is not None:
|
||||||
print("{}".format(ret))
|
pprint.pprint(ret)
|
||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
|
Loading…
Reference in New Issue