Closed
Bug 1215203
Opened 11 years ago
Closed 11 years ago
Log a deprecation warning when DevToolsUtils.dbg_assert is called
Categories
(DevTools :: General, defect)
DevTools
General
Tracking
(firefox44 fixed)
RESOLVED
FIXED
Firefox 44
| Tracking | Status | |
|---|---|---|
| firefox44 | --- | fixed |
People
(Reporter: fitzgen, Assigned: fitzgen)
References
Details
Attachments
(1 file, 1 obsolete file)
|
1.18 KB,
patch
|
jlong
:
review+
|
Details | Diff | Splinter Review |
No description provided.
| Assignee | ||
Comment 1•11 years ago
|
||
Attachment #8674360 -
Flags: review?(jlong)
| Assignee | ||
Updated•11 years ago
|
| Assignee | ||
Comment 2•11 years ago
|
||
| Assignee | ||
Comment 3•11 years ago
|
||
I think that this extra logging is making tests time out way more :-/
Comment 4•11 years ago
|
||
Comment on attachment 8674360 [details] [diff] [review]
Log a deprecation warning when DevToolsUtils.dbg_assert is called
Review of attachment 8674360 [details] [diff] [review]:
-----------------------------------------------------------------
::: devtools/shared/DevToolsUtils.js
@@ +442,5 @@
>
> // DEPRECATED: use DevToolsUtils.assert(condition, message) instead!
> exports.dbg_assert = function dbg_assert(cond, e) {
> + const deprecationMessage = "DevToolsUtils.dbg_assert is deprecated! Use DevToolsUtils.assert instead!\n"
> + + Error().stack;
We're going to have a lot of these messages right now, aren't we? Should we only print this message once, or wait a little while to give a chance to convert them over?
| Assignee | ||
Comment 5•11 years ago
|
||
I think printing once is a nice solution. Should also solve the timeouts, I hope.
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
| Assignee | ||
Updated•11 years ago
|
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
| Assignee | ||
Comment 7•11 years ago
|
||
Attachment #8674597 -
Flags: review?(jlong)
| Assignee | ||
Updated•11 years ago
|
Attachment #8674360 -
Attachment is obsolete: true
Attachment #8674360 -
Flags: review?(jlong)
| Assignee | ||
Comment 8•11 years ago
|
||
| Assignee | ||
Comment 9•11 years ago
|
||
(In reply to Nick Fitzgerald [:fitzgen][:nf] from comment #8)
> Try push:
> https://treeherder.mozilla.org/#/jobs?repo=try&revision=fabf3be5a257
Alright, all green this time around.
Comment 10•11 years ago
|
||
Comment on attachment 8674597 [details] [diff] [review]
Log a deprecation warning when DevToolsUtils.dbg_assert is called
Review of attachment 8674597 [details] [diff] [review]:
-----------------------------------------------------------------
::: devtools/shared/DevToolsUtils.js
@@ +448,5 @@
> + const deprecationMessage = "DevToolsUtils.dbg_assert is deprecated! Use DevToolsUtils.assert instead!\n"
> + + Error().stack;
> + dump(deprecationMessage);
> + if (typeof console === "object" && console && console.warn) {
> + console.warn(deprecationMessage);
I wish we could just use console everywhere! In certain cases 2 of these warnings will be dumped to the console, when `console.warn` is also outputting to stdout. Oh well, not a big deal.
Attachment #8674597 -
Flags: review?(jlong) → review+
| Assignee | ||
Updated•11 years ago
|
Keywords: checkin-needed
Comment 11•11 years ago
|
||
Keywords: checkin-needed
Comment 12•11 years ago
|
||
Status: NEW → RESOLVED
Closed: 11 years ago → 11 years ago
status-firefox44:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → Firefox 44
Updated•8 years ago
|
Product: Firefox → DevTools
You need to log in
before you can comment on or make changes to this bug.
Description
•