fix(cli): guide localhost transport failures to gateway start#88
fix(cli): guide localhost transport failures to gateway start#88
Conversation
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
onequery-landing | 9dc3f5a | Commit Preview URL Branch Preview URL |
Apr 14 2026, 12:53 PM |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: c9aa49a983
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: dbaf955e31
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
You can install any of these versions: `npm install -g @onequery/cli@<version>` ## [0.1.29] - 2026-04-15 ### 🚀 Features - Update landing page copy and sample visuals (#86) - Landing diagram redesign (#91) - *(repo)* Add OpenClaw plugin for OneQuery (#90) ### 🪲 Bug Fixes - *(cli-release)* Use versioned homebrew asset names (#87) - *(cli)* Guide localhost transport failures to gateway start (#88) ### 💼 Other - *(cli)* Align config set/get around canonical keys (#89) <!-- generated - do not edit -->
One-Line Summary
Make localhost self-host transport failures tell users to start the managed gateway instead of surfacing a generic Connect error.
User-Facing Changes
http://127.0.0.1:5656and nothing is listening, commands now fail withself-host gateway is not runningand actionable next steps likeonequery gateway start.auth,org,source,query,source connect, andapicommand surfaces, not justonequery auth login.retry <command>follow-up instead of only showing a raw transport failure.Why This Changed
client error (Connect).config.tomlandsecrets.toml, which could miss custom local self-host routing data during partial setup.How It Changed
crates/onequery-cli/src/local_target.rsto classify managed local self-host targets, normalize loopback probe hosts, and construct a dedicatedself_host_gateway_unavailableCLI error.present_api_failure_with_context(...)so commands can upgrade matched local self-host outages before falling back to the generic transport presenter.self_host_public_origin(...)and added a public-config-only loader so target resolution can useconfig.tomlrouting fields without depending onsecrets.toml.Bug Fixes
onequery auth logincould fail withlogin start failedand a raw Connect transport error when the gateway was simply stopped; it now points users toonequery gateway start.config.tomlexisted withoutsecrets.toml, local target detection could miss the configured local endpoint; it now reads the public config independently.Extra Context / Decisions (Optional)
Verification
cargo test -p onequery-clijust fix -p onequery-clijust fmtbun run formatapps/cli/crates/onequery-cli/src/snapshots/onequery__local_target__tests__managed_gateway_unavailable_error_snapshot_guides_gateway_start_for_local_targets.snap.apps/cli/crates/onequery-cli/src/local_target.rsfor default localhost matching, custom local runtime matching, and remote-origin opt-out.apps/cli/crates/onequery-cli/src/config/self_host.rsfor loading public self-host config withoutsecrets.toml.Video / Screenshot (Optional)