new frame infrastructure and error printing fixes