插件 Google Login "' com/google/gct/login/CredentialedUserRoster.setActiveUser 的 userEmail' 中的 Android Studio 异常不能为空”

标签 android intellij-idea google-signin

使用 Android Studio 1.2.1.1。单击登录图标(右上角)时出现此异常。

Argument for @NotNull parameter 'userEmail' of com/google/gct/login/CredentialedUserRoster.setActiveUser must not be null
java.lang.IllegalArgumentException: Argument for @NotNull parameter 'userEmail' of com/google/gct/login/CredentialedUserRoster.setActiveUser must not be null
    at com.google.gct.login.CredentialedUserRoster.setActiveUser(CredentialedUserRoster.java)
    at com.google.gct.login.GoogleLogin.setActiveUser(GoogleLogin.java:454)
    at com.google.gct.login.ui.GoogleLoginUsersPanel.valueChanged(GoogleLoginUsersPanel.java:232)
    at javax.swing.JList.fireSelectionValueChanged(JList.java:1798)
    at javax.swing.JList$ListSelectionHandler.valueChanged(JList.java:1812)
    at javax.swing.DefaultListSelectionModel.fireValueChanged(DefaultListSelectionModel.java:184)
    at javax.swing.DefaultListSelectionModel.fireValueChanged(DefaultListSelectionModel.java:154)
    at javax.swing.DefaultListSelectionModel.setValueIsAdjusting(DefaultListSelectionModel.java:685)
    at javax.swing.JList.setValueIsAdjusting(JList.java:2142)
    at javax.swing.plaf.basic.BasicListUI$Handler.mouseReleased(BasicListUI.java:2796)
    at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:290)
    at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:289)
    at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:289)
    at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:289)
    at java.awt.Component.processMouseEvent(Component.java:6516)
    at javax.swing.JComponent.processMouseEvent(JComponent.java:3321)
    at java.awt.Component.processEvent(Component.java:6281)
    at java.awt.Container.processEvent(Container.java:2229)
    at java.awt.Component.dispatchEventImpl(Component.java:4872)
    at java.awt.Container.dispatchEventImpl(Container.java:2287)
    at java.awt.Component.dispatchEvent(Component.java:4698)
    at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4832)
    at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4492)
    at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4422)
    at java.awt.Container.dispatchEventImpl(Container.java:2273)
    at java.awt.Window.dispatchEventImpl(Window.java:2719)
    at java.awt.Component.dispatchEvent(Component.java:4698)
    at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:747)
    at java.awt.EventQueue.access$300(EventQueue.java:103)
    at java.awt.EventQueue$3.run(EventQueue.java:706)
    at java.awt.EventQueue$3.run(EventQueue.java:704)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
    at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:87)
    at java.awt.EventQueue$4.run(EventQueue.java:720)
    at java.awt.EventQueue$4.run(EventQueue.java:718)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:717)
    at com.intellij.ide.IdeEventQueue.defaultDispatchEvent(IdeEventQueue.java:734)
    at com.intellij.ide.IdeEventQueue._dispatchEvent(IdeEventQueue.java:565)
    at com.intellij.ide.IdeEventQueue.dispatchEvent(IdeEventQueue.java:382)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:242)
    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:161)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:150)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:146)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:138)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:91)

我已尝试通过执行以下操作(未成功)来修复它:

  • 重新启动我的电脑。
  • 重新安装 Android Studio
  • 遵循 Google sign in issue 中建议的解决方案.我已撤销对与 Android、Android Studio 和 SDK 相关的所有内容的访问权限。
  • 禁用和重新启用“Google 登录”插件

如何解决这个问题?或者我应该在哪里寻找这个缺失的“userEmail”参数?

当我尝试将我的模块部署到 App Engine 时,同样的问题出现在不同的异常中:

Exception loading projects for null: 400 Bad Request
{
  "error" : "invalid_grant",
  "error_description" : "Token has been revoked."
}
com.google.api.client.auth.oauth2.TokenResponseException: 400 Bad Request
{
  "error" : "invalid_grant",
  "error_description" : "Token has been revoked."
}
at com.google.api.client.auth.oauth2.TokenResponseException.from(TokenResponseException.java:105)
at com.google.api.client.auth.oauth2.TokenRequest.executeUnparsed(TokenRequest.java:287)
at com.google.api.client.auth.oauth2.TokenRequest.execute(TokenRequest.java:307)
at com.google.api.client.auth.oauth2.Credential.executeRefreshToken(Credential.java:570)
at com.google.api.client.googleapis.auth.oauth2.GoogleCredential.executeRefreshToken(GoogleCredential.java:247)
at com.google.api.client.auth.oauth2.Credential.refreshToken(Credential.java:489)
at com.google.api.client.auth.oauth2.Credential.intercept(Credential.java:217)
at com.google.api.client.http.HttpRequest.execute(HttpRequest.java:859)
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:410)
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.executeUnparsed(AbstractGoogleClientRequest.java:343)
at com.google.api.client.googleapis.services.AbstractGoogleClientRequest.execute(AbstractGoogleClientRequest.java:460)
at com.google.gct.idea.elysium.GoogleUserModelItem.loadUserProjects(GoogleUserModelItem.java:130)
at com.google.gct.idea.elysium.GoogleUserModelItem.access$100(GoogleUserModelItem.java:41)
at com.google.gct.idea.elysium.GoogleUserModelItem$1.run(GoogleUserModelItem.java:95)
at com.intellij.openapi.application.impl.ApplicationImpl$8.run(ApplicationImpl.java:405)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask.run(FutureTask.java:262)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)
at org.jetbrains.ide.PooledThreadExecutor$1$1.run(PooledThreadExecutor.java:56)

请注意,Google sign in issue 中建议的解决方案并未解决此问题。 .该解决方案建议转到 https://security.google.com/settings/security/permissions?pli=1并撤销应用程序访问权限。我不允许与 Android、Android Studio 和 SDK 相关的访问。在我的 PC 上运行的其他应用程序(如 Chrome)可以毫无问题地登录。

最佳答案

此问题是 Android Studio 中的错误。当我升级到最新的“金丝雀 channel ”版本时它消失了。参见 http://tools.android.com/recent/androidstudio12beta3available看看什么是固定的。仅供引用,适用于我的版本是:

Android Studio AI-141.1962279
Build #AI-141.1962279, built on May 27, 2015
JRE: 1.7.0_79-b15 amd64
JVM: Java HotSpot(TM) 64-Bit Server VM by Oracle Corporation

关于插件 Google Login "' com/google/gct/login/CredentialedUserRoster.setActiveUser 的 userEmail' 中的 Android Studio 异常不能为空”,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/30410895/

相关文章:

android - 在 Android 的 Fragment 中显示数据

java - 在现有字段前加上 m

intellij-idea - Pub Serve 和 IntelliJ 社区版

react-native - Expo 中的 Google 登录按钮品牌样式

ios - AppDelegate 中的 Google 和 Facebook 登录 url 处理程序?

java - SharedPreference不保存以前的数据

android:orientation ="vertical"不适用于 TabWidget

c# - 将位图保存到文件 - Xamarin、Monodroid

java - IntelliJ 运行带有 @Ignore 注释的 Kotlin 测试

google-cloud-platform - 错误: 10: Developer console is not set up correctly (Not Using Firebase) (One Tap sign-up)