v0.3.2 — assessment backlog B
A developer-experience patch from the same whole-framework assessment that
drove v0.3.1 — twenty DX improvements and small features, all with tests and
shipped docs. No BREAKING changes; everything is additive.
Added
App.WithSeed(func(ctx) error)— register seed funcs that run AFTER
auto-migration (tables exist) and before the listener binds, fixing the
first-run "no such table" footgun.framework.DBFromContext(ctx)/WithDBContext+ an auto-wired
DBContextMiddleware— screens reach the app's*sql.DBfrom the request
context instead of a package-level global handle.access.GetRoles(ctx)(and theframework.GetRolesfacade) — the reader
half of the role-context seam, for role-based UI branching.PluginGetAs[T]— typed plugin lookup mirroring the existingGetAs[T].- Typed interactive effects —
Confirm/AfterText/AfterDisable/ScrollTo/
PushStatebuilders incore-ui/interactive, replacing hand-written
data-fui-*attribute strings. ListOptions.NestedFilters— in-processListAll/CountAllnow apply the
same?author.name=aliceEXISTS-subquery nested filters the HTTP path does.RedisQueue.Start(ctx, interval)— background reclaim ticker recovers jobs
stranded by a crashed worker, matchingDBQueue.Batterywrappers for cache/search/storage (NewBattery) with clean
lifecycle shutdown of background goroutines.gofastr harness creds add|list|delete— store credentials in the
encrypted credstore;gofastr --helpnow lists theharness/agentssubcommands.audit_log.tenant_id— a nullable column (idempotentADD COLUMN) stamped
from the request tenant, so multi-tenant audit trails are scopeable.
Changed
- The OpenAPI spec advertises
?fields=(projection) and?trashed=query
parameters so SDK generators and agents can see them. - Auto-CRUD registration pre-flights entity/screen path collisions with an
actionable diagnostic (names the entity, the colliding path, and the fixes)
instead of the opaque ServeMux/foods/llm.md conflictspanic. - Queue
Queue/Browsable/Replayableinterface assertions moved into source
files (fail at build, not test-link). - The
agents.mdsnippet validator now understands interface methods and
non-Newconstructors (e.g.embed.Open→Index), so it stops
false-flagging correct interface APIs while still catching fictional methods.
Documentation
- New
queue.mdandtestkit.mdreference pages;battery/embednow
shipsagents.go/agents.mdso semantic search is discoverable to agents. - Documented the typed list/get hooks (
OnBeforeList/OnAfterList/OnBeforeGet/
OnAfterGet) and a consolidated hook-skip matrix. - Security docstrings on the unscoped
softdelete.Restore/ForceDelete/WithTrashed
helpers; "Common mistakes" sections (form-module, api-versioning); deeper
observability docs;GetRoles/PluginGetAsdocs; and stale-claim fixes.