# Debug popout - does this already exist?

**URL:** <https://discourse.nodered.org/t/debug-popout-does-this-already-exist/48802>\
**Category:** General\
**Created:** [23 July 2021 03:57 UTC](https://discourse.nodered.org/t/debug-popout-does-this-already-exist/48802 "2021-07-23T03:57:32Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![mdkrieg](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/mdkrieg/32/39091_2.png) [@mdkrieg](https://discourse.nodered.org/u/mdkrieg)\
**Post date:** [23 July 2021 03:57 UTC](https://discourse.nodered.org/t/debug-popout-does-this-already-exist/48802/1 "2021-07-23T03:57:32Z")

</div>

I was browsing the Share Your Nodes forum today and came across this thread: [Flogger - the advanced logging node!](https://discourse.nodered.org/t/flogger-the-advanced-logging-node) - and [this post](https://discourse.nodered.org/t/flogger-the-advanced-logging-node/12382/4) piqued my interest.

I'm not so interested in logging my debugs to files, but having a separate debug dashboard sounds great!

So, I set out to see what it would take to hack it together using what's already available.

I found I could open `./debug/view/view.html` in a second window, but it doesn't connect on it's own.

Poking around in the code I found `handleDebugMessage()` in `debug-utils.js`

Then I found out I could do `RED.comms.subscribe("debug",console.log)` in the main UI to get my debugs to the browser console (cool!).

Then I discovered `RED.comms.connect()`, but it fails with a bogus path.

Next, I set `RED.settings.apiRootUrl = "http://myroot.url/"` and boom! it connects!

I'm feeling pretty slick at this point but get stuck because `subscribe("debug",handleDebugMessage)` creates debug messages in my second window but they're all `undefined` even though the browser console gets the full data.

I take another peek at the GitHub and I see this commit message on `lib/debug/debug.js`: "[Set apiRootUrl for debug pop-out to load locales properly](https://github.com/node-red/node-red/commit/c9acfdb1d7d19c1ad75e8d34e7c1d7d0931ca7b4)"

...has this already been done? Is there a way to get additional and theoretically limitless debug windows??

Please enlighten me o knowledgeable ones 🙏

---

<div class="post-metadata">

**Author:** ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)\
**Post date:** [23 July 2021 04:52 UTC](https://discourse.nodered.org/t/debug-popout-does-this-already-exist/48802/2 "2021-07-23T04:52:25Z")

</div>

> [@mdkrieg](#):
>
> Is there a way to get additional and theoretically limitless debug windows??

From the [docs](https://nodered.org/docs/user-guide/editor/sidebar/debug)...

> Note: the Debug sidebar can only show the 100 most recent messages. If the sidebar is currently showing a filtered list of messages, the hidden messages still count towards the 100 limit. If a flow has noisy Debug nodes, rather than filter them from the sidebar it can be better to disable them by clicking their button in the workspace.

> The button in the sidebar footer can be used to open a separate browser window containing the Debug sidebar

---

<div class="post-metadata">

**Author:** ![mdkrieg](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/mdkrieg/32/39091_2.png) [@mdkrieg](https://discourse.nodered.org/u/mdkrieg)\
**Post date:** [23 July 2021 05:11 UTC](https://discourse.nodered.org/t/debug-popout-does-this-already-exist/48802/3 "2021-07-23T05:11:16Z")

</div>

Yup, there it is, all along.

Thanks for the quick reply!

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [23 July 2021 18:55 UTC](https://discourse.nodered.org/t/debug-popout-does-this-already-exist/48802/4 "2021-07-23T18:55:53Z")

</div>

You could, of course, also output all of your debug messages to the log then use another program to grab and process the log.

---

<div class="post-metadata">

**Author:** ![mdkrieg](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/mdkrieg/32/39091_2.png) [@mdkrieg](https://discourse.nodered.org/u/mdkrieg)\
**Post date:** [23 July 2021 19:40 UTC](https://discourse.nodered.org/t/debug-popout-does-this-already-exist/48802/5 "2021-07-23T19:40:05Z")

</div>

What sort of program would do this? Sorry for my ignorance, I'm sure there's lots out there. I was playing with making one but wanted to avoid having to re-invent the code folding (although it doesn't look that bad with [jsonView](https://github.com/yesmeck/jquery-jsonview)).

I'm actually working on a node to pop open a window just for a specific debug node ...and huzzah!

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/a/7/a7b82d6236b1367f19a8778f61f34f41d2d21967.png)

Just finished this as I'm reading your message.

Link to GitHub repo: [https://github.com/mdkrieg/node-red-contrib-debug-specific](https://github.com/mdkrieg/node-red-contrib-debug-specific)

---

<div class="post-metadata">

**Author:** ![craigcurtin](https://avatars.discourse-cdn.com/v4/letter/c/94ad74/32.png) [@craigcurtin](https://discourse.nodered.org/u/craigcurtin)\
**Post date:** [24 July 2021 04:40 UTC](https://discourse.nodered.org/t/debug-popout-does-this-already-exist/48802/6 "2021-07-24T04:40:36Z")

</div>

If you are putting out to a file as suggested by Julian - then the Tail node is the obvious candidate and some form of input form on it to allow eithr grep (easiest) or regex parameters for filtering the output.

Craig

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [24 July 2021 14:04 UTC](https://discourse.nodered.org/t/debug-popout-does-this-already-exist/48802/7 "2021-07-24T14:04:25Z")

</div>

Coupled with grep or some such to filter things.

Of course, if you are putting stuff into logs, you can use anything that understands text files. This is something that flows through to enterprise monitoring as well so there are hundreds of tools that will work with log files and do monitoring and alerting.

For example:

> **[Create Metrics and Store as Time Series Data | InfluxData](https://www.influxdata.com/blog/telegraf-correlate-log-metrics-data-performance-bottlenecks/)**
>
> InfluxData is excited to announce that log monitoring support is the latest addition to Telegraf. Read more about our Telegraf Logparser here.

---

<div class="post-metadata">

**Author:** ![craigcurtin](https://avatars.discourse-cdn.com/v4/letter/c/94ad74/32.png) [@craigcurtin](https://discourse.nodered.org/u/craigcurtin)\
**Post date:** [24 July 2021 23:54 UTC](https://discourse.nodered.org/t/debug-popout-does-this-already-exist/48802/8 "2021-07-24T23:54:38Z")

</div>

Yep - i was more saying to him that if he wanted to extend his debugging within NR - it would be nice to tail the file into his debug window with some form of configureable parameters for watching it scroll by

Craig

---

<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:** [7 August 2021 23:55 UTC](https://discourse.nodered.org/t/debug-popout-does-this-already-exist/48802/9 "2021-08-07T23:55:30Z")

</div>

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