Skip to content

fix: resolve silent failure in lark-cli api error output (#39)#85

Merged
evandance merged 1 commit into
mainfrom
fix/api-silent-error-39
Mar 30, 2026
Merged

fix: resolve silent failure in lark-cli api error output (#39)#85
evandance merged 1 commit into
mainfrom
fix/api-silent-error-39

Conversation

@evandance

Copy link
Copy Markdown
Collaborator

Resolves #39
MarkRaw previously skipped both enrichPermissionError and WriteErrorEnvelope, causing api command to exit 1 with no output on API errors. Now MarkRaw only skips enrichPermissionError while WriteErrorEnvelope always runs, ensuring stderr error envelope is always written.

  • Simplify apiRun MarkRaw logic (remove unnecessary IsJSONContentType check)
  • Update existing tests to match new behavior
  • Add 5 e2e tests covering api/service/shortcut error output

MarkRaw previously skipped both enrichPermissionError and
WriteErrorEnvelope, causing api command to exit 1 with no output
on API errors. Now MarkRaw only skips enrichPermissionError while
WriteErrorEnvelope always runs, ensuring stderr error envelope is
always written.

- Simplify apiRun MarkRaw logic (remove unnecessary IsJSONContentType check)
- Update existing tests to match new behavior
- Add 5 e2e tests covering api/service/shortcut error output
@evandance evandance self-assigned this Mar 30, 2026
@CLAassistant

CLAassistant commented Mar 30, 2026

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

@evandance
evandance marked this pull request as ready for review March 30, 2026 07:37
@evandance
evandance merged commit a13bee8 into main Mar 30, 2026
7 checks passed
@evandance
evandance deleted the fix/api-silent-error-39 branch March 30, 2026 09:19
tuxedomm pushed a commit that referenced this pull request Apr 3, 2026
MarkRaw previously skipped both enrichPermissionError and
WriteErrorEnvelope, causing api command to exit 1 with no output
on API errors. Now MarkRaw only skips enrichPermissionError while
WriteErrorEnvelope always runs, ensuring stderr error envelope is
always written.

- Simplify apiRun MarkRaw logic (remove unnecessary IsJSONContentType check)
- Update existing tests to match new behavior
- Add 5 e2e tests covering api/service/shortcut error output
tuxedomm pushed a commit to zhumiaoxin/cli that referenced this pull request Jun 6, 2026
) (larksuite#85)

MarkRaw previously skipped both enrichPermissionError and
WriteErrorEnvelope, causing api command to exit 1 with no output
on API errors. Now MarkRaw only skips enrichPermissionError while
WriteErrorEnvelope always runs, ensuring stderr error envelope is
always written.

- Simplify apiRun MarkRaw logic (remove unnecessary IsJSONContentType check)
- Update existing tests to match new behavior
- Add 5 e2e tests covering api/service/shortcut error output
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.

在群里发消息一直调试不成功

3 participants