doing encoding sanity checks before voting