Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IllegalStateException when trying to initialize UVLModel from dependency #1

Open
DarioRomano opened this issue Mar 29, 2022 · 0 comments

Comments

@DarioRomano
Copy link

DarioRomano commented Mar 29, 2022

When importing the standalone JAR, and trying to instantiate an UVLModel or Feature Object (e.g. UVLModel model = new UVLModel();), the following exception is thrown:

java.lang.ExceptionInInitializerError
	at at.jku.cps.uvlexport.util.ExportHelper.buildModel(ExportHelper.java:38)
	at at.jku.cps.uvlimport.util.ImportRunner.run(ImportRunner.java:946)
	at at.jku.cps.uvlimport.ui.ImportWizard$1.run(ImportWizard.java:105)
	at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:122)
Caused by: java.lang.IllegalStateException: Attempting to call unbound fn: #'clojure.core/refer
	at clojure.lang.Var$Unbound.throwArity(Var.java:45)
	at clojure.lang.AFn.invoke(AFn.java:32)
	at clojure.lang.Var.invoke(Var.java:384)
	at clojure.lang.RT.doInit(RT.java:485)
	at clojure.lang.RT.init(RT.java:467)
	at clojure.lang.Util.loadWithClass(Util.java:248)
	at de.neominik.uvl.ast.Feature.<clinit>(Unknown Source)
	... 4 more

I have tried compiling the source with different versions of clojure, have tried to only use the Java API and add the Clojure 1.11.0 jar from maven central, but the issue remains.
Unfortunately I don't have any knowledge about clojure, so I have no means to debug the issue, but maybe it's some sort of problem in ast.clj where the defb macro is defined?

Because classloaders were regularly mentioned when googling this issue, I want to mention that my environment is an eclipse plugin.
I've given the use case of featureIDE a test run with the class de.ovgu.featureide.fm.core.io.uvl. UVLFeatureModelFormat having no issue with creating an emtpy UVLModel instance. In my test there I simply ran it without any OSGI context though and the classloader was sun.misc.Launcher$AppClassLoader, while in my use case it was org.eclipse.osgi.internal.loader.EquinoxClassLoader.
I'm not sure if this may cause the issue, and if yes, how to resolve it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant