open file in bytes mode fixes UnicodeDecodeError