# Syntax Error while installing new Nodes

**URL:** <https://discourse.nodered.org/t/syntax-error-while-installing-new-nodes/4020>\
**Category:** General\
**Created:** [16 October 2018 06:01 UTC](https://discourse.nodered.org/t/syntax-error-while-installing-new-nodes/4020 "2018-10-16T06:01:32Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![MrTreffnix601](https://avatars.discourse-cdn.com/v4/letter/m/ee59a6/32.png) [@MrTreffnix601](https://discourse.nodered.org/u/MrTreffnix601)\
**Post date:** [16 October 2018 06:01 UTC](https://discourse.nodered.org/t/syntax-error-while-installing-new-nodes/4020/1 "2018-10-16T06:01:32Z")

</div>

Hello, I´m having some trouble with my Node-RED.

Node-RED [v0.16.2]  
nodejs [v6.12.3]  
Hardware/OS [Siemens IoT Gateway 2040, Yocto Linux]  
Browser [Chrome]

I installed the node-red-contrib-s7comm palette and received the following error:

15 Oct 08:19:05 - [info] Installing module: node-red-contrib-s7comm  
15 Oct 08:20:31 - [info] Installed module: node-red-contrib-s7comm  
15 Oct 08:20:32 - [info] Added node types:  
15 Oct 08:20:32 - [info] - node-red-contrib-s7comm:s7comm read : SyntaxError: Unexpected token )  
15 Oct 08:20:32 - [info] - node-red-contrib-s7comm:s7comm write : SyntaxError: Unexpected token )  
15 Oct 08:20:32 - [info] - node-red-contrib-s7comm:s7comm : SyntaxError: Unexpected token )

I have already searched in the s7comm.js file for incorrect syntax, but I don´t know if this is the right place to search for the error? How can I locate the exact file?

Wenn I try to use the new nodes, I get this error...

15 Oct 08:24:26 - [info] Waiting for missing types to be registered:  
15 Oct 08:24:26 - [info] - s7comm read  
15 Oct 08:24:26 - [info] - s7comm write  
15 Oct 08:24:45 - [info] Stopping flows  
15 Oct 08:24:45 - [info] Stopped flows  
15 Oct 08:24:45 - [info] Waiting for missing types to be registered:  
15 Oct 08:24:45 - [info] - s7comm  
15 Oct 08:24:45 - [info] - s7comm read  
15 Oct 08:24:45 - [info] - s7comm write

Whats does this mean? Does this have anything to do with the other error?

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [16 October 2018 07:30 UTC](https://discourse.nodered.org/t/syntax-error-while-installing-new-nodes/4020/2 "2018-10-16T07:30:51Z")

</div>

Hi - as I said on the issue you raised, I suspect this is due to the version of Node.js. I think that module requires node 8 and you have node 6. You will need to update your node.js version to use that module.

---

<div class="post-metadata">

**Author:** ![MrTreffnix601](https://avatars.discourse-cdn.com/v4/letter/m/ee59a6/32.png) [@MrTreffnix601](https://discourse.nodered.org/u/MrTreffnix601)\
**Post date:** [16 October 2018 07:47 UTC](https://discourse.nodered.org/t/syntax-error-while-installing-new-nodes/4020/3 "2018-10-16T07:47:02Z")

</div>

Hi, I tried to do this. The IoT Gateway can´t update to newer versions of node.js. I already looked in the Siemens IoT Gateway forums for a way to update.. but I will continue to look for a way to update.

Is there a way to find out which file throws the syntax error? So that I cann look through the code and correct it for this special using case?

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [16 October 2018 08:15 UTC](https://discourse.nodered.org/t/syntax-error-while-installing-new-nodes/4020/4 "2018-10-16T08:15:10Z")

</div>

If you look the module up on [flows.nodered.org](http://flows.nodered.org) you'll see the link to its github repo. From there, you'll see it only has one .js file - [https://github.com/Hilscher/node-red-contrib-s7comm/blob/master/s7comm.js](https://github.com/Hilscher/node-red-contrib-s7comm/blob/master/s7comm.js)

Nick

---

<div class="post-metadata">

**Author:** ![MrTreffnix601](https://avatars.discourse-cdn.com/v4/letter/m/ee59a6/32.png) [@MrTreffnix601](https://discourse.nodered.org/u/MrTreffnix601)\
**Post date:** [16 October 2018 08:23 UTC](https://discourse.nodered.org/t/syntax-error-while-installing-new-nodes/4020/5 "2018-10-16T08:23:20Z")

</div>

Thanks for your advice, I will try it this way.

---

<div class="post-metadata">

**Author:** ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)\
**Post date:** [16 October 2018 10:19 UTC](https://discourse.nodered.org/t/syntax-error-while-installing-new-nodes/4020/6 "2018-10-16T10:19:50Z")

</div>

Is suspect it is the same cause for their Issues 4 and 5 - [https://github.com/Hilscher/node-red-contrib-s7comm/issues/](https://github.com/Hilscher/node-red-contrib-s7comm/issues/)  
So if you manage to fix it several people would very much appreciate it.

---

<div class="post-metadata">

**Author:** ![MrTreffnix601](https://avatars.discourse-cdn.com/v4/letter/m/ee59a6/32.png) [@MrTreffnix601](https://discourse.nodered.org/u/MrTreffnix601)\
**Post date:** [16 October 2018 10:42 UTC](https://discourse.nodered.org/t/syntax-error-while-installing-new-nodes/4020/7 "2018-10-16T10:42:23Z")

</div>

I pulled the git repository, made a new branch, cherry picked an old version of the .js file and changed some lines. Thats working for me an my Gateway.

I´m going to fork the repository and link it there.

---

<div class="post-metadata">

**Author:** ![Patrickhaas87](https://avatars.discourse-cdn.com/v4/letter/p/b19c9b/32.png) [@Patrickhaas87](https://discourse.nodered.org/u/Patrickhaas87)\
**Post date:** [20 March 2019 21:32 UTC](https://discourse.nodered.org/t/syntax-error-while-installing-new-nodes/4020/8 "2019-03-20T21:32:00Z")

</div>

Hello, I also have problems with node-red on the Siemens IOT

Node-RED [v0.19.6]  
nodejs [v6.8.0]  
Hardware/OS [Siemens IoT Gateway 2040, Yocto Linux v2.2.0]

If the s7comm node requires a more recent version of Nodejs, I do not know how to update it.  
Can anybody help me further?
