gpt4 book ai didi

java - 生成 Google Cloud 端点客户端库时获取 MalformedJsonException

转载 作者:太空宇宙 更新时间:2023-11-04 15:00:33 24 4
gpt4 key购买 nike

在为 Google 应用引擎生成云端点客户端库时,我在 Eclipse 中遇到以下错误。我尝试重新启动 eclipse,清理我的项目。什么都不起作用。有什么建议如何解决吗?

java.lang.reflect.InvocationTargetException
at com.google.gdt.eclipse.appengine.swarm.wizards.GenerateSwarmApiAction$1.run(GenerateSwarmApiAction.java:82)
at org.eclipse.jface.operation.ModalContext$ModalContextThread.run(ModalContext.java:121)
Caused by: com.google.gson.JsonSyntaxException: com.google.gson.stream.MalformedJsonException: Expected ':' at line 711 column 10
at com.google.gson.Gson.fromJson(Gson.java:769)
at com.google.gson.Gson.fromJson(Gson.java:721)
at com.google.gson.Gson.fromJson(Gson.java:670)
at com.google.gson.Gson.fromJson(Gson.java:642)
at com.google.gdt.eclipse.managedapis.ManagedApiUtils.findAndReadDependencyFile(ManagedApiUtils.java:185)
at com.google.gdt.eclipse.managedapis.ManagedApiUtils.findAndReadDependencyFile(ManagedApiUtils.java:179)
at com.google.gdt.eclipse.managedapis.ManagedApiUtils.findAndReadDependencyFile(ManagedApiUtils.java:179)
at com.google.gdt.eclipse.appengine.swarm.wizards.helpers.SwarmServiceCreator.copyToConnectedAndroidProject(SwarmServiceCreator.java:148)
at com.google.gdt.eclipse.appengine.swarm.wizards.helpers.SwarmServiceCreator.create(SwarmServiceCreator.java:453)
at com.google.gdt.eclipse.appengine.swarm.wizards.GenerateSwarmApiAction$1.run(GenerateSwarmApiAction.java:80)
... 1 more
Caused by: com.google.gson.stream.MalformedJsonException: Expected ':' at line 711 column 10
at com.google.gson.stream.JsonReader.syntaxError(JsonReader.java:1298)
at com.google.gson.stream.JsonReader.objectValue(JsonReader.java:762)
at com.google.gson.stream.JsonReader.peek(JsonReader.java:380)
at com.google.gson.stream.JsonReader.advance(JsonReader.java:426)
at com.google.gson.stream.JsonReader.skipValue(JsonReader.java:637)
at com.google.gson.internal.bind.ReflectiveTypeAdapterFactory$Adapter.read(ReflectiveTypeAdapterFactory.java:174)
at com.google.gson.Gson.fromJson(Gson.java:755)
... 10 more

最佳答案

删除 war/WEB-INF/文件夹的这 3 个自动生成的文件后,通过清理 Google 应用引擎项目解决了错误:*-rest.discovery、*-rpc.discovery、*.api

关于java - 生成 Google Cloud 端点客户端库时获取 MalformedJsonException,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22615359/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com