Report a bug of R2017a on MacBook Pro 2016, java.lang.reflect.InvocationTargetException
Mostrar comentarios más antiguos
Hi, I use MacBook Pro 2016 with Japanese Keyboard Layout.
I have installed MATLAB R2017a on macOS Sierra 10.12.4.


Following red error messages will appear in Command Window sometimes.
java.lang.reflect.InvocationTargetException
at sun.lwawt.macosx.LWCToolkit.invokeAndWait(LWCToolkit.java:572)
at sun.lwawt.macosx.CInputMethod.attributedSubstringFromRange(CInputMethod.java:586)
Caused by: java.lang.IllegalArgumentException: Invalid range
at javax.swing.text.JTextComponent$InputMethodRequestsHandler.getCommittedText(JTextComponent.java:4595)
at sun.awt.im.InputMethodContext.getCommittedText(InputMethodContext.java:302)
at sun.lwawt.macosx.CInputMethod$3.run(CInputMethod.java:598)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:302)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:738)
at java.awt.EventQueue.access$300(EventQueue.java:103)
at java.awt.EventQueue$3.run(EventQueue.java:699)
at java.awt.EventQueue$3.run(EventQueue.java:697)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:87)
at java.awt.EventQueue$4.run(EventQueue.java:713)
at java.awt.EventQueue$4.run(EventQueue.java:711)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:710)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:242)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:161)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:150)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:146)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:138)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:91)
There was a thread reported this bug. She gave a method to solve the problem, but I think she haven't solved the problem because I tried her method and it doesn't work well.
I think I find something useful for fixing the bug.
This bug was caused by Chinese Input Method. I installed Chinese Input Method into a MacBook Pro (2016) with Japanese Keyboard Layout. After running a script, if I clicked command window immediately under Chinese Input Method, the error messages will appear.
Temporary Solution:
After running a script, before clicking the command window,
change your input method to any other input methods if your current method is Chinese;
or click one of the other window blocks first, such as workspace.
I hope this bug can be fixed as soon as possible.
Thank you.
5 comentarios
Meixu Chen
el 29 de Jun. de 2017
I found the same bug and I also think it's the Chinese input method bug.
shilei su
el 22 de Jul. de 2017
the same to you
Donglei Zhang
el 18 de Sept. de 2017
the same to you
Jianqiu Wu
el 21 de Oct. de 2017
Same!
haidi zhu
el 16 de Dic. de 2017
the same to you
Respuestas (1)
Swathik Kurella Janardhan
el 19 de Abr. de 2017
1 voto
Thank you for reporting this error. I forwarded this information to my development team for further investigation. Starting MATLAB with admin privileges can resolve these errors.
1 comentario
Jun
el 24 de Abr. de 2017
Categorías
Más información sobre 基本设置 en Centro de ayuda y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!