fix(10.2-03): reorder Keyword Router rules — debug commands before generic contains

Two bugs: (1) connection array had old fallback at index [9] shifting debug
connections off-by-one, so /errors routed to Show Menu. (2) /debug status
matched rule 1 (contains "status") before rule 11 (startsWith /debug).
Fix: move startsWith debug rules [1-4] before contains rules [5-12].

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Lucas Berger
2026-02-08 13:12:26 -05:00
parent e7074288f0
commit 69eb4e0b9d
+120 -120
View File
@@ -180,6 +180,98 @@
"renameOutput": true,
"outputKey": "menu"
},
{
"id": "keyword-errors",
"conditions": {
"options": {
"caseSensitive": false,
"typeValidation": "loose"
},
"conditions": [
{
"id": "starts-with-errors",
"leftValue": "={{ $json.message.text }}",
"rightValue": "/errors",
"operator": {
"type": "string",
"operation": "startsWith"
}
}
],
"combinator": "and"
},
"renameOutput": true,
"outputKey": "errors"
},
{
"id": "keyword-clear-errors",
"conditions": {
"options": {
"caseSensitive": false,
"typeValidation": "loose"
},
"conditions": [
{
"id": "starts-with-clear",
"leftValue": "={{ $json.message.text }}",
"rightValue": "/clear",
"operator": {
"type": "string",
"operation": "startsWith"
}
}
],
"combinator": "and"
},
"renameOutput": true,
"outputKey": "clear-errors"
},
{
"id": "keyword-debug",
"conditions": {
"options": {
"caseSensitive": false,
"typeValidation": "loose"
},
"conditions": [
{
"id": "starts-with-debug",
"leftValue": "={{ $json.message.text }}",
"rightValue": "/debug",
"operator": {
"type": "string",
"operation": "startsWith"
}
}
],
"combinator": "and"
},
"renameOutput": true,
"outputKey": "debug"
},
{
"id": "keyword-trace",
"conditions": {
"options": {
"caseSensitive": false,
"typeValidation": "loose"
},
"conditions": [
{
"id": "starts-with-trace",
"leftValue": "={{ $json.message.text }}",
"rightValue": "/trace",
"operator": {
"type": "string",
"operation": "startsWith"
}
}
],
"combinator": "and"
},
"renameOutput": true,
"outputKey": "trace"
},
{
"id": "keyword-status",
"conditions": {
@@ -363,98 +455,6 @@
},
"renameOutput": true,
"outputKey": "status"
},
{
"id": "keyword-errors",
"conditions": {
"options": {
"caseSensitive": false,
"typeValidation": "loose"
},
"conditions": [
{
"id": "starts-with-errors",
"leftValue": "={{ $json.message.text }}",
"rightValue": "/errors",
"operator": {
"type": "string",
"operation": "startsWith"
}
}
],
"combinator": "and"
},
"renameOutput": true,
"outputKey": "errors"
},
{
"id": "keyword-clear-errors",
"conditions": {
"options": {
"caseSensitive": false,
"typeValidation": "loose"
},
"conditions": [
{
"id": "starts-with-clear",
"leftValue": "={{ $json.message.text }}",
"rightValue": "/clear",
"operator": {
"type": "string",
"operation": "startsWith"
}
}
],
"combinator": "and"
},
"renameOutput": true,
"outputKey": "clear-errors"
},
{
"id": "keyword-debug",
"conditions": {
"options": {
"caseSensitive": false,
"typeValidation": "loose"
},
"conditions": [
{
"id": "starts-with-debug",
"leftValue": "={{ $json.message.text }}",
"rightValue": "/debug",
"operator": {
"type": "string",
"operation": "startsWith"
}
}
],
"combinator": "and"
},
"renameOutput": true,
"outputKey": "debug"
},
{
"id": "keyword-trace",
"conditions": {
"options": {
"caseSensitive": false,
"typeValidation": "loose"
},
"conditions": [
{
"id": "starts-with-trace",
"leftValue": "={{ $json.message.text }}",
"rightValue": "/trace",
"operator": {
"type": "string",
"operation": "startsWith"
}
}
],
"combinator": "and"
},
"renameOutput": true,
"outputKey": "trace"
}
]
},
@@ -5463,6 +5463,34 @@
"index": 0
}
],
[
{
"node": "Process Debug Command",
"type": "main",
"index": 0
}
],
[
{
"node": "Process Debug Command",
"type": "main",
"index": 0
}
],
[
{
"node": "Process Debug Command",
"type": "main",
"index": 0
}
],
[
{
"node": "Process Debug Command",
"type": "main",
"index": 0
}
],
[
{
"node": "Prepare Status Input",
@@ -5525,34 +5553,6 @@
"type": "main",
"index": 0
}
],
[
{
"node": "Process Debug Command",
"type": "main",
"index": 0
}
],
[
{
"node": "Process Debug Command",
"type": "main",
"index": 0
}
],
[
{
"node": "Process Debug Command",
"type": "main",
"index": 0
}
],
[
{
"node": "Process Debug Command",
"type": "main",
"index": 0
}
]
]
},