Skip to content

Debug in Salesforce fast

Published: at 12:13 PM

Tired of having to create debug logs manually through trace flags?

If, like me, you’re tired of having to go into Setup and set trace flags on yourself or relevant users before beginning to test your new components JUST to have to navigate BACK to Debug Logs to see if they’re being created AND THEN having to open a full log to read …

Debug faster in Salesforce …

Open Developer Console by clicking the gear icon in the top right and clicking developer console (push both mouse buttons to open in new tab).

navigating-to-developer-console-in-salesforce-lightning

Once developer console is open … click on ‘Logs’ tab.

logs-tab-developer-console

Make note of the most recent log listed (unless recent logs is empty) and go to one of your other salesforce-lightning tabs and begin testing your desired components/screens.

recent-log-files-developer-console

After finishing manual testing of the desired components … navigate back to your developer console tab and open one of the new logs listed (see apex example below)

Apex debug log start (notice how you can see when you are entering / exiting methods)

apex-debug-log-start-developer-console

Apex debug log end (take note how you can see # of SOQL queries, DML statements, etc… all in one place)

apex-debug-log-end-developer-console

Filter for only your system debug statements in Apex by clicking ‘Debug Only’ for the fastest debugging experience.

apex-debug-log-debug-only-developer-console

Quick debugging tips