This happens if you don't build before you run the program. You will get the "failed to connect" message box eventually. It should rather show the "nothing recorded" message after the program quits.
|For Gerrit Dashboard: QTCREATORBUG-20499|
|231014,3||QmlProfiler: stop trying to connect when the application quits||4.7||qt-creator/qt-creator||Status: MERGED||+2||0|