Local Context Error using Pry

I’m working on the lesson on Ruby debugging. I installed pry and pry-byebug. Working in my terminal’s irb, I can successfully write the yell_greeting def with the binding.pry in it, and when I call it, it does indeed stop and open an irb-like pry. I can access variables there, too. However, if I try to use “next” or “continue”, I get the following error:

Error: Cannot find local context. Did you use binding.pry?

See the screenshot below. Why am I getting this error? Do some of pry-byebug’s commands just not work with irb?

This lesson was just updated yesterday. I will look into this problem further & clarify the lesson.

For now, I would suggest going with option 2: save the code into a Ruby file (e.g., script.rb ) and then run the file in your terminal (e.g., ruby script.rb ).