Closed Bug 553112 Opened 11 years ago Closed 11 years ago

Improved loggings for errors

Categories

(Toolkit :: Add-ons Manager, defect, P1)

defect

Tracking

()

VERIFIED FIXED
mozilla1.9.3a5

People

(Reporter: mossop, Assigned: mossop)

References

Details

(Whiteboard: [rewrite])

Attachments

(1 file)

No description provided.
Attached patch patch rev 1Splinter Review
What do you think about this as a first step (for the first trunk landing) Rob? It adds a shared logging module that all the parts use and lazily load when they first try to log. It logs out messages in the same way as the old extension manager.

I kind of want to make something all toolkit can use but maybe for now we just stick here. After the first landing I'd look at allowing exceptions and objects be passed along with the message to be included in the log output in some fashion.
Attachment #440544 - Flags: review?(robert.bugzilla)
Comment on attachment 440544 [details] [diff] [review]
patch rev 1

>diff --git a/toolkit/mozapps/extensions/AddonLogging.jsm b/toolkit/mozapps/extensions/AddonLogging.jsm
>new file mode 100644
>--- /dev/null
>+++ b/toolkit/mozapps/extensions/AddonLogging.jsm
>...
>+try {
>+  gDebugLogEnabled = Services.prefs.getBoolPref("extensions.logging.enabled");
>+}
>+catch (e) {
>+}
>+gDebugLogEnabled = true;
Do you really want this to always be true? Maybe for the initial landing?
Comment on attachment 440544 [details] [diff] [review]
patch rev 1

r=me with the above fixed per in person discussion
Attachment #440544 - Flags: review?(robert.bugzilla) → review+
landed on branch: http://hg.mozilla.org/projects/addonsmgr/rev/c7fd38eaf53c
Status: NEW → ASSIGNED
Flags: in-testsuite-
Flags: in-litmus-
Whiteboard: [rewrite] → [rewrite][fixed-in-addonsmgr][needs-landing]
http://hg.mozilla.org/mozilla-central/rev/89c73c22d7fb
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Whiteboard: [rewrite][fixed-in-addonsmgr][needs-landing] → [rewrite]
Target Milestone: --- → mozilla1.9.3a5
Verified fixed based on m-c landing.
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.