java NullPointerException with R2017b when closing simulink project

2 views (last 30 days)
I need help tracking down the source of a java error that appears in R2017b, but not in R2016b.
Closing a Simulink project when a Model is open generates errors like this:
Exception in thread "Simulink Project Thread: 48" java.lang.NullPointerException
at com.mathworks.toolbox.slproject.extensions.dependency.problems.managers.ProblemManagerBase.updateProblems(ProblemManagerBase.java:130)
at com.mathworks.toolbox.slproject.extensions.dependency.problems.managers.ProblemManagerBase.access$500(ProblemManagerBase.java:41)
at com.mathworks.toolbox.slproject.extensions.dependency.problems.managers.ProblemManagerBase$UpdateRunnable.run(ProblemManagerBase.java:242)
at com.mathworks.toolbox.shared.computils.threads.CoalescingExecutor$1.run(CoalescingExecutor.java:62)
at com.mathworks.toolbox.shared.computils.threads.WrappingExecutorService$WrappedRunnable.run(WrappingExecutorService.java:74)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
My project architecture is fairly complex: I have several Simulink projects which all have a reference to a common Simulink project. Besides a block library, the common project modifies my simulink environment by:
  • adding custom menus on the model editor window
  • selecting a set of model advisor options
  • storing a configuration set in a data dictionary, that all models reference
I've tried eliminating components of the referenced project (the error does not occur for projects which don't reference this project). But I can't narrow it down.
  2 Comments
Sharan Paramasivam Murugesan
1. It appears to be an unknown issue. Without reproduction files, it is hard to identify the root cause of this issue. Have you tried reproducing this with a sample parent project and a referenced project? This should help you narrow down the particular action that is causing this exception.
2. There should be a java log (java.log.xxxx) created when there is a java exception. It would be really useful if you could retrieve the java log file and attach it here. For info on how to retrieve this file, refer to https://www.mathworks.com/matlabcentral/answers/100816-how-do-i-locate-the-crash-dump-files-generated-by-matlab
3. If you are using GitHub for source control of these projects, can you try "https://github.com" as the remote address instead of "git@github.com"
John Harris
John Harris on 22 Mar 2018
Edited: John Harris on 22 Mar 2018
Thanks, Sharan!
Unfortunately, I'm striking out on all these suggestions. Yes, I've tried narrowing it down to a relatively simple architecture, but that did not bring me to a more specific scenario. I may try to generate a smaller example that I could send in as a working test case.
There are no java.log.xxxx files on the disk, and I caused the error then used the extractCrashLogs function, but the only extracted logs were matlab_crash_dump logs from days ago.
And lastly, we're not using any form of git - just TFS.
I'll report again if the problem persists in R2018a...Thanks!

Sign in to comment.

Answers (0)

Categories

Find more on Simulink Functions in Help Center and File Exchange

Products

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!