aristotll/RubyDocAdder

RubyMine compatibility

vladimir-koshelev opened this issue · 2 comments

I'm a software developer in RubyMine. Your plugin has a compatibly problem with upcoming version of RubyMine. I find out that the problem caused by me/aristotll/NewRubyHelpUtil.groovy. This file seems to be decompiled from RubyHelpUtil.class. Using decompiled files is bad idea because:

  1. it's illegal;
  2. it breaks binary compatibility.

It looks like you need to re-implement only one or two methods from RubyHelpUtil there are no reason to copy all methods to your project.
Could you please remove me/aristotll/NewRubyHelpUtil.groovy and replace it by an appropriate implementation?

Thanks for reporting, because of RubyMine doesn't have any open api (like PhpStorm or PyCharm do ), so I have to use some of api from the origin RubyHelpUtil ( for API references).

My first implementation is kind lazy, I just copied the origin implementations and modified something, which is inappropriate. I will remove the file.
I think a better implementation is needed.

Also I will use Gradle building system for better CI and testing experience.

Hi, this is a great plugin. Thanks for the effort!.
Unfortunately it seems to have stopped working with the latest Rubymine release.
If it helps, here is the error I'm getting:

No signature of method: static org.jetbrains.plugins.ruby.ruby.lang.documentation.RubyHelpUtil.getInferredMethodType() is applicable for argument types: (org.jetbrains.plugins.ruby.ruby.lang.psi.impl.controlStructures.methods.RMethodImpl) values: [Ruby:Method]

This is the full stack trace:

No signature of method: static org.jetbrains.plugins.ruby.ruby.lang.documentation.RubyHelpUtil.getInferredMethodType() is applicable for argument types: (org.jetbrains.plugins.ruby.ruby.lang.psi.impl.controlStructures.methods.RMethodImpl) values: [Ruby:Method]
groovy.lang.MissingMethodException: No signature of method: static org.jetbrains.plugins.ruby.ruby.lang.documentation.RubyHelpUtil.getInferredMethodType() is applicable for argument types: (org.jetbrains.plugins.ruby.ruby.lang.psi.impl.controlStructures.methods.RMethodImpl) values: [Ruby:Method]
	at groovy.lang.MetaClassImpl.invokeStaticMissingMethod(MetaClassImpl.java:1501)
	at groovy.lang.MetaClassImpl.invokeStaticMethod(MetaClassImpl.java:1487)
	at org.codehaus.groovy.runtime.callsite.StaticMetaClassSite.call(StaticMetaClassSite.java:53)
	at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:48)
	at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:113)
	at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:125)
	at me.aristotll.NewRubyHelpUtil.getInferredMethodType(NewRubyHelpUtil.groovy:70)
	at me.aristotll.NewRubyHelpUtil.appendTypeInfo(NewRubyHelpUtil.groovy:158)
	at me.aristotll.NewRubyHelpUtil.createDocForSymbol(NewRubyHelpUtil.groovy:115)
	at me.aristotll.NewRubyHelpUtil.getDocOfElementInner(NewRubyHelpUtil.groovy:51)
	at me.aristotll.NewRubyHelpUtil.getDocOfElement(NewRubyHelpUtil.groovy:37)
	at me.aristotll.RDocAdderAction.actionPerformed(RDocAdderAction.groovy:43)
	at com.intellij.openapi.actionSystem.ex.ActionUtil$1.run(ActionUtil.java:220)
	at com.intellij.openapi.actionSystem.ex.ActionUtil.performActionDumbAware(ActionUtil.java:237)
	at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher$1.performAction(IdeKeyEventDispatcher.java:576)
	at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.a(IdeKeyEventDispatcher.java:625)
	at com.intellij.openapi.application.TransactionGuardImpl.performUserActivity(TransactionGuardImpl.java:195)
	at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.processAction(IdeKeyEventDispatcher.java:624)
	at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.b(IdeKeyEventDispatcher.java:479)
	at com.intellij.openapi.keymap.impl.IdeKeyEventDispatcher.dispatchKeyEvent(IdeKeyEventDispatcher.java:213)
	at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:738)
	at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:434)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:201)
	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)