v0.4.1
Release Notes Draft - v0.4.1
Status: draft for the external release steps (tag / push / GitHub release / npm publish).
Release date target: 2026-04-24 or later.
Scope: reliability and interface-hygiene pass on top of v0.4.0, driven by a 5-agent audit of the codebase and a full live 8-provider test of the Claude Code host bundle. No breaking changes.
Highlights
- Aligned every
--jsonerror path across the host companion so argument, lookup, and validation failures return{ error, code, ... }with a stable exit 1, matching the shape consumers already get on success. - Made
askresponses report a non-null top-levelmodelfor all eight providers, with adefaultModelfallback when a provider's own stream events do not carry one. - Flattened
result --jsonso a completed job's payload exposesresponse,ok,sessionId, andtimingat the top level (likeask --json), while still surfacing job metadata under ajobsub-object. - Normalized provider CLI availability text so multi-line version banners (notably GitHub Copilot CLI's update notice) no longer break the single-line render in
setup. - Subcommand
--helpnow short-circuits to Usage instead of being forwarded to the provider CLI as a prompt. - Tightened
timingargument validation for--providerand--history. - Declared
@bbingz/polycli-utils,@bbingz/polycli-timing, and@bbingz/polycli-runtimeas private internal bundler inputs so accidentalnpm publishis impossible. - Codex host plugin and Copilot host plugin now have their own marketplace manifests;
release:checkvalidates manifests and version alignment across every release artifact in one step.
User-Facing Changes
ask --json,rescue --json,review --json,adversarial-review --json,status --json,result --json,cancel --json,timing --json, andsetup --jsonall return structured JSON on every error path, neverError: ...text. Existing success payloads are unchanged.result --jsontop-level shape now mirrorsask --json. Consumers readingdata.response/data.sessionId/data.timingno longer need a fallback todata.result.response. Job metadata (jobId,createdAt,finishedAt,status,logFile) lives underdata.job.setup --jsonavailabilityDetailandauthDetailare now single-line strings (the first non-empty line of the probed CLI's output); multi-line banners are preserved in logs but not in the rendered summary.- Every
askresponse (JSON or text) now reports the answering model at the top level. Previously onlyqwenandcopilotpopulated this; the other six providers returnedmodel: null. polycli-companion.mjs ask --help(and every subcommand--help) now prints Usage immediately and exits 0, without invoking any provider CLI.timing --provider <unknown>andtiming --history abcnow return structured validation errors instead of an empty record list with exit 0.cancelno-op return is exit code 1 in both text and JSON mode (previously text exit 3, JSON exit 1).
Fixes Since v0.4.0
- Host companion
--jsonerror path: introducedexitWithErrorhelper and aclassifyErrorCodemapping so every error branch (missing provider, unknown provider, invalid scope, invalid history, missing prompt, unknown subcommand, no-completed-job, no-active-job, job-not-found) returns{ error, code, ... }+ exit 1 when--jsonis set.- Subcommand
--helpshort-circuit prevents accidental provider CLI invocations. result --jsonenvelope flattened to matchask --jsontop-level keys.cancelno-op exit code aligned across output modes;cancel.mddocuments the non-zero no-op semantics.timing --provider <unknown>now routes through the sameunknown_providererror asask/setup/health;timing --historyrejects non-integers and negative values.
- Provider runtimes
- All eight provider
askresponses now surface a top-levelmodelfield.claude/gemini/kimi/minimax/opencode/pilift model from their own stream events;qwen/copilotalready populated it and are unchanged. registry.runProviderPromptandregistry.runProviderPromptStreamingaccept an optionaldefaultModelparameter used as the final fallback when no event-based model is emitted. The host supplies this from its cachedgetAuthStatuslookup so users never seemodel: nullon a live run.
- All eight provider
- Utilities
binaryAvailablereturns the first non-empty line of the probed CLI's stdout / stderr asdetail, so second-line update banners (copilot) or deprecation notices no longer breaksetup's single-line rendering. Raw multi-line output remains available on the runtime result object.
- Release artifacts
- Claude marketplace (
.claude-plugin/marketplace.json), Codex marketplace (.agents/plugins/marketplace.json), and GitHub Copilot marketplace (.github/plugin/marketplace.json) all list at version0.4.1. Codex host now has its ownpack:codexscript. scripts/validate-release-manifests.mjsis wired intorelease:checkand fails the release if any host version disagrees with any other.@bbingz/polycli-utils,@bbingz/polycli-timing, and@bbingz/polycli-runtimeare now flagged"private": trueto lock them as internal bundler inputs.
- Claude marketplace (
Test Coverage
-
npm test: 221/221 pass (up from 211 at v0.4.0). -
New tests: live error-shape assertions for every
--jsonerror branch; per-providermodelnon-null assertions in fixture replays;registry.test.jsfallback-path lock for thedefaultModelcontract;process.test.jsassertion that multi-line--versionstdout is collapsed to the first non-empty line. -
npm run release:checkpasses end-to-end: manifest validation, marketplace validation, plugin validation, and@bbingz/polycli-opencode@0.4.1dry-run publish. -
Live 8-provider smoke (real CLIs, no fixtures) confirms every provider returns a real model in
ask --json:provider model gemini gemini-3.1-pro-preview kimi kimi-code/kimi-for-coding qwen qwen3.6-plus minimax MiniMax-M2.7-highspeed claude claude-opus-4-7[1m] copilot gpt-5.4 opencode opencode-go/mimo-v2-pro pi openai-codex/gpt-5.4
Notes for Maintainers
@bbingz/polycli-opencodewas not published to npm for v0.4.0 despite the tag. The v0.4.1 publish will be the first real npm publish of that package; confirmnpm whoamiand@bbingzscope access before runningnpm publish.- Four review artifacts are landing with this release:
docs/review-2026-04-24.md(main audit),docs/review-2026-04-24-followup.md(release-prep follow-ups),docs/review-2026-04-24-bugs.md(B1–B8 runtime observations),docs/review-2026-04-24-b6-spec.md(standalone B6 spec + verdict).
Non-Goals / Intentionally Deferred
packages/polycli-utilsandpackages/polycli-timingstay on the internal1.0.0line and are not published. External publication of those packages will be a separate, versioned decision.docs/polycli-v1-public-surface.mdstill describes the v1 utility-only scope and is now out of date relative to the v0.4.x provider runtimes. A rewrite or supersede banner is tracked as a follow-up, not blocking this release.- Integration tests in
plugins/polycli/scripts/tests/still mock child processes; migrating them to captured CLI fixtures (likepackages/polycli-runtime/test/fixtures/) is tracked for a later iteration.