When hub loading fails for a path that looks like a hub slug (owner/agent)
and is NOT a markdown file, re-throw the hub error instead of showing
"Not a markdown file". This preserves the actual error from the hub
(e.g., network error, auth error, not found) instead of a confusing
generic message.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Add mockLoadPackageFromHub.mockRejectedValue() to test that verifies
file reading failure for markdown paths. Without this, the hub would
succeed and the file reading code wouldn't be exercised.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- Remove unused variable 'e' in catch block
- Update tests to use .md extensions for file path loading tests
- Add test for non-markdown paths throwing errors
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Update BUILT_IN_TOOL_NAMES to match the actual tools in allBuiltIns.ts,
including UploadArtifact which was missing. Remove incorrect tool names
that don't exist.
Co-authored-by: nate <nate@continue.dev>
Create builtInToolNames.ts with just the tool name constants to avoid
importing the actual tool implementations. This breaks the circular
dependency chain: ToolPermissionService -> allBuiltIns -> subagent ->
executor -> services -> ToolPermissionService.
Co-authored-by: nate <nate@continue.dev>
Move services import to lazy evaluation inside executeSubAgent function
to avoid circular dependency. Pass services as parameter to
buildAgentSystemMessage helper function.
Co-authored-by: nate <nate@continue.dev>
Move services import to lazy evaluation inside the run function to avoid
circular dependency between ToolPermissionService -> allBuiltIns -> subagent -> services -> ToolPermissionService.
This fixes the 'ToolPermissionService is not a constructor' error in tests.
Co-authored-by: nate <nate@continue.dev>
The test was timing out on Windows CI due to slower rendering.
Increased the timeout from 2000ms to 5000ms and interval from 50ms to 100ms
to give more time for the UI to render the /title command.
Generated with [Continue](https://continue.dev)
Co-Authored-By: Continue <noreply@continue.dev>
Co-authored-by: nate <nate@continue.dev>
- Grouped function parameters into HandleToolCallsOptions interface
- Reduced parameter count from 6 to 1 (options object)
- Updated call site in streamChatResponse.ts to use new signature
Co-authored-by: nate <nate@continue.dev>
Add per-message cost tracking by capturing usage data from LLM API
responses and attaching it to assistant messages when saved to session.
- Update addAssistantMessage to accept usage parameter
- Modify handleToolCalls to pass usage to message creation
- Enhance processStreamingResponse to return usage with model and cost
- Calculate cost in cents and include model name in usage metadata
This enables the control plane cost analysis page to display accurate
per-message costs without client-side token estimation.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>