Unable to use any JS transformation

Hi all,

today I copy/pasted two different items from different web sites. Both use http binding + JS transformation and both fail when loading the *.js files in my /etc/openhab2/transform folders. No clue why. openhab.log says:

An error occurred while loading script

Furthermore I see that the http binding works fine and the result is returned correctly, but then thrown as an exception when loading the js file. Seems it cannot find it or permissions are wrong. Latter are correct.

What’s the best way to trouble shoot this?

Stefan

any push into the right direction is highly appreciated.

Post your .js file here.

Maybe too easy, but as there is no info yet about it from your side:
You did install http binding and js transformation service successful?

The error without a file in that folder seems valid.
For the situation when is files are present:
Maybe you can post the is files here, so we can have a look at them too?

sorry guys, I think this was error 60 (error sits 60cm in front of screen)

in one case I made a typo in the filename and in the other case the script was faulty. sorry again

No problem, mistakes happen every day. None of us is perfect. :slightly_smiling_face:

May I ask you to mark your last post as solution?
So others with javascript transformation problems can see the final result of this topic directly in the first post.