[Development] Cake and eating it too for qDebug printing to system log - https://codereview.qt-project.org/89357
corentin.jabot at gmail.com
Thu Jul 10 02:54:12 CEST 2014
I feel the urge to give my two cents on that.
At least on unix desktop platforms, I expect to get stderr output on the
So, detecting its presence is certainly a good approach.
When there is no console, I probably don't care about the logs at all.
I *may* care about error/warning messages, granted that the application
outputs diligently, which is often not the case.
One argument is that the system logging offers better rotating & search
which is true, but the logs would still be cluttered by probably useless
There are tons of signal/slot missing throughout KDE applications, as a end
what can I possibly do about it ?
I do not have a huge ~/.xsession-error file, but for those who have,
I think it's a problem for distributions to solve, not Qt.
On the other end, I usually have a large /home partition and relatively
small root partition,
so, of to evil, I would prefer my home to be cluttered. I think that's true
Depending on its features or importance to the system or to the user an
is either important, in which case some log should be conserved or
unimportant logs should
certainly be dropped.
A think an application should be assumed to be unimportant ( not to log to
the system's journal)
by default. The choice should be given both to the developer ( with an api)
and maintainers/end user (environment variable) to modify this behavior.
As for Qt Creator, my opinion is that the logs of an in-development
irrelevant the second you press the rebuild button and so its output should
go to stderr only.
For platforms which offer no or poor console support, not-in-development
should arguably go to the system journal to be forever forgotten :
I don't expect end-users to know how access those logs, even less to
provide the developers
with them when something goes wrong.
2014-07-10 1:20 GMT+02:00 Thiago Macieira <thiago.macieira at intel.com>:
> On Wednesday 09 July 2014 14:43:36 Thiago Macieira wrote:
> > Current Linux desktops with journald:
> > - default stderr: captured into ~/.xsession-errors
> > - system logging available: available
> > - is stderr useful: yes, for launching from terminal
> > [when Linux desktops start using user-mode systemd, it will be as below]
> Note: if journald is writing to volatile storage, regular users can't read
> log. Therefore, system logging is *not* available.
> Linux distributions should not enable journald logging unless regular users
> can read the output.
> Thiago Macieira - thiago.macieira (AT) intel.com
> Software Architect - Intel Open Source Technology Center
> Development mailing list
> Development at qt-project.org
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Development