def set_trace(frame=None):
 Pdb().set_trace((frame or sys._getframe().f_back))

def set_trace ( frame = None ) : Pdb ( ) . set_trace ( ( frame or sys . _getframe ( ) . f_back ) )
start debugging from frame .