Rails Debugging

Even the best Rails developers in the world have to debug their code from time to time. Unlike other frameworks, Rails makes it easy to debug your code, so you can limit your downtime and get your applications up and running. Debugging has never been easier!
Let’s start our debugging session by installing the byebug gem. This gem enables you to temporarily stop the code execution at a breakpoint, which is marked with the keyword byebug inside the code. When execution reaches the breakpoint, a marker will point to the current line, and you will be able to type in commands.

Link: https://dzone.com/articles/rails-debugging