ensure encoding/decoding is done properly in observations, closes #492