bun
bun copied to clipboard
--covarage crashed on windows and show files from node_modules
What version of Bun is running?
1.0.35-canary.23+e808cdb72 and 1.0.35-canary.35+dea877f19
What platform is your computer?
Microsoft Windows NT 10.0.22631.0 x64
What steps can reproduce the bug?
please run bun test --coverage apps\web\src\utils\handleResponse
in my project
I'll give a simpler example if I find the source of the problem
What is the expected behavior?
see the coverage
What do you see instead?
uh-oh: attempt to cast negative value to unsigned integer bun will crash now 😭😭😭
----- bun meta ----- Bun v1.0.35-canary.23 (e808cdb7) Windows x64 TestCommand: bunfig transpiler_cache Elapsed: 3576ms | User: 406ms | Sys: 140ms RSS: 0.24GB | Peak: 0.24GB | Commit: 0.27GB | Faults: 60395 ----- bun meta -----
0 00007FF6A5917428 1 ??? 2 ??? 3 ??? 4 ??? 5 ??? 6 ??? 7 ??? 8 ??? 9 ??? 10 ??? 11 ???
Search GitHub issues https://bun.sh/issues or join in #windows channel in https://bun.sh/discord
thread 28168 panic: attempt to cast negative value to unsigned integer ???:?:?: 0x7ff6a46eba8a in ??? (bun.exe) ???:?:?: 0x7ff6a46b845e in ??? (bun.exe) ???:?:?: 0x7ff6a69591de in ??? (bun.exe) ???:?:?: 0x7ff6a4549609 in ??? (bun.exe) ???:?:?: 0x7ff6a454e594 in ??? (bun.exe) ???:?:?: 0x7ff6a458b119 in ??? (bun.exe) ???:?:?: 0x7ff6a42c16c6 in ??? (bun.exe) ???:?:?: 0x7ff6a6dce053 in ??? (bun.exe) ???:?:?: 0x7ffcedca257c in ??? (KERNEL32.DLL) ???:?:?: 0x7ffceea6aa47 in ??? (ntdll.dll)
Additional information
this command actually didn't work correct with custom path
and idk why but bun show files from node_modules
Same here. I'm using v1.1.2.
Still happening with v1.1.3 as well.
deprecated, now it works good
for me after upgrade bun the `bun test` command just can't find any of files with `.test` in filename
but there is a lot of files with .test
@Electroid sorry for ping but should I create a new issue about that or what?
@Electroid sorry for ping bun should I create a new issue about that or what?
If you could create a new issue for the .test/spec
that would be great!
If you could create a new issue for the
.test/spec
that would be great!
idk how but for now the problem is gone (with .test/spec)
maybe after I reboot my PC or smth
Since Bun's new crash reporter was released, this crash report may help:
Bun v1.1.5 (#10527) on windows x86_64_baseline [TestCommand]
panic: attempt to cast negative value to unsigned integer
-
parse_args.zig:254
:checkOptionUsage
-
migration.zig:196
:migrateNPMLockfile
-
??$putDirectInternal@$00@JSObject@JSC@@AEAA?AVASCIILiteral@WTF@@AEAVVM@1@VPropertyName@1@VJSValue@1@IAEAVPutPropertySlot@1@@Z
-
pm_trusted_command.zig:289
:exec
-
Allocator.zig:98
:rawFree
-
Allocator.zig:227
:allocBytesWithAlignment
-
logger.zig:682
:init
-
main.zig:52
:main
-
wasmLLIntPCRangeStart
- ??? at
0x17344
in /KERNEL32.DLL
In my case, the crash seems to be caused by defining the class properties like this:
// lexer.js
export default class Lexer {
input; // this line caused the crash
constructor(input) {
this.input = input;
}
}
Bun v1.1.5 (b257a309) Windows x64 Args: "C:\Users\scffs.bun\bin\bun.exe", "test", "--coverage", "apps\web\src\utils\handleResponse" Features: bunfig transpiler_cache(6) tsconfig_paths(2) tsconfig(10) Builtins: "node:assert" "node:buffer" "node:child_process" "node:crypto" "node:events" "node:fs" "node:http" "node:https" "node:net" "node:path" "node:stream" "node:stream/web" "node:string_decoder" "node:url" "node:util" "node:util/types" "node:vm" "node:zlib" Elapsed: 5314ms | User: 500ms | Sys: 390ms RSS: 0.25GB | Peak: 0.25GB | Commit: 0.28GB | Faults: 61111
panic(main thread): attempt to cast negative value to unsigned integer oh no: Bun has crashed. This indicates a bug in Bun, not your code.
To send a redacted crash report to Bun's team, please file a GitHub issue using the link below:
https://bun.report/1.1.5/wt1b257a30AghggwDgvgtIgul+H+5/4sCkqw9E8h3+E+zztFql/Bu4Iojrj2CCa\KERNEL32.DLL63yEA0eNoVyMEJACAMA8BVslrRUApaRaPzi/c8k9inoIFiW0i6KS5xrR3+PrnDkxWRonM95EETDA