title: How to fix 'QML Debugger: Unable to listen to port'
body: <p>I'm new to QML and have to work on a project started by a colleague.
  When starting the application, I receive the following messages:</p>
  <pre><code>QML debugging is enabled. Only use this in a safe environment.
  QML Debugger: Unable to listen to port 34567.
  </code></pre>
  <p>Due to that is a ROS project I have to work with cmake.</p>
  <hr />
  <h2>System:</h2>
  <ul>
  <li>Ubuntu 16.04</li>
  <li>Qt Creator 4.9.2</li>
  <li>QT 5.8.0</li>
  <li>ROS Kinetic</li>
  <li>Enable QML in the Debugger settings</li>
  </ul>
  <hr />
  <h2>What I've tried until now:</h2>
  <ul>
  <li>restart system</li>
  <li>tried several ports</li>
  <li>checked, that no other Qt Application is started</li>
  <li>listen to port with netcat</li>
  </ul>
  <hr />
  <h2>Code snippets:</h2>
  <p><strong>CMakeLists.txt:</strong></p>
  <pre><code>set(CMAKE_CXX_FLAGS_DEBUG &quot;${CMAKE_CXX_FLAGS_DEBUG} -DQT_QML_DEBUG &quot;)
  
  set(TEMPLATE_QT_VERSION &quot;5.8.0&quot; CACHE STRING &quot;Qt Version&quot;)
  set(TEMPLATE_QT_MODULES Core Gui Widgets Quick Qml Concurrent Network DBus PrintSupport)
  
  find_package(Qt5 ${TEMPLATE_QT_VERSION} EXACT CONFIG REQUIRED ${TEMPLATE_QT_MODULES})
  </code></pre>
  <p><strong>main.cpp:</strong></p>
  <pre><code>#include &lt;QGuiApplication&gt;
  
    #include &lt;QQmlDebuggingEnabler&gt;
  
    #include &quot;ros/ros.h&quot;
    #include &quot;heartbeat/heartbeat.h&quot; 
    #include &lt;string.h&gt;
    #include &lt;iostream&gt;
    #include &quot;message_handler/ros2tag.h&quot;
    #include &lt;QQmlContext&gt;
    #include &lt;QtCore/QDir&gt;
    #include &lt;QtQuick/QQuickView&gt;
    #include &lt;QtQml/QQmlEngine&gt;
    #include &lt;QQmlApplicationEngine&gt;
    #include &quot;imageprovider.h&quot;
  
    #include &quot;qmlprox.h&quot;
    #include &lt;QtGui/QGuiApplication&gt;
    #include &lt;QtCore/QDir&gt;
    #include &lt;QQmlEngine&gt;
  
    #include &lt;QList&gt;
    #include &lt;QString&gt;
  
    #include &quot;geodataprovider.h&quot;
    #include &quot;georeferenceddatalistmodel.h&quot;
    #include &quot;georeferenceddatatriplelistmodel.h&quot;
    #include &quot;parameterdatalistmodel.h&quot;
    #include &quot;parameterdata.h&quot;
    #include &quot;beetImageHandler.h&quot;
  
  
  
  
    int main(int argc, char **argv)
    {
        QGuiApplication app(argc, argv);
  
        QQmlDebuggingEnabler enabler;
  
        //Initialisierung Knoten
        ros::init(argc, argv, &quot;hmi&quot;);
        ros::NodeHandle n;
  </code></pre>
  <p><strong>ROS-Launchfile:</strong></p>
  <pre><code>&lt;launch&gt;
    &lt;arg name=&quot;externParameters&quot; default=&quot;0&quot; /&gt;
    &lt;group ns=&quot;hmi&quot;&gt;
      &lt;node name=&quot;hmi&quot; pkg=&quot;hmi&quot; type=&quot;hmi&quot; respawn=&quot;true&quot; respawn_delay=&quot;10&quot; args=&quot;-qmljsdebugger=port:34567&quot; /&gt;
    &lt;/group&gt;
  &lt;/launch&gt;
  </code></pre>
  <p>Due to the ROS launch-file the application is started with the argument &quot;-qmljsdebugger=port:34567&quot;.</p>
  <p>Can anyone of you give me please an hint or a solution for my problem?</p>
  <p>Thank you in advance</p>