Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
309 changes: 296 additions & 13 deletions package-lock.json

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion packages/cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
},
"dependencies": {
"@google/gemini-cli-core": "file:../core",
"@google/genai": "1.16.0",
"@google/genai": "1.30.0",
"@iarna/toml": "^2.2.5",
"@modelcontextprotocol/sdk": "^1.15.1",
"@types/update-notifier": "^6.0.8",
Expand Down
2 changes: 1 addition & 1 deletion packages/cli/src/services/McpPromptLoader.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ const mockPrompt = {
{ name: 'trail', required: false, description: "The animal's trail." },
],
invoke: vi.fn().mockResolvedValue({
messages: [{ content: { text: 'Hello, world!' } }],
messages: [{ content: { type: 'text', text: 'Hello, world!' } }],
}),
};

Expand Down
5 changes: 3 additions & 2 deletions packages/cli/src/services/McpPromptLoader.ts
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,8 @@ export class McpPromptLoader implements ICommandLoader {
};
}

if (!result.messages?.[0]?.content?.['text']) {
const maybeContent = result.messages?.[0]?.content;
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This MCP type seems to have changed, and now a type field is provided.

if (maybeContent.type !== 'text') {
return {
type: 'message',
messageType: 'error',
Expand All @@ -133,7 +134,7 @@ export class McpPromptLoader implements ICommandLoader {

return {
type: 'submit_prompt',
content: JSON.stringify(result.messages[0].content.text),
content: JSON.stringify(maybeContent.text),
};
} catch (error) {
return {
Expand Down
3 changes: 3 additions & 0 deletions packages/cli/src/ui/hooks/useGeminiStream.ts
Original file line number Diff line number Diff line change
Expand Up @@ -634,6 +634,9 @@ export const useGeminiStream = (
'Response stopped due to image safety violations.',
[FinishReason.UNEXPECTED_TOOL_CALL]:
'Response stopped due to unexpected tool call.',
[FinishReason.IMAGE_PROHIBITED_CONTENT]:
'Response stopped due to prohibited content.',
[FinishReason.NO_IMAGE]: 'Response stopped due to no image.',
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

New finish reasons.

};

const message = finishReasonMessages[finishReason];
Expand Down
2 changes: 1 addition & 1 deletion packages/core/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"@google-cloud/logging": "^11.2.1",
"@google-cloud/opentelemetry-cloud-monitoring-exporter": "^0.21.0",
"@google-cloud/opentelemetry-cloud-trace-exporter": "^3.0.0",
"@google/genai": "1.16.0",
"@google/genai": "1.30.0",
"@iarna/toml": "^2.2.5",
"@joshua.litt/get-ripgrep": "^0.0.3",
"@modelcontextprotocol/sdk": "^1.11.0",
Expand Down
1 change: 0 additions & 1 deletion packages/core/src/prompts/mcp-prompts.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ describe('getMCPServerPrompts', () => {
{
name: 'prompt1',
serverName: 'server1',
tool: { name: 'p1', description: '', inputSchema: {} },
invoke: async () => ({
messages: [
{ role: 'assistant', content: { type: 'text', text: '' } },
Expand Down
15 changes: 0 additions & 15 deletions packages/core/src/prompts/prompt-registry.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,6 @@ describe('PromptRegistry', () => {
const prompt1: DiscoveredMCPPrompt = {
name: 'prompt1',
serverName: 'server1',
tool: {
name: 'prompt1',
description: 'Prompt 1',
inputSchema: {},
},
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This property was removed from the Prompt type in @mcpcontextprotocol/sdk.

invoke: async () => ({
messages: [
{ role: 'assistant', content: { type: 'text', text: 'response1' } },
Expand All @@ -36,11 +31,6 @@ describe('PromptRegistry', () => {
const prompt2: DiscoveredMCPPrompt = {
name: 'prompt2',
serverName: 'server1',
tool: {
name: 'prompt2',
description: 'Prompt 2',
inputSchema: {},
},
invoke: async () => ({
messages: [
{ role: 'assistant', content: { type: 'text', text: 'response2' } },
Expand All @@ -51,11 +41,6 @@ describe('PromptRegistry', () => {
const prompt3: DiscoveredMCPPrompt = {
name: 'prompt1',
serverName: 'server2',
tool: {
name: 'prompt1',
description: 'Prompt 3',
inputSchema: {},
},
invoke: async () => ({
messages: [
{ role: 'assistant', content: { type: 'text', text: 'response3' } },
Expand Down
29 changes: 28 additions & 1 deletion packages/vscode-ide-companion/NOTICES.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
This file contains third-party software notices and license terms.

============================================================
@modelcontextprotocol/sdk@1.15.1
@modelcontextprotocol/sdk@1.22.0
(git+https://github.com/modelcontextprotocol/typescript-sdk.git)

MIT License
Expand Down Expand Up @@ -179,6 +179,33 @@ OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.


============================================================
ajv-formats@3.0.1
(git+https://github.com/ajv-validator/ajv-formats.git)

MIT License

Copyright (c) 2020 Evgeny Poberezkin

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.


============================================================
content-type@1.0.5
(No repository found)
Expand Down