Fix #954. Remove pdb. Will add the issue as test case.