%+27788225528 love spells in Huntington Beach Psychic Readings, Attraction sp...
Debugging para el no iniciado
1. De Frustrado a Competente
Debugging para el no iniciado:
Barcamp 2015, Santiago, R.D.
2. What we will cover
Barcamp 2015, Santiago, R.D.
- What is debugging
- Why is hard
- Know yourself
- The true path to debugging
- The rules of debugging
- What debugging displays
- Remember
3. About me
Barcamp 2015, Santiago, R.D.
Leonardo Jimenez (Un entusiasta del software)
Blog: www.leonardo.do
correo: leonardo@codetiger.co
Co-Founder and Developer @Codetiger
We love Python, We use a ton of stuff
One of the organizers of @pythondo && @Jsdo
5. Can you tell me what debugging means to you?
What is debugging?
Barcamp 2015, Santiago, R.D.
6. What is debugging?
Barcamp 2015, Santiago, R.D.
Can you tell me what debugging means to you?
Some frequent answers:
- Make the error go away
- Eliminate the errors on the screen
- “Resolver…!”
7. What is debugging?
Barcamp 2015, Santiago, R.D.
Most of the answers are related to fixing the actual
problem ...
8. What is debugging?
Barcamp 2015, Santiago, R.D.
My (really recent definition) Definition
“Debugging is the process of finding and resolving bugs or
defects in the code in a manner that the code is better than
the way it was found”
9. What is debugging?
Barcamp 2015, Santiago, R.D.
Debugging Normally includes:
1. Get the bug in the database (if you are lucky)
2. Reproduce the problem
3. Automate and simplify the test case (if you know what you
are doing)
4. Find possible infection origins
5. Focus on the most likely origins
6. Isolate the infection chain
7. Correct the defect
10. What is debugging?
Barcamp 2015, Santiago, R.D.
Debugging Normally includes:
1. Get the bug in the database (if you are lucky)
2. Reproduce the problem
3. Automate and simplify the test case (if you know what you
are doing)
4. Find possible infection origins
5. Focus on the most likely origins
6. Isolate the infection chain
7. Correct the defect
{
Understand the Problem
11. What is debugging?
Barcamp 2015, Santiago, R.D.
Debugging Normally includes:
1. Get the bug in the database (if you are lucky)
2. Reproduce the problem
3. Automate and simplify the test case (if you know what you
are doing)
4. Find possible infection origins
5. Focus on the most likely origins
6. Isolate the infection chain
7. Correct the defect
{
Search the Problem
12. What is debugging?
Barcamp 2015, Santiago, R.D.
Debugging Normally includes:
1. Get the bug in the database (if you are lucky)
2. Reproduce the problem
3. Automate and simplify the test case (if you know what you
are doing)
4. Find possible infection origins
5. Focus on the most likely origins
6. Isolate the infection chain
7. Correct the defect{
Fixing it
13. What is debugging?
Barcamp 2015, Santiago, R.D.
Debugging Normally includes:
1. Get the bug in the database (if you are lucky)
2. Reproduce the problem
3. Automate and simplify the test case (if you know what you
are doing)
4. Find possible infection origins
5. Focus on the most likely origins
6. Isolate the infection chain
7. Correct the defect
{
Most of your time goes here
14. Why is debugging hard?
Barcamp 2015, Santiago, R.D.
Key Takeaway #1
Debugging is a problem of scarcity
15. Why is debugging hard?
Barcamp 2015, Santiago, R.D.
Let’s do an exercise:
- Search on Google “Learn to Program”
16. Why is debugging hard?
Barcamp 2015, Santiago, R.D.
Let’s do an exercise:
- Search on Google “Learn to Program”
- 1,540,000,000 Results (1.5 Billion results)
17. Why is debugging hard?
Barcamp 2015, Santiago, R.D.
Let’s do another exercise:
- Search on Google “Implement an
ordered List”
- 3,020,000 Results
18. Why is debugging hard?
Barcamp 2015, Santiago, R.D.
Let’s do another exercise:
- Search on Google “Ordered Hash Table”
- 758,000 Results
19. Why is debugging hard?
Barcamp 2015, Santiago, R.D.
The more advanced your question is,
the less easy answers you will find
20. Why is debugging hard?
Barcamp 2015, Santiago, R.D.
Do you remember your first time?
21. Why is debugging hard?
Barcamp 2015, Santiago, R.D.
Do you remember your first time?
print “Hello world”
22. Why is debugging hard?
Barcamp 2015, Santiago, R.D.
Do you remember your first CRUD App?
Your first blog?, your first to do list?
What do they have in common?
23. Why is debugging hard?
Barcamp 2015, Santiago, R.D.
Do you remember your first CRUD App?
Your first blog?, your first to do list?
What do they have in common?
You knew the whole App!!!
24. Why is debugging hard?
Barcamp 2015, Santiago, R.D.
This is what it feels like working on a new,
different and legacy codebase ...
26. Why is debugging hard?
Barcamp 2015, Santiago, R.D.
The difference between a good developer
and a bad developer is understanding.
27. Why is debugging hard?
Barcamp 2015, Santiago, R.D.
The difference between a good developer
and a bad developer is understanding.
Understanding of what does not change.
28. Know yourself
Barcamp 2015, Santiago, R.D.
Do you understand the basics of your
(Language/Library/framework) or you just
did a tutorial?
29. Know yourself
Barcamp 2015, Santiago, R.D.
Do you read the documentation while
learning the technology or after something’s
break?
30. Know yourself
Barcamp 2015, Santiago, R.D.
Do you know the standard library well or
you just copy/paste from stack overflow?
50. In General
Barcamp 2015, Santiago, R.D.
The code can give you the right result for
the wrong reasons.
51. The True Path to Debugging
Barcamp 2015, Santiago, R.D.
52. The True Path to Debugging
Barcamp 2016, Santiago, R.D.
53. In General
Barcamp 2015, Santiago, R.D.
Key Takeaway #3
Growing as a software developer means
moving from memorisation to understanding
54. In General
Barcamp 2015, Santiago, R.D.
Key Takeaway #4
Avoid shotgun surgery become a neurosurgeon.
55. The True Path to Debugging
Barcamp 2015, Santiago, R.D.
- Know Yourself tools
- Search within your code
- Be one with the universe person who asks
56. The True Path to Debugging
Barcamp 2015, Santiago, R.D.
(You can Name it)
ARE
TOOLS
57. The True Path to Debugging
Barcamp 2015, Santiago, R.D.
LEARN:
- When to use it and when not
- Learn Many and avoid a lot more
- One really well
- Learn the principles
58. In General
Barcamp 2015, Santiago, R.D.
Key Takeaway #5
Debugging is not a tool, is a mindset.
The mindset name is curiosity.
Be Curious.
59. The True Path to Debugging
Barcamp 2015, Santiago, R.D.
READ THE $#%@$%# MANUAL:
- Read the documentation
- Read the specifications
- Read the code (yes, for Fun)
60. The True Path to Debugging
Barcamp 2015, Santiago, R.D.
If Nothing else works ask, but:
- Make sure you read the documentation
- Make your homework
- Tried to solve it yourself
61. The True Path to Debugging
Barcamp 2015, Santiago, R.D.
When asking:
- Be respectful
- Tell the facts not your theories
- Don’t be proud
62. Debugging Rules
Barcamp 2015, Santiago, R.D.
- Understand the system
- Make it Fail
- Quit Thinking and look
- Divide and conquer
- Change one thing at a time
- Keep up an audit trail
- Check if it is on
- Talk with another person
- If you don't fix it, it ain't fixed
64. What is debugging?
Barcamp 2015, Santiago, R.D.
My (really recent definition) Definition
“Debugging is the process of finding and resolving bugs or
defects in the code in a manner that the code is better than
the way it was found”
66. Remember?
Barcamp 2015, Santiago, R.D.
Or do you sing ?
99 little bugs in the code
99 little bugs in the code
Take one down, patch it around
117 little bugs in the code
67. In General
Barcamp 2015, Santiago, R.D.
Key Takeaway #6
In order to be an amazing debugger you
should be an incredible refactorer.
68. In the end
- Don’t rush
- Don’t Panic
- Understand the problem
- Understand your Language
- Understand your tools
- RTFM
In General
Barcamp 2015, Santiago, R.D.