fix(websets): validate import/scope conflicts and improve CLI help#7
Merged
benjaminjackson merged 1 commit intomainfrom Dec 4, 2025
Merged
Conversation
Add validation to prevent using the same import/webset ID in both top-level :import and search[:scope] parameters, which causes a 400 error from the API. Improve CLI help text with: - JSON format examples for all parameters - Clear distinction between :import (data loading) and scope (search filtering) - Warning about the duplicate ID constraint - Additional examples showing scoped searches and hop searches Changes: - Add validate_no_duplicate_ids_in_import_and_scope! to CreateValidator - Add comprehensive tests for duplicate ID detection - Update webset-create help with JSON formats and important warnings - Update webset-search-create help with JSON formats and examples 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
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
Fixes an issue where users could specify the same import/webset ID in both top-level :import and search[:scope] parameters, causing a 400 error from the API. Adds client-side validation to catch this early with a clear error message.
Also significantly improves CLI help text by adding JSON format examples and clarifying the distinction between :import (data loading) and scope (search filtering).
Changes
Validation
Tests
CLI Help Text Improvements
webset-create:
webset-search-create:
Test Results
Files Changed
🤖 Generated with Claude Code