[Development] QLog ( Work on qDebug and friends)

wolfgang.beck at nokia.com wolfgang.beck at nokia.com
Fri Feb 3 00:00:33 CET 2012


I think we can change the current QLog.

Category using qDebug(category) and writing stuff out in an output file.
For me a logging file is much more important than system logs or socket because you can ask the customer that uses your Qt application to send you back the output log file.
Other cool stuff like writing into sockets can be done in an addOn or even in a plugin.

--
WB





-----Original Message-----
From: development-bounces+wolfgang.beck=nokia.com at qt-project.org [mailto:development-bounces+wolfgang.beck=nokia.com at qt-project.org] On Behalf Of ext Robin Burchell
Sent: Thursday, February 02, 2012 9:50 AM
To: David Faure
Cc: development at qt-project.org
Subject: Re: [Development] QLog ( Work on qDebug and friends)

On Wed, Feb 1, 2012 at 4:53 PM, David Faure <david.faure at kdab.com> wrote:
> However I would like this to be called qDebug(AREA) rather than qLog(AREA).
> Otherwise we are presenting a confusing situation of two competing 
> debug- output frameworks inside Qt.

Agreed. Extra functionality can be built on top of what is there already. Adding categories, etc, via overloads is fine, IMO. Things like file logging, socket logging, etc... need a bit more consideration, but are also not something that is unthinkable to have done as extensions of the existing system, which also handily provides log *levels*, even if not categories. (think: qDebug(SOCKETS) << "Socket created"; .... qWarning(SOCKETS) << "Couldn't connect, did something break?"; type things)

Something related I'd like to stress here (not to anyone in
particular): when you write this stuff in applications, it can be changed at will. But when it's in Qt, you can't change it for a very, very, very long time (if ever) if you suddenly decide the implementation isn't ideal or you could do better. It's better to not jam the moon on a stick into it from the word go, to take some time, and do it properly.

My point is: feature requests are great, I'm sure we'd all adore them, but let's rush into implementing without considering them carefully :) _______________________________________________
Development mailing list
Development at qt-project.org
http://lists.qt-project.org/mailman/listinfo/development



More information about the Development mailing list