Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Debugando com Pry
Search
Philippe Hardardt
October 19, 2019
Programming
56
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Debugando com Pry
https://www.youtube.com/watch?v=s_Hy_RYUCtU
https://github.com/peagha/pry_game_of_life
Philippe Hardardt
October 19, 2019
More Decks by Philippe Hardardt
See All by Philippe Hardardt
Rack - A interface por trás dos frameworks web em Ruby
peagha
1
96
Do ASP.NET para o Rails - as melhores partes
peagha
2
370
Other Decks in Programming
See All in Programming
不幸な GC
chencmd
0
840
AIの中の人になってみる
htkym
0
150
VibeCodingからAgenticWorkflowへ
starfish719
0
1k
夏だ!祭りだ!祭りとはドメインモデリングでは?
ryugen04
0
480
信頼性の目標を誰も求めてない
shubox
0
440
Detecting Compromised CI with eBPF and Cilium Tetragon
lizrice
0
280
in-process GraphQL のすすめ #ginzajs
izumin5210
4
1.5k
Hello, Hiroshima Geospatial Data! — Exploring DoboX with Python
ra0kley
0
140
freee が目指す データ マネジメント戦略 AI-Ready 時代を支える 攻めのガバナンスとは
freee
PRO
0
550
[PyCon KR 2026] More Variants, More Diversity for AI Accelerators
achimnol
0
130
コンパウンドプロダクト開発のためのローカルプロセスマネージャー再発明 #layerxgo
izumin5210
0
590
まずはプロンプトガイドを読もう、話はそれからだ
kiakiraki
1
240
Featured
See All Featured
ReactJS: Keep Simple. Everything can be a component!
pedronauck
666
130k
YesSQL, Process and Tooling at Scale
rocio
174
15k
The untapped power of vector embeddings
frankvandijk
2
1.8k
VelocityConf: Rendering Performance Case Studies
addyosmani
331
25k
New Earth Scene 8
popppiees
3
2.5k
Jess Joyce - The Pitfalls of Following Frameworks
techseoconnect
PRO
1
390
The Spectacular Lies of Maps
axbom
PRO
1
950
Building Flexible Design Systems
yeseniaperezcruz
330
41k
Faster Mobile Websites
deanohume
310
32k
What's in a price? How to price your products and services
michaelherold
247
13k
Code Review Best Practice
trishagee
74
20k
Typedesign – Prime Four
hannesfritz
42
3.2k
Transcript
Debugando com Pry
Oi, eu sou o Phil
None
Mas antes…
Jogo da vida de Conway
None
Implementado em Ruby
[código ao vivo] https://github.com/peagha/ pry_game_of_life
Recapitulando
binding.pry if true pry: criar um breakpoint quando o código
atingir um determinado estado
whereami pry: ver o código onde se encontra o breakpoint
atual
edit pry: edit Classe#método ou edit Classe Editar o código
fonte de um arquivo e recarregar o mesmo
show-source pry: show-source Classe#método ou show-source Classe Ver o o
fonte de um método ou classe
disable-pry Desliga o pry até o fim da execução do
programa
up / down pry-byebug: up: subir para o método que
chama o atual down: voltar para o método atual
$variaveis_globais Ruby: variáveis que você pode acessar em qualquer lugar
def inspect Ruby: definir o método que será usado pelo
Pry ou IRB para apresentar um objeto
Ferramental de debug
Leiam os docs
Obrigado! peagha @philHenri