Repository navigation
Releases
v0.26.0
Additive release. Nothing existing changes. New: httpx.Serve, httpx.WriteBudget, middleware.FixedWindow, middleware.Gzip, health.Version, netguard. Released with testdb/v0.2.0 (see below). Full list in CHANGELOG.md.
MIGRATION: what each app deletes and what it imports
Tronc imports are all github.com/FacileStudio/tronc/<pkg>. Bump tronc to v0.26.0 and tronc/testdb to v0.2.0 first.
1. Serve and graceful shutdown (all 24 backends)
Delete the &http.Server{...}, the ListenAndServe goroutine, the select on serverErrCh and the server.Shutdown block in main.go. Import .../httpx and call httpx.Serve(ctx, router, httpx.ServeConfig{Addr: addr, Logger: logger}), where ctx comes from signal.NotifyContext(ctx, os.Interrupt, syscall.SIGTERM). It returns nil after a clean stop.
Defaults: read header 5s, read 30s, write 60s, idle 120s, shutdown grace 15s. Zero takes the default, a negative value means no limit. Serve never wraps the ResponseWriter, so SSE, WebSocket and http.ResponseController keep working.
Keep today's behaviour with these settings:
| App | Set |
|---|---|
| Bulle | WriteTimeout: -1, OnShutdown: []func(){pushSender.CloseStreams} (HTTP/2 resets a stream at an expired write deadline; model output streams for minutes) |
| Nuage | ReadTimeout: -1, WriteTimeout: -1, ShutdownGrace: 45*time.Second, MaxHeaderBytes: 1<<20 (multi-gigabyte transfers) |
| Courrier | ReadTimeout: 10*time.Second, WriteTimeout: 15*time.Second, IdleTimeout: 60*time.Second. Its assist and push handlers already move their own deadlines with ResponseController, which still works. |
| Echo | ReadTimeout/WriteTimeout: 30*time.Second, ShutdownGrace: 10*time.Second. Replace extendWriteDeadline(suffix, d) with httpx.WriteBudget(d) on the summary and recording routes (r.With(...)), then delete the helper. |
| Antenne | Nothing: it gains read, write and idle timeouts it never had. Check any long route first. |
| Everyone else | Nothing, or copy the 5/10/15/60 values if a route depends on them. |
2. Rate limiter and gzip
- Agenda and Courrier: delete
apps/api/internal/middleware/ratelimit.go. Usemiddleware.FixedWindow(middleware.FixedWindowConfig{Requests: 100, Window: time.Minute, MaxKeys: 50000}); Courrier'sRateLimitBybecomesKeyFunc. Same window shape and envelope as before. Import.../middleware. - Perception: delete
internal/middleware/ratelimit.goand use the existingmiddleware.Ratelimit(recipe indocs/ratelimit.md). ItsRetry-Afterbecomes the computed wait instead of 60. - Echo: stays app-side (identity-dependent budgets, /64 and /48 buckets). Documented in
docs/ratelimit.md. - Agenda and Courrier: delete
apps/api/internal/middleware/gzip.goand mountmiddleware.Gzip. It now compresses only text, JSON, XML, JavaScript and SVG, skips Range, Upgrade, event-stream, 204 and 304, and addsVary: Accept-Encoding.
3. testdb (tronc/testdb v0.2.0)
- Model drift: in each of Agenda, Courrier, Echo, GoSvelteBoilerplate, Journal, Nuage, Perception, Place, Plume, Prisme, Sablier, Vision (and Capsule/Casier where present), replace the body of
schemas/columns_test.go(compatibleTypes,migratedColumnTypes, the loop) withtestdb.AssertModelsMatch(t, db, queryModels...). Perception's pgvector column passestestdb.MatchOptions{Extra: ...}viaAssertModelsMatchWith. The porte and MCP schema-drift tests (Plume, Courrier, Echo, Prisme) stay. - Hand-rolled harnesses: Echo and Journal delete
internal/testdb/testdb.goand calltestdb.OpenIsolatedwithtestdb.URLFrom("ECHO_TEST_DATABASE_URL"); Antenne deletesinternal/pgtest; Casier deletesinternal/testdbfortestdb.Openplustestdb.LockID; Sablier usesOpen,TruncateandLockID; Place setsConfig.SearchPathTail: []string{"public"}. Nuage'stests/helpers_test.godrops and recreatespublic; move it toOpenandTruncate.
4. netguard (security: one copy)
Import .../netguard.
- Registre: delete
apps/api/internal/netguard/(6 files).Guard.Client(timeout, roots)becomes(&netguard.Guard{TLS: roots}).Client(timeout). - sonar: delete
internal/netguard/{ranges,guard,dial}.goand their tests; keepproxy.go, qualify its calls withnetguard.. UseGuard.ClientFollowing(timeout)where redirects must be followed (add the cookie jar locally). - Journal
modules/alerts/safeguard.go: deleteisBlockedIP, setControl: netguard.Controlon the dialer. - Plume: delete
internal/urlsafe;netguard.CheckURLat save time and(&netguard.Guard{}).Client(timeout)for delivery. - Nuage
modules/settings/service.go: deleteisPrivateAddress, callnetguard.CheckURL, and send the webhook with a guarded client (today only the save-time check exists, so a rebinding name passes). - porte
oidc/avatar.go: replaceisPublicIP,embeddedIPv4andblockedNetworks(needs tronc >= v0.26.0 in porte). - Unguarded today, add a guard or document why not: Sonde (checker probes and webhooks), Antenne (webhooks, delivery senders and probes), Casier and Echo webhooks, Vision webhooks. Gare's ingress probe is a loopback probe, not an SSRF guard.
5. health.Version
Agenda, Bulle, Casier, Courrier, Echo, Journal, Prisme, Sonde (identical 13-line apps/api/version.go), and Bobine, Capsule, Opus, Vision, Sablier (variants): delete versionHandler, keep var version = "dev" in main.go for -ldflags "-X main.version=...", and mount router.Get("/version", health.Version(version)). Import .../health (already imported for Mount). The answer now carries Cache-Control: no-store.
Notes
tronc/env(env.LoadCore,env.Stringand the typed helpers) is still skipped by GoSvelteBoilerplate, Place and Sonde, which hand-rollos.Getenvconfig (about 700 lines). GoSvelteBoilerplate seeds every new app, so fix it first.- The GitHub release for v0.25.0 was missing; it is created with this one.
v0.25.0
Adds bulle.Client.Summarize, makes bulle.Client.DecideAI run as the user, and removes bulle.ErrNoActingFor (breaking). joblock.Hold now checks for a cancelled context with a select. See CHANGELOG.md.
MIGRATION
bulle.ErrNoActingForis gone. An emptyActingForonDecideAIis now the normal call with the user's exchanged token. Delete anyerrors.Is(err, bulle.ErrNoActingFor)branch. SettingActingForkeeps the old service-key call and is deprecated, as isActingForHeader.Summarize(ctx, SummarizeRequest{Query, Sources})callsPOST /api/ai/summarizeas the user theTokenSourcespeaks for.
testdb/v0.2.0
tronc/testdb v0.2.0, additive. New: AssertModelsMatch, AssertModelsMatchWith, AllowedTypes, OpenIsolated, LockID, URLFrom, Config.SearchPathTail. See testdb/CHANGELOG.md.
MIGRATION
- 13 apps delete the body of
schemas/columns_test.goand calltestdb.AssertModelsMatch(t, db, queryModels...). Importgithub.com/FacileStudio/tronc/testdb(already required). Details per app are in the tronc v0.26.0 release notes. - Echo, Journal, Antenne, Casier, Sablier and Place can delete their own schema harness:
OpenIsolated(schema per test),LockID(goose lock per schema),URLFrom(their own env var),SearchPathTail(publicfor extensions).
v0.24.0
v0.23.2
Rust: tronc-rs follow-up; TS: tronc-ts follow-up.
Changed
mcp.Failureplan-limit text says nothing was done and names the feature readably. A
PlanLimitnow reads "Nothing was done: the plan limit for storage is reached. Upgrade at
" instead of "The plan limit for nuage.storage_gb is reached. Upgrade at ", so a
model no longer tells the user a refused write partly happened, and no longer shows an
internal key. A small table maps the suite's forfait keys (ai.access,courrier.mailboxes,
echo.max_call_minutes,echo.max_participants,echo.recording,nuage.storage_gb,
sonar.searches_daily); any other key stays as is. The upgrade link still goes through
errors.SafeUpgradeURL.payment_requiredtext is unchanged. Vectormcp_failure.json
gainsplan_limit_known_key_readableandplan_limit_unknown_key_raw, source@v0.23.2.
Rust: tronc-rs follow-up (text and table). TS: tronc-ts follow-up (text and table).
v0.23.1
Rust: tronc-rs follow-up; TS: tronc-ts follow-up.
Security
mcprequest dedupe matches the OAuth client.Requestreuses an open action only when
the user, kind, target, digest and the requesting client id all match. Before, a second
client of the same person reused the first client's action, so consent given to client B
could let client A collect the result (found in Casier, where the result is revealed
values). Each client now opens its own action. Go-only in the vectors: nomcp_*subject
covers confirmations, and the test pins it (TestRequestReusesOnlyTheSameClientsAction).
Rust: tronc-rs follow-up. TS: tronc-ts follow-up.
Added
bulle.StatusError.RetryAfter: the wait Bulle'sRetry-Afterheader names, delay
seconds or an HTTP date, on a 429 or a 503, capped at a day; zero when it names none or a
past date. A 503 with aRetry-Afternow comes back as a*StatusErrorthat still wraps
ErrUnreachable; a 503 without one is unchanged. Vectorbulle_errors.jsongains four
cases and aretry_after_secondsfield, source@v0.23.1. Rust: tronc-rs follow-up. TS:
tronc-ts follow-up.
v0.23.0
Rust: ported in tronc-rs v0.5.0; TS: ported in tronc-ts v0.3.0. Each entry names the port's
counterpart.
Added
mcp.AppSpec.Scopes, so a read-only server (sonar) goes throughNewAppwith
Scopes{Read: "<app>.read"}instead of copying it. Rust: tronc-rsApp::new. TS: has
read-only servers already.mcp.StateKey(app, secret): SHA-256 over<app>-mcp-state:<secret>, byte for byte the key
the thirteen apps derived by hand, so signed questions survive the move. Vector
mcp_state_key.json. Rust:state_key. TS:stateKey.- Bounded pending actions.
Requestasks about the person's open action of the same kind,
target and digest instead of inserting another, on the link and the MRTR paths.
PostgresPending.Openreads at mostOpenLimit+ 1 rows;Confirmations.Listkeeps
OpenLimit(100) and reportstruncated, whichPendingListcarries as
"truncated": true.PostgresPending.Prune,PrunePending(ctx, exec, olderThan)and
KeepPruned(ctx, store, every, olderThan, logger)delete the actions resolved or expired
more than 30 days ago, hourly. No migration or index. A Postgres-backed test pins that prune
spares open, recently resolved and recently expired actions. The dedupe is best effort, and a
reused action keeps its first client and expiry. Rust: dedupe, limit, prune. TS: same. - Confirmation text.
Outcome.Messagecarries the standard "Nothing happened yet…" text
(Confirmations.Waiting(), naming the pending lifetime, or the time a reused action has left)
on a link, andMessageDeclinedon a declinedResume, the text eight apps each kept a copy
of. Rust: ask/resume helper. TS: same. PendingPage.Mount(router, auth...)mounts the confirm page API at/mcp/pending
(PendingAPIPath) behind the app's auth, nil-safe for docs tests. Rust:PendingPagerouter.
TS: Go-only for now, tronc-ts has no confirm page.- Offset pager
Page(items, cursor, size),Offset(cursor)andCursor(offset, total), the
copies in Plume, Casier and Echo. Rust: pager. TS: same. mcp.PlanLimit:Failuremaps any error withPlanLimit() (feature, upgradeURL), such as
porte'sforfait.LimitErroronce it gains the method, to "The plan limit for is
reached. Upgrade at ". Rust and TS: same text.- Typed Bulle AI calls.
bulle.Client.Complete(ctx, CompleteRequest{System, Prompt, Input, Schema, MaxTokens, SpaceID})forPOST /api/ai/completeas the user, and
DecideAI(ctx, DecideRequest{ActingFor, State, Questions})forPOST /api/ai/decideas the
app's service withX-Bulle-Acting-For.SpaceIDis omitted when empty, so it is safe before
Bulle accepts it.Request.Headeradds headers toCall.PlanRequired.Limitcarries a
402'slimit. Rust:complete(space_id). TS:complete,decideAI. - Conformance vectors for
mcpandbulle:mcp_http(401 and 403 challenges, write gate,
Origin refusal, 405, RFC 9728 metadata),mcp_rate_limit(default burst 120, burst equal to the
per-minute limit, one bucket per user, none depending on replay speed),mcp_digest,mcp_state_key,mcp_failure,bulle_errors(402 bare and
enveloped, upgrade URL filter, 4xx, 5xx, redirect) andbulle_paths. Theirsourceis
tronc@v0.23.0; the eight older files are unchanged. Rust: consume in CI. TS: same.
Changed
mcp.Failurekeeps anunavailableerror's message instead of the generic text, and
re-checks apayment_requiredupgrade URL witherrors.SafeUpgradeURL. Rust and TS: align.bulle.Clientnever follows a redirect: a 3xx fails asErrUnreachable, so the token
never leaves for another URL. It works on a copy ofConfig.HTTPClient. Rust: redirect-refusing
client. TS: same.- Annotations rule written into
mcp.Annotationsand docs/api.md: overwriting or removing
the user's data, or silencing an alert, isDestructive; only a tool with no further effect
on a repeat call isIdempotent. Docs only; Rust and TS: annotation presets. - build(deps): the root module requires
jackc/pgx/v5v5.9.2 for the Postgres-backed prune
test, which runs whenTEST_DATABASE_URLis set (CI sets it), and movesgolang.org/x/textto
v0.41.0 andgolang.org/x/syncto v0.22.0, the versionstestdbalready uses. No package
outside the tests imports pgx.
Fixed
mcp.Failurecapitalised one byte, so a message starting with an accented letter
("échec") came out garbled. It now uppercases the first rune. Rust and TS were already right.
v0.22.0
Added
mcp.PendingPage[T], the confirm page API.RoutesservesGET /,POST /{id}/confirm
andPOST /{id}/dismiss, the handlers Courrier, Agenda, Nuage, Opus and Sablier each wrote in
modules/mcp/pending_routes.go. The app passes how to read the signed-in person (User, which
refuses a delegated token with the newErrDelegated), the detail of each target
(Describe, over the sharedPendingItemits item type embeds) and the confirm result
(Done).PendingList[T],PendingResultandEmptyRequestreplace the five copies of
types_pending.go;PendingRoutes[T](PendingDoc)replaces the fivedocumentation.go
route lists.mcp.NewApp(AppConfig, AppSpec), the wiring every app'sNewServicerepeated: resource
check, confirmations with the confirm page at<origin>/pending, and the server at
PerMinutecalls a minute (default 120).AppConfigis the five apps' identicalConfig.mcp.Digestandmcp.TargetIDs. The fingerprint all five apps computed (hex of the first
16 bytes of SHA-256 over NUL-joined fields), byte for byte, so actions opened before an app
adopts it still confirm; and the user-plus-numeric-target parse Agenda, Opus and Sablier
shared.- Erasing pending actions.
Pending.Erase(ctx, userIDs...), implemented by
PostgresPendingandmcptest.Pending, andErasePending(ctx, exec, userIDs...)to run the
same delete inside an account erasure's own transaction. Courrier, Nuage, Opus and Sablier
each kept their ownDELETE FROM mcp_actionsfor this. - apiref reflects embedded structs and generic types. The fields of a struct embedded by
value are promoted into the outer schema, as encoding/json promotes them, instead of being
dropped (unexported type) or nested under the type name. An instance of a generic type gets a
valid component name,PendingList_Item, instead of one holding brackets and package paths. - Conformance vectors.
conformance/vectors/*.jsonpins whaterrors,httpjson,health,
the request log, the security headers, the client-IP rule,spaandspa.InlineScriptHashes
answer today, in a JSON envelope (source,subject,cases) a port reads as its
specification.go test ./conformancebuilds every case from the real packages and fails on
any drift;go test ./conformance -updaterewrites the files after a deliberate change.
tronc-rs copies them at a tag.
Changed
- Breaking for custom stores:
mcp.PendinggainsErase. Every suite app uses
PostgresPendingormcptest.Pending, which both implement it. - Licence: tronc is now licensed under
MIT(seeLICENSE); before this, the repository carried no licence. The nestedmigrateandtestdbmodules carry the same file.
v0.20.0
Added
- Read-only MCP servers.
mcp.Options.Scopesmay setReadalone when every tool is
read-only: the metadata then lists only that scope and the write gate is not mounted. A tool
that is not read-only on such a server is refused at boot.mcptest.Runaccepts metadata with
one scope and fails when a server listing no write scope serves a write tool. sonar's search
server is the first user, withsonar.readas its only scope.
Fixed
mcp.Failurekeeps plan refusals actionable. Apayment_requirederror, such as an
exhausted daily quota, kept only the generic "could not finish" text. It now keeps its message
and appends the upgrade page fromWithUpgradeURL, so the model can send the user there.
v0.19.0
Added
mcp, the remote MCP server kit, extracted from Courrier.mcp.Mount(router, Options)
serves the go-sdk v1.8.0 streamable transport in stateless mode at the resource's path, with
the RFC 9728 metadata at its well-known path. In front of it: the Origin check (403), the
bearer check witherror="invalid_token"andresource_metadatain the 401 challenge, a 403
insufficient_scopestep-up challenge for a write tool called without the write scope, and a
per-person rate limit. GET answers 405. List results are cached privately.- Typed tools with required annotations.
mcp.NewTool(ToolSpec, handler)builds a tool from a
typed go-sdk handler.Mountrefuses a tool without the<app>_prefix, a title, a
description or all four hints, and any tool that is not read-only needs the write scope, at
the HTTP gate and again inside the handler. Write calls are audited, without arguments. mcp.Confirmationsasks a person before a sensitive action runs: MRTRinput_required
when the client declares form elicitation on 2026-07-28, otherwise a pending action and a
confirm link. The question state is HMAC-signed and bound to the person, each action runs at
most once (atomic claim), and a target that changed since the question closes the action.
mcp.PostgresPendingstores actions inmcp_actions(mcp.PendingSchema, additive).- Helpers:
Failurefor actionable tool errors,Detailed,EncodeCursor/DecodeCursor,
FitCount,EncodedSizeandClipfor a 25k-token result budget. mcp/mcptest, the conformance kit.mcptest.Runchecks the 401 challenge, the metadata,
405 on GET, the Origin check, annotations, schemas, a stable sorted tool list, the write-scope
challenge and each sensitive tool's confirmation path.NewIssueris a fake authorization
server andNewPendingan in-memory store.
Changed
- The root module now requires
github.com/modelcontextprotocol/go-sdkv1.8.0 beside chi
(owner decision; seedocs/development.md).