[SOLVED] JSONPATH since 2.5 M3

All,

since 2.5 M3 I get log entries I never had before:

Transformation 'JSONPATH($[0].sensordatavalues[1].value)' threw an exception. [response=<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>

My item:
Number Particles_PM2 "PM2 Partikel [%s] µg/m3" (G_jdbc) {http="<[cacheLuft:600000:JSONPATH($[0].sensordatavalues[1].value)]" }

However, the item is updated frequently and the JSONPATH is correct (according to online JSONPATH tester)

Any suggestion?

It looks like the input is not a valid JSON. Where does it come from? Probably something else changed?

Thanks, Jan.

I just checked it with JSONPATH tester.
The data is coming from here:
http://api.luftdaten.info/v1/sensor/1000/

and the data of the item is updated.

Maybe the http binding changed? Or it‘s just coincidence and the server response looks different? I can‘t imagine what should change the jsonpath behaviour. You could try to open that page in a Webbrowser and click „show source“. If the headers are there, the transformation warning is correct.

I can confirm that the JSONPATH transform works with that JSON string.
By the way, I know where you live now…
I would suggest removing that link and posting an amended json string.

@J-N-K suggestion is good, however the response page is a jsonstring only.
Can you post the http binding config please?

If the item does update, are you getting those exceptions on every request or only ln some?
I’d try to check if all http requests get a complete return.

1 Like

That’s a valid point.
Is does NOT succeed every now and then.
Before M3 I did not see this at all.
Maybe I just need to live with it… or increase the time out timer for http.

After setting the timeout in http from 13 sec to 20 sec I don’t see the error anymore.
:+1: