- About Scala
- Documentation
- Code Examples
- Software
- Scala Developers
Getting the plugin running in Eclipse PDE
Wed, 2009-07-08, 15:02
Hi,
I'm trying to run the Scala plugin (2.7.5) in the Eclipse PDE (to hack some
JUnit stuff :-), but can't seem to get it to run correctly
Reading http://lampsvn.epfl.ch/trac/scala/wiki/EclipsePlugin it seem it
shouldn't be necessary to create a config.ini for Eclipse 3.5?
I've imported great many plugins to my workspace (jdt, scala, etc) and
I don't get any errors on launch of the PDE workbench.
But compiling a Scala project in the launched workbench fails. It
reports lots of Java problems on Scala source files? Only the scala
builder is enabled for the project.
JDT weaving seems disabled, and enabling doesn't do anything. My guess
is this might be causing some problems?
Any hints?
/Jeppe
Wed, 2009-07-08, 19:57
#2
Re: Getting the plugin running in Eclipse PDE
On Wed, Jul 8, 2009 at 6:15 PM, Miles Sabin wrote:
> On Wed, Jul 8, 2009 at 3:02 PM, Jeppe Nejsum Madsen wrote:
>> I'm trying to run the Scala plugin (2.7.5) in the Eclipse PDE (to hack some
>> JUnit stuff :-), but can't seem to get it to run correctly
>>
>> Reading http://lampsvn.epfl.ch/trac/scala/wiki/EclipsePlugin it seem it
>> shouldn't be necessary to create a config.ini for Eclipse 3.5?
>
> Nb. the following is *only* relevant to people who want to help out
> with developement of the Scala IDE for Eclipse, not to people who just
> want to use it.
>
> For the development time workspace (ie. the outer, hosting one) that's
> true. Unfortunately you do still need a config.ini for the runtime
> workspace (ie. the inner, hosted one). The section "Creating a
> config.ini file" here,
>
> http://lampsvn.epfl.ch/trac/scala/wiki/EclipsePlugin
That worked (my config.ini already contained a
osgi.framework.extensions, which I commented out)
> Great to hear that you want to work on JUnit integration! If you can
> cope with the pain of the current state of trunk, I'd very much
> appreciate it if you worked there rather than on the 2.7.x branch ...
> it'll make it a lot easier to integrate anything you can contribute to
> the next release.
I'll see what I can do, but don't get your hopes up just yet :-) One
showstopper for using trunk is that afaik, Lift doesn't currently work
with 2.8, which means I will not be running trunk on a regular basis
/Jeppe
Wed, 2009-07-08, 22:37
#3
Re: Getting the plugin running in Eclipse PDE
On Wed, Jul 8, 2009 at 6:15 PM, Miles Sabin wrote:
> Great to hear that you want to work on JUnit integration! If you can
> cope with the pain of the current state of trunk, I'd very much
> appreciate it if you worked there rather than on the 2.7.x branch ...
> it'll make it a lot easier to integrate anything you can contribute to
> the next release.
Don't know if this is the right place for discussing plugin development, but:
Just for fun I tried running with trunk but since neither Lift nor
specs seem to run with 2.8 this seems like a dead end for now (for me
at least). Real pita that scala is not binary compatible between
versions.
The issue I was trying to solve was the inability of the Eclipse JUnit
runner to launch specs test cases without weird workarounds. A brief
debugging session (with 2.7.5) showed that with a declaration like
class UserUnitTest extends JUnit4(UserSpec)
It seems like Eclipse is unable to find the superclass of UserUnitTest
and therefore figure out that JUnit4 has the RunWith annotation. I
haven't digged deep into the Scala plugin, but was wondering if this
is some bigger piece that's missing or just i mishap in this specific
case?
/Jeppe
Thu, 2009-07-09, 12:57
#4
Re: Getting the plugin running in Eclipse PDE
On Wed, Jul 8, 2009 at 10:36 PM, Jeppe Nejsum Madsen wrote:
> The issue I was trying to solve was the inability of the Eclipse JUnit
> runner to launch specs test cases without weird workarounds. A brief
> debugging session (with 2.7.5) showed that with a declaration like
>
> class UserUnitTest extends JUnit4(UserSpec)
>
> It seems like Eclipse is unable to find the superclass of UserUnitTest
> and therefore figure out that JUnit4 has the RunWith annotation. I
> haven't digged deep into the Scala plugin, but was wondering if this
> is some bigger piece that's missing or just i mishap in this specific
> case?
This sounds like quite a plausible diagnosis ... the IDE isn't
constructing the corresponding JDT type hierarchy completely/correctly
at the moment, and very likely that's frustrating searches which
depend on the type hierarchy.
Patches (against trunk if at all possible) which address that would be
very much appreciated, but failing that, a ticket on Trac so that this
doesn't get forgotten would help too.
Cheers,
Miles
On Wed, Jul 8, 2009 at 3:02 PM, Jeppe Nejsum Madsen wrote:
> I'm trying to run the Scala plugin (2.7.5) in the Eclipse PDE (to hack some
> JUnit stuff :-), but can't seem to get it to run correctly
>
> Reading http://lampsvn.epfl.ch/trac/scala/wiki/EclipsePlugin it seem it
> shouldn't be necessary to create a config.ini for Eclipse 3.5?
Nb. the following is *only* relevant to people who want to help out
with developement of the Scala IDE for Eclipse, not to people who just
want to use it.
For the development time workspace (ie. the outer, hosting one) that's
true. Unfortunately you do still need a config.ini for the runtime
workspace (ie. the inner, hosted one). The section "Creating a
config.ini file" here,
http://lampsvn.epfl.ch/trac/scala/wiki/EclipsePlugin
should get you going.
Great to hear that you want to work on JUnit integration! If you can
cope with the pain of the current state of trunk, I'd very much
appreciate it if you worked there rather than on the 2.7.x branch ...
it'll make it a lot easier to integrate anything you can contribute to
the next release.
Cheers,
Miles