I previously asked about helping get things updated for helios; thanks
David and Matt for the help. I got code checked out (from the
tycho-reorg branch), was able to build, install the plugins from the
local update site, restart my workbench and then... a bunch of class
not found errors. There's probably some kind of issue with the
metadata or the build/runtime classpaths, who knows. So, I have
several questions about how you scala-ide devs build, test and debug
the ide plugins.
First, it seems the various top-level directories in the checkout are
valid PDE projects, so that you can import them into eclipse and work
on them there. You get special editors for the manifest files, build
properties, etc. Is this the way you all do things, or do you work on
the projects totally outside the IDE?
I understand that tycho is a nice tool for managing dependencies and
integrating with the maven workflow, but all the eclipse plugin
documentation I can find is centered around building from within the
PDE. They also talk about how to debug, how to launch a new workbench
that will run the most-recently built version of the plugin you're
working on, etc. How is this done with tycho the way you have things
set up? Do I always have to build from outside the ide, then launch a
new test workbench myself, install from the local update site, etc?
If so, how do I set up that test workbench so I can debug plugin
errors, get tracebacks, etc? As far as I can tell, Jin's helios patch
was mostly about setting up his environment so he could build from
within the PDE using ant and thus take advantage of the platform
infrastructure that is already there. But this would seem to totally
negate the whole tycho reorganization, unless I'm missing something.
How were things done before tycho? What are people doing now?
Sorry for all the newbie questions, but I feel like there's a lot of
complicated infrastructure I need to understand before I can really
help. Any info you have would be greatly appreciated, and I
definitely plan to document this all on the wiki so other can get up
and running more quickly than me.
Thanks,
Matthew
> (sometime to read the source I import/open and then close
> org.scala-ide.sdt.aspects)
>
> I did live test of change :
> * via Eclipse > run Eclipse Appication (I reduce the number of plugins
> to minimum) I can dump/send you my launcher script if you want.
I'd appreciate if you could send that. Can this be set up using the
standard eclipse run configuration editors, or does it require editing
raw XML?
-Matthew
As i work on 3.5.x, I imported project into 3.5.x.
I don't know how to code for 3.6 from 3.5.x, so IMO, until you'll be
able to create an update-site for 3.6 and use scala-ide with e3.6 you
will have to code with editor + maven.
Then you will use/eat your own build to improve 3.6 support.
Doing cross eclipse dev is not the simple way to start contributing ;-)
> Also, when you import these projects into eclipse, is maven/tycho
> doing the build behind the scenes regardless of which way it is
> imported into eclipse, or does eclipse do the build itself?
under 3.5 (my config)
if you import as existing project then eclipse do the build itself via
Scala-IDE (other version installed from http update-site or your own)
if you import as maven project with m2eclipse + m2eclipse-scala +
scala-ide installed, maven will only do some resources processing (~
nothing) and delegate to scala-ide
under 3.6
if you don't have scala-ide but m2eclipse, i suppose you could edit
source (as raw text) and build (run maven from command line, or
run-as>maven ... menu on project)
>
>
>> (sometime to read the source I import/open and then close
>> org.scala-ide.sdt.aspects)
>>
>> I did live test of change :
>> * via Eclipse > run Eclipse Appication (I reduce the number of plugins
>> to minimum) I can dump/send you my launcher script if you want.
>
> I'd appreciate if you could send that. Can this be set up using the
> standard eclipse run configuration editors, or does it require editing
> raw XML?
Args, I currently testing some additional module with it.
To create the run configuration (under eclipse):
1. open META-INF/MANIFEST.MF
2. on 'Overview' tab, hit 'Launch an Ecplise Application' (Shift+Alt+X E)
3. play with the eclipse env with your plugin
4. back on original Eclipse, call Run >Run Configurations ... , under
EclipseApplication select the newly created configuration adjust name,
and plugins (enabled, deselect all, select yours, hit add required,
validate, apply, run)
/davidB
>
> -Matthew
>
I tried running a maven build in this way from inside eclipse
(helios), but I can't figure out how to do the equivalent of the -P
helios options used in the build scripts. When I run the build it
starts adding galileo repos and (I assume) building for galileo. Any
thoughts here?
>>
>>
>>> (sometime to read the source I import/open and then close
>>> org.scala-ide.sdt.aspects)
>>>
>>> I did live test of change :
>>> * via Eclipse > run Eclipse Appication (I reduce the number of plugins
>>> to minimum) I can dump/send you my launcher script if you want.
>>
>> I'd appreciate if you could send that. Can this be set up using the
>> standard eclipse run configuration editors, or does it require editing
>> raw XML?
>
> Args, I currently testing some additional module with it.
> To create the run configuration (under eclipse):
> 1. open META-INF/MANIFEST.MF
> 2. on 'Overview' tab, hit 'Launch an Ecplise Application' (Shift+Alt+X E)
> 3. play with the eclipse env with your plugin
> 4. back on original Eclipse, call Run >Run Configurations ... , under
> EclipseApplication select the newly created configuration adjust name,
> and plugins (enabled, deselect all, select yours, hit add required,
> validate, apply, run)
>
I can launch with a run configuration, but the plugins are not
activated because it says there are missing dependencies on the
bundles
org.scala-ide.scala.library
org.scala-ide.scala.compiler
org.scala-refactoring.library
scalariform
these are getting built by the command-line maven build and the jars
show up in the local update site, but how do I tell the eclipse PDE
project how to find these so that the dependencies are satisfied? I
tried adding the built jars and the maven projects to the .core
plugin's build path, but neither of those things seemed to work.
cheers,
Matthew
Properties of your project > Maven therer is field "Active Maven Profiles"
Else In the Run Conffiguration, I think you could complete the
configuration of your build command : "Maven Build" section.
Else you could edit (on your branch) org.scala-ide.build/pom.xml and
move the <activeByDefault>true</activeByDefault> from profile
"galileo" to "helios"
My hackerie (I'm not sure, it's the right solution) :
I installed the plugins in my main eclipse and use the "add required" plugin.
Else you need to have those project as eclipse project.
Sorry to not be helpfull about cross eclipse build/test (I never did it).
>
> cheers,
> Matthew
>
>> I can launch with a run configuration, but the plugins are not
>> activated because it says there are missing dependencies on the
>> bundles
>>
>> org.scala-ide.scala.library
>> org.scala-ide.scala.compiler
>> org.scala-refactoring.library
>> scalariform
>>
>> these are getting built by the command-line maven build and the jars
>> show up in the local update site, but how do I tell the eclipse PDE
>> project how to find these so that the dependencies are satisfied? I
>> tried adding the built jars and the maven projects to the .core
>> plugin's build path, but neither of those things seemed to work.
>
> My hackerie (I'm not sure, it's the right solution) :
> I installed the plugins in my main eclipse and use the "add required" plugin.
> Else you need to have those project as eclipse project.
>
> Sorry to not be helpfull about cross eclipse build/test (I never did it).
>
I've searched around and seen that other people have the same problems
with dependencies when trying to use eclipse, so for now I've decide
to punt on this issue. I just start up a workbench using a run
configuration with the scala plugins deactivated, then use the local
update site (built previously by maven) to install the plugins.
This works, but the plugins do not install and run because of a
missing dependency. It says org.scala-refactoring.library depends on
junit-0.0.0 and this bundle can't be resolved. Shouldn't the maven
build be managing the transitive dependencies when it build the
refactoring library? Also what's with the 0.0.0 version number? I
see these all over (for example in the various feature.xml files);
does this mean any version number will do, or get the latest version,
or something like that?
Thanks again for the help.
Cheers,
Matthew
refactoring library is provide by an other update-site (listed in main pom.xml)
Mirko (the author) doesn't seem (like eclipse, PDE,...) to separate
test and main dependencies.
It is strange as junit plugins are provided with default eclipse
distribution (classic and java developper).
Do you have some *junit* jar into your helios's plugins directory ?
> Also what's with the 0.0.0 version number? I
> see these all over (for example in the various feature.xml files);
> does this mean any version number will do, or get the latest version,
> or something like that?
I read 0.0.0 as "unspecified", "latest". I don't know exactly, I use
it into feature.xml and site.xml to not have to keep the value
uptodate with plugins and features.
>
> Thanks again for the help.
Do made some progress ?
> Cheers,
> Matthew
>
/davidB
I'm getting an error while maven is building the core ide plugin. For
some reason Maven continues on happily with the build even after the
error, which is why I hadn't noticed this before. It's an out of
memory error happening in the scala compiler (see traceback below). I
turned on maven debug output, but still can't tell what file is being
compiled when the error happens. I also set MAVEN_OPTS=-Xmx1024m to
increase the heap space, but that doesn't solve the problem, so I
don't know whether I'm just running out of memory, or seeing some sort
of compiler bug. Any thoughts about finding which file, and how much
memory I should need for the build? Also, when I look at the final
org.scala-ide.cor_xxx.jar that gets packaged up, it is only 400kB,
while the version installed in 3.5.2 is something like 1.3MB, so I'm
guessing there is a lot missing from the package.
cheers,
Matthew
Great, with more heap space the build works. There is a compile
error, but at least it stops and shows me where the error is so I can
try to fix it. I've attached the gory details of the debug output
with the OOM error that did not stop the build. There's actually only
one [ERROR] line in the whole thing, right in the middle of the
relevant traceback so it's easy to find, though if you're writing
maven plugins you're probably used to looking at this kind of output
:-)
-Matthew
Another issue: I tried installing the scala plugin in the eclipse
installation where I had been working on developing the plugin and
already had installed AJDT along with its weaving feature. When I
restarted eclipse after the install, it went into an infinite loop
with the launcher window appearing, disappearing, etc. Again, no
errors were logged anywhere I could see them, but clearly the
bootstrapping was broken. I tried again on a fresh installation of
eclipse, this time installing AJDT _without_ its weaving feature, and
then just installing the weaving feature of the scala plugin, and now
at least eclipse boots, though the plugin has issues as described
above. Any thoughts? I used the AJDT release update site:
http://download.eclipse.org/tools/ajdt/36/update
Thanks for all your help. I feel like this is pretty close.
Cheers,
Matthew
The Milles advice about having AJDT + scala in same install is to :
1. install AJDT + weaving feature
2. install Scala only, no weaving feature
I must admit, that run into trouble in my 3.5.2 install with AJDT (and
did a fresh install without AJDT to be able to work)
May be, it's time to share your work.
Do you have permissions to push your branch somewhere (scala assembla
git repository or github) ?
git push origin wip_helios
Can you deploy your update site on a static web server ?
Thanks for your time and feedback
/davidB
The advice (from Miles) ....
The problem seems to be that JDT weaving service is not getting
started. I had a fresh eclipse 3.6 installation, installed the plugin
from local update site, then looked at Eclipse preference and under
JDT Weaving it says the service is disabled and gives the option to
start it. When I enable the service and then restart Eclipse it still
shows up as disabled. Not sure what's up or how to fix it, but I'll
continue to explore.
-Matthew
On Fri, Jul 23, 2010 at 12:01 AM, David Bernard
/davidB
The weird thing about the weaving service issue is that it's even
happening in a fresh eclipse installation with AJDT completely out of
the picture. But glad to know it's not specific to me or to helios.
-Matthew
On Fri, Jul 23, 2010 at 9:02 AM, David Bernard
Thank for your works, I spent few hours to complete your job.
I attach I patch who allow me to install Scala-IDE on helios and test it with a basic project.
I used the AspectJ Equinox Weaving feature (not the own provide by Scala-IDE), so the generation of the update site should be fixe to us the "official".
/davidB
I also had to remove and then re-add the Scala Nature on a few
existing projects to get them properly compiled and I saw a few
failures in the presentation compiler, but generally things are
working. I've update the update site at
http://maffoo.net/scala-ide/site-helios if anyone else wants to give
it a try. Thanks for getting the last bits fixed!
-matthew
Yes I notice the issue (and others), IMO it's an AJDT behavior.
Against Miles advice, I don't use -clean (only explicitly sometimes).
>
> I also had to remove and then re-add the Scala Nature on a few
> existing projects to get them properly compiled and I saw a few
> failures in the presentation compiler, but generally things are
> working. I've update the update site at
> http://maffoo.net/scala-ide/site-helios if anyone else wants to give
> it a try. Thanks for getting the last bits fixed!
Please update the ticket, to show the progress an try to have user feedback.
Tomorrow I'll push your wip_tuning branch as a branch on assembla git repo (or you can do it, ask Miles (privately) for permission).
I'll see how we can link the feature to use the AJDT weaving instead of our own.
Good job.
/davidB
-matthew
https://www.assembla.com/wiki/show/scala-ide/Setup_with_Helios_and_Tycho
Would be nice to have someone else try this out and let me know how it
works for you.
Cheers,
Matthew
I push back your stuff under assembla repo and I update/merge latest
changeset from tycho-reorg into wip_helios.
/davidB
Cheers,
Miles
--
Miles Sabin
tel: +44 7813 944 528
gtalk: mi...@milessabin.com
skype: milessabin
http://www.chuusai.com/
http://twitter.com/milessabin
On 25/07/2010, at 11:11 AM, Matthew Neeley wrote:
> I put some detailed instructions up on the wiki about setting things
> up for development with/for helios, now that I've got it working:
>
> https://www.assembla.com/wiki/show/scala-ide/Setup_with_Helios_and_Tycho
>
> Would be nice to have someone else try this out and let me know how it
> works for you.
Just going through this at the moment and there's a step missing somewhere.
After importing the projects from the wip_helios branch into eclipse via File > Import > git etc...
The projects
- org.scala-ide.sdt.aspects
- org.scala-ide.sdt.core
- org.scala-ide.sdt.feature
- org.scala-ide.sdt.update-site
- org.scala-ide.sdt.weaving-feature
are failing to compile due to a missing dependency.
e.g.,
28/07/10 3:11:36 AM: Build errors for org.scala-ide.sdt.aspects; org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal on project org.scala-ide.sdt.aspects: Unable to get dependency information for org.scala-ide:org.scala-ide.scala.library:jar:2.8.0: Failed to process POM for org.scala-ide:org.scala-ide.scala.library:jar:2.8.0: Non-resolvable parent POM org.scala-ide:scala-toolchain-for-eclipse:2.8.0 for org.scala-ide:org.scala-ide.scala.library:2.8.0: Failed to resolve POM for org.scala-ide:scala-toolchain-for-eclipse:2.8.0 due to Missing:
----------
1) org.scala-ide:scala-toolchain-for-eclipse:pom:2.8.0
----------
1 required artifact is missing.
for artifact:
org.scala-ide:scala-toolchain-for-eclipse:pom:2.8.0
from the specified remote repositories:
helios (http://download.eclipse.org/releases/helios/, releases=false, snapshots=false),
jdt-weaving (http://download.eclipse.org/tools/ajdt/36/update, releases=false, snapshots=false),
scala-refactoring (http://download.scala-ide.org/scala-refactoring, releases=false, snapshots=false),
scalariform (http://download.scala-ide.org/scalariform, releases=false, snapshots=false),
scala-tools.release (http://scala-tools.org/repo-releases, releases=true, snapshots=false),
scala-tools.snapshot (http://scala-tools.org/repo-snapshots, releases=true, snapshots=true),
central (http://repo1.maven.org/maven2, releases=true, snapshots=false)
with regards,
--
Lachlan Deck
else you could try under eclipse with m2eclipse plugin (not tested as
I used shell and eclipse only for project org.scala-ide.sdt.core) :
open folder org.scala-ide.build
on 'toolchain-pom.xml' => run as > install
after
on 'pom.xml' (same dir) => run as > install
/davidB
-Matthew
that should build everything (from bundle for scala-library to
update-site for helios)
/davidB
On 25/07/2010, at 11:11 AM, Matthew Neeley wrote:
> I put some detailed instructions up on the wiki about setting things
> up for development with/for helios, now that I've got it working:
>
> https://www.assembla.com/wiki/show/scala-ide/Setup_with_Helios_and_Tycho
>
> Would be nice to have someone else try this out and let me know how it
> works for you.
I'm still having no luck in building all modules.
I can successfully build/install:
- org.scala-ide.scala.compiler
- org.scala-ide.scala.library
- org.scala-ide.sdt.aspects
- org.scala-ide.sdt.core
- org.scala-ide.sdt.feature
- org.scala-ide.sdt.weaving.feature
But when doing Run > Maven Install on
- org.scala-ide.sdt.update-site
I get the below stack trace. What am I missing?
Mac OS X 10.6.x, Eclipse Helios Java EE, etc.
Thanks.
with regards,
--
Lachlan Deck
[INFO] Scanning for projects...
[WARNING] No explicit target runtime environment configuration. Build is platform dependent.
[INFO] Resolving target platform for project MavenProject: org.scala-ide:org.scala-ide.sdt.update-site:1.0.0-SNAPSHOT @ /Users/ldeck/Developer/scala/scala-ide/org.scala-ide.sdt.update-site/pom.xml
log4j:WARN No appenders could be found for logger (org.apache.commons.httpclient.HttpClient).
log4j:WARN Please initialize the log4j system properly.
[INFO] Adding repository http://download.eclipse.org/releases/helios/
[INFO] Adding repository http://download.eclipse.org/releases/helios/
[INFO] Adding repository http://download.eclipse.org/tools/ajdt/36/update
[INFO] Adding repository http://download.eclipse.org/tools/ajdt/36/update
[INFO] Adding repository http://download.scala-ide.org/scala-refactoring
[INFO] Adding repository http://download.scala-ide.org/scala-refactoring
[INFO] Adding repository http://download.scala-ide.org/scalariform
[INFO] Adding repository http://download.scala-ide.org/scalariform
[INFO] Cannot complete the request. Generating details.
{org.osgi.framework.executionenvironment=OSGi/Minimum-1.0,OSGi/Minimum-1.1, osgi.ws=cocoa, osgi.arch=x86_64, osgi.os=macosx, org.eclipse.update.install.features=true, org.osgi.framework.system.packages=}
[Software being installed: org.scala-ide.sdt.update-site raw:1.0.0.'SNAPSHOT'/format(n[.n=0;[.n=0;[-S]]]):1.0.0-SNAPSHOT, Missing requirement: org.scala-ide.sdt.feature.feature.group 1.0.0.201008041244 requires 'org.scala-ide.sdt.core [1.0.0.201007301349]' but it could not be found, Cannot satisfy dependency: org.scala-ide.sdt.update-site raw:1.0.0.'SNAPSHOT'/format(n[.n=0;[.n=0;[-S]]]):1.0.0-SNAPSHOT depends on: org.scala-ide.sdt.feature.feature.group 0.0.0]
You need to build (install) other projects. see my previous email.
/davidB