-
Notifications
You must be signed in to change notification settings - Fork 278
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
recon_trace:calls - no output on OTP26 #105
Comments
I'm a bit surprised yeah. This worked on OTP-26-RC3, and the full pattern still works outside of it on OTP-26 when using the matching function to make it work:
The translation there is just a shortcut toward I think this might be a break in Erlang/OTP itself, I'll see if I can follow up with folks from the OTP team. |
Oh actually odd thing: they are fully equivalent. It's just the first call that fails:
So the bug is really that the first invocation to a trace fails somehow. |
Oh interesting, I decomposed the calls and it works fine with the built-in functions, so it is a recon bug. That's odd.
I'm now thinking this is a problem with the rebar3 shell -- there were a lot of changes around that, and the hack is on rebar3's side so I'll look into it. |
Here's the diff I ran: diff --git a/src/recon_trace.erl b/src/recon_trace.erl
index 975f536..2d78009 100644
--- a/src/recon_trace.erl
+++ b/src/recon_trace.erl
@@ -354,6 +354,7 @@ count_tracer(0) ->
count_tracer(N) ->
receive
Msg ->
+ io:format(standard_error, "tracer received ~p~n", [Msg]),
recon_trace_formatter ! Msg,
count_tracer(N-1)
end.
@@ -393,6 +394,7 @@ formatter(Tracer, IOServer, FormatterFun) ->
{'EXIT', Tracer, Reason} ->
exit(Reason);
TraceMsg ->
+ io:format(standard_error, "~n Fake: ~p~n", [FormatterFun(TraceMsg)]),
io:format(IOServer, FormatterFun(TraceMsg), []),
formatter(Tracer, IOServer, FormatterFun)
end. And how I invoke it:
Beats me why, but the second loop invocation works and gets the data out, but the first batch of call never does (even though it works with It's like until that formatter loop returns once, everything is hung. |
Might be related to erlang/otp#7263 |
This was seen outside of Rebar first, in a RabbitMQ shell, for what it's worth. |
Yeah for the time being I'll stop investigating here and track the OTP repo's bug, seems related. |
When using
recon_trace:calls
, I don't get any (meaningful) output on OTP26. Empty lines are printed for every function call, but I can't see the actual trace output:On OTP25, everything works as expected:
The text was updated successfully, but these errors were encountered: