pdb rewrite