Debug erlang problems