fix(fleet): persist fleet name in definition body + restore button cursor - #552
Merged
rschardosin merged 1 commit intoSep 26, 2026
Conversation
…rsor Two Studio UI fixes: 1. "Save Agent" in the Fleet UI returned HTTP 400 "fleet name is required". The plan/template display name was stored only in the ent `name` column, never in the definition body. On read, GetPlan deserialized the body into *fleet.FleetPlan without injecting the column name, so plan.Name was empty and the agent PATCH handler's plan.Validate() failed on its first check. FleetPlan embeds FleetConfig and both declare a `name` JSON tag, so encoding/json populates only the shallower FleetPlan.Name and leaves the embedded FleetConfig.Name (the field Validate checks) empty — unlike the YAML path, which syncs them explicitly. GetPlan now reconciles both fields and falls back to the `name` column, healing legacy rows on read. Save writes the resolved name back into the body so new rows are self-consistent. Mirrored in the template store. 2. Tailwind v4's Preflight (unlike v3) no longer sets cursor:pointer on buttons, so no button in Studio showed a hand on hover. Restore it for enabled buttons and role="button" elements. Verified in-browser: agent PATCH now returns 200, editor panel closes, buttons show a pointer cursor on hover.
corey-aloia
force-pushed
the
fix/fleet-save-agent-name-and-button-cursor
branch
from
September 25, 2026 12:41
0153e58 to
22599db
Compare
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
Two Studio UI fixes.
Bug 1 — "Save Agent" returned HTTP 400
"fleet name is required". A plan/template's display name was stored only in the entnamecolumn, never in the definition body. On read,GetPlandeserialized the body into*fleet.FleetPlanwithout the column name, soplan.Namewas empty and the agent PATCH handler'sValidate()failed. Compounding it,FleetPlanembedsFleetConfigand both declare anameJSON tag, soencoding/jsonfills only the outerFleetPlan.Nameand leaves the embeddedFleetConfig.Name(the fieldValidatechecks) empty. Fix:GetPlan/GetFleetnow reconcile both name fields and fall back to thenamecolumn (healing legacy rows on read);Savewrites the resolved name back into the body. Mirrored in the template store.Bug 2 — no pointer cursor on buttons. Tailwind v4's Preflight dropped
cursor: pointeron<button>(v3 set it). Restored for enabled buttons /role="button"inweb/src/index.css.Testing
go test ./pkg/store/entstore/... ./pkg/api/...green (pre-existing unrelatedTestOAuthServerCleanupfailure confirmed on cleanmain).go vet/gofmt/npm run typecheckclean.