Could not connect to the in-process QML debugger
-
Hi everyone,
I'm trying to debug a QML application, but as soon as I run it in debug mode I get the message "could not connect to the in-process QML debugger, The application is not setup for QML/JS debugging". The problem is I followed all the steps for configuring the project: In the projects tab I have the "Link QML debugging library" checked, I have the QML checked in the run settings tab, the port (3768) is open and the firewall is disabled. But I noticed one thing, when I build the debugging helpers in the Tools->options->Qt4 menu, the QML dump and the QML debugging library build ok, but the QML Observer, even though it builds ok, I'm even able tu run the .exe from the qrc-qmlobserver folder, the Qt menu stills says "not yet built", does anyone know how to get this working?
These are my specs:
windows 7 pro x64
windows 7 SDK 7.1 with debugger tools both x86 and x64
Qt 4.7.3 built with x86
Qt Creator 2.2.1Even though my PC is x64, I build everything with the x86 toolchain for compatibility. I'm even able to run the QML apps and all, but I'm just not able to debug.
I have also noticed on the debugger log that I get this message: Exception at 0x775c0f3b, code: 0x4000001f: Win32 x86 emulation subsystem breakpoint hit, flags=0x0 in ntdll32!LdrpDoDebuggerBreak
Any help? thanks!
EDIT: The line before the Exception, I get this:
NOTE: ENGINE RUN FAILED
dState changed from EngineRunRequested(7) to EngineRunFailed(8).
dQUIT DEBUGGER REQUESTED
dState changed from InferiorRunOk(11) to InferiorStopRequested(13).
dCALL: INTERRUPT INFERIOR
QDeclarativeDebugServer: Ignoring "-qmljsdebugger=port:3768". Debugging has not been enabled.ModLoad: 00000000
021e0000 00000000
02270000 C:\Windows\SysWOW64\gdi32.dll
ModLoad: 0000000071880000 00000000
71896000 C:\Windows\SysWOW64\CRYPTSP.dll
ModLoad: 0000000071780000 00000000
717bb000 C:\Windows\SysWOW64\rsaenh.dll
ModLoad: 0000000071770000 00000000
7177e000 C:\Windows\SysWOW64\RpcRtRemote.dll
ModLoad: 00000000044d0000 00000000
0462c000 C:\Windows\SysWOW64\ole32.dll
(1490.1fec): WOW64 breakpoint - code 4000001f (first chance)I don't know if that's relevant, nor why the debugging says it's not being enabled.
-
Ok, I figured out how to debug QML, but I guess I'll have to learn how to submit an issue in JIRA for this:
What I had to do was to go to projects->build settings and in the "Build Steps" section, on the qmake step, there was no QMLJSDEBUGGER_PATH variable set, so I manually added it with "QMLJSDEBUGGER_PATH=D:/qt/4.7.3_vs100/qtc-qmldbg", after that, I hit build, and it says it wasn't able to build because the qmldebug library was already added. I checked again in the qmake build step, and now at last QtCreator automatically added the QMLJSDEBUGGER_PATH variable, so I removed the one I manually added and voila! it debugged.
Another thing is that, I'm not able to debug a QML file in "Debug" configuration, just in "release" configuration, because QtCreator doesn't build helpers for debug, so if I try to debug in "debug" config, it crashes saying it's not able to find a QmlJSDebuggerd.lib library (notice that in debug config, it adds the d suffix to the library, and Creator just builds the helper QmlJSDebugger.lib and not QmlJSDebuggerd.lib). I opened the qmljsdebugger.pro project and built a debug version by myself, and now I'm able to run in debug config, but QtCreator should build both the debug and release library by itself right?
And by the way, I still haven't figured out how to make QtCreator recognize the QMLObserver build, it still shows "not yet built" in the helpers, even though it's built OK, and I'm even running it outside to test my QML files.
Thanks everyone, someone please point me to where to submit this bugs.