n8n-nodes-github-copilot 3.38.13 → 3.38.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -108,7 +108,7 @@ class GitHubCopilotOpenAI {
|
|
|
108
108
|
role: msg.role,
|
|
109
109
|
content: msg.content,
|
|
110
110
|
};
|
|
111
|
-
if (msg.type && msg.type
|
|
111
|
+
if (msg.type && (msg.type === 'text' || msg.type === 'image_url')) {
|
|
112
112
|
message.type = msg.type;
|
|
113
113
|
}
|
|
114
114
|
messages.push(message);
|
|
@@ -128,19 +128,31 @@ class GitHubCopilotOpenAI {
|
|
|
128
128
|
const tools = advancedOptions.tools;
|
|
129
129
|
if (tools) {
|
|
130
130
|
try {
|
|
131
|
-
if (typeof tools === 'object' && Array.isArray(tools)) {
|
|
131
|
+
if (typeof tools === 'object' && Array.isArray(tools) && tools.length > 0) {
|
|
132
132
|
parsedTools = tools;
|
|
133
133
|
console.log('📥 Received tools as direct array (no parsing needed)');
|
|
134
134
|
}
|
|
135
135
|
else if (typeof tools === 'string' && tools.trim()) {
|
|
136
|
-
|
|
137
|
-
|
|
136
|
+
const parsed = JSON.parse(tools);
|
|
137
|
+
if (Array.isArray(parsed) && parsed.length > 0) {
|
|
138
|
+
parsedTools = parsed;
|
|
139
|
+
console.log('📥 Parsed tools from JSON string');
|
|
140
|
+
}
|
|
141
|
+
else {
|
|
142
|
+
console.log('📥 Tools string parsed but empty or not an array');
|
|
143
|
+
}
|
|
144
|
+
}
|
|
145
|
+
else {
|
|
146
|
+
console.log('📥 Tools field present but empty or invalid');
|
|
138
147
|
}
|
|
139
148
|
}
|
|
140
149
|
catch (error) {
|
|
141
|
-
|
|
150
|
+
console.log('⚠️ Failed to parse tools, ignoring:', error instanceof Error ? error.message : "Unknown error");
|
|
142
151
|
}
|
|
143
152
|
}
|
|
153
|
+
else {
|
|
154
|
+
console.log('📥 No tools specified');
|
|
155
|
+
}
|
|
144
156
|
let max_tokens = advancedOptions.max_tokens || 4096;
|
|
145
157
|
if (!max_tokens || max_tokens <= 0 || isNaN(max_tokens)) {
|
|
146
158
|
max_tokens = 4096;
|
package/dist/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "n8n-nodes-github-copilot",
|
|
3
|
-
"version": "3.38.
|
|
3
|
+
"version": "3.38.14",
|
|
4
4
|
"description": "n8n community node for GitHub Copilot with CLI integration, Chat API access, and AI Chat Model for workflows - access GPT-5, Claude, Gemini and more using your Copilot subscription",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"homepage": "https://github.com/sufficit/n8n-nodes-github-copilot",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "n8n-nodes-github-copilot",
|
|
3
|
-
"version": "3.38.
|
|
3
|
+
"version": "3.38.14",
|
|
4
4
|
"description": "n8n community node for GitHub Copilot with CLI integration, Chat API access, and AI Chat Model for workflows - access GPT-5, Claude, Gemini and more using your Copilot subscription",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"homepage": "https://github.com/sufficit/n8n-nodes-github-copilot",
|