Open Bug 1531381 Opened 5 years ago Updated 2 years ago

Hide messages for disabled logpoints

Categories

(DevTools :: Debugger, enhancement, P3)

enhancement

Tracking

(Not tracked)

People

(Reporter: bhackett1024, Unassigned)

References

(Blocks 1 open bug)

Details

Bug 1530133 adds the ability to regenerate logpoint messages according to the currently installed logpoints when using web replay. We should do something similar in the normal case. Disabling a logpoint should hide its messages in the console, and reenabling the logpoint should add them back. There might be other things we want to do here (e.g. removing the messages for a deleted logpoint), but these are not as clear cut and should probably wait until we have more experience with this basic interface.

Blocks: dbg-logpoints
No longer blocks: logpoints-m1
Priority: -- → P3
Flags: needinfo?(nchevobbe)
Flags: needinfo?(hkirschner)

I think it would be nice to be able to prompt users if they would like to remove the messages.

We discussed some other ideas as well for log points

  1. showing a log point icon on the left as opposed to the msg icon
  2. highlighting the other messages for the same point on hover
  3. nesting messages by callee, which is closer to how users think about logging

my first reaction is that it might be confusing?
Like, you wanted to log a given action, you:

  1. add the log point in the debugger
  2. do the action
  3. remove the logpoint because you don't want to pollute the output anymore (imagine you were logging on mousemove, or something very spammy)
  4. You go to the console to investigate the logs

if at the last step we remove the logs, the whole investigation is meaningless, and will definitely make people confused and angry.
Having a prompt each time might be an overkill as well? I can see it getting into the way of the user.

However, we could think of something generic enough that it would be useful for any kind of logs.
We could have a context menu action to remove all the messages from a given location/file/origin (this could go well with blackboxing too).
A context menu is not super discoverable, but we could think of having a call to action button on hover for the location for example, or something better.

We could get crazy and have other items like:

  • remove prior messages
  • remove messages after this one
Flags: needinfo?(nchevobbe)

This seems to be a case that makes a lot of sense for WebReplay, where the recording can be used to rewrite history. I am not sure how this behavior would solve a problem for normal use, beyond being an unexpected side effect when logs disappear without a hint.

Flags: needinfo?(hkirschner)
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.