replace pymimesniffer with mimetypes from python std lib and refactor FileFormat