CssBoundLiftScreen throws AbstractMethodError with Scala 2.11

42 views
Skip to first unread message

Torsten Uhlmann

unread,
Jun 18, 2015, 12:11:21 PM6/18/15
to lif...@googlegroups.com
Hi,

we're running into a strange problem in our application.

We just upgraded from Scala 2.10.4 to Scala 2.11.6 and Lift 2.6.1 to 2.6.1. Our application uses a few small CssBoundLiftScreens.
Everything compiles fine, but accessing such a screen yields an AbstractMethodError:

Message: java.lang.AbstractMethodError: code.snippet.AccountScreen$.NextId()Lnet/liftweb/util/AnyVar;
	net.liftweb.http.CssBoundScreen$class.renderAll(CssBoundScreen.scala:134)
	code.snippet.BootstrapCssBoundLiftScreen.renderAll(BaseScreen.scala:23)
	net.liftweb.http.LiftScreen$class.renderHtml(LiftScreen.scala:1535)
	code.snippet.BootstrapCssBoundLiftScreen.renderHtml(BaseScreen.scala:33)
	net.liftweb.http.LiftScreen$class.toForm(LiftScreen.scala:1495)
        ...

Do you have any idea what causes this?

The Java description of the exeption says it only occurs if the runtime version of the called class is different from the compile time one. 
I don't see how that could be possible in a sbt project. Anyway, maybe there are other causes.

Any ideas would be greatly appreciated.

Thanks,
Torsten.

Richard Dallaway

unread,
Jun 18, 2015, 12:16:48 PM6/18/15
to lif...@googlegroups.com
Hey Torsten - I suspect you've tried this, but do make sure you've done an `sbt clean` or removed all the target folders.  That's all that springs to mind.

--
--
Lift, the simply functional web framework: http://liftweb.net
Code: http://github.com/lift
Discussion: http://groups.google.com/group/liftweb
Stuck? Help us help you: https://www.assembla.com/wiki/show/liftweb/Posting_example_code

---
You received this message because you are subscribed to the Google Groups "Lift" group.
To unsubscribe from this group and stop receiving emails from it, send an email to liftweb+u...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Torsten Uhlmann

unread,
Jun 18, 2015, 2:21:59 PM6/18/15
to lif...@googlegroups.com
Thanks, Richard!

Unfortunately, that doesn't help.

I removed the .ivy2 cache and the two target directories. Also did a clean. The error still occurs.

Could it be that Lift is compiled a different Scala version (other than 2.11.6) and that's causing the trouble?

Antonio Salazar Cardozo

unread,
Jun 18, 2015, 3:04:29 PM6/18/15
to lif...@googlegroups.com, torsten...@gmail.com
I would check your dependency trees and make sure you're not accidentally pulling in
a different lift transient dependency. 2.11 should be binary compatible between minor
releases, afaik…
Thanks,
Antonio

Torsten Uhlmann

unread,
Jun 19, 2015, 4:11:46 AM6/19/15
to lif...@googlegroups.com, torsten...@gmail.com
Thank, Antonio!

I checked the dependencyTree and also the package we generate with "assembly". No *2.10* libraries are referenced or included.

Assembly reports "lift-webkit_2.11-2.6.2.jar" twice but I guess that's not a problem, just the way it resolves the dependencies.

Thanks for all the help and more help welcome :)

Torsten.

Antonio Salazar Cardozo

unread,
Jun 19, 2015, 2:16:10 PM6/19/15
to lif...@googlegroups.com, torsten...@gmail.com
Hmm… Any chance you can construct a github repo that reproduces this? It seems
like it may help to see it failing locally.

Also, have you tried a different 2.11 release just to see if it helps?
Thanks,
Antonio

Torsten Uhlmann

unread,
Jun 20, 2015, 10:19:33 AM6/20/15
to lif...@googlegroups.com, torsten...@gmail.com
I have created a repository here: https://github.com/tuhlmann/liftscreen-error

It's a sample app based on lift-mongo and using the CssBoundLiftScreen stuff we're using in our app.
Scala version is 2.11.6, Lift is 2.6.2

And of course, all works fine, it doesn't reproduce the problem.
So no need for you to look into it, it will only show a nicely working Lift app :)

But that tells me that it's not a fundamental problem in the Lift artifacts, rather it has to do with the dependencies of our application.

Thanks,
Torsten.

Antonio Salazar Cardozo

unread,
Jun 20, 2015, 1:41:01 PM6/20/15
to lif...@googlegroups.com, torsten...@gmail.com
Yeah, super bizarre :/ Let us know if you discover the oddity that's causing this!
Thanks,
Antonio
Reply all
Reply to author
Forward
0 new messages