Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

report state need a Integer value type #46

Closed
kingskylar opened this issue Feb 24, 2020 · 4 comments
Closed

report state need a Integer value type #46

kingskylar opened this issue Feb 24, 2020 · 4 comments

Comments

@kingskylar
Copy link

kingskylar commented Feb 24, 2020

The spectrumRgb report state need a integer value,but the Value build only has a number type and will turn to Double type.
https://developers.google.com/assistant/smarthome/traits/colorsetting#device-states

below is the main error log info:

`
value {
struct_value {
fields {
key: "color"
value {
struct_value {
fields {
key: "spectrumRgb"
value {
number_value: 9109504.0
}
}
}
}
}
}
}

org.springframework.web.util.NestedServletException: Request processing failed; nested exception is io.grpc.StatusRuntimeException: INVALID_ARGUMENT: Request contains an invalid argument.
at org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:982) ~[spring-webmvc-5.0.7.RELEASE.jar:5.0.7.RELEASE]
Caused by: io.grpc.StatusRuntimeException: INVALID_ARGUMENT: Request contains an invalid argument.
at io.grpc.stub.ClientCalls.toStatusRuntimeException(ClientCalls.java:233) ~[grpc-stub-1.15.1.jar:1.15.1]
at io.grpc.stub.ClientCalls.getUnchecked(ClientCalls.java:214) ~[grpc-stub-1.15.1.jar:1.15.1]
at io.grpc.stub.ClientCalls.blockingUnaryCall(ClientCalls.java:139) ~[grpc-stub-1.15.1.jar:1.15.1]
at com.google.home.graph.v1.HomeGraphApiServiceGrpc$HomeGraphApiServiceBlockingStub.reportStateAndNotification(HomeGraphApiServiceGrpc.java:425) ~[actions-on-google-1.8.0.jar:?]
at com.google.actions.api.smarthome.SmartHomeApp.reportState(SmartHomeApp.kt:132) ~[actions-on-google-1.8.0.jar:?]`

@Fleker
Copy link
Member

Fleker commented Mar 3, 2020

Can you update the key you're sending to be "spectrumRGB" as capitalized?

@kingskylar
Copy link
Author

The guide noted reporting state use "spectrumRgb",i will test use "spectrumRGB".
0E4FD599-BB06-4173-B4DF-7B182DFC998F

@Fleker
Copy link
Member

Fleker commented Mar 5, 2020

There is also a note a bit higher on the page.

image

@kingskylar
Copy link
Author

yes,you are right,thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants