My advice in such cases is:

  1. Spend time and try to think of a possible error.
  2. Narrow the log down to the domain which, as you think, might be buggy. If possible, disable all other logging so it doesn’t consume priceless time.
  3. Simplify log: print inputs, outputs and actions done.
  4. Repeat until you find the error in function output.

This reduces cognitive load down to a minimum and allows you to finally read all the important actions.

This works best if the final execution takes under 1 second, or at most 10 seconds.