fix: improve InvalidSourceError message clarity#488
Merged
KyleAMathews merged 4 commits intomainfrom Sep 3, 2025
Merged
Conversation
The InvalidSourceError now provides a clear, actionable error message that: - Explicitly states the problem is passing a non-Collection to a live query - Includes the alias name to help identify which source is problematic - Provides guidance on what should be passed instead (Collection instances) This replaces the generic "Invalid source" message with helpful debugging information. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
🦋 Changeset detectedLatest commit: 8eabb42 The changes in this PR will be included in the next version bump. This PR includes changesets to release 8 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
More templates
@tanstack/db
@tanstack/db-ivm
@tanstack/electric-db-collection
@tanstack/query-db-collection
@tanstack/react-db
@tanstack/solid-db
@tanstack/svelte-db
@tanstack/trailbase-db-collection
@tanstack/vue-db
commit: |
Contributor
|
Size Change: +101 B (+0.16%) Total Size: 65 kB
ℹ️ View Unchanged
|
Contributor
|
Size Change: 0 B Total Size: 1.16 kB ℹ️ View Unchanged
|
samwillis
requested changes
Sep 3, 2025
Collaborator
samwillis
left a comment
There was a problem hiding this comment.
The error should make clear it can be a collection or subquery. Also need changeset
Co-authored-by: Sam Willis <[email protected]>
samwillis
approved these changes
Sep 3, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
InvalidSourceErrormessage to be more descriptive and actionableTest plan
Error message before/after
Before:
After:
🤖 Generated with Claude Code