我正在使用 IntelliJ IDEA Ultimate version 2018.1.1 for Linux
在尝试对由Intellij的OSGi捆绑包组成的maven项目上运行测试时,我不断遇到以下提到的错误
Error:osgi: [org.wso2.carbon.identity.oauth] In component <name not yet determined>, method framework.authentication.context.method.name.translator, cannot recognize the signature of the descriptor: ()V
Error:osgi: [org.wso2.carbon.identity.oauth] In component class org.wso2.carbon.identity.oauth2.internal.OAuth2ServiceComponent, reference framework.authentication.context.method.name.translator is dynamic but has no unbind method.
Error:osgi: [org.wso2.carbon.identity.oauth] No interface specified on framework.authentication.context.method.name.translator
以前有人遇到过这个问题吗?
我能够在这里找到类似的问题。
通过删除项目中的OSGi方面解决了这个问题,并且测试成功。
要删除 OSGi 方面,请转至项目结构 -> 项目设置 -> 方面;选择并删除 OSGi 方面。
如果重新导入所有项目,问题又回来了。要永久修复它,请从 intellij 中删除插件 Osmorc。 您可以通过转到Intellij ->首选项->插件来执行此操作 搜索Osmorc并取消选中复选框并重新启动Intellij
从IntelliJ IDEA版本2019.2开始,我无法在已安装的插件下找到Osmorc插件,相反,禁用OSGi插件对我有帮助。