Closed GoogleCodeExporter closed 9 years ago
I deleted manually all the references to the previous version 0.30.0 and
restarted Eclipse. I managed to open a .clj file. But after restarting I got
the same error.
Original comment by i...@akvo.org
on 4 Dec 2014 at 5:55
May the problem be related to the fact that editors are automatically reopened
when eclipse restarts ? Do things improve if you close all editors before
restarting eclipse (and then opening an editor after eclipse has had the time
to finish bootstrapping)? Or does it seem not to be correlated?
Still trying to figure out why the error pops up frequently but not everytime...
Original comment by laurent....@gmail.com
on 4 Dec 2014 at 6:04
Hi,
Well, if I close all editors and restart Eclipse, I'm able to open the Clojure
editor. So it might be related.
Steps:
* Close all editors
* Restart Eclipse
* Open a .clj file via "Open Resource" - OK
* Leave that editor open
* Restart Eclipse
* The error -> Plug-in "ccw.core" was unable to instantiate class
"ccw.editors.clojure.ClojureEditor". - KO
Original comment by i...@akvo.org
on 4 Dec 2014 at 6:11
Ok, here's the idea: ccw.events does a call to require lazily a namespace,
inside a delay in line 12.
My guess is that this is sometimes triggered when the namespace is reachable
via the classloaders, and sometimes not, depending on how it is triggered.
I've changed ccw.events so that the namespace loading is not deferred. Can your
replace your version of events.clj with the attached file to see if this fixes
the problem? (you'll need to restart eclipse).
Original comment by laurent....@gmail.com
on 4 Dec 2014 at 6:13
Attachments:
I'm protecting the call to (require '[ccw.core.e4.model]) since it will only be
available for eclipse 4.x (dropping support of eclipse 3.x would remove the
need to do these kinds of tweaks).
Original comment by laurent....@gmail.com
on 4 Dec 2014 at 6:15
The change in events.clj seems to solve the issue. I left a couple of Clojure
editor tabs opened and I'm able to restart without getting the exception.
Many thanks for the support.
Original comment by i...@akvo.org
on 4 Dec 2014 at 6:19
Yes, the guess was spot on. Good news, I also was able to reproduce the issue
locally, and then the fix, and finely understand the issue. It so happens that
it is somewhat illegal to do what I did, e.g. use (require) beyond compile time
(it was wrapped in a delay). That's why the namespace ccw.events not being
found, the compiler tried to find a ccw.events class, unsuccessfully of course.
Many thanks for the accurate precision you gave, your patience and dedicated
time!
Original comment by laurent....@gmail.com
on 4 Dec 2014 at 10:20
Original comment by laurent....@gmail.com
on 4 Dec 2014 at 10:36
Original issue reported on code.google.com by
i...@akvo.org
on 4 Dec 2014 at 5:51Attachments: