• AVR Freaks

Helpful ReplyHot!Harmony 3 window will not launch

Author
yp66
Starting Member
  • Total Posts : 23
  • Reward points : 0
  • Status: offline
2020/07/09 04:43:03 (permalink)
5 (1)

Harmony 3 window will not launch

I have run into a weird problem at one of the PCs I'm using.  It started with MPLAB X IDE 5.3x and as part of trying to address it, I completely uninstalled MPLAB X IDE and installed version 5.40 but the issue persists. In summary, Harmony Configurator 3 won't launch, instead, it throws an exception.  This is more or less the same setup I am using in various other machines and works fine - it also used to work fine in this machine but I can't point to anything that may have changed to cause this.
 
My system runs Windows 10 Pro, 64-bit, 16 GB RAM.
 
I start MPLABX IDE, select a project, and set it as my main and then I go to the Tools->Embedded Menu and select "MPLAB Harmony 3 Configurator".  As usual, a window pops up asking for the launch path and once I hit Launch.  In the past, I would get the Harmony window(s) to pop up but now nothing happens.
 
The notifications window shows an "Unexpected Exception" with the following info
Priority: SILENT Category: Error
Show and Report Problem
freemarker/cache/TemplateLoader
 
If I click on 'Show and Report', I get a window with the following info:
 
A java.lang.NoClassDefFoundError exception has occurred.
Click Show Details or see the messages.log file located in your C:\Users\yiann\AppData\Roaming\mplab_ide\dev\v5.40\var\log folder.
 
Further pressing the 'Show Details', yields the following trace:
 
java.lang.ClassNotFoundException: freemarker.cache.TemplateLoader
at java.net.URLClassLoader.findClass(URLClassLoader.java:382)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
Caused: java.lang.NoClassDefFoundError: freemarker/cache/TemplateLoader
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:348)
at com.microchip.mplab.modules.mh3.MHCLauncher.loadLauncherJar(MHCLauncher.java:389)
at com.microchip.mplab.modules.mh3.MHCLauncher.Launch(MHCLauncher.java:154)
at com.microchip.mplab.modules.mh3.MHCLauncher.PreLaunch(MHCLauncher.java:128)
at com.microchip.mplab.modules.mh3.MH3OpenActionPerformed.actionPerformed(MH3OpenActionPerformed.java:23)
at org.openide.awt.AlwaysEnabledAction$1.run(AlwaysEnabledAction.java:199)
at org.openide.util.actions.ActionInvoker$1.run(ActionInvoker.java:95)
at org.openide.util.actions.ActionInvoker.doPerformAction(ActionInvoker.java:116)
at org.openide.util.actions.ActionInvoker.invokeAction(ActionInvoker.java:99)
at org.openide.awt.AlwaysEnabledAction.actionPerformed(AlwaysEnabledAction.java:202)
at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2022)
at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2348)
at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:402)
at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:259)
at javax.swing.AbstractButton.doClick(AbstractButton.java:376)
at javax.swing.plaf.basic.BasicMenuItemUI.doClick(BasicMenuItemUI.java:842)
at javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(BasicMenuItemUI.java:886)
at java.awt.Component.processMouseEvent(Component.java:6539)
at javax.swing.JComponent.processMouseEvent(JComponent.java:3324)
at java.awt.Component.processEvent(Component.java:6304)
at java.awt.Container.processEvent(Container.java:2239)
at java.awt.Component.dispatchEventImpl(Component.java:4889)
at java.awt.Container.dispatchEventImpl(Container.java:2297)
at java.awt.Component.dispatchEvent(Component.java:4711)
at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4904)
at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4535)
at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4476)
at java.awt.Container.dispatchEventImpl(Container.java:2283)
at java.awt.Window.dispatchEventImpl(Window.java:2746)
at java.awt.Component.dispatchEvent(Component.java:4711)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:760)
at java.awt.EventQueue.access$500(EventQueue.java:97)
at java.awt.EventQueue$3.run(EventQueue.java:709)
at java.awt.EventQueue$3.run(EventQueue.java:703)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:84)
at java.awt.EventQueue$4.run(EventQueue.java:733)
at java.awt.EventQueue$4.run(EventQueue.java:731)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(ProtectionDomain.java:74)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:730)
at org.netbeans.core.TimableEventQueue.dispatchEvent(TimableEventQueue.java:159)
[catch] at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:205)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:116)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:105)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:101)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:93)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:82)
 
 
Any suggestions would be greatly appreciated.
 
#1
arpananand
Super Member
  • Total Posts : 498
  • Reward points : 0
  • Joined: 2009/11/18 04:35:42
  • Location: 0
  • Status: offline
Re: Harmony 3 window will not launch 2020/07/09 07:04:06 (permalink)
3.5 (2)
go to MPLABX menu "view-->Toolbars-->Reset Toolbars" and see if it solves the issue.
#2
Edson Brusque
Starting Member
  • Total Posts : 9
  • Reward points : 0
  • Joined: 2016/01/07 10:28:18
  • Location: 0
  • Status: offline
Re: Harmony 3 window will not launch 2020/07/09 07:43:30 (permalink)
5 (2)
Hello yp66!
 
Have you tried loading a different project?
 
Something similar occurred to me. After a power outage, Harmony 3 Configurator wouldn't open anymore. After spending hours uninstalling and reinstalling things, I opened a backup of my project and it worked. Go figure...
 
Best regards,
 
Brusque
#3
yp66
Starting Member
  • Total Posts : 23
  • Reward points : 0
  • Status: offline
Re: Harmony 3 window will not launch 2020/07/09 12:42:21 (permalink)
0
Thank you for the suggestion, unfortunately, that did not solve it as the exception still occurs.
#4
yp66
Starting Member
  • Total Posts : 23
  • Reward points : 0
  • Status: offline
Re: Harmony 3 window will not launch 2020/07/09 12:47:22 (permalink)
0
Edson Brusque
Hello yp66!
 
Have you tried loading a different project?
 
Something similar occurred to me. After a power outage, Harmony 3 Configurator wouldn't open anymore. After spending hours uninstalling and reinstalling things, I opened a backup of my project and it worked. Go figure...
 
Best regards,
 
Brusque





I tried loading various projects, some supporting harmony and some not supporting harmony and other than getting an error in the latter case, attempting to start harmony on a compatible project always leads to the exception.
 
I also tried creating a brand new harmony project but that didn't help either.

Very frustrating!
#5
arpananand
Super Member
  • Total Posts : 498
  • Reward points : 0
  • Joined: 2009/11/18 04:35:42
  • Location: 0
  • Status: offline
Re: Harmony 3 window will not launch 2020/07/09 14:27:34 (permalink)
0
can you attach your non-working Harmony project here?
#6
yp66
Starting Member
  • Total Posts : 23
  • Reward points : 0
  • Status: offline
Re: Harmony 3 window will not launch 2020/07/09 14:59:55 (permalink)
0
There is no specific project that doesn't work.  Any project that is based on Harmony exhibits the problem, i.e., Harmony won't launch after throwing an exception.

Having said that, I have attached a zip file with all the project-related files that exhibits the problem.  These are the files that are maintained in version control.
#7
sandeepm
New Member
  • Total Posts : 2
  • Reward points : 0
  • Joined: 2017/01/18 22:18:05
  • Location: 0
  • Status: offline
Re: Harmony 3 window will not launch 2020/07/09 21:59:25 (permalink) ☄ Helpfulby ullagaddi 2020/07/24 21:53:02
5 (2)
Hi
This error occurs when MHC is not able to load the required jar files from <framework path>/mhc folder.
Please check if <framework path>/mhc folder is checked out properly and have all required jar files. 
From your log it appears that MHC is not able to load freemarker jar file. 
 
Please verify and let us know if this works for you.
 
#8
yp66
Starting Member
  • Total Posts : 23
  • Reward points : 0
  • Status: offline
Re: Harmony 3 window will not launch 2020/07/10 03:04:15 (permalink)
0
sandeepm
Hi
This error occurs when MHC is not able to load the required jar files from <framework path>/mhc folder.
Please check if <framework path>/mhc folder is checked out properly and have all required jar files. 
From your log it appears that MHC is not able to load freemarker jar file. 
 
Please verify and let us know if this works for you.
 


Thank you for the pointer.  
 
I haven't much looked "under the hood" before, but I assumed you refer to the directory that the launcher asks you to select if the Tools->Options->Plugins/MPLAB harmony Configurator 3 setting is set to "Prompt at Launch".
 
The mhc directory contains no freemarker jar file.  I looked at another computer I use that does not exhibit this problem and in that installation, there is indeed a freemarker jar file, so this is the issue.
 
However, I never managed any of this by hand - I use the Harmony Content Manager (version 1.3.1) so not sure why the file wasn't there.  In any case, I used the content manager to delete the directory of mhc and then re-install it and the issue is now fixed.
 
Thank you.
#9
Jump to:
© 2020 APG vNext Commercial Version 4.5