HaxeFoundation / haxe

Haxe - The Cross-Platform Toolkit
https://haxe.org
6.03k stars 648 forks source link

Haxe error Invalid_argument("index out of bounds") on JS project compile with --connect #11589

Closed yuxiaomao closed 3 months ago

yuxiaomao commented 4 months ago

Recently (bisect tell me this is the first bad commit https://github.com/HaxeFoundation/haxe/commit/30a0163302a31214dff91ab14492530a60d80307), when I build a JS project such as hide for the second time and above (with --connect), it fail with Invalid_argument("index out of bounds").

This complicates development with VSCode.

Simn commented 4 months ago

Could you define the environment variable OCAMLRUNPARAM=b and post the printed stack trace?

yuxiaomao commented 4 months ago

It does not show more information

$ OCAMLRUMPARAM=b haxe.exe --connect 127.0.0.1:6001 hide.hxml
Invalid_argument("index out of bounds")
kLabz commented 4 months ago

Can repro locally

yuxiaomao commented 3 months ago

The issue is fixed for hide, but not for https://github.com/vshaxe/hashlink-debugger (Build with OCAMLRUMPARAM=b haxe.exe --connect 127.0.0.1:6000 build.hxml) Same error, no additional print with OCAMLRUMPARAM=b, same bad commit. @kLabz Could you please check?