Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

regression: Windows test runs failing in PipelineMainTest, due to sys.process parsing change #814

Closed
SethTisue opened this issue Aug 25, 2022 · 11 comments · Fixed by scala/scala#10123 or scala/scala#10128
Assignees
Labels
Milestone

Comments

@SethTisue
Copy link
Member

@som-snytt this is causing the test suite to time out on Windows — not intermittently, every time, at https://github.com/scala/scala/actions/runs/2907898126 but also subsequent runs since then:

[info] Test scala.tools.nsc.PipelineMainTest.pipelineMainBuildsSeparate started
[3789](https://github.com/scala/scala/runs/8001625648?check_suite_focus=true#step:6:3790)
error: IO error while decoding C:UsersRUNNER~1AppDataLocalTemppipelineBase8762258594693087133projectsm1p1srcm1p1Macro.scala with UTF-8: C:UsersRUNNER~1AppDataLocalTemppipelineBase8762258594693087133projectsm1p1srcm1p1Macro.scala (The system cannot find the file specified)
[3790](https://github.com/scala/scala/runs/8001625648?check_suite_focus=true#step:6:3791)
1 error
[3791](https://github.com/scala/scala/runs/8001625648?check_suite_focus=true#step:6:3792)
Please try specifying another one using the -encoding option
[3792](https://github.com/scala/scala/runs/8001625648?check_suite_focus=true#step:6:3793)
1 error
[3793](https://github.com/scala/scala/runs/8001625648?check_suite_focus=true#step:6:3794)
error: IO error while decoding C:UsersRUNNER~1AppDataLocalTemppipelineBase8762258594693087133projectsm1internalMacroClientsrcm2p2InternalClient.scala with UTF-8: C:UsersRUNNER~1AppDataLocalTemppipelineBase8762258594693087133projectsm1internalMacroClientsrcm2p2InternalClient.scala (The system cannot find the file specified)
[3794](https://github.com/scala/scala/runs/8001625648?check_suite_focus=true#step:6:3795)
Please try specifying another one using the -encoding option
[3795](https://github.com/scala/scala/runs/8001625648?check_suite_focus=true#step:6:3796)

on my Mac, I tried inserting Thread.dumpStack() at the top of sys.process.Parser.tokenize and I see:

	at scala.sys.process.Parser$.tokenize(Parser.scala:34)
	at scala.tools.nsc.settings.MutableSettings.splitParams(MutableSettings.scala:115)
	at scala.tools.nsc.CompilerCommand.expandArg(CompilerCommand.scala:133)
	at scala.tools.nsc.CompilerCommand.$anonfun$processArguments$1(CompilerCommand.scala:142)
	at scala.collection.immutable.List.flatMap(List.scala:293)
	at scala.tools.nsc.CompilerCommand.processArguments(CompilerCommand.scala:141)
	at scala.tools.nsc.CompilerCommand.<init>(CompilerCommand.scala:23)
	at scala.tools.nsc.PipelineMainClass.commandFor$1(PipelineMain.scala:117)

if that's any help. I believe PipelineMain and PipelineMainTest are @retronym territory

@SethTisue SethTisue added this to the 2.13.9 milestone Aug 25, 2022
@SethTisue SethTisue changed the title Windows test runs failing in PipelineMainTest, due to sys.process parsing change regression: Windows test runs failing in PipelineMainTest, due to sys.process parsing change Aug 25, 2022
@som-snytt
Copy link

som-snytt commented Aug 26, 2022

FSR testAll passes locally running sbt under PowerShell, jdk 15, fresh repo. Not sure yet what differs, presumably the tmp dir location.

But my first thought is to provide a convenience method or interpolator for adding File or Path to a command string with appropriate adjustments (either escaping backslash or converting to forward).

This parsing is done for args supplied as string, not in a list. The quoting feature is for // scalac: options in test files. The current code (on dotty) has a comment that not stripping escape was intended in the sense of accepted limitation. Stripping them is just so it works sanely for common use cases and always the same idiosyncratic shell way.

@SethTisue
Copy link
Member Author

SethTisue commented Aug 31, 2022

keeping open until we have a green run at https://github.com/scala/scala/actions

@som-snytt
Copy link

I can't tell if anything progressed, but there are still path errors in tests. Probably tests that construct a string of args with paths interpolated. I'll take a look during lunch break.

@SethTisue
Copy link
Member Author

For the record, the error currently (at https://github.com/scala/scala/runs/8119344147) is

!!  1 - run/macro_annot.scala                     [output differs]
[13709](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13710)
% diff D:\a\scala\scala\test\scaladoc\run\macro_annot.check D:\a\scala\scala\test\scaladoc\run\macro_annot-run.log--- macro_annot.check
[13710](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13711)
+++ macro_annot-run.log
[13711](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13712)
@@ -1,1 +1,44 @@
[13712](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13713)
-Done.
[13713](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13714)
+D:ascalascalatestscaladocrunmacro_annot-run.obj does not exist or is not a directory
[13714](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13715)
+newSource:5: error: not found: type simulacrum
[13715](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13716)
+@simulacrum trait Applicative[F[_]] {
[13716](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13717)
+ ^
[13717](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13718)
+newSource:10: error: not found: type simulacrum
[13718](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13719)
+  @simulacrum def no1 = ???
[13719](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13720)
+   ^
[13720](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13721)
+newSource:11: error: not found: type simulacrum
[13721](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13722)
+  /** 1 */ @simulacrum def yes1 = ???
[13722](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13723)
+            ^
[13723](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13724)
+java.lang.RuntimeException: Scaladoc Model Test ERROR: No universe generated!
[13724](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13725)
+java.lang.RuntimeException: Scaladoc Model Test ERROR: No universe generated!
[13725](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13726)
+	at scala.tools.partest.ScaladocModelTest.show(ScaladocModelTest.scala:75)
[13726](https://github.com/scala/scala/runs/8119344147?check_suite_focus=true#step:6:13727)
+	at scala.tools.partest.DirectTest.main(DirectTest.scala:117)

@SethTisue
Copy link
Member Author

SethTisue commented Sep 1, 2022

@som-snytt this is now the only remaining issue preventing us from designating a Scala 2.13.9 release candidate. perhaps we should simply revert scala/scala#10114 (and scala/scala#10123?) and reconsider the change for 2.13.10?

one way or the other I would like to designate a release candidate by the end of the day tomorrow (Fri Sep 2)

@som-snytt
Copy link

@SethTisue reverting is OK. Don't let the good interfere with convenience, or whatever the saying is.

@SethTisue
Copy link
Member Author

SethTisue commented Sep 1, 2022

should I revert 10123 at the same time?

@som-snytt
Copy link

@SethTisue that is OK. I did look at fixing the tests but why risk a kerfuffle. "This is how I define 'unwarranted'." To quote Star Trek: The Motion Picture that is playing now.

@SethTisue
Copy link
Member Author

ok will do

@SethTisue
Copy link
Member Author

keeping open until we have a green run at https://github.com/scala/scala/actions

@SethTisue
Copy link
Member Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
2 participants