amweiss / dark-sky-core

A .NET Standard Library for using the Dark Sky API.
MIT License
54 stars 14 forks source link

Icon not returning for Currently #26

Closed FreezingCode closed 6 years ago

FreezingCode commented 6 years ago

Under Response -> Currently, Icon always returns None, although it does show up in the response if I paste the call into the browser. Using v3.1.3

https://api.darksky.net/forecast/your-key/44.8365032,-93.2734517

missingicon

resp

Seems to also be true regarding Response -> Daily -> Data -> Icon.

amweiss commented 6 years ago

It's changed now, but if I look at tomorrow at 8am it shows the right icon. So make sure your GetForecast request in the program matches that URL request. image

mgbbs commented 6 years ago

This is happening to me also. Project is targeting .NET Framework 4.6.1, Newtonsoft.Json 11.0.2 installed. DarkSkyCore v1.4.0 was working fine, upgraded to 3.1.5 and the Icon is always set to "None", all other properties were deserialized just fine. Downgraded to 3.0.0, it was still happening. Downgraded to 1.4.0 again and it's working fine. I'll do a bit more investigating.

Edit: looks like it breaks starting in v2.0.0

Deserialization works fine if I run a unit test locally with the DarkSkyCore source, slightly modified to get it working in Visual Studio 2015. Could this possibly be something with the NuGet build or is this a .NET Core issue?

amweiss commented 6 years ago

I'm running a web service with asp.net core 2.1 and DarkSkyCore 3.1.5 from NuGet and seeing Icons returned. I don't currently have a framework 4.6.1 setup so I can't verify that.