Release v0.28.0 - #95
Merged
Merged
Conversation
…no rich (#81) The runner now binds the runtime's log context per request and emits its fields through the runtime's log calls, so its own request-id contextvars and logfmt flattener are gone. It boots on the json sink with the silent pretty-print mode and builds its image without the Rich extra; it pins `pipelex` 0.66.0, the release that carries the log seam. Closes L-260916-b7759f 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_019vmb35cM2bCxTwn49kCAXQ <!-- This is an auto-generated description by cubic. --> --- ## Summary by cubic Replaces the runner's request-id contextvars and logfmt flattener with Pipelex's runtime log context and a JSON line sink on stderr. Error lines now carry each value as its own JSON field, and `request_id` is bound per request so every record the request emits — including ones Pipelex emits from inside a run — carries it. Drops the `cli` extra, so the Rich terminal renderer is never reached. Closes L-260916-b7759f. **Notes** - Anything parsing the old console/logfmt output must switch to the JSON line format. - A custom `pipelex.toml` must keep `sink = "json"`, `console_log_target = "stderr"`, and `pretty_print_mode = "silent"`. - The sprint git-source pin for `pipelex` has collapsed onto the released `0.66.0`; the runtime-contract guard and its test are deleted with it. - `pipelex` 0.66.0's redaction processor escapes control characters in field values and redacts credentials echoed into `detail`; tests and `docs/logging.md` cover both. - Local Docker builds no longer bake untracked `.pipelex` override files into the image. - Deferred review findings are tracked in `wip/structured-logs/review-deferrals.md`. <sup>Written for commit ef292eb. Summary will update on new commits.</sup> <a href="https://cubic.dev/pr/Pipelex/pipelex-api/pull/81?utm_source=github" target="_blank" rel="noopener noreferrer" data-no-image-dialog="true"><picture><source media="(prefers-color-scheme: dark)" srcset="https://www.cubic.dev/buttons/review-in-cubic-dark.svg"><source media="(prefers-color-scheme: light)" srcset="https://www.cubic.dev/buttons/review-in-cubic-light.svg"><img alt="Review in cubic" src="https://www.cubic.dev/buttons/review-in-cubic-dark.svg"></picture></a> <!-- End of auto-generated description by cubic. --> --------- Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TpAMq6PZNQfauyDvx3GR2H
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Release v0.28.0
Bumps version from
0.27.5to0.28.0. Promotesdev→main.Changelog
Highlights
The runner's logs are structured. Every line it writes to stderr is one JSON object with each value under a key of its own, the request id rides every record a request emits, the Pipelex runtime's included, and secrets are scrubbed before a line is written.
Changed
[runtime.log] sink = "json"replaces the Rich console renderer,console_log_targetmoves tostderr, andpretty_print_mode = "silent"stops an operator pipe drawing its "Output of pipe" panel on the thread serving a request. Every value an error line carries —route,status,error_type,error_domain,retryable,user_id/pipe_code/pipeline_run_idwhen the request bound them, anddetailon the failures this API authors itself — is a key of its own now rather than part of akey=valuerun inside the message, andrequest_idrides the runtime's request-scoped log context, so it lands on every record emitted during a request, including the ones Pipelex emits from inside a run. The message is a short sentence built only from the status and the error type, so no caller-supplied string reaches it and the API's own escaping is gone: the sink is what serializes a value now. A log query matchingevent=api_erroras text has to move to theeventfield. The newdocs/logging.mddocuments the line and every field on it. Uvicorn's own banner and access log are unchanged and still plain text.pipelex0.66.0 (Breaking): up from==0.65.0, exactly, the release that carries the structured-log seam the entry above rides on: named fields and the run-scoped log context, thejsonsink selected by[runtime.log] sink, the redaction of secrets before any sink sees a record, and Rich behind thecliextra, which this server's extras leave out. On this server's lines that means a credential echoed intodetailreads[REDACTED], a control character in a field's value reads as its printable escape (\nwhere a caller sent a newline), and a line logged inside a traced run carriestrace_id,span_idandtrace_flags;docs/logging.mdsays so. The.pipelex/config shipped here already sits at the schema that release migrates to, so no migration is required. One change reaches an operator beyond the logs: the S3 storage provider now signs links and reads and writes objects on the bucket's own regional host,<bucket>.s3.<region>.amazonaws.com, so a deployment whose egress rules allow S3 by hostname must allow*.s3.<region>.amazonaws.com. Nothing on the wire moves.POST /v1/codegenstampsengine_version0.66.0: the stamp is the pinnedpipelexversion, so acodegen.lockcommitted against0.65.0no longer matches until it is regenerated.POST /v1/build/runnercarries the same stamp.Fixed
.pipelex/pipelex_override.tomland.pipelex/telemetry_override.tomlare untracked per-developer files, so CI never had them, butmake docker-buildcopied whatever the developer had into the image — their storage backend, their log level, their telemetry credentials. A locally built image then behaved differently from the published one, with nothing in the diff to say so..dockerignoreexcludes them; an operator still supplies overrides to a container by mounting them at/root/.pipelex.Closes L-260925-b2bafb
🤖 Generated with Claude Code
https://claude.ai/code/session_01TpAMq6PZNQfauyDvx3GR2H
Summary by cubic
Promotes
dev→mainforv0.28.0. The server's logs are now one JSON object per line on stderr instead of the Rich console renderer, andpipelexis pinned to0.66.0, the release behind the structured-log seam. Error lines carry each value under its own key, secrets are redacted, and the request id rides every record a request emits, including ones Pipelex logs from inside a run.Breaking
pipelex.tomlmust keepsink = "json",console_log_target = "stderr", andpretty_print_mode = "silent".POST /v1/codegenandPOST /v1/build/runnerstampengine_version0.66.0, so acodegen.lockagainst0.65.0must be regenerated.<bucket>.s3.<region>.amazonaws.com; egress rules that allow S3 by hostname must allow*.s3.<region>.amazonaws.com.Fixed
.dockerignoreexcludes the untracked.pipelexoverride files, so a localmake docker-buildno longer bakes a developer's storage backend, log level, or telemetry credentials into the image.Written for commit 5e2f627. Summary will update on new commits.