elixir-lang.github.com icon indicating copy to clipboard operation
elixir-lang.github.com copied to clipboard

Add "dbg" section in the "Debugging" guide

Open whatyouhide opened this issue 2 years ago • 7 comments

whatyouhide avatar Jul 20 '22 07:07 whatyouhide

I think we can remove the IO.inspect section? If we want to keep it, I would have this new section after IO.inspect, as it is easier to use than Pry. :)

josevalim avatar Jul 20 '22 07:07 josevalim

Ah, sure! I think IO.inspect/1 is a good intro to the debugging. I'll move the dbg section before breakpoints though.

whatyouhide avatar Jul 20 '22 08:07 whatyouhide

@josevalim ready for re-review 👀

whatyouhide avatar Jul 20 '22 08:07 whatyouhide

I am thinking there is no benefit in talking about IEx.pry directly. We should just teach how to use it through “dbg” API and talk about breaks too. WDYT?

josevalim avatar Jul 20 '22 10:07 josevalim

I don't have a strong preference. I like to talk about pry too because other folks might be more used to something like that. Maybe if the community moves to dbg more in the future, we can revisit this 🤔

whatyouhide avatar Jul 20 '22 13:07 whatyouhide

I like to talk about pry too because other folks might be more used to something like that.

pry is very Ruby specific though and I think having too many options can actually be confusing because people won't know which one to reach out too. That's one of the points of dbg, so we should rally behind it.

josevalim avatar Jul 20 '22 20:07 josevalim

@josevalim pushed more commits, ready for re-review! 🙃

whatyouhide avatar Jul 24 '22 21:07 whatyouhide

:green_heart: :blue_heart: :purple_heart: :yellow_heart: :heart:

josevalim avatar Sep 01 '22 18:09 josevalim