Thunderbird:Logging UI

From MozillaWiki
Jump to: navigation, search

this is a design scratch area for bug 193873


Developers and program debuggers need to get logged information from a user's Thunderbird instance via email or uploaded file to bugzilla. The desired interface enables any user to a) turn on MailNews:Logging mailnews logging and b) send their logs to the proper location. MailNews:Logging#Logging_Tools has some workarounds.


  • Logging slows down Thunderbird quite a bit
    • Logging should only be on when needed, then off the rest of the time
      • Our interactions require a restart into logging mode and the next restart would take the user out of that mode
    • The log directory should probably be made available even while logging is disabled
      • Current preferences interface always displays the location of the log directory and allows for it to be changed
    • Some indication of logging mode should be used to indicate why Thunderbird is behaving differently
      • Current preferences mockups do not do a good job of this and the main interface requires some kind of indication


  • Do we notify someone if they change logging levels and do not restart thunderbird?
    • Only while in logging mode?
  • How do we display the fact that we are in logging mode in the main mail interface?
    • Assumption that this is necessary because we don't want people to forget and continue using thunerbird in logging mode beyond the task it's called for
  • How do we better show status of logging mode in the Preferences UI?
    • The current ON / off in the title is pretty lame, but I'm a little tired right now

Common Use Cases

Here are some common use cases with steps taken by each party involved.

Reproduce Problem

  1. User has problems with Thunderbird
  2. Developer or IT person instructs user how to turn on logging
  3. User turns on logging
    1. Set logging modules and levels?? (I doubt this is worthwhile -- many users won't know enough to be smart here --davida)
    2. restart required
  4. User attempts to reproduce problem
  5. User could :
    1. forward it to their local IT person via email
    2. attach log file to a bug
    3. read the debug information (developers especially)
  6. User turns off logging
    1. restart required
    2. should offer to delete logs?

Possible Improvements

  • Could automate the uploading of information in a similar way to Breakpad
    • Complicated and might ignore the local IT person case
  • Preferences for
    • logging levels
    • modules
    • logging directory
  • Button to open log directory in Finder/Explorer
  • Remove thunderbird restart requirement


Options that are important for proper usage and are going to be changed by the majority of users should be in the main interface so they are obvious and easily changed. Other options should be in a preferences menu or scuttled away in the about:config.

Logging Modules

According to mail troubleshoot and MailNews:LDAP_Address_Books there are 6 types of protocol logging.

  1. "all" for All Protocols
  2. "IMAP" for IMAP
  3. "POP3" for POP
  4. "NNTP" for NNTP
  5. "SMTP" for SMTP
  6. "LDAP" for LDAP

These can be provided for in a drop down selector.

Logging Levels

Again, the mail troubleshoot page describes 5 levels of logging.

  1. PR_LOG_NONE = 0, /* nothing */
  2. PR_LOG_ALWAYS = 1, /* always printed */
  3. PR_LOG_ERROR = 2, /* error messages */
  4. PR_LOG_WARNING = 3, /* warning messages */
  5. PR_LOG_DEBUG = 4, /* debug messages */

These can be provided for in a drop down selector.


These are the mockups for the various pages required to make this interaction a reality.


Since there are only a few protocols I flattened them all out of their combobox into a list where enabling them is done by setting the log level above zero. Initially all levels will be at zero and users would be expected to set the log level to something before restarting TB into logging mode. The assumption is that the developer would tell the person exactly which ones to turn on and to what levels. However many developers have said that no one really uses the alternate levels, it is really just an on or off from 0 to 5.

Debug Logging Preference (off)
Debug Logging Preference (on)

Mail Interface

The mail interface requires some kind of indication that the user is running in logging mode (not completed yet). We also have a nice way for people to mail their log files off, however this extra menu item would only be present during logging mode so it might not be that useful as much as it's nice.

Easy way to Send the Debug Log via Email