[Qt-creator] Qt Creator Issues tab does not populate

Hunger Tobias Tobias.Hunger at digia.com
Fri Mar 8 09:19:54 CET 2013


Hello Alfonso!

<snip>Description of problem with output parsing</snip>

> How can I work around this problem?

That depends a lot on what kind of output you get from your tools and whether you receive
the output via stdout (black text in compile output) or stderr (red text).

> How does Qt Creator populate the Issues tab?

Each build step (make, qmake, custom build step, etc.) defines a list of output parsers that
look at each line of output received and extracts Tasks from that which are then routed to the
Issues pane.

The list of parsers for make contains e.g. a gnumakeparser and parsers for the tool chain
you have set up (MSVC, gcc, clang, whatever).

> As a reference, in their existing CodeWright IDE, they manually configure a "Custom Error Parser".

Creator does not have that yet, sorry.

> They essentially point the IDE to a .err file generated by the compile step and give CodeWright a
> complex regular expression to use to parse the .err file and populate the error list.

Something similar would be necessary, but you will have to do this in code.

> Perhaps this complex configuration doesn't need to be performed to get Qt Creator set up for
> this, but I just have no idea how to get the Issues tab to populate or how to continue to troubleshoot this.

How to proceed depends a lot on what the output looks like as well as how you get it. 

The simplest case would be if wmk is compatible with make (it is called a "make tool" on the
site you pointed too). Compatible in this context means it accepts the command line arguments
we need (-w to print working directories), it produces similar output and does not alter the
compiler output in any way (by e.g. moving the compilers stdout to stderr or the other way
around).

If you are then using a compiler that produces output like GCC or any other supported compiler,
then you only need to have a makestep and override the make command used.

If the tool does something different, then you will need to do some coding.

<hack>

You mention a .err file... You might get away with having a script that turns this into a .tasks file.
When loading a .tasks file into creator it will treat each line as one issue to put into the
isssues pane. That is very convenient for things like static code analysis results, etc. but might
be abused for your use case: You would need a script that turns the .err file into a .tasks file
(e.g. by watching the filesystem or by way of it being a wrapper around wmk). Creator will
watch .tasks files it opened and reload them whenever they change.

</hack>


Tobias Hunger
Senior Software Engineer
Digia, Qt

Digia Germany GmbH
Rudower Chaussee 13, 12489 D-Berlin
Sitz der Gesellschaft: Berlin, Registergericht: Amtsgericht Charlottenburg, HRB 144331 B,
Geschäftsführer: Mika Pälsi, Juha Varelius, Anja Wasenius
Email: tobias.hunger at digia.com
http://qt.digia.com
Qt Blog: http://blog.qt.digia.com/
Qt Facebook: www.facebook.com/qtcommercial
Qt Twitter: www.twitter.com/qtcommercial

Digia Germany is a group company of Digia Plc,
Valimotie 21, FI-00380 Helsinki Finland
Visit us at: www.digia.com



More information about the Qt-creator mailing list