remove unused import, some reformatting
sorting, add some common utils