This change wouldn't be needed if we made the convention in `br` to only enter the event loop when in GUI mode. As it stands now, needWindow() triggers the creation of a QLabel which causes a crash if QApplication hasn't been created.