Skip to content

feat: SDK update for version 22.2.3#333

Closed
ChiragAgg5k wants to merge 1 commit into
masterfrom
cli-22.2.3
Closed

feat: SDK update for version 22.2.3#333
ChiragAgg5k wants to merge 1 commit into
masterfrom
cli-22.2.3

Conversation

@ChiragAgg5k

Copy link
Copy Markdown
Member

This PR contains updates to the SDK for version 22.2.3.

What's Changed

  • Fixed: Verbose and report error output no longer dumps bundled source context from compiled binaries

@greptile-apps

greptile-apps Bot commented Jun 25, 2026

Copy link
Copy Markdown

Greptile Summary

This PR bumps the CLI SDK from version 22.2.2 to 22.2.3 and introduces a formatErrorForLog helper that converts Error objects to a plain string before passing them to console.error, preventing compiled binaries from dumping their entire bundled source context on verbose or report errors.

  • lib/parser.ts: Adds formatErrorForLog, which inserts known Appwrite error fields (code, type, response) between the stack summary line and the frame list, then replaces both console.error(err) call sites with console.error(formatErrorForLog(err)).
  • Version files: package.json, package-lock.json, lib/constants.ts, install.sh, install.ps1, scoop/appwrite.config.json, and docs all consistently updated to 22.2.3.

Confidence Score: 4/5

The change is safe to merge; it only affects how errors are formatted before being printed to stderr and does not touch any business logic or data paths.

The core fix is straightforward and well-scoped. One minor gap remains: the --report path still embeds the raw err.stack when constructing the GitHub issue URL, so a large stack from a compiled binary could still produce an unusably long URL printed to the terminal — the same class of problem the PR is solving for console.error. Everything else, including the version bumps, is consistent across all relevant files.

lib/parser.ts — specifically the GitHub issue URL construction in the report path (line 720).

Important Files Changed

Filename Overview
lib/parser.ts Adds formatErrorForLog to convert Error objects to formatted strings before passing to console.error, preventing bundled source context from being dumped; the report-mode GitHub URL still embeds the raw stack
lib/constants.ts SDK_VERSION bumped from 22.2.2 to 22.2.3
package.json Package version bumped from 22.2.2 to 22.2.3, consistent with other files
package-lock.json Lock file version updated to 22.2.3 to match package.json
install.sh GITHUB_LATEST_VERSION updated to 22.2.3 for binary download
install.ps1 Windows binary download URLs updated to 22.2.3 for both x64 and arm64
scoop/appwrite.config.json Scoop package version and binary download URLs updated to 22.2.3
CHANGELOG.md 22.2.3 changelog entry added describing the verbose/report error output fix
README.md Version string in installation verification examples updated to 22.2.3

Comments Outside Diff (1)

  1. lib/parser.ts, line 720-742 (link)

    P2 Report path GitHub URL still embeds raw stack

    The --report path passes the raw err.stack into the actual-behavior URL query parameter (line 720), which is then printed to the terminal as part of githubIssueUrl.href (line 742). If err.stack contains bundled source context from a compiled binary — the same condition this PR is fixing for console.error — the generated URL will be extremely long, making it hard to use or even truncated/broken in some terminals and browsers. Consider using formatErrorForLog(err) here as well to keep the URL manageable.

Reviews (1): Last reviewed commit: "chore: update Command Line SDK to 22.2.3" | Re-trigger Greptile

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant