Skip to content

fix: await locale manifest write - #3199

Open
OskarEichler wants to merge 1 commit into
iamkun:devfrom
OskarEichler:codex/await-locale-manifest-write
Open

fix: await locale manifest write#3199
OskarEichler wants to merge 1 commit into
iamkun:devfrom
OskarEichler:codex/await-locale-manifest-write

Conversation

@OskarEichler

Copy link
Copy Markdown

Breaking/build behavior changes

  • The build command now waits for locale.json to be written before completing.
  • Locale manifest write failures now reach the existing top-level build error handler.
  • Runtime library behavior and the manifest format are unchanged.
  • PR fix: fail builds after generation errors #3195 separately makes the existing error handler return a non-zero process status.

Problem

listLocaleJson started promisifyWriteFile(...) without awaiting or returning it. The build could complete before the manifest was durable, while write failures escaped as unhandled promise rejections.

Fix

Await the locale manifest write inside the existing async helper.

The regression test injects a failed write and verifies that the exact error reaches the build's error handler.

Verification

  • npm test — 94 suites, 795 tests passed
  • npm run lint
  • NODE_OPTIONS=--openssl-legacy-provider npm run build
  • git diff --check

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