fix(cli): use canonical error documentation URLs - #70
Merged
Conversation
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Intent
Fix every Akua CLI structured error documentation URL to use https://cli.akua.dev/errors/
from one authoritative crates/akua-core base, with real human and JSON lint regression coverage, all-known-code coverage, SDK generated schema and type propagation, CLI contract documentation, generated error-site canonical and OpenGraph exact routes, and Pages path triggers that redeploy when the authoritative error contract changes. Keep legitimate https://akua.dev product, dashboard, API, logo, and unrelated links unchanged; update only PR 70 and do not deploy or merge.What Changed
https://cli.akua.dev/errors/<CODE>and propagate them through human/JSON CLI output, SDK artifacts, and CLI documentation.Risk Assessment
✅ Low: The change is well-bounded, the prior dead documentation route is now consistently mapped to the existing E_INPUTS_PARSE code, and no material risks were found in the full base-to-target review.
Testing
After correcting initial missing-dependency and disk-space setup failures, focused core, CLI, SDK generation/schema, static-site generation, direct binary, and rendered-browser checks all passed; the evidence shows canonical human/JSON URLs and exact page metadata, with a clean worktree afterward.
Evidence: CLI human and JSON error transcript
/var/folders/1y/cjgf53nj31n_dxsspqnjfjvc0000gn/T/no-mistakes-evidence/01KXB3V7A414R7AECFFN0J1MJN/error-page-E_PACKAGE_MISSING.png)Evidence: Rendered page metadata
canonical: https://cli.akua.dev/errors/E_PACKAGE_MISSING og:url: https://cli.akua.dev/errors/E_PACKAGE_MISSINGPipeline
Updates from git push no-mistakes
✅ **intent** - passed
✅ No issues found.
✅ **Rebase** - passed
✅ No issues found.
🔧 **Review** - 1 issue found → auto-fixed ✅
docs/cli-contract.md:28- This example points toE_SCHEMA_INVALID, but that code is absent fromcodes.rsand no corresponding error page is generated, so the documented URL will return 404 after deployment. Use an existing code and update the mirrored Rust tests, or addE_SCHEMA_INVALIDto the official inventory if it is intentional.🔧 Fix: fix CLI contract inputs error documentation route
✅ Re-checked - no issues remain.
✅ **Test** - passed
✅ No issues found.
cargo test -p akua-core cli_contract::error::tests::(initial environment failure: disk exhausted during default-feature compilation)cargo test -p akua-core --no-default-features cli_contract::error::tests::bun test packages/sdk/src/standard-schema.test.ts(initial setup failure, then passed afterbun install --frozen-lockfile)bun scripts/gen-error-pages.tscargo test -p akua-cli --no-default-features --features oci-fetch,cosign-verify,dev-watch --test cli_integration lint_missing_packageTS_RS_EXPORT_DIR=packages/sdk/src/types cargo test -p akua-core --no-default-features --features ts-export --lib export_bindingsTS_RS_EXPORT_DIR=packages/sdk/src/types cargo test -p akua-cli --no-default-features --features oci-fetch,cosign-verify,dev-watch,schema-export,ts-export --lib export_bindingscargo test -p akua-cli --no-default-features --features oci-fetch,cosign-verify,dev-watch,schema-export,ts-export --test export_sdk_bundlegit diff --exit-code -- packages/sdk/src/types packages/sdk/src/schemas site/errorsAKUA_NO_AGENT_DETECT=1 target/debug/akua lintfrom an empty workspaceAKUA_NO_AGENT_DETECT=1 target/debug/akua lint --jsonfrom an empty workspaceServedsite/locally, renderedE_PACKAGE_MISSING.htmlin Chrome, captured a screenshot, and inspected canonical plus OpenGraph URLsConfirmed the worktree remained clean and removed transienttarget/andnode_modules/directories✅ **Document** - passed
✅ No issues found.
🔧 **Lint** - 1 issue found → auto-fixed ✅
🔧 Fix: Verify formatting and static analysis clean
✅ Re-checked - no issues remain.
✅ **Push** - passed
✅ No issues found.