Google smart home test suit fail - google-smart-home

when I tested "Query after xxxxx" case in smart home test suite, I got below error.
Actually, I already implemented Report state and Query.
I don't know why it is and what it's means.
//State 'online' is in queried states but not in reported states: expected false to be true//
enter image description here

When you run your action in the Test Suite it needs to report state to the Home Graph after every execution. Those states are then compared to the results returned from the QUERY intent. The attached image suggests that online:true is missing from the report state response. Please visit Report State Documentation for more information.

Related

homegraph.devices.reportStateAndNotification does not trigger google home app to update the state

I am playing around with the nodejs packages googleapis and actions-on-google.
I am stuck reporting the state, which changed without googles note, so that google keeps in sync!
Sadly this does not work. I am using this method: homegraph.devices.reportStateAndNotification().
described here: https://developers.google.com/assistant/smarthome/reference/rest/v1/devices/reportStateAndNotification
The call is fine, I am getting a correct answer and everythign seems fine. Except that my google home app does not update the state.
I have another thirdparty-device which has a button to toggle the state, this works fine. So the app has no bug, it must be on my side..
I am wondering if this "feature" does only work in production and not during the test phase?
test suite says its fine too:
Google Home Assistant UI depends on various factors for the state, including query and report state responses. One should make sure that they are invoking the query correctly.
You should also try to verify that your report state implementation is correct by making use of tools provided by Google like Home Graph Viewer (make sure states are updated in the homegraph) and Test Suite (to see if both query and report state implementation pass).
I don't think the status shown by the Google Home app coming from what you have reported to HomeGraph by using the reportStateAndNotification. The QUERY intent must be invoked from Google Home app in order to see the current status of your device.
Ref
When Google Assistant wants to take an action that requires understanding the current state of a device, it can simply look up the state information in the Home Graph instead of issuing a QUERY intent
As an above statement, I think the status that you reported to HomeGraph is beneficial only for the Google Assistant not for your Google Home app.
We found it, see this issue-tracker too:
https://issuetracker.google.com/issues/238499831#comment16
Google Home App does ONLY use the home-graph for devices that are associated with your home "directly".
It is not enough to just have them in the bottom of your app in the section "other devices connected with your account" ..
You NEED to add them properly..

The given data was invalid React and Commerce JS

I am currently following a tutorial on how to build a web commerce website (His GitHub: https://github.com/adrianhajdin/project_e_commerce) and I am getting this error when submitting data:
and looking at the response I see this:
I haven't got a clue what this means and been stuck for at least 3 hours trying to fix this.
The stripe payment is actually logging it as a successful logs.
But within Commerce JS it detects the errors:
Check the information of the orderData object, something must have been misspelled, as suggested by the error "The given data was invalid".
In my case the problem was that the instructor indicated to access the property of the shippingObject as "address1", but I had that property defined as "address" without the number 1, enough to give me a delay of 20+ minutes, watch out for that and check carefully your orderData object

SPA DTM analytics pagename issue

I am using Angular SPA with DTM.Using custom event based rules, I am able to get all my data including pageName, v41,v42 as correct. Now inside adobe editor, i am storing pagename to s.pageName and some hard-coded value to s.server. I have verified that all my data is correctly populating using OMNIBUG tool as server,pageName, v41 and v42.
Problem is coming in Omniture reporting, as server and page data are not coming through. Page-name data only showing SPA homepage in all page visits and server also coming as default from s.code and not the one i am passing from s.server. eVar/prop are all coming fine.Even if I do prop40=s.pageName/prop41=s.server, then in omniutre reporting i am seeing correct data populating in prop40/prop41 but not under Page and server. And again I cant use prop40/prop41 for pagename/server as its not a correct way to follow and PAGE-VISITS are ZERO in that case.
Any help how to get data in page/server in omniture for SPA or anything wrong in my implementation? Thanks in advance!!
If you really do see the correct values in Omnibug (or more specifically, network request to Adobe collection server), then the issue is not in the code.
Check against another AA hit debugger. Possible Omnibug is somehow bugging out. There are a ton of alternatives out there. Adobe Experience Cloud Debugger. Observepoint. Charles Proxy. Fiddler. Or just use the browser dev tool network tab (what I usually do as a backup).
Make sure you are looking in the correct report suite. Perhaps your data is being sent to a dev report suite, and you are looking at prod report suite, or visa versa?
Check to see if you have any Processing Rules that are overriding your values.
Contact your Adobe Rep to check if there are any VISTA Rules present for the report suite, that are overriding your values.
If you have verified none of the above is the case, then sorry, but it sounds like the issue must really be in your code, but there is a problem with your QA method (e.g. maybe you are looking at the wrong AA request, or something).
Update:
Based on your comment:
Earlier, i was making s.tl() call, but replacing it with s.t() call
resolved my problem for data was not populating
pageName/server/page-views in Omniture and now it is. But the current
problem is we need PageName on all SPA clicks (can be achieved by
s.t() call ) , but the page-Views are not needed on all clicks. So,
its like link-tracking needed only but with PageName data. I am
struggling not to populate page-views on a s.t() call or vice-versa
how to get PageName populated on s.tl() call. Again, omnibug shows all
requests just fine but the issue comes in reports in omniture
When Adobe processes a hit, it wipes pageName for s.tl calls, as that's how it determines whether to count the request as a page view or not. If you want to see page name even for s.tl calls, the common practice is to dupe the pageName value to a prop or eVar and send in with the s.tl call, and look at that report. In fact, most clients I work with don't even use the native pages report, and instead use the (usually eVar) report.

Piwik, Export count of page visits for a specific url

I Make artificial page views with javascript on my website using javascript, because I need to track them later
piwikTracker.trackPageView('/lid/902095/website');
I need to be able to export how many times the above code was executed, i.e. how many times /lid/902095/website was visited, so that I can show some stats on my website, however I'm not sure what my query to the API should be, here is my attempt:
?module=API&method=Actions.getExitPageUrls&idSite=2&period=day&date=today&format=JSON&token_auth=anonymous&segment=pageUrl=#%2Flid%2F902095%2Fwebsite
It returns an error at this time "Error: The report 'VisitsSummary_CoreMetrics' was requested but it is not available at this stage. You may also disable the related plugin to avoid this error."
I don't see a plugin with that name in plugins section, my active plugins are "Actions, Dashbord, DoNotTrack, ExampleAPI, ExamplePlugin, Live, Login, Widgetize"
Not sure if this is the right query to send to the API or not, any help is appreciated.
If you want to track the visits use this api call
?module=API&method=VisitsSummary.getVisits&idSite=2&period=day&date=today&format=json&token_auth=anonymous
by default VisitsSummary plugin is provided
Piwik Web Essentials is a good book for reference.

Is Google Website Optimizer omitting my query data transfer?

Symptom: I'm running a Google Website Optimizer A-B test on a web page, which is reached after the user fills out a form. The form data appears to arrive successfully when GWO does not fire a redirect (when the default page is reached after submitting the web form). The data does not appear to arrive, however, when the alternate page is reached (i.e. when GWO redirects the user).
Details: I wouldn't attribute this to GWO, except that in my development environment, where I was obliged to comment out the GWO javascript, everything works as it should do. (The GWO code had to be omitted, of course, to prevent my browser redirecting me to the production environment, i.e. the live version of my site.) (Naturally, without the GWO code in place, I had to hard code a change to my form's action attribute in order to verify that my query data was handled successfully by the alternate destination page.)
Really, it looks as though GWO is just failing to pass on the requisite query parameters when it performs its redirect, but that seems unlikely. Can you give me any advice?
Fixed (rather): I changed the form to pass GET (not POST) data, and indeed, GWO was able to collect that query data and pass it on to the new URL. (I find that surprising, since the url is stipulated, and I should have thought it easier to accept and pass on POST data.)

Resources