Closed Bug 954311 Opened 10 years ago Closed 10 years ago

Do not log UI system messages.

Categories

(Chat Core :: General, enhancement)

enhancement
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: benediktp, Assigned: clokep)

References

Details

Attachments

(1 file)

*** Original post on bio 878 at 2011-06-30 10:24:00 UTC ***

Sometimes there's need to set flags on system messages.

For example noLog for system messages that don't need to appear in the log files (help messages, completion suggestion of an addon, ..). Right now we don't support this:

http://lxr.instantbird.org/instantbird/source/purple/purplexpcom/src/imConversations.js#231
Blocks: 954312
*** Original post on bio 878 at 2011-07-08 01:54:16 UTC ***

So looking into this a bit, systemMessage [1] actually follows the same form as sendMsg [2], which makes me think this bug shouldn't be fixed, or both should be changed over?

Do we really want system messages to have flags or do we just want system messages to not be logged automatically? (The latter is easier, I'm not really sure how we'd implement the former is an XPCOM way.)

[1] http://lxr.instantbird.org/instantbird/source/purple/purplexpcom/public/imIConversationsService.idl#46
[2] http://lxr.instantbird.org/instantbird/source/purple/purplexpcom/public/purpleIConversation.idl#74
Status: NEW → ASSIGNED
*** Original post on bio 878 at 2011-07-11 18:07:20 UTC ***

From discussion on IRC [1] and looking at lxr [2], systemMessage is only used by the conversation and command services, i.e. it's a "UI only" type function, so we shouldn't ever have to have logging functionality from this (which makes my life easier!). This and bug 954312 (bio 879) will probably be merged into have systemMessage automatically use the noLog flag.

[1] http://log.bezut.info/instantbird/110711/#m426
[2] http://lxr.instantbird.org/instantbird/search?string=systemMessage
*** Original post on bio 878 at 2011-07-11 18:13:38 UTC ***

Changing this to be able not logging system messages caused by the UI / instantbird. Protocol system messages will still be logged of course!
Summary: Allow system messages to have flags → Do not log UI system messages.
*** Original post on bio 878 at 2011-07-11 18:17:24 UTC ***

(In reply to comment #2)
> From discussion on IRC [1] and looking at lxr [2], systemMessage is only used
> by the conversation and command services, i.e. it's a "UI only" type function

It's UI only because it's in the imIConversation interface. The conversation methods related to protocol conversations are in purpleIConversation.
Attached patch v1.0Splinter Review
*** Original post on bio 878 as attmnt 744 at 2011-07-15 10:56:00 UTC ***

The (rather simple) patch, also includes a comment in the interface. I wasn't sure exactly how to break up the line to not go over 80 chars (or 72, or whatever we use!) I tried my best!
Attachment #8352486 - Flags: review?(florian)
Comment on attachment 8352486 [details] [diff] [review]
v1.0

*** Original change on bio 878 attmnt 744 at 2011-07-15 11:16:51 UTC was without comment, so any subsequent comment numbers will be shifted ***
Attachment #8352486 - Flags: review?(florian) → review+
*** Original post on bio 878 at 2011-07-20 23:22:05 UTC ***

https://hg.instantbird.org/instantbird/rev/63816cb54288
Status: ASSIGNED → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → 1.1
You need to log in before you can comment on or make changes to this bug.