SlideShare uma empresa Scribd logo
1 de 18
Baixar para ler offline
Debugging with Pry
Michal Oláh
@michalolah
@bonetics
Progammers spend 60% of
their time debugging
We should pay attention to
our workflow
“There are no fully fledged IDEs for Ruby on
Rails…”

–Agile Web Development with
Rails
-July 2009
WTF
WTF?
WTF?!
Actually its not that bad
we have
tests after all
And puts is a powerfull thing
But what if you meet this
guy?
Commands
!

binding.pry
play
whereami
edit -c
exit
ls
cd
next, previous, skip, breakpoint (debugger)
Demo 1
!
•

debugging integration tests
!

•

fast feedback of what works and what doesn’t
Demo 2
!
•

debugging controller action
!

•

ls, cd
!

•

inplace code edit and debug with breakpoints
!

•

edit, breakpoint, whereami, wtf?!
!

•

debugging with pry-rescue
Plugins and features
•

pry-debugger (MRI 1.8-1.9)

•

pry-byebug (MRI 2.0+)

•

pry-rescue - resque from exceptions in to a pry
session

•

plymounth - jump into a pry session on test failure

•

pry-rails

•

help command

•

pry custom commands
Resources
•

http://pryrepl.org

•

http://gaslight.co/blog/i-like-pry-but-dot-dot-dot

•

http://railscasts.com/episodes/280-pry-with-rails

•

http://www.youtube.com/watch?v=o90CCPjcIKE

•

https://github.com/m1k3/rubyslava_pry_demo

Mais conteúdo relacionado

Mais procurados

Bsu on rails_testing
Bsu on rails_testingBsu on rails_testing
Bsu on rails_testing
Pavel Shutin
 
WTF TDD?
WTF TDD?WTF TDD?
WTF TDD?
jeremyw
 
Keeping your users happy with testable apps - Greg Shackles
Keeping your users happy with testable apps - Greg ShacklesKeeping your users happy with testable apps - Greg Shackles
Keeping your users happy with testable apps - Greg Shackles
Xamarin
 
'IS THERE JAVASCRIPT ON SWAGGER PLUGINS?' by Dmytro Gusev
'IS THERE JAVASCRIPT ON SWAGGER PLUGINS?' by  Dmytro Gusev'IS THERE JAVASCRIPT ON SWAGGER PLUGINS?' by  Dmytro Gusev
'IS THERE JAVASCRIPT ON SWAGGER PLUGINS?' by Dmytro Gusev
OdessaJS Conf
 

Mais procurados (20)

team++; making your team work better together
team++; making your team work better togetherteam++; making your team work better together
team++; making your team work better together
 
Bsu on rails_testing
Bsu on rails_testingBsu on rails_testing
Bsu on rails_testing
 
WTF TDD?
WTF TDD?WTF TDD?
WTF TDD?
 
Testing Pyramid
Testing PyramidTesting Pyramid
Testing Pyramid
 
Building a PWA with Ionic, Angular and Spring Boot - Jfokus 2017
Building a PWA with Ionic, Angular and Spring Boot - Jfokus 2017Building a PWA with Ionic, Angular and Spring Boot - Jfokus 2017
Building a PWA with Ionic, Angular and Spring Boot - Jfokus 2017
 
Lrug
LrugLrug
Lrug
 
Patterns and antipatterns in Docker image lifecycle as was presented at Globa...
Patterns and antipatterns in Docker image lifecycle as was presented at Globa...Patterns and antipatterns in Docker image lifecycle as was presented at Globa...
Patterns and antipatterns in Docker image lifecycle as was presented at Globa...
 
Patterns and antipatterns in Docker image lifecycle as was presented at Scale...
Patterns and antipatterns in Docker image lifecycle as was presented at Scale...Patterns and antipatterns in Docker image lifecycle as was presented at Scale...
Patterns and antipatterns in Docker image lifecycle as was presented at Scale...
 
Keeping your users happy with testable apps - Greg Shackles
Keeping your users happy with testable apps - Greg ShacklesKeeping your users happy with testable apps - Greg Shackles
Keeping your users happy with testable apps - Greg Shackles
 
DevOps @Scale (Greek Tragedy in 3 Acts) as it was presented at DevOps Detroit...
DevOps @Scale (Greek Tragedy in 3 Acts) as it was presented at DevOps Detroit...DevOps @Scale (Greek Tragedy in 3 Acts) as it was presented at DevOps Detroit...
DevOps @Scale (Greek Tragedy in 3 Acts) as it was presented at DevOps Detroit...
 
DevOps @Scale (Greek Tragedy in 3 Acts) as it was presented at Devoxx 2017
DevOps @Scale (Greek Tragedy in 3 Acts) as it was presented at Devoxx 2017DevOps @Scale (Greek Tragedy in 3 Acts) as it was presented at Devoxx 2017
DevOps @Scale (Greek Tragedy in 3 Acts) as it was presented at Devoxx 2017
 
Test Driven Development on Android (Kotlin Kenya)
Test Driven Development on Android (Kotlin Kenya)Test Driven Development on Android (Kotlin Kenya)
Test Driven Development on Android (Kotlin Kenya)
 
TDD on android. Why and How? (Coding Serbia 2019)
TDD on android. Why and How? (Coding Serbia 2019)TDD on android. Why and How? (Coding Serbia 2019)
TDD on android. Why and How? (Coding Serbia 2019)
 
Chaos Engineering Talk at DevOps Days Austin
Chaos Engineering Talk at DevOps Days AustinChaos Engineering Talk at DevOps Days Austin
Chaos Engineering Talk at DevOps Days Austin
 
Joel Arvidsson, Klarna. What You See is What You Get – a case for visual testing
Joel Arvidsson, Klarna. What You See is What You Get – a case for visual testingJoel Arvidsson, Klarna. What You See is What You Get – a case for visual testing
Joel Arvidsson, Klarna. What You See is What You Get – a case for visual testing
 
PSPDFKit on Android
PSPDFKit on AndroidPSPDFKit on Android
PSPDFKit on Android
 
Hacking on gems
Hacking on gemsHacking on gems
Hacking on gems
 
'IS THERE JAVASCRIPT ON SWAGGER PLUGINS?' by Dmytro Gusev
'IS THERE JAVASCRIPT ON SWAGGER PLUGINS?' by  Dmytro Gusev'IS THERE JAVASCRIPT ON SWAGGER PLUGINS?' by  Dmytro Gusev
'IS THERE JAVASCRIPT ON SWAGGER PLUGINS?' by Dmytro Gusev
 
Burp better - Finding Struts and XXE Vulns with Burp Extensions
Burp better - Finding Struts and XXE Vulns with Burp ExtensionsBurp better - Finding Struts and XXE Vulns with Burp Extensions
Burp better - Finding Struts and XXE Vulns with Burp Extensions
 
Solving Cross-Cutting Concerns in PHP - DutchPHP Conference 2016
Solving Cross-Cutting Concerns in PHP - DutchPHP Conference 2016 Solving Cross-Cutting Concerns in PHP - DutchPHP Conference 2016
Solving Cross-Cutting Concerns in PHP - DutchPHP Conference 2016
 

Destaque

Are Automated Debugging Techniques Actually Helping Programmers
Are Automated Debugging Techniques Actually Helping ProgrammersAre Automated Debugging Techniques Actually Helping Programmers
Are Automated Debugging Techniques Actually Helping Programmers
Chris Parnin
 
Debugging Rails 3 Applications
Debugging Rails 3 ApplicationsDebugging Rails 3 Applications
Debugging Rails 3 Applications
Nathan Broadbent
 
CDFA Annual VC Report for 2013
CDFA Annual VC Report for 2013CDFA Annual VC Report for 2013
CDFA Annual VC Report for 2013
Logan Dawson
 
Financing_Contamination_Remediation_FinalReport
Financing_Contamination_Remediation_FinalReportFinancing_Contamination_Remediation_FinalReport
Financing_Contamination_Remediation_FinalReport
Logan Dawson
 
Eb 14 15 application process
Eb 14 15 application processEb 14 15 application process
Eb 14 15 application process
Foo Fonsey
 
(Pdf) yury chemerkin def_con_2013
(Pdf) yury chemerkin def_con_2013(Pdf) yury chemerkin def_con_2013
(Pdf) yury chemerkin def_con_2013
STO STRATEGY
 
(Pdf) yury chemerkin _ath_con_2013
(Pdf) yury chemerkin _ath_con_2013(Pdf) yury chemerkin _ath_con_2013
(Pdf) yury chemerkin _ath_con_2013
STO STRATEGY
 
AIESEC in SIM 14/15 Team Leaders & Team Members Application
AIESEC in SIM 14/15 Team Leaders & Team Members ApplicationAIESEC in SIM 14/15 Team Leaders & Team Members Application
AIESEC in SIM 14/15 Team Leaders & Team Members Application
Foo Fonsey
 
2014-geothermal-opportunities-usa
2014-geothermal-opportunities-usa2014-geothermal-opportunities-usa
2014-geothermal-opportunities-usa
Gretchen Heberling
 

Destaque (19)

Are Automated Debugging Techniques Actually Helping Programmers
Are Automated Debugging Techniques Actually Helping ProgrammersAre Automated Debugging Techniques Actually Helping Programmers
Are Automated Debugging Techniques Actually Helping Programmers
 
Debugging Rails 3 Applications
Debugging Rails 3 ApplicationsDebugging Rails 3 Applications
Debugging Rails 3 Applications
 
CDFA Annual VC Report for 2013
CDFA Annual VC Report for 2013CDFA Annual VC Report for 2013
CDFA Annual VC Report for 2013
 
Rubyslava beyond the_monolith
Rubyslava beyond the_monolithRubyslava beyond the_monolith
Rubyslava beyond the_monolith
 
Financing_Contamination_Remediation_FinalReport
Financing_Contamination_Remediation_FinalReportFinancing_Contamination_Remediation_FinalReport
Financing_Contamination_Remediation_FinalReport
 
Debugging application using visual studio 2010 and intellitrace
Debugging application using visual studio 2010 and intellitraceDebugging application using visual studio 2010 and intellitrace
Debugging application using visual studio 2010 and intellitrace
 
Eb 14 15 application process
Eb 14 15 application processEb 14 15 application process
Eb 14 15 application process
 
Django debugging
Django debuggingDjango debugging
Django debugging
 
(Pdf) yury chemerkin def_con_2013
(Pdf) yury chemerkin def_con_2013(Pdf) yury chemerkin def_con_2013
(Pdf) yury chemerkin def_con_2013
 
AP_2015_AIESEC in SIM_AP Achievement Awards
AP_2015_AIESEC in SIM_AP Achievement AwardsAP_2015_AIESEC in SIM_AP Achievement Awards
AP_2015_AIESEC in SIM_AP Achievement Awards
 
(Pdf) yury chemerkin _ath_con_2013
(Pdf) yury chemerkin _ath_con_2013(Pdf) yury chemerkin _ath_con_2013
(Pdf) yury chemerkin _ath_con_2013
 
Node.js debugging
Node.js debuggingNode.js debugging
Node.js debugging
 
Debugging Debugging
Debugging DebuggingDebugging Debugging
Debugging Debugging
 
Principles in software debugging
Principles in software debuggingPrinciples in software debugging
Principles in software debugging
 
AIESEC in SIM 14/15 Team Leaders & Team Members Application
AIESEC in SIM 14/15 Team Leaders & Team Members ApplicationAIESEC in SIM 14/15 Team Leaders & Team Members Application
AIESEC in SIM 14/15 Team Leaders & Team Members Application
 
Debugging (Django) application in PyCharm
Debugging (Django) application in PyCharmDebugging (Django) application in PyCharm
Debugging (Django) application in PyCharm
 
Myanmar's Politics, Economy, and Government
Myanmar's Politics, Economy, and GovernmentMyanmar's Politics, Economy, and Government
Myanmar's Politics, Economy, and Government
 
2014-geothermal-opportunities-usa
2014-geothermal-opportunities-usa2014-geothermal-opportunities-usa
2014-geothermal-opportunities-usa
 
Cambios físicos y químicos - Mora Arguelles
Cambios físicos y químicos - Mora ArguellesCambios físicos y químicos - Mora Arguelles
Cambios físicos y químicos - Mora Arguelles
 

Semelhante a Rubyslava debugging with_pry

Waterfalls for Agile in a bag
Waterfalls for Agile in a bagWaterfalls for Agile in a bag
Waterfalls for Agile in a bag
Steve Wells
 
Dev ops lessons learned - Michael Collins
Dev ops lessons learned  - Michael CollinsDev ops lessons learned  - Michael Collins
Dev ops lessons learned - Michael Collins
Devopsdays
 
Fighting Ruby code smell
Fighting Ruby code smellFighting Ruby code smell
Fighting Ruby code smell
olegshpynov
 

Semelhante a Rubyslava debugging with_pry (20)

Hangout Utche #6. "Rambovidnaya problema"
Hangout Utche #6. "Rambovidnaya problema"Hangout Utche #6. "Rambovidnaya problema"
Hangout Utche #6. "Rambovidnaya problema"
 
CI doesn’t start with Jenkins
CI doesn’t start with JenkinsCI doesn’t start with Jenkins
CI doesn’t start with Jenkins
 
Waterfalls for Agile in a bag
Waterfalls for Agile in a bagWaterfalls for Agile in a bag
Waterfalls for Agile in a bag
 
Waterfalls for agile cambridge
Waterfalls for agile cambridgeWaterfalls for agile cambridge
Waterfalls for agile cambridge
 
Battle for Code Quality - A Story of One Java Project
Battle for Code Quality - A Story of One Java ProjectBattle for Code Quality - A Story of One Java Project
Battle for Code Quality - A Story of One Java Project
 
Surviving SOA - delivering (somewhat) continuously on a hostile planet
Surviving SOA - delivering (somewhat) continuously on a hostile planetSurviving SOA - delivering (somewhat) continuously on a hostile planet
Surviving SOA - delivering (somewhat) continuously on a hostile planet
 
Surviving SOA
Surviving SOASurviving SOA
Surviving SOA
 
Quality at Speed - Penny Wyatt
Quality at Speed - Penny WyattQuality at Speed - Penny Wyatt
Quality at Speed - Penny Wyatt
 
Conquering AngularJS Limitations
Conquering AngularJS LimitationsConquering AngularJS Limitations
Conquering AngularJS Limitations
 
Conquering AngularJS Limitations
Conquering AngularJS LimitationsConquering AngularJS Limitations
Conquering AngularJS Limitations
 
Dev ops lessons learned - Michael Collins
Dev ops lessons learned  - Michael CollinsDev ops lessons learned  - Michael Collins
Dev ops lessons learned - Michael Collins
 
Fighting Ruby code smell
Fighting Ruby code smellFighting Ruby code smell
Fighting Ruby code smell
 
React, London JS Meetup, 11 Aug 2015
React, London JS Meetup, 11 Aug 2015React, London JS Meetup, 11 Aug 2015
React, London JS Meetup, 11 Aug 2015
 
Ruby codebases in an entropic universe
Ruby codebases in an entropic universeRuby codebases in an entropic universe
Ruby codebases in an entropic universe
 
Deploying 3 times a day without a downtime @ Rocket Tech Summit in Berlin
Deploying 3 times a day without a downtime @ Rocket Tech Summit in BerlinDeploying 3 times a day without a downtime @ Rocket Tech Summit in Berlin
Deploying 3 times a day without a downtime @ Rocket Tech Summit in Berlin
 
Test Driven Development - Workshop
Test Driven Development - WorkshopTest Driven Development - Workshop
Test Driven Development - Workshop
 
My Little Webap - DevOpsSec is Magic
My Little Webap - DevOpsSec is MagicMy Little Webap - DevOpsSec is Magic
My Little Webap - DevOpsSec is Magic
 
6 reasons Jubilee could be a Rubyist's new best friend
6 reasons Jubilee could be a Rubyist's new best friend6 reasons Jubilee could be a Rubyist's new best friend
6 reasons Jubilee could be a Rubyist's new best friend
 
10+ Deploys Per Day: Dev and Ops Cooperation at Flickr
10+ Deploys Per Day: Dev and Ops Cooperation at Flickr10+ Deploys Per Day: Dev and Ops Cooperation at Flickr
10+ Deploys Per Day: Dev and Ops Cooperation at Flickr
 
Why You Should Be Fixing Bugs
Why You Should Be Fixing BugsWhy You Should Be Fixing Bugs
Why You Should Be Fixing Bugs
 

Último

Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
giselly40
 

Último (20)

Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 

Rubyslava debugging with_pry