How to monitor a dynamic WAN IP address

Tags: #<Tag:0x00007f616ebb3588> #<Tag:0x00007f616ebb34c0> #<Tag:0x00007f616ebb33f8>

Perhaps that square bracket is the error. It is not in my script.

Oh, don’t how this typo happens. Copy paste your original and restarted the Raspberry Pi. But same behavior

2017-09-10 20:55:20.521 [ERROR] [ab.binding.http.internal.HttpBinding] - Transformation ‘JS(valid_ip.js)’ threw an exception. [response=91.240.65.131
]
org.openhab.core.transform.TransformationException: An error occurred while loading script.
at org.openhab.core.transform.TransformationHelper$TransformationServiceDelegate.transform(TransformationHelper.java:62)[189:org.openhab.core.compat1x:2.1.0]
at org.openhab.binding.http.internal.HttpBinding.execute(HttpBinding.java:189)[188:org.openhab.binding.http:1.10.0]
at org.openhab.core.binding.AbstractActiveBinding$BindingActiveService.execute(AbstractActiveBinding.java:157)[189:org.openhab.core.compat1x:2.1.0]
at org.openhab.core.service.AbstractActiveService$RefreshThread.run(AbstractActiveService.java:169)[189:org.openhab.core.compat1x:2.1.0]

Update: Moved the *.js from scripts to transform folder and it is working

1 Like

Hi Robert,

I have implemented your script on OH2.2 and it works, but I got this warning in my openhab.lg file:
2018-01-30 15:20:11.016 [WARN ] [.core.transform.TransformationHelper] - Cannot get service reference for transformation service of type JS
2018-01-30 15:20:11.020 [WARN ] [ab.binding.http.internal.HttpBinding] - Couldn’t transform response because transformationService of type ‘JS’ is unavailable

What is the problem ?

Bye Mirko

I think you need to install the JavaScript transformation service first. The easiest wat is to do this through Paper UI.

That was the problem.

Thanks