-
Notifications
You must be signed in to change notification settings - Fork 3.1k
when running tests during PR validation, use sbt not ant [ci: last-only] #4933
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
Conversation
|
(not done yet: making it respect |
aef30bb to
d91ee73
Compare
|
hello permgen our old friend you've come to talk to us again |
|
if I run |
|
increasing PermGen from 128M to 192M didn't help — and failed on the exact same test. note also |
|
sbt/sbt#1223 might offer some clues. SBT forces GC and finalization periodically if the number of objects pending finalization exceeds a threshold. It appears that this is only done after a task has executed, so it probably won't help if a single task like |
|
The permgen failure also happens when running locally on Mac OS X. It sat a long time before failing; sample stack trace not long before failing: https://gist.github.com/SethTisue/8db45ef617a0542057b2 |
|
Strange, I can run partest locally from sbt without problems. |
I don't think so, because partest runs in a forked JVM.
@szeiger on Java 6? |
|
Hah, good point, I probably only ran it on Java 8. |
|
as I study a log of the old test/validate script a little closer, I see that ant was invoking partest multiple times, once per category of test. whereas in sbt we're doing one single giant partest invocation. so it's actually not surprising this might cause a PermGen regression, and I don't think there's any need to investigate the details. I'll just change it to match the old setup. the easiest way, as @retronym suggests, is simply not to invoke partest through sbt at all. at some point, we might like to change |
|
@SethTisue you can run individual categories from sbt, e.g. |
rather use sbt and direct invocation of partest this is the next Ant-elimination step after scala#4884
6a12c52 to
93b84a3
Compare
good to know. ultimately, we should switch to that. |
|
it didn't fail the job, but: |
|
sigh, |
The SBT build now generates this file, albeit under See 2a57f82 We'd still need to modify the |
|
That explains why it fails on Windows. I don't think partest or sbt-partest-interface should call any script at all. All that suite.init does is to build the classpath for partest in build/pack/partest.properties, which triggers a full ant build and pulling the libraries with the shell script, because all that stuff goes on the classpath. I wonder why I haven't noticed this before. sbt can build a correct partest.properties (but it goes into build-sbt/quick) which works for running partest from the command line. We should pass that to partest from sbt instead of calling ant. |
|
It looks like the problem with partest in sbt is really just Line 536 in 9fb85af
I tested this on a Windows system that doesn't even have ant installed. This includes running partest from the shell (MSYS bash) after sbt dist/mkQuick and cp build-sbt/quick/partest.properties build/pack/. No ant and no JARs in lib required. |
1b068a5 to
fc73bbc
Compare
fc73bbc to
64c0334
Compare
|
MiMa failure: doesn't happen when I run locally. perhaps the 2.11.0 jar it's trying to use isn't a real jar, perhaps because retrieving it failed because validation stuff is running with special resolver settings, that kind of thing. I'll look into it (but not right away). |
| runsbt "test/it:testOnly -- specialized" | ||
| runsbt "test/it:testOnly -- scalacheck" | ||
| runsbt "test/it:testOnly -- instrumented" | ||
| runsbt "test/it:testOnly -- presentation" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
TODO (pending a new partest release to honour --srcpath)
runsbt "test/it:testOnly -- --srcpath scaladoc --run"
runsbt "test/it:testOnly -- --srcpath scaladoc --scalacheck"
project/MiMa.scala
Outdated
| // TODO: it would be nicer if each subproject had its own whitelist, but for now | ||
| // for compatibility with how Ant did things, there's just one at the root. | ||
| // once Ant is gone we'd be free to split it up. | ||
| filter = baseDirectory.value / ".." / ".." / s"bincompat-$direction.whitelist.conf", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd opt for (baseDirectory in ThisBuild).value / s"bincompat-$direction.whitelist.conf",
c813859 to
44c9ef1
Compare
turned out to be transient, so I think the MiMa part of this is done (& I can move on to the other remaining parts) |
yum! delicious dogfood!
|
Closing in favor of #5190 |
this is the next step after #4884