Skip to content
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

Dbg crashes when tracing calls #12

Open
indiejames opened this issue Jan 10, 2016 · 1 comment
Open

Dbg crashes when tracing calls #12

indiejames opened this issue Jan 10, 2016 · 1 comment

Comments

@indiejames
Copy link

Attempted to follow instructions in README.md, but getting erorr with verison 1.0.1, Erlang 18, Elixir 1.2.0. Ran iex -S mix in dbg directory after mix compile then followed steps in README.m and got the following:

Erlang/OTP 18 [erts-7.2.1] [source] [64-bit] [smp:8:8] [async-threads:10] [hipe] [kernel-poll:false] [dtrace]

Interactive Elixir (1.2.0) - press Ctrl+C to exit (type h() ENTER for help)

iex(1)> Dbg.trace(self(), :call)
%{counts: %{nonode@nohost: 1}, errors: %{}}
iex(2)> Dbg.call(&Map.new/0)
%{counts: %{nonode@nohost: 1}, errors: %{}}
iex(3)> Map.new()
%{}
iex(4)> ** dbg got EXIT - terminating: {trace_handler_crashed,
{function_clause,
[{'Elixir.IEx.Config',default_option,
[width],
[{file,"lib/iex/config.ex"},{line,63}]},
{'Elixir.IEx.Config',
'-default_config/0-fun-0-',1,
[{file,"lib/iex/config.ex"},{line,60}]},
{'Elixir.Enum','-map/2-lists^map/1-0-',2,
[{file,"lib/enum.ex"},{line,1088}]},
{'Elixir.Enum','-map/2-lists^map/1-0-',2,
[{file,"lib/enum.ex"},{line,1088}]},
{'Elixir.IEx.Config',configuration,0,
[{file,"lib/iex/config.ex"},{line,56}]},
{'Elixir.Dbg.Handler',handle_event,2,
[{file,"lib/dbg/handler.ex"},{line,9}]},
{dbg,handle_traces,4,
[{file,"dbg.erl"},{line,819}]},
{dbg,tracer_loop,2,
[{file,"dbg.erl"},{line,783}]}]}}

=ERROR REPORT==== 9-Jan-2016::23:05:46 ===
** Generic server 'Elixir.Dbg.Watcher' terminating
** Last message in was {'DOWN',#Ref<0.0.4.689>,process,<0.121.0>,
{trace_handler_crashed,
{function_clause,
[{'Elixir.IEx.Config',default_option,
[width],
[{file,"lib/iex/config.ex"},{line,63}]},
{'Elixir.IEx.Config','-default_config/0-fun-0-',1,
[{file,"lib/iex/config.ex"},{line,60}]},
{'Elixir.Enum','-map/2-lists^map/1-0-',2,
[{file,"lib/enum.ex"},{line,1088}]},
{'Elixir.Enum','-map/2-lists^map/1-0-',2,
[{file,"lib/enum.ex"},{line,1088}]},
{'Elixir.IEx.Config',configuration,0,
[{file,"lib/iex/config.ex"},{line,56}]},
{'Elixir.Dbg.Handler',handle_event,2,
[{file,"lib/dbg/handler.ex"},{line,9}]},
{dbg,handle_traces,4,[{file,"dbg.erl"},{line,819}]},
{dbg,tracer_loop,2,
[{file,"dbg.erl"},{line,783}]}]}}}
** When Server state == #{'struct' => 'Elixir.Dbg.Watcher',
dbg_ref => #Ref<0.0.4.688>,
tracer => nil,
tracer_ref => nil}
** Reason for termination ==
** {trace_handler_crashed,
{function_clause,
[{'Elixir.IEx.Config',default_option,
[width],
[{file,"lib/iex/config.ex"},{line,63}]},
{'Elixir.IEx.Config','-default_config/0-fun-0-',1,
[{file,"lib/iex/config.ex"},{line,60}]},
{'Elixir.Enum','-map/2-lists^map/1-0-',2,
[{file,"lib/enum.ex"},{line,1088}]},
{'Elixir.Enum','-map/2-lists^map/1-0-',2,
[{file,"lib/enum.ex"},{line,1088}]},
{'Elixir.IEx.Config',configuration,0,
[{file,"lib/iex/config.ex"},{line,56}]},
{'Elixir.Dbg.Handler',handle_event,2,
[{file,"lib/dbg/handler.ex"},{line,9}]},
{dbg,handle_traces,4,[{file,"dbg.erl"},{line,819}]},
{dbg,tracer_loop,2,[{file,"dbg.erl"},{line,783}]}]}}

@fishcakez
Copy link
Owner

Unfortunately this is due to a bug in Elixir 1.2.0. It is fixed in 1.3.0-dev and 1.2.1-dev. elixir-lang/elixir@a6b80a1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants