-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
sbt 1.10.5 (was 1.9.9) #20157
base: main
Are you sure you want to change the base?
sbt 1.10.5 (was 1.9.9) #20157
Conversation
@eed3si9n the test failures here worry me somewhat, but I might not have time this week to look into it |
Acknowledged. Thanks for starting this, @SethTisue! |
Opened sbt/zinc#1351 |
FYI @bishabosha - new Zinc 1.10.x breaks scripted test added by #18880. [info] [error] java.lang.RuntimeException: Can't find source file for a.A.Inner_sel
[info] [error] at scala.sys.package$.error(package.scala:30)
[info] [error] at sbt.internal.inc.Analysis$.$anonfun$sources$1(Analysis.scala:105)
[info] [error] at scala.Option.getOrElse(Option.scala:189)
[info] [error] at sbt.internal.inc.Analysis$.sourceFileForClass$1(Analysis.scala:105)
[info] [error] at sbt.internal.inc.Analysis$.isJavaClass$1(Analysis.scala:107)
[info] [error] at sbt.internal.inc.Analysis$.$anonfun$sources$2(Analysis.scala:108)
[info] [error] at sbt.internal.inc.Analysis$.$anonfun$sources$2$adapted(Analysis.scala:108)
[info] [error] at scala.collection.TraversableLike.$anonfun$partition$1(TraversableLike.scala:450)
[info] [error] at scala.collection.immutable.HashMap$HashMapKeys.$anonfun$foreach$1(HashMap.scala:150)
[info] [error] at scala.collection.immutable.HashMap$HashMap1.foreachEntry(HashMap.scala:401)
[info] [error] at scala.collection.immutable.HashMap$HashTrieMap.foreachEntry(HashMap.scala:735)
[info] [error] at scala.collection.immutable.HashMap$HashTrieMap.foreachEntry(HashMap.scala:735)
[info] [error] at scala.collection.immutable.HashMap$HashMapKeys.foreach(HashMap.scala:150)
[info] [error] at scala.collection.TraversableLike.partition(TraversableLike.scala:450)
[info] [error] at scala.collection.TraversableLike.partition$(TraversableLike.scala:448)
[info] [error] at scala.collection.AbstractTraversable.partition(Traversable.scala:108)
[info] [error] at sbt.internal.inc.Analysis$.sources(Analysis.scala:108)
[info] [error] at sbt.internal.inc.IncrementalCommon$CycleState$IncrementalCallbackImpl.mergeAndInvalidate(IncrementalCommon.scala:193)
[info] [error] at sbt.internal.inc.IncrementalCommon$CycleState$IncrementalCallbackImpl.completeCycle(IncrementalCommon.scala:209)
[info] [error] at sbt.internal.inc.AnalysisCallback.getCycleResultOnce(Incremental.scala:940)
[info] [error] at sbt.internal.inc.Incremental$$anon$2.run(Incremental.scala:455)
[info] [error] at sbt.internal.inc.IncrementalCommon$CycleState.next(IncrementalCommon.scala:117)
[info] [error] at sbt.internal.inc.IncrementalCommon$$anon$1.next(IncrementalCommon.scala:56)
[info] [error] at sbt.internal.inc.IncrementalCommon$$anon$1.next(IncrementalCommon.scala:52)
[info] [error] at sbt.internal.inc.IncrementalCommon.cycle(IncrementalCommon.scala:265)
[info] [error] at sbt.internal.inc.Incremental$.$anonfun$incrementalCompile$8(Incremental.scala:409)
[info] [error] at sbt.internal.inc.Incremental$.withClassfileManager(Incremental.scala:496)
[info] [error] at sbt.internal.inc.Incremental$.incrementalCompile(Incremental.scala:396)
[info] [error] at sbt.internal.inc.Incremental$.apply(Incremental.scala:170)
[info] [error] at sbt.internal.inc.IncrementalCompilerImpl.compileInternal(IncrementalCompilerImpl.scala:534)
[info] [error] at sbt.internal.inc.IncrementalCompilerImpl.$anonfun$compileIncrementally$1(IncrementalCompilerImpl.scala:488)
[info] [error] at sbt.internal.inc.IncrementalCompilerImpl.handleCompilationError(IncrementalCompilerImpl.scala:332)
[info] [error] at sbt.internal.inc.IncrementalCompilerImpl.compileIncrementally(IncrementalCompilerImpl.scala:425)
[info] [error] at sbt.internal.inc.IncrementalCompilerImpl.compile(IncrementalCompilerImpl.scala:137) I can' tell if this is uncovering some changes Zinc made in 1.10.0 (https://eed3si9n.com/sbt-1.10.0-beta), or uncovering some issue with the compiler bridge. |
@eed3si9n on the current main branch with sbt 1.9.9, I printed out the relations after
here are the set of
|
@bishabosha Thanks. To clarify, you mean it's there in sbt 1.9.9, but those entries that should be coming from Java sources are missing in sbt 1.10.0-RC2, right? |
@eed3si9n both those outputs are with sbt 1.9.9. From what I understand (please verify), the class names relation comes from |
If Java compiler works like Scala compiler, I guess javac only emits |
**Problem** scala/scala3#20157 identified that `sbt-dotty/dotty-knowledge.i17` scripted test fails on sbt 1.10.0-RC2. The regression happened in https://github.com/sbt/sbt/pull/7480/files#diff-6d9589bfb3f1247d2eace99bab7e928590337680d1aebd087d9da286586fba77L739-L740 where global setting was removed, and moved to project level. **Solution** This restores the global setting that is apparently referenced by now defunct Dotty plugin.
The scripted tests are now running afoul of SIP-51 😆 I'll update it soon-ish |
## Problem #20157 demonstrated that some build pipelining tests fail on the latest sbt 1.10.0-RC2: ``` Error: (sbt-test / scripted) Failed tests: Error: pipelining/Yjava-tasty-fromjavaobject Error: pipelining/Yjava-tasty-paths ``` This is likely caused by inconsistent capturing of APIs from Java sources in ExtractAPI vs AnalyzingJavaCompiler in Zinc. ## Solution This adjusts the API name entry for Java nested classes.
Out of curiosity, why not also updating the sbt version in tests and community projects as you did in 19a6990? |
oh, I suppose I'd have gotten to that before undraft-ing it anyway, I've just updated it if CI still fails, I won't have time to look at it until October, so if somebody's in more of a hurry than that, please feel free to take it over |
I don't understand why the community build failure:
is somehow being surfaced in this PR, as the compilation failure is reproducible outside of the community build context, even on sbt 1.6.2, at dotty-staging/fastparse@8b934380 , with however the problem does not reproduce if I @WojciechMazur do you have any hunches about what could be going on here? why on earth would 3.6.0 vs 3.6.1 matter? why is this PR affected, but I don't see the same failure in any of the sampling of other recent PRs that I looked at? I'm willing to go digging into it myself, but I thought I'd ask you first, since you have so much experience troubleshooting these sorts of problems — is there is anything here that is familiar to you, any clues you see? |
Is it possible that sbt has changed the version of scala-compiler dependency? It's used directly in the test to access UnitParser which in latest version of Scala 2.13 defines |
@WojciechMazur good call. with but it's baffling to me why 3.6.0 vs 3.6.1 would make a difference; the scala3-library and scala3-compiler POMs for those versions differ only by version numbers
except the problem is reproducible even on sbt 1.6.2 😱 but anyway, my hunch is that it isn't worth getting all the way to the bottom of this I've pushed commits that update our fork of fastparse to use 2.13.15 instead of 2.13.0, which is the straightforward fix... hopefully CI will like it |
one CI failure is because I'll need to rebase to pull in #21895 |
and compiler-interface to 1.10.4, there is no 1.10.5 for that fastparse was on Scala 2.13.0, needed updating to 2.13.15
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.
LGTM, I based my review on #19581
@@ -28,5 +28,5 @@ object Dependencies { | |||
"com.vladsch.flexmark" % "flexmark-ext-yaml-front-matter" % flexmarkVersion, | |||
) | |||
|
|||
val compilerInterface = "org.scala-sbt" % "compiler-interface" % "1.9.6" | |||
val compilerInterface = "org.scala-sbt" % "compiler-interface" % "1.10.4" |
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.
why not 1.10.5
and not 1.10.6
here ?
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.
it's intentional. 1.10.4 is the newest version. there isn't always a new compiler-interface for every new sbt version, as per https://github.com/sbt/zinc/releases/
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.
Is this changes necessary to be included in this PR (I doubt) ?
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.
it is needed or the community build fails. there is some discussion with Wojciech about it above. I had to upgrade the project from Scala 2.13.0 to 2.13.15.
not for merge until 1.10.0 final; but let's see if CI likes it