This is part of a larger problem I am working on. However, I have attempted to break it down to the simplest form possible.
I am using JSON.Net, and trying to deserialize several JSON objects into KeyValuePair, but I cannot get even a simple example test to work.
var pair = JsonConvert.DeserializeObject<KeyValuePair<string, string>>(@"""the key"": ""the value""");
This throws a JsonReaderException -- After parsing a value an unexpected character was encountered: :. Line 1, position 10.
It seems to choke on the colon character, which I find rather odd. I've used JSON.Net several times before, and never have run into anything like this.