The Content-Length
and Content-Encoding
are not necessary in this plugin. Just reporting it because they are standard headers and missing them could indicate that something is not right handling the responses. I just tested also with Android 3.19 and got the same undefined results…
But then other issue: the weather service which this plugin is querying is requesting to use If-Modified-Since
header. If the server has new data it will respond with status 200 but if the data has not been changed since the date in this header the server response will be 304 status.
So my plugin should check that if response status is 200 then update values and if response status is 304 then do nothing. But now when testing if the response status is 304 then console shows message
Response status code does not indicate success: 304 (Not Modified).
and my plugin code is not executed anymore.
So is this intended behavior that plugin cannot receive all status responses or should it be able to receive all?