Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Getting Unstuck: Using the Scientific Method for Debugging

Getting Unstuck: Using the Scientific Method for Debugging

Have you ever gotten really stuck while trying to understand the cause of a bug? Thinking of your debugging session as a science experiment, and using the scientific method can help you make progress again. Come and learn how to adapt the scientific method (the process used for scientific research) to get past that stuck place and find the cause of bugs or production incidents. You’ll walk away with a great new tool to keep you calm and focused in the face of inevitable bugs.

Caroline Taymor

November 16, 2017
Tweet

Other Decks in Technology

Transcript

  1. The plan ◎ When ◎ What ◎ How ◎ Why

    Getting Unstuck | Fog City Ruby @CarolineTaymor
  2. When should I use the Scientific Method for debugging? Photo

    courtesy of Nick Amuscato Getting Unstuck | Fog City Ruby @CarolineTaymor
  3. • “It could be any one of 1000 things!” •

    Overwhelmed • Bewildered • You notice impossible things Getting Unstuck | Fog City Ruby @CarolineTaymor When you have TOO MUCH info Two types of stuck heuristic from Jesse Alford
  4. • “I can’t think of anything” • Frustrated • Stalled

    • “I have no more ideas” Getting Unstuck | Fog City Ruby @CarolineTaymor When you have TOO LITTLE info Two types of stuck heuristic from Jesse Alford
  5. What is the Scientific Method? The process for doing science!

    Photo courtesy of Nick Amuscato Getting Unstuck | Fog City Ruby @CarolineTaymor A way to learn about the world!
  6. Gather Knowledge Ask Questions Make a Hypothesis Design an Experiment

    Run the Experiment Take Good Notes Make a Conclusion Share Out Getting Unstuck | Fog City Ruby @CarolineTaymor
  7. Gather Knowledge Ask Questions Make a Hypothesis Design an Experiment

    Run the Experiment Take Good Notes Make a Conclusion Share Out Getting Unstuck | Fog City Ruby @CarolineTaymor
  8. Gather Knowledge Ask Questions Make a Hypothesis Design an Experiment

    Run the Experiment Take Good Notes Make a Conclusion Share Out Getting Unstuck | Fog City Ruby @CarolineTaymor
  9. Gather Knowledge Ask Questions Make a Hypothesis Design an Experiment

    Run the Experiment Take Good Notes Make a Conclusion Share Out Getting Unstuck | Fog City Ruby @CarolineTaymor
  10. Gather Knowledge Ask Questions Make a Hypothesis Design an Experiment

    Run the Experiment Take Good Notes Make a Conclusion Share Out Getting Unstuck | Fog City Ruby @CarolineTaymor
  11. Gather Knowledge Ask Questions Make a Hypothesis Design an Experiment

    Run the Experiment Take Good Notes Make a Conclusion Share Out Getting Unstuck | Fog City Ruby @CarolineTaymor
  12. Gather Knowledge Ask Questions Make a Hypothesis Design an Experiment

    Run the Experiment Take Good Notes Make a Conclusion Share Out Getting Unstuck | Fog City Ruby @CarolineTaymor
  13. Gather Knowledge Ask Questions Make a Hypothesis Design an Experiment

    Run the Experiment Take Good Notes Make a Conclusion Share Out Getting Unstuck | Fog City Ruby @CarolineTaymor
  14. Gather Knowledge Ask Questions Make a Hypothesis Design an Experiment

    Run the Experiment Take Good Notes Make a Conclusion Share Out Getting Unstuck | Fog City Ruby @CarolineTaymor
  15. How do you debug with the Scientific Method? Photo courtesy

    of Nick Amuscato Getting Unstuck | Fog City Ruby @CarolineTaymor
  16. Design an Experiment What do you need to know to

    (dis)prove your hypothesis? Getting Unstuck | Fog City Ruby @CarolineTaymor
  17. // The time between staging and container creation phase used

    up // 52 seconds of our 3 minute timeout. In a healthy system, the // time between these loglines is usually takes 3-4 seconds. // application logs for c86b59e0-049b-483d-ac93-31c3942774a5 // Time in UTC. This is 5:45:52 AM PDT. The deploy started at 5 AM PDT // Logs from diego.out.log on cell 100 2017-10-19T12:45:51.05 [STG/0] OUT Destroying container 2017-10-19T12:45:52.91 [STG/0] OUT Successfully destroyed container 2017-10-19T12:46:44.78 [CELL/0] OUT Creating container 2017-10-19T12:46:45.08 [CELL/0] OUT Successfully created container Getting Unstuck | Fog City Ruby @CarolineTaymor
  18. // The time between staging and container creation phase used

    up // 52 seconds of our 3 minute timeout. In a healthy system, the // time between these loglines is usually takes 3-4 seconds. // application logs for c86b59e0-049b-483d-ac93-31c3942774a5 // Time in UTC. This is 5:45:52 AM PDT. The deploy started at 5 AM PDT // Logs from diego.out.log on cell 100 2017-10-19T12:45:51.05 [STG/0] OUT Destroying container 2017-10-19T12:45:52.91 [STG/0] OUT Successfully destroyed container 2017-10-19T12:46:44.78 [CELL/0] OUT Creating container 2017-10-19T12:46:45.08 [CELL/0] OUT Successfully created container Getting Unstuck | Fog City Ruby @CarolineTaymor
  19. // The time between staging and container creation phase used

    up // 52 seconds of our 3 minute timeout. In a healthy system, the // time between these loglines is usually takes 3-4 seconds. // application logs for c86b59e0-049b-483d-ac93-31c3942774a5 // Time in UTC. This is 5:45:52 AM PDT. The deploy started at 5 AM PDT // Logs from diego.out.log on cell 100 2017-10-19T12:45:51.05 [STG/0] OUT Destroying container 2017-10-19T12:45:52.91 [STG/0] OUT Successfully destroyed container 2017-10-19T12:46:44.78 [CELL/0] OUT Creating container 2017-10-19T12:46:45.08 [CELL/0] OUT Successfully created container Getting Unstuck | Fog City Ruby @CarolineTaymor
  20. // The time between staging and container creation phase used

    up // 52 seconds of our 3 minute timeout. In a healthy system, the // time between these loglines is usually takes 3-4 seconds. // application logs for c86b59e0-049b-483d-ac93-31c3942774a5 // Time in UTC. This is 5:45:52 AM PDT. The deploy started at 5 AM PDT // Logs from diego.out.log on cell 100 2017-10-19T12:45:51.05 [STG/0] OUT Destroying container 2017-10-19T12:45:52.91 [STG/0] OUT Successfully destroyed container 2017-10-19T12:46:44.78 [CELL/0] OUT Creating container 2017-10-19T12:46:45.08 [CELL/0] OUT Successfully created container Getting Unstuck | Fog City Ruby @CarolineTaymor
  21. // The time between staging and container creation phase used

    up // 52 seconds of our 3 minute timeout. In a healthy system, the // time between these loglines is usually takes 3-4 seconds. // application logs for c86b59e0-049b-483d-ac93-31c3942774a5 // Time in UTC. This is 5:45:52 AM PDT. The deploy started at 5 AM PDT // Logs from diego.out.log on cell 100 2017-10-19T12:45:51.05 [STG/0] OUT Destroying container 2017-10-19T12:45:52.91 [STG/0] OUT Successfully destroyed container 2017-10-19T12:46:44.78 [CELL/0] OUT Creating container 2017-10-19T12:46:45.08 [CELL/0] OUT Successfully created container Getting Unstuck | Fog City Ruby @CarolineTaymor
  22. // The time between staging and container creation phase used

    up // 52 seconds of our 3 minute timeout. In a healthy system, the // time between these loglines is usually takes 3-4 seconds. // application logs for c86b59e0-049b-483d-ac93-31c3942774a5 // Time in UTC. This is 5:45:52 AM PDT. The deploy started at 5 AM PDT // Logs from diego.out.log on cell 100 2017-10-19T12:45:51.05 [STG/0] OUT Destroying container 2017-10-19T12:45:52.91 [STG/0] OUT Successfully destroyed container 2017-10-19T12:46:44.78 [CELL/0] OUT Creating container 2017-10-19T12:46:45.08 [CELL/0] OUT Successfully created container Getting Unstuck | Fog City Ruby @CarolineTaymor
  23. Circle Back Getting Unstuck | Fog City Ruby @CarolineTaymor ◎

    Bug solutions ◎ Old Questions ◎ New questions ◎ New experiments
  24. Share what you learned Getting Unstuck | Fog City Ruby

    Getting Unstuck | Fog City Ruby @CarolineTaymor
  25. Why is the Scientific Method helpful for debugging? 1. Collaboration

    2. Get Unstuck 3. Keep Moving Forward Photo courtesy of Nick Amuscato Getting Unstuck | Fog City Ruby @CarolineTaymor
  26. “ Writing down what you know helps organize your thoughts

    Getting Unstuck | Fog City Ruby @CarolineTaymor
  27. 3. Keep Moving Forward Photo courtesy of Jan Kraus Getting

    Unstuck | Fog City Ruby @CarolineTaymor
  28. We covered ◎ When - you’re stuck on complex bugs

    ◎ What - The process of doing science ◎ How - with lots of writing ◎ Why - the scientific method helps you collaborate, get unstuck, and keep moving forward Getting Unstuck | Fog City Ruby @CarolineTaymor
  29. Gather Knowledge Ask Questions Make a Hypothesis Design an Experiment

    Run the Experiment Take Good Notes Make a Conclusion Share Out Getting Unstuck | Fog City Ruby @CarolineTaymor