Open sturman opened 6 years ago
Hi,
Thanks for reporting this bug. Will check it and provide a patch ASAP.
Regards
Just to chime in, I'm getting the exact same issue (the exception thrown above).
PhpStorm 2018.1.6 Build #PS-181.5281.35, built on June 14, 2018 JRE: 1.8.0_152-release-1136-b39 amd64 JVM: OpenJDK 64-Bit Server VM by JetBrains s.r.o Linux 4.15.0-29-generic
hi all,
what is your current configuration? 0 server, 1 or more than 1?
I had 2 servers before upgrading the plugin, now when I open it I see none. The add new server dialog loads but doesn't save the details so remains empty. (Hope this helps)
I made a quick patch (Jetbrains may have changed the way to load the tree to make it more asynchronous). Please try this SNAPSHOT version and tell me whether it works on you IDE
Unfortunately that hasn't fixed it for me.
I downloaded the zip, installed it manually in plugins (which updated it), restarted phpstorm, same error. I tried to add a server didn't save. I removed the plugin completely, and added 0.12.1 and it came up with the same error.
Just realised I might not have been said earlier, I updated the mongo plugin, but I'm still on phpstorm 2018.1
https://www.dropbox.com/s/nc34t3i7u41dyl3/mongo-result1.png?dl=0 https://www.dropbox.com/s/1atuvkzridg3kfb/mongo-result2.png?dl=0
Did you set a label for each configuration you set? If not, it might be the cause of the bug.
I pushed a new snapshot (same link than above). Now the Label of the configuration is mandatory to prevent this bug.
If you want to repair your configuration, open the file .idea/mongoSettings.xml
and add under <ServerConfiguration>
the line <option name="label" value="MyLabel" />
if needed.
Ahh! Fantastic, that was it. Checked that file and there was one without a label, added the label, restarted and it works perfectly! (I find this plugin ever so useful, thanks!)
Same bug here on High Sierra 10.13.6 (17G65). Tried to manually replace the plugin with snapshot above - did not help. Also, I do not have mongoSettings.xml
in ~/Library/Preferences/IdeaVersion.
@rdev02 you can find mongoSettings.xml
in .idea
folder in your project directory, not in ~/Library/Preferences/IdeaVersion
found it. I simply removed it and after I restarted my IDE it started working. Thanks!
Hello
I am still seeing this NPE stack in DataGrip 2018.2 I have tried the main release version as well as the snapshot version. My server is hosted on mLab.com and the version there is 3.6.6. I did not leave the label blank.
edit installing IntelliJ to test. The program is essentially the same but better safe than sorry.
edit again IntelliJ with the snapshot works. But would be super cool to be able to use this plugin through DataGrip. I can make a formal feature request if that is possible.
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="MongoConfiguration">
<option name="serverConfigurations">
<list>
<ServerConfiguration>
<option name="label" value="demo服务器" />
<option name="serverUrls">
<list>
<option value="172.16.20.xx:27017" />
</list>
</option>
<option name="sshTunnelingConfiguration">
<SshTunnelingConfiguration />
</option>
</ServerConfiguration>
</list>
</option>
</component>
</project>
Exception in Mongo Plugin happens on IDEA start
Environment:
Steps:
Actual result: NullPointerException happens on IDE start. Stacktrace:
Expected: Plugin start without fatal error and without any exceptions