Today's -SNAPSHOT includes the new reflection breakout ...

159 views
Skip to first unread message

Josh Suereth

unread,
Jun 5, 2012, 1:18:34 PM6/5/12
to scala-i...@googlegroups.com
.... so we can get a chance to test out some tools before the M4.

Here's the list of folks that should try the nightly -
  • Me (Maven plugin + Scala distribution project)
  • Eclipse IDE  (Make sure your bundling works with new scala-reflect.jar)
  • SBT  (scala-reflect.jar is now required on the classpath for artifacts).
  • Anyone who's interested in testing.

I'd like to give us all a shot at ensuring the tools work before the code finally gets merged into trunk and we cut another milestone.

Eugene Burmako

unread,
Jun 5, 2012, 1:50:50 PM6/5/12
to scala-i...@googlegroups.com
A clarification about scala-reflect.jar.

Say we have the following shell script:

java -cp $toolcp scala.tools.nsc.Main -cp $librarycp $scala_args
java -cp $runtimecp scala.tools.nsc.MainGenericRunner $classname $args

Then:
1) $javacp must include scala-reflect.jar
2) $librarycp might include scala-reflect.jar, but it's not mandatory (neither manifests, nor type tags require that)
3) $runtimecp is the same as $librarycp

Eugene Burmako

unread,
Jun 5, 2012, 1:51:17 PM6/5/12
to scala-i...@googlegroups.com
Oops, sorry.

1) should read as "$toolcp must include scala-reflect.jar"

Eugene Burmako

unread,
Jun 6, 2012, 3:14:44 AM6/6/12
to scala-internals
SBT failed to build with NoClassDefFound error:

https://scala-webapps.epfl.ch/jenkins/job/run-sbt-on-scala-snapshot/43/console

The class in question has been moved to scala-reflect.jar, so, I
think, that's the problem.

On Jun 5, 7:18 pm, Josh Suereth <joshua.suer...@gmail.com> wrote:
> .... so we can get a chance to test out some tools before the M4.
>
> Here's the list of folks that should try the nightly -
>
>    - Me (Maven plugin + Scala distribution project)
>    - Eclipse IDE  (Make sure your bundling works with new scala-reflect.jar)
>    - SBT  (scala-reflect.jar is now required on the classpath for
>    artifacts).
>    - Anyone who's interested in testing.

Eugene Vigdorchik

unread,
Jun 6, 2012, 5:21:28 AM6/6/12
to scala-i...@googlegroups.com, mark....@typesafe.com
On Wed, Jun 6, 2012 at 11:14 AM, Eugene Burmako <eugene....@epfl.ch> wrote:
> SBT failed to build with NoClassDefFound error:
>
> https://scala-webapps.epfl.ch/jenkins/job/run-sbt-on-scala-snapshot/43/console
>
> The class in question has been moved to scala-reflect.jar, so, I
> think, that's the problem.
Yes I think that's a problem. As I see it, sbt doesn't yet (as of
0.12-RC1) include scala-reflect.jar along with scala-library.jar to
bootclasspath when building compiler arguments.
A proper fix would require adding reflectLibrary to scala instance and
a new release candidate for sbt 0.12.
If we can't have a new sbt RC before scala M4 with reflection, we can
point the users at adding reflect jar to bootclasspath manually,
though it's definitely not a permanent solution.

Cheers,
Eugene.

Josh Suereth

unread,
Jun 6, 2012, 6:45:32 AM6/6/12
to scala-i...@googlegroups.com, mark....@typesafe.com

Yeah...  You can make your own ScalaInstance, but we probably need a new RC for Sbt.

Johannes Rudolph

unread,
Jun 6, 2012, 7:16:01 AM6/6/12
to scala-i...@googlegroups.com, mark....@typesafe.com
Shouldn't the scala-compiler pom list scala-reflect if it is a runtime
dependency of the compiler?
--
Johannes

-----------------------------------------------
Johannes Rudolph
http://virtual-void.net

Eugene Vigdorchik

unread,
Jun 6, 2012, 7:21:18 AM6/6/12
to scala-i...@googlegroups.com, mark....@typesafe.com
On Wed, Jun 6, 2012 at 1:21 PM, Eugene Vigdorchik
<eugene.v...@gmail.com> wrote:
> On Wed, Jun 6, 2012 at 11:14 AM, Eugene Burmako <eugene....@epfl.ch> wrote:
>> SBT failed to build with NoClassDefFound error:
>>
>> https://scala-webapps.epfl.ch/jenkins/job/run-sbt-on-scala-snapshot/43/console
>>
>> The class in question has been moved to scala-reflect.jar, so, I
>> think, that's the problem
To avoid such cases in the future, maybe it makes sense to introduce a
regexp for all jars that are required by the compiler?
That would definitely help if scala library is modularized further.

Eugene.

Johannes Rudolph

unread,
Jun 6, 2012, 7:28:52 AM6/6/12
to scala-i...@googlegroups.com, mark....@typesafe.com
If I locally add the dependency to the scala-compiler pom sbt seems to
work as intended (I tested with 0.12.0-Beta2).

Josh Suereth

unread,
Jun 6, 2012, 7:29:07 AM6/6/12
to scala-i...@googlegroups.com, mark....@typesafe.com
No... it appears to be missing from the commit. DRAT!  I'll fix that and push anightly immediately.

Josh Suereth

unread,
Jun 6, 2012, 7:30:45 AM6/6/12
to scala-i...@googlegroups.com, mark....@typesafe.com
Ok, I'm pushing the snapshot now.  If you try again in 15 minutes, you should hopefully see things start working....

Eugene Burmako

unread,
Jun 6, 2012, 7:34:38 AM6/6/12
to scala-i...@googlegroups.com, Josh Suereth
Could you please submit a pullrequest to my branch afterwards, please?

Eugene Burmako

unread,
Jun 6, 2012, 7:35:25 AM6/6/12
to scala-i...@googlegroups.com, Josh Suereth
Haha you already did it. Awesome! <3

Johannes Rudolph

unread,
Jun 6, 2012, 8:24:54 AM6/6/12
to scala-i...@googlegroups.com, mark....@typesafe.com
On Wed, Jun 6, 2012 at 1:30 PM, Josh Suereth <joshua....@gmail.com> wrote:
> Ok, I'm pushing the snapshot now.  If you try again in 15 minutes, you
> should hopefully see things start working....

sbt seems to work for me now.

Eugene Burmako

unread,
Jun 6, 2012, 9:02:31 AM6/6/12
to scala-i...@googlegroups.com, mark....@typesafe.com
Wow! No way!! 

√iktor Ҡlang

unread,
Jun 6, 2012, 10:14:46 AM6/6/12
to scala-i...@googlegroups.com, mark....@typesafe.com
Wicked,

so how are things looking for 2.10-M4?

Cheers,
--
Viktor Klang

Akka Tech Lead
Typesafe - The software stack for applications that scale

Twitter: @viktorklang

Eugene Burmako

unread,
Jun 6, 2012, 10:20:12 AM6/6/12
to scala-i...@googlegroups.com, viktor...@gmail.com
I'm finishing with chunking the pull request, Iulian is looking into the IDE.

Speaking of timelines, you'd better ask someone else, but I've got a feeling that we'll release by the end of the week, since everyone else is ready.

√iktor Ҡlang

unread,
Jun 6, 2012, 10:22:46 AM6/6/12
to Eugene Burmako, scala-i...@googlegroups.com
On Wed, Jun 6, 2012 at 4:20 PM, Eugene Burmako <eugene....@epfl.ch> wrote:
I'm finishing with chunking the pull request, Iulian is looking into the IDE.

Speaking of timelines, you'd better ask someone else, but I've got a feeling that we'll release by the end of the week, since everyone else is ready.

End of the week would be nice, then I got next week cut out for me.

Cheers,

Eugene Vigdorchik

unread,
Jun 6, 2012, 10:41:25 AM6/6/12
to scala-i...@googlegroups.com
On Wed, Jun 6, 2012 at 3:28 PM, Johannes Rudolph
<johannes...@googlemail.com> wrote:
> If I locally add the dependency to the scala-compiler pom sbt seems to
> work as intended (I tested with 0.12.0-Beta2).
Right. Still this doesn't relate to working with a future
distribution, or am I missing something obvious?

Eugene.

Johannes Rudolph

unread,
Jun 6, 2012, 11:23:48 AM6/6/12
to scala-i...@googlegroups.com, mark....@typesafe.com
On Wed, Jun 6, 2012 at 2:24 PM, Johannes Rudolph
<johannes...@googlemail.com> wrote:
> sbt seems to work for me now.

Alas, that was just sbt 0.12.0-Beta2. That's what happens for me for
sbt 0.12.0-RC1 (though my environment might be borked):

[info] Compiling 10 Scala sources to
/home/johannes/git/self/enhanced-strings/target/scala-2.10/classes...
[info] 'compiler-interface' not yet compiled for Scala
2.10.0-20120604-195756-706656ee41. Compiling...
/tmp/sbt_44aaef36/CompilerInterface.scala:251: error: value RootClass
is not a member of object xsbt.CachedCompiler0.compiler.definitions
reSyncCompat(definitions.RootClass, Some(classPath),
Some(oldEntry), Some(newEntry))

^
/tmp/sbt_44aaef36/CompilerInterface.scala:321: error: value RootClass
is not a member of object xsbt.CachedCompiler0.compiler.definitions
pkg == definitions.RootClass ||
^
/tmp/sbt_44aaef36/CompilerInterface.scala:276: error: value
EmptyPackageClass is not a member of object
xsbt.CachedCompiler0.compiler.definitions
invalidateOrRemove(definitions.EmptyPackageClass.asInstanceOf[ClassSymbol])
^
three errors found
[error] (compile:compile) Error compiling sbt component 'compiler-interface'
[error] Total time: 11 s, completed Jun 6, 2012 5:19:22 PM

martin odersky

unread,
Jun 6, 2012, 11:25:07 AM6/6/12
to scala-i...@googlegroups.com
You need to replace definitions with rootMirror, than it should be OK.

Cheers

 - Martin
--
Martin Odersky
Prof., EPFL and Chairman, Typesafe
PSED, 1015 Lausanne, Switzerland
Tel. EPFL: +41 21 693 6863
Tel. Typesafe: +41 21 691 4967

Eugene Burmako

unread,
Jun 6, 2012, 11:25:47 AM6/6/12
to scala-internals
RootXXX and EmptyPackageXXX are moved to compiler.rootMirror. Same
goes for requiredClass and likes.

On Jun 6, 5:23 pm, Johannes Rudolph <johannes.rudo...@googlemail.com>
wrote:
> On Wed, Jun 6, 2012 at 2:24 PM, Johannes Rudolph
>

Johannes Rudolph

unread,
Jun 6, 2012, 11:28:02 AM6/6/12
to scala-i...@googlegroups.com
On Wed, Jun 6, 2012 at 5:25 PM, Eugene Burmako <eugene....@epfl.ch> wrote:
> RootXXX and EmptyPackageXXX are moved to compiler.rootMirror. Same
> goes for requiredClass and likes.

Aha does anyone understand why the compiler-interface is now broken
for sbt 0.12.0-RC1 and not for 0.12.0-Beta2?

Perhaps someone could retrigger the "run-sbt-on-scala-snapshot"
jenkins task to check if that's not something particular to my sbt
setup?

Johannes Rudolph

unread,
Jun 6, 2012, 11:35:45 AM6/6/12
to scala-i...@googlegroups.com
On Wed, Jun 6, 2012 at 5:28 PM, Johannes Rudolph
<johannes...@googlemail.com> wrote:
> On Wed, Jun 6, 2012 at 5:25 PM, Eugene Burmako <eugene....@epfl.ch> wrote:
>> RootXXX and EmptyPackageXXX are moved to compiler.rootMirror. Same
>> goes for requiredClass and likes.
>
> Aha does anyone understand why the compiler-interface is now broken
> for sbt 0.12.0-RC1 and not for 0.12.0-Beta2?

Seems like that the newly failing code in sbt's compiler interface is
part of the recent classpath changes:

https://github.com/harrah/xsbt/commit/2db0101eb803255433558cc6626ca6706623497b

Josh Suereth

unread,
Jun 6, 2012, 11:35:50 AM6/6/12
to scala-i...@googlegroups.com
That's odd....

I spent a long time trying to hack my compiler-interface dependency in SBT to be something other than default, and eventually gave up.  I think perhaps this kind of a setting is actually worthwhile to determine this kind of thing:  Why is one working and another not?  Check the sources...

iulian dragos

unread,
Jun 6, 2012, 11:50:32 AM6/6/12
to scala-i...@googlegroups.com
On Tue, Jun 5, 2012 at 7:18 PM, Josh Suereth <joshua....@gmail.com> wrote:
> .... so we can get a chance to test out some tools before the M4.
>
> Here's the list of folks that should try the nightly -
>
> Me (Maven plugin + Scala distribution project)
> Eclipse IDE  (Make sure your bundling works with new scala-reflect.jar)

There are a couple of hurdles, but in general it looks better than I feared! :-)

1) scala-refactoring
- needs 'duplicateTree(Tree)' -- was replaced with `duplicate' on Tree.
- fails 16 tests after fixing the above. The way I know Mirko, he
will jump on it the moment there is IDE support, so I can disable them
for the next nightly build

2) the IDE itself:
- definitions.EmptyPackage (need an alias to the new mirror-based
EmptyPackage)
- definitions.getClass (need an alias to the new getClassByName)
- for uniformity, you should probably rename getModule to getModuleByName
- setting 'sourcepath' is deprecated, but throws an assertion error
when setting it. That should not be the case. Issue a warning and
route it to YsourcePath.

I can't say more at this moment, since the IDE is unusable because of
the sourcepath issue. Since the IDE has to work with both, I'd prefer
to have a fallback in the compiler (or remove the setting altogether).

If you could add @deprecated aliases for the above methods, and remove
the assertion error, tomorrow we can most probably have an IDE working
with the new reflection.

cheers,
iulian



> SBT  (scala-reflect.jar is now required on the classpath for artifacts).
> Anyone who's interested in testing.
>
>
> I'd like to give us all a shot at ensuring the tools work before the code
> finally gets merged into trunk and we cut another milestone.



--
« Je déteste la montagne, ça cache le paysage »
Alphonse Allais

Mirko Stocker

unread,
Jun 6, 2012, 11:56:20 AM6/6/12
to scala-i...@googlegroups.com
On Wed, Jun 6, 2012 at 5:50 PM, iulian dragos <jagu...@gmail.com> wrote:
> 1) scala-refactoring
>  - needs 'duplicateTree(Tree)' -- was replaced with `duplicate' on Tree.

I can change that, but I'm at ICSE at the moment so I don't have much
time before the weekend.

>  - fails 16 tests after fixing the above. The way I know Mirko, he
> will jump on it the moment there is IDE support, so I can disable them
> for the next nightly build

Tests have been failing for some time now, but I think there's nothing
that should block the IDE, and yes, as soon as I have an IDE where I
can debug that, I'm going to fix it.

Cheers,

Mirko

--
Mirko Stocker | m...@misto.ch
Work: http://ifs.hsr.ch | http://infoq.com
Personal: http://misto.ch | http://twitter.com/m_st

iulian dragos

unread,
Jun 6, 2012, 11:59:54 AM6/6/12
to scala-i...@googlegroups.com
On Wed, Jun 6, 2012 at 5:56 PM, Mirko Stocker <m...@misto.ch> wrote:
> On Wed, Jun 6, 2012 at 5:50 PM, iulian dragos <jagu...@gmail.com> wrote:
>> 1) scala-refactoring
>>  - needs 'duplicateTree(Tree)' -- was replaced with `duplicate' on Tree.
>
> I can change that, but I'm at ICSE at the moment so I don't have much
> time before the weekend.

I didn't see a 2.10 branch yet, otherwise I could have pushed this fix
(there are only 3 occurrences).

iulian

>
>>  - fails 16 tests after fixing the above. The way I know Mirko, he
>> will jump on it the moment there is IDE support, so I can disable them
>> for the next nightly build
>
> Tests have been failing for some time now, but I think there's nothing
> that should block the IDE, and yes, as soon as I have an IDE where I
> can debug that, I'm going to fix it.
>
> Cheers,
>
> Mirko
>
> --
> Mirko Stocker | m...@misto.ch
> Work: http://ifs.hsr.ch | http://infoq.com
> Personal: http://misto.ch | http://twitter.com/m_st



Mirko Stocker

unread,
Jun 6, 2012, 3:21:59 PM6/6/12
to scala-i...@googlegroups.com
On Wed, Jun 6, 2012 at 5:59 PM, iulian dragos <jagu...@gmail.com> wrote:
> I didn't see a 2.10 branch yet, otherwise I could have pushed this fix
> (there are only 3 occurrences).

So far I've been able to keep 2.9 and 2.10 supported in master by
checking the Scala version at runtime and then doing one thing or the
other, but sooner or later I'll have to create a branch I fear.
Anyway, I tried to build with 2.10 and got the following - somewhat
expected - error:

[INFO] [Software being installed: org.scala-refactoring.library
0.5.0.qualifier, Missing requirement: org.scala-ide.scala.compiler
2.10.0.v20120604-195756-706656ee41 requires 'package
scala.reflect.internal 0.0.0' but it could not be found, Cannot
satisfy dependency: org.scala-refactoring.library 0.5.0.qualifier
depends on: package scala.tools.nsc 0.0.0]

I wonder why the compiler version is from Monday, but that seems to be
the latest available on
http://download.scala-ide.org/scala-eclipse-toolchain-osgi-trunk/plugins/

Can I do something about that?

iulian dragos

unread,
Jun 6, 2012, 5:03:31 PM6/6/12
to scala-i...@googlegroups.com
On Wed, Jun 6, 2012 at 9:21 PM, Mirko Stocker <m...@misto.ch> wrote:
> On Wed, Jun 6, 2012 at 5:59 PM, iulian dragos <jagu...@gmail.com> wrote:
>> I didn't see a 2.10 branch yet, otherwise I could have pushed this fix
>> (there are only 3 occurrences).
>
> So far I've been able to keep 2.9 and 2.10 supported in master by
> checking the Scala version at runtime and then doing one thing or the
> other, but sooner or later I'll have to create a branch I fear.
> Anyway, I tried to build with 2.10 and got the following - somewhat
> expected - error:
>
> [INFO] [Software being installed: org.scala-refactoring.library
> 0.5.0.qualifier, Missing requirement: org.scala-ide.scala.compiler
> 2.10.0.v20120604-195756-706656ee41 requires 'package
> scala.reflect.internal 0.0.0' but it could not be found, Cannot
> satisfy dependency: org.scala-refactoring.library 0.5.0.qualifier
> depends on: package scala.tools.nsc 0.0.0]
>
> I wonder why the compiler version is from Monday, but that seems to be
> the latest available on
> http://download.scala-ide.org/scala-eclipse-toolchain-osgi-trunk/plugins/
>
> Can I do something about that?

I have a bunch of local changes to get the build going. I wasn't ready
to push them. You'd need to build the toolchain locally and add a
dependency to scala-reflect in org.scala-ide.scala.compiler/pom.xml.
I'll do it tomorrow.

iulian

>
> Cheers,
>
> Mirko
>
> --
> Mirko Stocker | m...@misto.ch
> Work: http://ifs.hsr.ch | http://infoq.com
> Personal: http://misto.ch | http://twitter.com/m_st



Josh Suereth

unread,
Jun 6, 2012, 5:48:11 PM6/6/12
to scala-i...@googlegroups.com
The nightly should have that dependency correctly....

Vlad Ureche

unread,
Jun 6, 2012, 6:23:22 PM6/6/12
to scala-i...@googlegroups.com, Iulian Dragos


On Wed, Jun 6, 2012 at 5:50 PM, iulian dragos <jagu...@gmail.com> wrote:
 - setting 'sourcepath' is deprecated, but throws an assertion error
when setting it. That should not be the case. Issue a warning and
route it to YsourcePath.

I think it's safe to do that, as I replaced all the scaladoc code to use docSourcePath.
https://github.com/scalamacros/kepler/pull/4 should fix it.

Vlad

Eugene Burmako

unread,
Jun 6, 2012, 6:41:56 PM6/6/12
to scala-internals
Integrated Vlad's fix into nightly/2012-06-07 [1] (and also renamed
pullrequest/reflection-for-todays-nightly to nightly/2012-06-06).

Could you, please, cut a nightly build from that branch?

[1] https://github.com/scalamacros/kepler/tree/nightly/2012-06-07

On Jun 7, 12:23 am, Vlad Ureche <vlad.ure...@gmail.com> wrote:

iulian dragos

unread,
Jun 7, 2012, 4:48:29 AM6/7/12
to scala-i...@googlegroups.com
On Thu, Jun 7, 2012 at 12:41 AM, Eugene Burmako <eugene....@epfl.ch> wrote:
> Integrated Vlad's fix into nightly/2012-06-07 [1] (and also renamed
> pullrequest/reflection-for-todays-nightly to nightly/2012-06-06).
>
> Could you, please, cut a nightly build from that branch?

It looks like there isn't a nightly with the latest changes, am I right?

iulian

>
> [1] https://github.com/scalamacros/kepler/tree/nightly/2012-06-07
>
> On Jun 7, 12:23 am, Vlad Ureche <vlad.ure...@gmail.com> wrote:
>> On Wed, Jun 6, 2012 at 5:50 PM, iulian dragos <jagua...@gmail.com> wrote:
>> >  - setting 'sourcepath' is deprecated, but throws an assertion error
>> > when setting it. That should not be the case. Issue a warning and
>> > route it to YsourcePath.
>>
>> I think it's safe to do that, as I replaced all the scaladoc code to use
>> docSourcePath.https://github.com/scalamacros/kepler/pull/4should fix it.
>>
>> Vlad



Eugene Burmako

unread,
Jun 7, 2012, 4:51:44 AM6/7/12
to <scala-internals@googlegroups.com>, Lukas Rytz
Dunno, not that I know of.

Lukas, could you, please, roll one?

Lukas Rytz

unread,
Jun 7, 2012, 4:52:06 AM6/7/12
to Eugene Burmako, <scala-internals@googlegroups.com>
I don't know how. If I run the nightlies on jenkins it uses the scala/scala master
branch, which is not what you want, no?

Josh Suereth

unread,
Jun 7, 2012, 6:38:19 AM6/7/12
to scala-i...@googlegroups.com

My bad... I missed this yesterday.   I'll push one in the next hour after build completes.

Josh Suereth

unread,
Jun 7, 2012, 7:48:06 AM6/7/12
to scala-i...@googlegroups.com
Ok, pushing as we speak.  Should be live in 5 minutes.

Mirko Stocker

unread,
Jun 8, 2012, 1:43:55 AM6/8/12
to scala-i...@googlegroups.com
On Wed, Jun 6, 2012 at 5:59 PM, iulian dragos <jagu...@gmail.com> wrote:
>>>  - needs 'duplicateTree(Tree)' -- was replaced with `duplicate' on Tree.
>>
>> I can change that, but I'm at ICSE at the moment so I don't have much
>> time before the weekend.
>
> I didn't see a 2.10 branch yet, otherwise I could have pushed this fix
> (there are only 3 occurrences).

I discovered that 2.9 already has the duplicate methods on trees, so
it's easy to change :-) I've committed it, but I couldn't verify that
it works on 2.10.

Christopher Vogt

unread,
Jun 8, 2012, 9:00:21 AM6/8/12
to scala-i...@googlegroups.com
> Aha does anyone understand why the compiler-interface is now broken
> for sbt 0.12.0-RC1 and not for 0.12.0-Beta2?

Any news? For me the compiler-interface can't be compiled with both sbt
versions right now (using kepler/pullrequest/reflection as the
compiler). The problem is also a class which was moved to
scala-reflect.jar (NoClassDefFoundError:
scala/reflect/internal/settings/AbsSettings).

We need to verify that SLICK works with upcoming M4, before the release,
so we urgently need a workaround :).

Somebody mentioned the scala-compiler.pom? Where can I find it? Any
other workaround?

Thx

Chris
--
Scala-Team EPFL

Eugene Burmako

unread,
Jun 8, 2012, 9:12:39 AM6/8/12
to scala-i...@googlegroups.com
updated scala-compiler-pom.xml can be found in pullrequest/reflection

Stefan Zeiger

unread,
Jun 9, 2012, 7:59:16 AM6/9/12
to scala-i...@googlegroups.com
The parts of SLICK that don't rely on reflection compile and pass all tests with the latest nightly: https://github.com/slick/slick/tree/topic/scala-2.10.0-M4 . I'll leave the refactoring of the reflection-based code to Chris.

BTW, the changes to auto-generated copy() methods are pretty annoying when you use context bounds: https://github.com/slick/slick/commit/c8d089084412aa83355558e42ddb1c75a754d3cd#L1L138


On 2012-06-05 19:18, Josh Suereth wrote:
.... so we can get a chance to test out some tools before the M4.

Here's the list of folks that should try the nightly -
  • Me (Maven plugin + Scala distribution project)
  • Eclipse IDE  (Make sure your bundling works with new scala-reflect.jar)
  • SBT  (scala-reflect.jar is now required on the classpath for artifacts).
  • Anyone who's interested in testing.

Paul Butcher

unread,
Jun 9, 2012, 8:50:34 AM6/9/12
to scala-i...@googlegroups.com
Eugene's asked me to try the most recent nightly, but I'm falling at the first hurdle :-(

Can someone talk me through how to workaround the NoClassDefFoundError:
scala/reflect/internal/settings/AbsSettings problem?

I've tried putting scala-reflect.jar on the classpath explicitly with:

sbt -J-Xbootclasspath/a:/Users/paul/scala-2.10.0-20120608-194203-43ae8259f2/lib/scala-reflect.jar

(this is using paulp's sbt-extras sbt launcher) but I still get the same problem.

--
paul.butcher->msgCount++

Snetterton, Castle Combe, Cadwell Park...
Who says I have a one track mind?

http://www.paulbutcher.com/
LinkedIn: http://www.linkedin.com/in/paulbutcher
MSN: pa...@paulbutcher.com
AIM: paulrabutcher
Skype: paulrabutcher

Paul Phillips

unread,
Jun 9, 2012, 10:35:02 AM6/9/12
to scala-i...@googlegroups.com


On Sat, Jun 9, 2012 at 4:59 AM, Stefan Zeiger <sze...@novocode.com> wrote:
BTW, the changes to auto-generated copy() methods are pretty annoying when you use context bounds: https://github.com/slick/slick/commit/c8d089084412aa83355558e42ddb1c75a754d3cd#L1L138

Ouch.  There's no good resolution without some way to control what case classes do, because to avoid that there has to be a field for the implicit parameter.  That is, in principle.  In fact you can't avoid it at all, even if the implicit is a val.

This is a direct collision between two unrelated reasons people use a second parameter list.

If there is any appetite for more logic I can imagine it being changed so implicit parameter lists get vals again, or at least so that if you specify them with vals the copy method honors their existence by using them and skipping the eta-expansion.  But that would mean losing context bounds, so it probably has to be automatic for implicits to be useful.

Eugene Vigdorchik

unread,
Jun 9, 2012, 11:05:25 AM6/9/12
to scala-i...@googlegroups.com
On Sat, Jun 9, 2012 at 4:50 PM, Paul Butcher <pa...@paulbutcher.com> wrote:
> Eugene's asked me to try the most recent nightly, but I'm falling at the
> first hurdle :-(
>
> Can someone talk me through how to workaround the NoClassDefFoundError:
> scala/reflect/internal/settings/AbsSettings problem?
It works ok to me with the latest nightly with "scalaVersion :=
2.10.0-SNAPSHOT" with todays nightly. Maybe you have a stale version
in cache?
Try 'update' or maybe even wipe your .m2.

Eugene.

Eugene Vigdorchik

unread,
Jun 9, 2012, 11:10:52 AM6/9/12
to scala-i...@googlegroups.com
On Sat, Jun 9, 2012 at 7:05 PM, Eugene Vigdorchik
<eugene.v...@gmail.com> wrote:
> On Sat, Jun 9, 2012 at 4:50 PM, Paul Butcher <pa...@paulbutcher.com> wrote:
>> Eugene's asked me to try the most recent nightly, but I'm falling at the
>> first hurdle :-(
>>
>> Can someone talk me through how to workaround the NoClassDefFoundError:
>> scala/reflect/internal/settings/AbsSettings problem?
> It works ok to me with the latest nightly with "scalaVersion :=
> 2.10.0-SNAPSHOT" with todays nightly. Maybe you have a stale version
> in cache?
> Try 'update' or maybe even wipe your .m2.
Oops, I meant .ivy2 of course.

Paul Butcher

unread,
Jun 9, 2012, 11:12:15 AM6/9/12
to scala-i...@googlegroups.com
Thanks Eugene - I was using a manually downloaded snapshot that was clearly a day too old.

--
paul.butcher->msgCount++

Snetterton, Castle Combe, Cadwell Park...
Who says I have a one track mind?

http://www.paulbutcher.com/
LinkedIn: http://www.linkedin.com/in/paulbutcher
MSN: pa...@paulbutcher.com
AIM: paulrabutcher
Skype: paulrabutcher

Reply all
Reply to author
Forward
0 new messages