some bugfix of lib.py and format top.py one line.