Cannot load logic module to Open

Application Name: logic module Version Number: version 0.5.2

Question:

I am using OpenMRS 2.2.0. The following modules are included in the modules folder

  1. calculation 1.2
  2. htmlwidgets-1.90
  3. legacyui-1.3.2
  4. logic 0.5.2
  5. reporting 1.14.0
  6. serialization.xstream 0.2.12

However, once I run the openmrs application using jetty I get an error saying the logic module cannot be started. I manually tried to start the module but it failed. Following is the log relevant to adding the logic module

WARN - ModuleFactory.stopModule(1235) |2017-10-03 11:42:03,094| Unable to call module’s Activator.shutdown() method org.openmrs.module.ModuleException: Unable to load/find moduleActivator: ‘org.openmrs.module.logic.LogicModuleActivator’ Module: Logic Module at org.openmrs.module.Module.getModuleActivator(Module.java:174) at org.openmrs.module.ModuleFactory.stopModule(ModuleFactory.java:1230) at org.openmrs.module.ModuleFactory.startModuleInternal(ModuleFactory.java:840) at org.openmrs.api.context.Daemon$1.run(Daemon.java:74) Caused by: java.lang.NoClassDefFoundError: org/openmrs/module/Activator at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:763) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) at java.net.URLClassLoader.defineClass(URLClassLoader.java:467) at java.net.URLClassLoader.access$100(URLClassLoader.java:73) at java.net.URLClassLoader$1.run(URLClassLoader.java:368) at java.net.URLClassLoader$1.run(URLClassLoader.java:362) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:361) at org.openmrs.module.ModuleClassLoader.loadClass(ModuleClassLoader.java:632) at org.openmrs.module.ModuleClassLoader.loadClass(ModuleClassLoader.java:551) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at org.openmrs.module.Module.getModuleActivator(Module.java:155) … 3 more Caused by: java.lang.ClassNotFoundException: org.openmrs.module.Activator at org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass(SelfFirstStrategy.java:50) at org.codehaus.plexus.classworlds.realm.ClassRealm.unsynchronizedLoadClass(ClassRealm.java:271) at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:247) at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:239) at org.eclipse.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:470) at org.eclipse.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:421) at org.openmrs.module.ModuleClassLoader.loadClass(ModuleClassLoader.java:558) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) … 16 more WARN - Module.expandExtensionNames(575) |2017-10-03 11:42:03,116| logic: Unable to find class definition for extension: org.openmrs.admin.list java.lang.NoClassDefFoundError: org/openmrs/module/web/extension/AdministrationSectionExt at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:763) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) at java.net.URLClassLoader.defineClass(URLClassLoader.java:467) at java.net.URLClassLoader.access$100(URLClassLoader.java:73) at java.net.URLClassLoader$1.run(URLClassLoader.java:368) at java.net.URLClassLoader$1.run(URLClassLoader.java:362) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:361) at org.openmrs.module.ModuleClassLoader.loadClass(ModuleClassLoader.java:632) at org.openmrs.module.ModuleClassLoader.loadClass(ModuleClassLoader.java:551) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at org.openmrs.module.Module.expandExtensionNames(Module.java:567) at org.openmrs.module.Module.getExtensions(Module.java:494) at org.openmrs.module.ModuleFactory.stopModule(ModuleFactory.java:1248) at org.openmrs.module.ModuleFactory.startModuleInternal(ModuleFactory.java:840) at org.openmrs.api.context.Daemon$1.run(Daemon.java:74) Caused by: java.lang.ClassNotFoundException: org.openmrs.module.web.extension.AdministrationSectionExt at org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass(SelfFirstStrategy.java:50) at org.codehaus.plexus.classworlds.realm.ClassRealm.unsynchronizedLoadClass(ClassRealm.java:271) at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:247) at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:239) at org.eclipse.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:470) at org.eclipse.jetty.webapp.WebAppClassLoader.loadClass(WebAppClassLoader.java:421) at org.openmrs.module.ModuleClassLoader.loadClass(ModuleClassLoader.java:558) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) … 17 more WARN - OpenmrsUtil.deleteDirectory(922) |2017-10-03 11:42:03,135| …could not remove directory: C:\Users\Kalana\Application Data\OpenMRS.openmrs-lib-cache\logic\lib WARN - OpenmrsUtil.deleteDirectory(922) |2017-10-03 11:42:03,161| …could not remove directory: C:\Users\Kalana\Application Data\OpenMRS.openmrs-lib-cache\logic

How can I fix this?

Can you just delete that module?

I am using patientflags module which require logic module to work, if that is deleted then we won’t use it, check here, maybe we need to make a new release that do not need logic module cc @valvijo