Logging again

As I mentioned earlier, Metacity has quite a good logging system, but it’s almost never turned on; you have to set some environment variables. If someone reports a bug, we have to ask them specifically to turn it on, and then run Metacity again, and see whether the problem recurs. Federico and Luke suggested earlier that it could be supplanted by a gconf key, which users find easier to turn on and off than an environment variable; I think that’s a generally good idea.

I’m also floating the idea here of encouraging people to log all the time, at least on unstable builds, perhaps by making it the default. In that way, when something went wrong there’d be a logfile to refer to, even when you couldn’t recreate the bug. Obviously you’d be able to turn it off as well.

The files would be dated as Sabayon now can. Since we also have the ability (for session management) to dump a list of window details, it might be useful to dump them in the file when it got closed, too. Perhaps we could do some kind of logrotate thing so that the files didn’t grow like that fish (no, not our own Wanda).

Federico mentions that bug-buddy now has the ability to attach logfiles to bug reports; I think this would be enormously useful, and save us days of debugging time, but is still a bad idea because nobody wants a list of all the names and movements of all their windows for the past few hours attached to a public bug (some people may remember the unfortunate side-effects last year of having a stack trace of someone’s totem process attached in such a way). This is an existing problem, since it’s inherent to the use of logfiles in a window manager, and applies whether the log is supplied by bug-buddy or attached by a human. I’m having trouble thinking of a good way around it.

Published by

Thomas Thurman

Mostly themes, triaging, and patch review.

One thought on “Logging again”

  1. If you were going to log everything all the time, you’d have to have rotating logs or they’d get pretty big… you would probably also need to actually write to the log in a separate process that has its own write buffer, so that you don’t ever block on write when logging (it would make window management sluggish…)

    Maybe bug-buddy could support regexps that automatically obfuscate things in logfiles that could be sensitive (in this case, window titles)…

Comments are closed.

Leave a Reply

Your email address will not be published. Required fields are marked *