Skip to content

Enforce strict error handling in Zig native module#252

Merged
emil-e merged 1 commit into
dakra:mainfrom
mgeisler:zig-error-handling
May 10, 2026
Merged

Enforce strict error handling in Zig native module#252
emil-e merged 1 commit into
dakra:mainfrom
mgeisler:zig-error-handling

Conversation

@mgeisler
Copy link
Copy Markdown
Contributor

Replace swallowed errors (bare catch {}) with explicit logging to the Emacs *Messages* buffer using env.logErrorf() and env.signalErrorf(). This aligns the codebase with the guidelines in src/AGENTS.md and improves observability for failures in color configuration, PWD updates, and render state management.

Standardize logging messages to the ghostel: [function] failed: [error] pattern.

Written by Gemini, lightly audited by me.

Replace swallowed errors (bare `catch {}`) with explicit logging to
the Emacs `*Messages*` buffer using `env.logErrorf()` and
`env.signalErrorf()`. This aligns the codebase with the guidelines in
`src/AGENTS.md` and improves observability for failures in color
configuration, PWD updates, and render state management.

Standardize logging messages to the `ghostel: [function] failed:
[error]` pattern.

> Written by Gemini, lightly audited by me.
@mgeisler mgeisler force-pushed the zig-error-handling branch from fffa79f to 2a0fb79 Compare May 10, 2026 09:11
@dakra dakra requested a review from emil-e May 10, 2026 09:12
@emil-e
Copy link
Copy Markdown
Collaborator

emil-e commented May 10, 2026

I'm planning a bit of an overhaul of this aspect of the Zig code but this is a step in the right direction so I will merge it.

@emil-e emil-e merged commit c5f9181 into dakra:main May 10, 2026
20 checks passed
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.

2 participants