mirror of
https://github.com/m-labs/artiq.git
synced 2024-12-18 16:06:30 +08:00
artiq_dashboard: style (NFC)
This commit is contained in:
parent
43edffc67e
commit
7d9199a2ee
@ -154,6 +154,7 @@ def main():
|
|||||||
master_management.close_rpc()
|
master_management.close_rpc()
|
||||||
|
|
||||||
disconnect_reported = False
|
disconnect_reported = False
|
||||||
|
|
||||||
def report_disconnect():
|
def report_disconnect():
|
||||||
nonlocal disconnect_reported
|
nonlocal disconnect_reported
|
||||||
if not disconnect_reported:
|
if not disconnect_reported:
|
||||||
@ -167,8 +168,7 @@ def main():
|
|||||||
("datasets", datasets.Model),
|
("datasets", datasets.Model),
|
||||||
("schedule", schedule.Model),
|
("schedule", schedule.Model),
|
||||||
("interactive_args", interactive_args.Model)):
|
("interactive_args", interactive_args.Model)):
|
||||||
subscriber = ModelSubscriber(notifier_name, modelf,
|
subscriber = ModelSubscriber(notifier_name, modelf, report_disconnect)
|
||||||
report_disconnect)
|
|
||||||
loop.run_until_complete(subscriber.connect(
|
loop.run_until_complete(subscriber.connect(
|
||||||
args.server, args.port_notify))
|
args.server, args.port_notify))
|
||||||
atexit_register_coroutine(subscriber.close, loop=loop)
|
atexit_register_coroutine(subscriber.close, loop=loop)
|
||||||
@ -288,7 +288,6 @@ def main():
|
|||||||
if d_log0 is not None:
|
if d_log0 is not None:
|
||||||
main_window.tabifyDockWidget(d_schedule, d_log0)
|
main_window.tabifyDockWidget(d_schedule, d_log0)
|
||||||
|
|
||||||
|
|
||||||
if server_name is not None:
|
if server_name is not None:
|
||||||
server_description = server_name + " ({})".format(args.server)
|
server_description = server_name + " ({})".format(args.server)
|
||||||
else:
|
else:
|
||||||
@ -299,5 +298,6 @@ def main():
|
|||||||
main_window.show()
|
main_window.show()
|
||||||
loop.run_until_complete(main_window.exit_request.wait())
|
loop.run_until_complete(main_window.exit_request.wait())
|
||||||
|
|
||||||
|
|
||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
main()
|
main()
|
||||||
|
Loading…
Reference in New Issue
Block a user