Update Mill from 0.11.7-17-17dea9 to a newer version (fails)
So, I tried to restart the build multiple times but it seems the failure isn't just flakiness but something else I still don't understand.
Looks like the produced assembly isn't executable.
> cmd /C %GITHUB_WORKSPACE%\ci\mill.bat -i -d -k "{main,scalalib,bsp}.__.test"
...
mill.scalalib.AssemblyTests: [55/55] exe.small.assembly
File size: 10954343
<h1>tutu</h1>
X mill.scalalib.AssemblyTests.Assembly.exe.small 5445ms
java.io.IOException: Cannot run program "D:\a\mill\mill\target\workspace\mill\scalalib\AssemblyTests\eval\Assembly\exe\small\exe\small\assembly.dest\out.jar" (in directory "D:\a\mill\mill\target\worksources\mill\scalalib\AssemblyTests\TestCase"): CreateProcess error=193, %1 is not a valid Win32 application
java.lang.ProcessBuilder.start(ProcessBuilder.java:1048)
os.proc.proc$lzycompute$1(ProcessOps.scala:123)
os.proc.proc$1(ProcessOps.scala:122)
os.proc.spawn(ProcessOps.scala:129)
mill.util.Jvm$.spawnSubprocessWithBackgroundOutputs(Jvm.scala:258)
mill.util.Jvm$.runSubprocess(Jvm.scala:168)
mill.scalalib.AssemblyTests$.runAssembly(AssemblyTests.scala:104)
mill.scalalib.AssemblyTests$.$anonfun$tests$10(AssemblyTests.scala:129)
mill.scalalib.AssemblyTests$.$anonfun$tests$10$adapted(AssemblyTests.scala:127)
mill.scalalib.AssemblyTests$.workspaceTest(AssemblyTests.scala:89)
mill.scalalib.AssemblyTests$.$anonfun$tests$9(AssemblyTests.scala:109)
java.io.IOException: CreateProcess error=193, %1 is not a valid Win32 application
java.lang.ProcessImpl.create(ProcessImpl.java:-2)
java.lang.ProcessImpl.<init>(ProcessImpl.java:453)
java.lang.ProcessImpl.start(ProcessImpl.java:139)
java.lang.ProcessBuilder.start(ProcessBuilder.java:1029)
os.proc.proc$lzycompute$1(ProcessOps.scala:123)
os.proc.proc$1(ProcessOps.scala:122)
os.proc.spawn(ProcessOps.scala:129)
mill.util.Jvm$.spawnSubprocessWithBackgroundOutputs(Jvm.scala:258)
mill.util.Jvm$.runSubprocess(Jvm.scala:168)
mill.scalalib.AssemblyTests$.runAssembly(AssemblyTests.scala:104)
mill.scalalib.AssemblyTests$.$anonfun$tests$10(AssemblyTests.scala:129)
mill.scalalib.AssemblyTests$.$anonfun$tests$10$adapted(AssemblyTests.scala:127)
mill.scalalib.AssemblyTests$.workspaceTest(AssemblyTests.scala:89)
mill.scalalib.AssemblyTests$.$anonfun$tests$9(AssemblyTests.scala:109)
The bumped Mill version (the essence of this PR) contains also a fix for the assembly target, which should fail the target if a script-prepended assembly jar might be too big to be executable. Now, the strange thing is that the failing test is also about the assembly target, but only on Windows (which I haven't access to). I think the Mill under test and the actual executing Mill versions shouldn't influence each other, but I have no other explanation for the failing test.
The test also fails with Mill 0.11.7-50-9a734a, so there seems to be another issue than I thought. I will try to narrow it down further...
So, the assembly test fails when we bump the build tool Mill from version 0.11.7-17-17dea9 to 0.11.7-29-f2e220.
https://github.com/com-lihaoyi/mill/compare/17dea9...f2e220
My recent bisection shows 824f9 passes tests (https://github.com/com-lihaoyi/mill/pull/3247), so that narrows things down a bit
https://github.com/com-lihaoyi/mill/compare/824f9...f2e220
The only recent changes to Assembly.scala are https://github.com/com-lihaoyi/mill/commits/main/scalalib/src/mill/scalalib/Assembly.scala, I wonder if it's one of those
Eh not sure why https://github.com/com-lihaoyi/mill/pull/3253 failed while https://github.com/com-lihaoyi/mill/pull/3252 passed while trying to update Mill to an artifact built on the same commit. Something funny is going on