Handle "Invalid byte" error in msgpack