fix(model): drop non-string tags from modelSearch response#77
Conversation
Numeric IDs appear in the tags array when a server-side join fails. These are internal artefacts — silently skip them rather than failing to unmarshal the response. Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
|
Important Review skippedAuto reviews are disabled on this repository. To trigger a review, include ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches✨ Simplify code
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. Comment |
There was a problem hiding this comment.
Pull request overview
This PR aims to make modelSearch response decoding resilient to server-side data issues where the tags array may contain non-string elements (e.g., numeric IDs), by dropping those elements instead of failing JSON unmarshalling.
Changes:
- Introduces a
ModelTagshelper type with custom JSON unmarshalling that filters out non-string values. - Updates
ModelResult.Tagsto use the new decoding behavior (currently via a type change).
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Numeric IDs appear in the tags array when a server-side join fails. These are internal artefacts — silently skip them rather than failing to unmarshal the response.