Repository navigation
refactor: rename onTrace to onError - #2121
Conversation
- Rename CopilotTraceEvent to CopilotErrorEvent and CopilotTraceHandler to CopilotErrorHandler - Update CopilotRuntime class to use onError instead of onTrace - Update all React core components and hooks to use onError terminology - Update GraphQL resolver to use errorGraphQLError method name - Rename test files from *-trace.test.* to *-error.test.* and update content - Update documentation to reference onError instead of onTrace - Fix linter errors in example files (Next.js Image components, useEffect dependencies) - Fix Jest type configuration in react-core package This refactor provides better semantic clarity by using 'error' terminology instead of 'trace' for error handling throughout the CopilotKit codebase.
- Update CopilotRuntime.mdx to use CopilotErrorHandler instead of CopilotTraceHandler - Update CopilotKit.mdx to use CopilotErrorHandler instead of CopilotTraceHandler - Update documentation terminology from 'tracing' to 'error handling' These changes were auto-generated during the precommit hook after the onTrace to onError refactor.
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
1 Skipped Deployment
|
WalkthroughThe changes systematically rename and refocus all tracing-related types, handlers, props, methods, and documentation from "trace" to "error" semantics throughout the CopilotKit codebase. This affects shared types, runtime, React components, hooks, context, tests, and documentation, shifting the observability and debugging interface from tracing events to error events. Changes
Sequence Diagram(s)sequenceDiagram
participant UI as React Component
participant Context as CopilotContext
participant Runtime as CopilotRuntime
participant Handler as onError Handler
UI->>Context: Triggers error event (e.g., UI error)
Context->>Runtime: Passes error context
Runtime->>Handler: Calls onError(errorEvent)
Handler-->>Runtime: Handles error event (async/sync)
Possibly related PRs
Suggested reviewers
📜 Recent review detailsConfiguration used: .coderabbit.yaml 📒 Files selected for processing (1)
✅ Files skipped from review due to trivial changes (1)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (11)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
Documentation and Community
|
🦋 Changeset detectedLatest commit: a84b897 The changes in this PR will be included in the next version bump. This PR includes changesets to release 7 packages
Click here if you're a maintainer who wants to add another changeset to this PR |
|
Preview environments destroyed for this pull request. |
Test ResultsStatus: ✅ Passed (View Run) Commit: cd78737 Duration: 234.4s Total Tests: 20 Pass Rate: 100.0% Failed Tests: 0 🔍 Detailed Resultscoagents-research-canvasCoAgents Research Canvas (UI) - Local Depenencies
coagents-qa-nativeCoAgents QA Native (UI) - Local
coagents-qa-textCoAgents QA Text (UI) - Local
coagents-routingCoAgents Routing (UI) - Local
next-openaiNext OpenAI - Self Hosted
|
Summary by CodeRabbit
New Features
onError) for enhanced error reporting and observability.Refactor
onTracewithonErrorand related type names for clarity.Documentation
onErrorandCopilotErrorHandler.