oven-sh / bun

Incredibly fast JavaScript runtime, bundler, test runner, and package manager – all in one
https://bun.sh
Other
74.42k stars 2.78k forks source link

Bun crashes when using fillText @napi-rs/canvas #15372

Open taro445 opened 3 days ago

taro445 commented 3 days ago

How can we reproduce the crash?

I am experiencing a crash in Bun when using ctx['fillText']("Big smile!", 10, 90) with @napi-rs/canvas while integrating with Elysia on Bun.

Relevant log output

node_modules\@napi-rs\canvas-win32-x64-msvc\icudtl.dat.
SkIcuLoader: datafile missing: C:\Users\...\AppData\Roaming\npm\node_modules\bun\bin\icudtl.dat.
../../modules/skparagraph/src/ParagraphBuilderImpl.cpp(252): fatal error: "check(fUnicode)"
============================================================
Bun v1.1.36 (ededc168) Windows x64
Windows v.win10_fe
CPU: sse42 avx avx2 avx512
Args: "C:\Users\...\AppData\Roaming\npm\\node_modules\bun\bin\bun.exe" "run" "--watch" "./src/app.ts"
Features: Bun.stdin(2) dotenv http_server jsc transpiler_cache(12) tsconfig(14) tsconfig_paths(2) process_dlopen
Builtins: "bun:main" "node:assert" "node:async_hooks" "node:buffer" "node:crypto" "node:dns" "node:events" "node:fs" "node:fs/promises" "node:http" "node:https" "node:module" "node:net" "node:os" "node:path" "node:process" "node:querystring" "node:stream" "node:string_decoder" "node:timers" "node:timers/promises" "node:tls" "node:tty" "node:url" "node:util" "node:util/types" "node:zlib" "node:worker_threads"
Elapsed: 2690ms | User: 578ms | Sys: 281ms
RSS: 0.51GB | Peak: 0.51GB | Commit: 0.77GB | Faults: 130554

panic(main thread): Illegal instruction at address 0x7FFD829BA420
oh no: Bun has crashed. This indicates a bug in Bun, not your code.

Stack Trace (bun.report)

Bun v1.1.36 (ededc16) on windows x86_64 [RunCommand]

Illegal instruction at address 0x7FFD829BA420

Features: process_dlopen, Bun.stdin, dotenv, http_server, jsc, transpiler_cache, tsconfig, tsconfig_paths, tsconfig_paths

Sentry Issue: BUN-8TN

AceLikesGhosts commented 2 days ago

Can reproduce on Bun 1.1.34 and Windows 10 Edit: The underlying issue which caused this for the library was fixed, although Bun should not be dying like this.