modify debug.py for some tests