decoding before parsing