# Filter errors in sidebar

**URL:** <https://discourse.nodered.org/t/filter-errors-in-sidebar/71044>\
**Category:** General\
**Created:** [22 November 2022 12:12 UTC](https://discourse.nodered.org/t/filter-errors-in-sidebar/71044 "2022-11-22T12:12:46Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![digidax](https://avatars.discourse-cdn.com/v4/letter/d/edb3f5/32.png) [@digidax](https://discourse.nodered.org/u/digidax)\
**Post date:** [22 November 2022 12:12 UTC](https://discourse.nodered.org/t/filter-errors-in-sidebar/71044/1 "2022-11-22T12:12:46Z")

</div>

Hi,  
I'm using the node-red-contrib-s7 node to read from S7 PLC. Working fine.  
But some PLCs are not in use 24/7. This produces the error: Error: connect EHOSTUNREACH  
When working on a flow, often it overfills the debug sidebar with this errors. The errors are displaying also, if the filter is set to current flow, where no S7 node is present. How can I solve this?

Thanks for any hints,  
Frank

---

<div class="post-metadata">

**Author:** ![jbudd](https://avatars.discourse-cdn.com/v4/letter/j/5f8ce5/32.png) [@jbudd](https://discourse.nodered.org/u/jbudd)\
**Post date:** [22 November 2022 12:25 UTC](https://discourse.nodered.org/t/filter-errors-in-sidebar/71044/2 "2022-11-22T12:25:34Z")

</div>

Some thoughts:

- Turn off the debug node.
- Use a switch node to throw away payloads containing "EHOSTUNREACH".
- Maintain an array of currently active devices and only show messages about these.

---

<div class="post-metadata">

**Author:** ![digidax](https://avatars.discourse-cdn.com/v4/letter/d/edb3f5/32.png) [@digidax](https://discourse.nodered.org/u/digidax)\
**Post date:** [22 November 2022 13:03 UTC](https://discourse.nodered.org/t/filter-errors-in-sidebar/71044/3 "2022-11-22T13:03:26Z")

</div>

There's no debug node active. As I have found out, the error is produced by node.js

> [@jbudd](#):
>
> Maintain an array of currently active devices and only show messages about these.

In this flow I have selected a directly placed inject node, deployed it and select this node, then in the sidebar set the filter to "selected" node, no success, the EHOSTUNREACH error are still displaying.

---

<div class="post-metadata">

**Author:** ![jbudd](https://avatars.discourse-cdn.com/v4/letter/j/5f8ce5/32.png) [@jbudd](https://discourse.nodered.org/u/jbudd)\
**Post date:** [22 November 2022 13:08 UTC](https://discourse.nodered.org/t/filter-errors-in-sidebar/71044/4 "2022-11-22T13:08:26Z")

</div>

Sorry, I assumed it was debug nodes.

Can you use a Catch node to handle the errors?

> [@digidax](#):
>
> in the sidebar set the filter to "selected" node,

Actually I can't get "Filter this node" to do anything either, but I'm sure it works 😉

---

<div class="post-metadata">

**Author:** ![digidax](https://avatars.discourse-cdn.com/v4/letter/d/edb3f5/32.png) [@digidax](https://discourse.nodered.org/u/digidax)\
**Post date:** [22 November 2022 13:36 UTC](https://discourse.nodered.org/t/filter-errors-in-sidebar/71044/5 "2022-11-22T13:36:02Z")

</div>

Have selected the nodes which are producing the errors to a catch node with no debug output: no Chance, Errors still in debug sidebar present:

 ![grafik](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/8/e/8ea134f74aa9d298b6f844c8951616f3cee167f3.png)

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [22 November 2022 13:41 UTC](https://discourse.nodered.org/t/filter-errors-in-sidebar/71044/6 "2022-11-22T13:41:55Z")

</div>

I assume that the error is coming directly from an S7 config node that you have configured to connect to a non-existent PLC. To stop those you will either have to remove that config node (which you probably don't want to do, if it is only a temporary shutdown) or contact the node author to get him/her to provide something like a checkbox in the node config to say whether you want the errors to be seen.

---

<div class="post-metadata">

**Author:** ![digidax](https://avatars.discourse-cdn.com/v4/letter/d/edb3f5/32.png) [@digidax](https://discourse.nodered.org/u/digidax)\
**Post date:** [23 November 2022 05:05 UTC](https://discourse.nodered.org/t/filter-errors-in-sidebar/71044/7 "2022-11-23T05:05:53Z")

</div>

Thanks for helping. Have add a feature request: [https://github.com/st-one-io/node-red-contrib-s7/issues/116](https://github.com/st-one-io/node-red-contrib-s7/issues/116)

If outher users have this problem too, please leave a sign on Github to contribute this feature request.

Thanks, Frank

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [22 January 2023 05:06 UTC](https://discourse.nodered.org/t/filter-errors-in-sidebar/71044/8 "2023-01-22T05:06:19Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
