Aviate, Navigate, Communicate. Troubleshooting is a consistent, but subordinate task to the 3 primary ones.
Isolate-to/switch-to/get-to to a stable air source, ascend, whoops!
The SCUBA twist is the ethical burden of making a reasonable attempt to inform a buddy of the situation before disappearing to the surface. Which reorders things a bit to: Air source, communicaton (if possible), surface.
Troubleshooting is subordinate to buddy responsibility and also to forcing your survival to be in your buddys hands.