fix: return snake_case runtime assignments and events (MCP-14) - #45
Merged
Merged
Conversation
GET/PATCH /projects/:id/skill-runtime encoded the Fluent SkillAssignment and SkillRuntimeEvent models directly, so the dashboard received camelCase property names (plus internal fields such as client identity, request hash and detail JSON). Recent events rendered blank, and saved assignments could not be resubmitted. Map both to explicit snake_case response DTOs with only browser-needed fields, and rename the section to Recent Runtime Events. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The runtime-settings PATCH round trip passed locally only because a local env file set FRONTEND_URL; CI has none, so the origin check returned 403. Set FRONTEND_URL in the test app and send that origin. Co-Authored-By: Claude Opus 5.5 <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.
Fixes MCP-14 / #39.
ProjectController.runtimeSettingsResponsereturned the raw FluentSkillAssignmentandSkillRuntimeEventmodels. Fluent encodes Swift property names (traceId,eventType,skillId,activationMode, …), while the dashboard contract reads snake_case. As a result:: runtime, and a dash.skill_id, so any save (including telemetry-only) resubmitted them in a form the PATCH validator rejects.Changes
RuntimeAssignmentResponse/RuntimeEventResponseDTOs for both GET and PATCH, with only browser-needed fields.Tests
swift test --filter SkillUsageRoute(2/2)vitest run components/dashboard/skill-usage-section.test.tsx(9/9),bun run typecheck,bun run lint🤖 Generated with Claude Code