-
-
Notifications
You must be signed in to change notification settings - Fork 565
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
NPE in DefaultPluginManager.stopPlugin #99
Comments
I will take a look. Pull Request is welcome. |
You are right, the value of
So, I believe that something is strange in your code. |
|
By adding a small check on dependencyResolver not being null or else skipping the line where it trigger the NPE fixed the issue for me. It happens for plugins without dependencies in most projects both with version 0.13 and the snapshot version of 0.14. Basically this confirms the finding xiyoufang mentioned in his/her comment. This bug even occurs by using the sample code only in the sample projects. I am not sure if you have this fixed yet. If it has been fixed ignore this post all together. |
@heyokajan Thanks for comment. I will check if the fix is already pushed on github and if it's not then I will push the fix. |
@xiyoufang, @heyokajan Please try the fix and confirm that the issue is resolved. |
Is there a workaround for this until the next release? |
I don't have any feedback from people if this issue is resolved or not on trunk. I updated the SNAPSHOT version. |
I will test based on the SNAPSHOT, thanks! |
Confirmed, 0.14.0-SNAPSHOT fixes this issue for me. |
I can stay on the snapshot for now, but definitely would love to go back to release once you feel 0.14.0 is ready. |
@justinnichols Thank you for confirmation |
If plugins directory is null, load and start a Plugin, finally stop plugin :
Exception in thread "main" java.lang.NullPointerException at ro.fortsoft.pf4j.DefaultPluginManager.stopPlugin(DefaultPluginManager.java:340) at ro.fortsoft.pf4j.DefaultPluginManager.stopPlugin(DefaultPluginManager.java:317)
If plugins directory is not null, not have this Exception.
pluginsDirectory is null , dependencyResolver can't instanced
The text was updated successfully, but these errors were encountered: