{"action":"created","issue":{"url":"https://api.github.com/repos/jvermillard/leshan/issues/57","labels_url":"https://api.github.com/repos/jvermillard/leshan/issues/57/labels{/name}","comments_url":"https://api.github.com/repos/jvermillard/leshan/issues/57/comments","events_url":"https://api.github.com/repos/jvermillard/leshan/issues/57/events","html_url":"https://github.com/jvermillard/leshan/issues/57","id":53884904,"number":57,"title":"Error while parsing the response of resource /3/0/11 (Object/Instance/ErrorCode)","user":{"login":"davidfdezros","id":8007584,"avatar_url":"https://avatars.githubusercontent.com/u/8007584?v=3","gravatar_id":"","url":"https://api.github.com/users/davidfdezros","html_url":"https://github.com/davidfdezros","followers_url":"https://api.github.com/users/davidfdezros/followers","following_url":"https://api.github.com/users/davidfdezros/following{/other_user}","gists_url":"https://api.github.com/users/davidfdezros/gists{/gist_id}","starred_url":"https://api.github.com/users/davidfdezros/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/davidfdezros/subscriptions","organizations_url":"https://api.github.com/users/davidfdezros/orgs","repos_url":"https://api.github.com/users/davidfdezros/repos","events_url":"https://api.github.com/users/davidfdezros/events{/privacy}","received_events_url":"https://api.github.com/users/davidfdezros/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-01-09T16:20:20Z","updated_at":"2015-01-09T16:43:24Z","closed_at":null,"body":"Hi guys,\r\n\r\nI'm not sure if I'm doing something wrong, but when I read the Error Code resource  value (/3/0/11) on a device object, while parsing the response, the interface shows a message with something like \"can't decode the tlv\" and the console outputs the following stack trace:\r\n\r\n![console-error](https://cloud.githubusercontent.com/assets/8007584/5682858/85d85c1c-9823-11e4-966f-2f7c183c12fd.png)\r\n\r\nThe received response packet is equals to, for example, read the resource 3/0/10.\r\n\r\n![wireshark-3-0-10](https://cloud.githubusercontent.com/assets/8007584/5682659/e3e6f57c-9821-11e4-8a6a-3af1ee06c1e9.png)\r\n\r\n![wireshark-3-0-11](https://cloud.githubusercontent.com/assets/8007584/5682664/ea6268b4-9821-11e4-8948-fc79e3ee6e40.png)\r\n\r\nHowever if I read the entire object resources (/3/0), the value is successfully parsed (no error message) and printed in leshan.\r\n\r\nWhat I'm missing or doing wrong?\r\n\r\nExtra Info: I'm using a client based on wakaama implementations but using CoAP RFC."},"comment":{"url":"https://api.github.com/repos/jvermillard/leshan/issues/comments/69360768","html_url":"https://github.com/jvermillard/leshan/issues/57#issuecomment-69360768","issue_url":"https://api.github.com/repos/jvermillard/leshan/issues/57","id":69360768,"user":{"login":"msangoi","id":3940991,"avatar_url":"https://avatars.githubusercontent.com/u/3940991?v=3","gravatar_id":"","url":"https://api.github.com/users/msangoi","html_url":"https://github.com/msangoi","followers_url":"https://api.github.com/users/msangoi/followers","following_url":"https://api.github.com/users/msangoi/following{/other_user}","gists_url":"https://api.github.com/users/msangoi/gists{/gist_id}","starred_url":"https://api.github.com/users/msangoi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/msangoi/subscriptions","organizations_url":"https://api.github.com/users/msangoi/orgs","repos_url":"https://api.github.com/users/msangoi/repos","events_url":"https://api.github.com/users/msangoi/events{/privacy}","received_events_url":"https://api.github.com/users/msangoi/received_events","type":"User","site_admin":false},"created_at":"2015-01-09T16:43:23Z","updated_at":"2015-01-09T16:43:23Z","body":"Hello,\r\n\r\nI think your issue is related to the resource value format.\r\nThe /3/0/10 resource is a \"single\" resource, and when you try to read this resource, the value is expected to be in the \"Plain text\" format.\r\nThe /3/0/11 resource is a \"multiple instance\" resource, so the value is expected to be in \"TLV\" format (even if you have only one instance).\r\n\r\nYour TLV parsing error probably occurs because the /3/0/11 value is returned in \"Plain text\" format.\r\n\r\nNo problem when reading the whole /3/0 instance because the content is encoded in TLV.\r\n\r\nHTH\r\nManu"}}