google-home / smart-home-java

Apache License 2.0
92 stars 47 forks source link

Problem with intent Sync #14

Closed electrofun-smart closed 3 years ago

electrofun-smart commented 4 years ago

Hi,

I started to receive this error on Sync:

<stdout>: response = java.lang.ClassCastException: java.util.HashMap cannot be cast to com.google.protobuf.Message

As I have not changed the code, I'm suspecting some changes on grpc.

[i~smart-devices-mbfa/20200704t133437.427854056012528247].<stdout>: 2020-07-14 13:32:15 [Request99B2CD97] ERROR:: request sync failed: {}
io.grpc.StatusRuntimeException: INVALID_ARGUMENT: Request contains an invalid argument.
at io.grpc.stub.ClientCalls.toStatusRuntimeException(ClientCalls.java:235)
at io.grpc.stub.ClientCalls.getUnchecked(ClientCalls.java:216)
at io.grpc.stub.ClientCalls.blockingUnaryCall(ClientCalls.java:141)
at com.google.home.graph.v1.HomeGraphApiServiceGrpc$HomeGraphApiServiceBlockingStub.requestSyncDevices(HomeGraphApiServiceGrpc.java:406)
at com.google.actions.api.smarthome.SmartHomeApp.requestSync(SmartHomeApp.kt:109)
at com.example.SmartHomeCreateServlet.doPost(SmartHomeCreateServlet.java:80)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:790)
at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:848)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1772)
at com.google.apphosting.utils.servlet.JdbcMySqlConnectionCleanupFilter.doFilter(JdbcMySqlConnectionCleanupFilter.java:60)
at org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1759)
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:582)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143)
at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:524)
at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:226)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:134)
at com.google.apphosting.runtime.jetty9.ParseBlobUploadHandler.handle(ParseBlobUploadHandler.java:119)
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1182)
at com.google.apphosting.runtime.jetty9.AppEngineWebAppContext.doHandle(AppEngineWebAppContext.java:187)
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:512)
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:185)
at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1112)
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141)
at com.google.apphosting.runtime.jetty9.AppVersionHandlerMap.handle(AppVersionHandlerMap.java:293)
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:134)
at org.eclipse.jetty.server.Server.handle(Server.java:539)
at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:333)
at com.google.apphosting.runtime.jetty9.RpcConnection.handle(RpcConnection.java:213)
at com.google.apphosting.runtime.jetty9.RpcConnector.serviceRequest(RpcConnector.java:81)
at com.google.apphosting.runtime.jetty9.JettyServletEngineAdapter.serviceRequest(JettyServletEngineAdapter.java:134)
at com.google.apphosting.runtime.JavaRuntime$RequestRunnable.dispatchServletRequest(JavaRuntime.java:760)
at com.google.apphosting.runtime.JavaRuntime$RequestRunnable.dispatchRequest(JavaRuntime.java:723)
at com.google.apphosting.runtime.JavaRuntime$RequestRunnable.run(JavaRuntime.java:693)
at com.google.apphosting.runtime.JavaRuntime$NullSandboxRequestRunnable.run(JavaRuntime.java:885)
at com.google.apphosting.runtime.ThreadGroupPool$PoolEntry.run(ThreadGroupPool.java:270)
at java.lang.Thread.run(Thread.java:748)
Fleker commented 4 years ago

What devices do you have setup in the database?

electrofun-smart commented 4 years ago

I have a couple of devices like Air conditioner, TV, Set-up box, thermostats. But this started happening after I added a Pet Feeder device. Then I deleted all devices and added again (except Pet Feeder) and it is working fine now. When Pet Feeder was added the device was not functional on touch control, seems that is being created by front-end with some error or missing data, as you can see in the image below, the Pet Feeder icon has a small icon on top right corner like a configuration icon.

petFeeder

Fleker commented 4 years ago

Does it continue to be a problem when running with patch 503a0a013823d86b92098c15dd0ab9a228965ee6?

proppy commented 3 years ago

Closing as obsolete.