# Chat Trigger - Error in sub-node ‘Window Buffer Memory’ when Loading Previous Session

**URL:** <https://community.n8n.io/t/chat-trigger-error-in-sub-node-window-buffer-memory-when-loading-previous-session/47757>\
**Category:** Questions\
**Created:** [June 3, 2024, 9:15pm UTC](https://community.n8n.io/t/chat-trigger-error-in-sub-node-window-buffer-memory-when-loading-previous-session/47757 "2024-06-03T21:15:45Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![thomasmay](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/thomasmay/32/33375_2.png) [@thomasmay](https://community.n8n.io/u/thomasmay)\
**Post date:** [June 3, 2024, 9:15pm UTC](https://community.n8n.io/t/chat-trigger-error-in-sub-node-window-buffer-memory-when-loading-previous-session/47757/1 "2024-06-03T21:15:45Z")

</div>

## Describe the problem/error/question

When using a modified version of this flow: [Chat with OpenAI Assistant (by adding a memory) | n8n workflow template](https://n8n.io/workflows/2098-chat-with-openai-assistant-by-adding-a-memory/)

and embedding the chat trigger in a website. The OpenAI assistant is perfectly usable and has memory, but when the webpage is refreshed or a new page is loaded and the embed chat widget tries to retrieve past messages from ‘Window Buffer Memory’ is errors out.

## What is the error message (if any)?

Error in sub-node ‘Window Buffer Memory’

## Information on your n8n setup

Node type

@n8n/n8n-nodes-langchain.memoryBufferWindow

Node version

1.1 (Latest version: 1.2)

n8n version

1.42.1 (Cloud)

Time

6/3/2024, 10:48:09 PM

Stack trace

NodeOperationError: Error in sub-node Window Buffer Memory at /usr/local/lib/node\_modules/n8n/node\_modules/n8n-core/dist/NodeExecuteFunctions.js:1759:19 at processTicksAndRejections (node:internal/process/task\_queues:95:5) at async Promise.all (index 0) at Object.getInputConnectionData (/usr/local/lib/node\_modules/n8n/node\_modules/n8n-core/dist/NodeExecuteFunctions.js:1766:19) at Object.getInputConnectionData (/usr/local/lib/node\_modules/n8n/node\_modules/n8n-core/dist/NodeExecuteFunctions.js:2507:24) at Object.webhook (/usr/local/lib/node\_modules/n8n/node\_modules/@n8n/n8n-nodes-langchain/dist/nodes/trigger/ChatTrigger/ChatTrigger.node.js:369:33) at Workflow.runWebhook (/usr/local/lib/node\_modules/n8n/node\_modules/n8n-workflow/dist/Workflow.js:665:15) at Object.executeWebhook (/usr/local/lib/node\_modules/n8n/dist/WebhookHelpers.js:226:33)

---

<div class="post-metadata">

**Author:** ![n8n](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/n8n/32/196425_2.png) [@n8n](https://community.n8n.io/u/n8n)\
**Post date:** [June 3, 2024, 9:15pm UTC](https://community.n8n.io/t/chat-trigger-error-in-sub-node-window-buffer-memory-when-loading-previous-session/47757/2 "2024-06-03T21:15:46Z")

</div>

It looks like your topic is missing some important information. Could you provide the following if applicable.

- **n8n version:**
- **Database (default: SQLite):**
- **n8n EXECUTIONS\_PROCESS setting (default: own, main):**
- **Running n8n via (Docker, npm, n8n cloud, desktop app):**
- **Operating system:**

---

<div class="post-metadata">

**Author:** ![thomasmay](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/thomasmay/32/33375_2.png) [@thomasmay](https://community.n8n.io/u/thomasmay)\
**Post date:** [June 6, 2024, 3:44pm UTC](https://community.n8n.io/t/chat-trigger-error-in-sub-node-window-buffer-memory-when-loading-previous-session/47757/3 "2024-06-06T15:44:28Z")

</div>

> [@n8n](#):
>
> ould you provide the following if applicable.

I did provide this information:

n8n version: 1.42.1  
Running n8n via: Cloud  
n8n EXECUTIONS\_PROCESS: default  
OS: cloud

---

<div class="post-metadata">

**Author:** ![ria](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/ria/32/99251_2.png) [@ria](https://community.n8n.io/u/ria)\
**Post date:** [June 13, 2024, 9:39am UTC](https://community.n8n.io/t/chat-trigger-error-in-sub-node-window-buffer-memory-when-loading-previous-session/47757/4 "2024-06-13T09:39:58Z")

</div>

Hi @thomasmay

Thanks for posting here and welcome to the community! 🍰

I just tried the template myself and I think you will have to just add in the newest node versions for the Window Buffer Memory. Unfortunately when you copy a template it will use the node versions of the time (which may have had some bugs). Let me actually raise this internally.

I had the timeout happening as well but then I changed the nodes (newest version), refreshed my browser and it worked.

Let us know if this helped?

---

<div class="post-metadata">

**Author:** ![thomasmay](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/thomasmay/32/33375_2.png) [@thomasmay](https://community.n8n.io/u/thomasmay)\
**Post date:** [July 13, 2024, 12:14pm UTC](https://community.n8n.io/t/chat-trigger-error-in-sub-node-window-buffer-memory-when-loading-previous-session/47757/5 "2024-07-13T12:14:56Z")

</div>

Been trying to figure out what is going on but I am unable to get the chat to recall prior sessions using the window buffer memory without getting an error.

This first chat session works but when refreshing the page, or navigating to a different page on the site where the embedded chat widget has been placed, the recall of the past chats gives an error.

Here is the link to where the widget is running: [https://euwholesale.zipfit.com](https://euwholesale.zipfit.com)

I updated all the nodes as described. running the latest n8n cloud version.

here is my current flow.

any help would be appreciated.

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/system/32/195824_2.png) [@system](https://community.n8n.io/u/system)\
**Post date:** [October 11, 2024, 12:15pm UTC](https://community.n8n.io/t/chat-trigger-error-in-sub-node-window-buffer-memory-when-loading-previous-session/47757/6 "2024-10-11T12:15:29Z")

</div>

Closed on October 11, 2024, 12:15pm UTC

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