massemanet / eper

Erlang performance and debugging tools
MIT License
437 stars 128 forks source link

Idea and some more questions: only print last message #32

Closed mattiasw2 closed 9 years ago

mattiasw2 commented 9 years ago

When a function calls fails, I typically use redbug to trace a function higher in the call stack to see why it was called and how.

In this cases, often, only the last call is relevant. Since redbug anyway uses a buffer, maybe, redbug could hold the printing for a second or so, and then print.

Other questions:

massemanet commented 9 years ago

for question 1, try the "blocking" flag? (see redbug:help/0) for question 2; conf file... I'll put it on the potential improvements list. for q3, the first arg to redbug:start is really a list of trace patterns, like this; redbug:start(["erlang:element(2,_)","erlang:now->return"]).

mattiasw2 commented 9 years ago
  1. blocking, missed that. Yes, you are right, if number of traces not huge, this works fine.
  2. -
  3. Perfect!