Skip to content

Commit

Permalink
dashboard: kill the Qt built-in main window closing mechanism
Browse files Browse the repository at this point in the history
When the main window is closed, Qt makes QApplication.exec() return, which conflicts with Quamash's implementation of loop.run_until_complete(). The conflict causes Quamash's run_forever() to return earlier than it should, and cause "RuntimeError('Event loop stopped before Future completed.')".

Closes #475
sbourdeauducq committed Jul 1, 2016
1 parent 6dc510a commit e116d75
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion artiq/frontend/artiq_gui.py
Original file line number Diff line number Diff line change
@@ -47,7 +47,8 @@ def __init__(self, server):

self.exit_request = asyncio.Event()

def closeEvent(self, *args):
def closeEvent(self, event):
event.ignore()
self.exit_request.set()

def save_state(self):

0 comments on commit e116d75

Please sign in to comment.