added pdb tracing for debug