One of the highlights of Magento Live Europe 2018 was the ‘Elite Bug Squashing’ presentation, held by Tony Brown, Technical Director at Space48.

The topic? How to take your code debugging to another level.

Here, he spoke about 3 different stages in a debugging approach:

– Level 1 – using var_dump, print_r to check your data and research such as googling to check this issue has been encountered before

– Level 2 – Logging your issues to comprehend the issue better and using more advanced tools such as Blackfire and New Relic

– Level 3 – Using Xdebug to step through the code and see exactly what is happening on each line of code. Also writing code that adheres to SOLID principles and create a defensive code strategy to avoid potential pitfalls

He also discussed the ‘Pomodoro Technique’, a strategy we also use when debugging here at IGOO.

It involves approaching an issue in 25 minute stints – if you are no closer to the solution, take a break and come back for another 25 minutes.  During your break away, ask questions about progress and approach; this help to reduce the risk of going down the dreaded rabbit hole.