question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Error in Call Metrics Call Details Report

See original GitHub issue

I’m attempting to run the CALL_METRICS_CALL_DETAILS_REPORT, but am receiving the following error:

System.InvalidOperationException: Could not set the member startTime with value Jan 22, 2018 12:41:56 PM

I am requesting the CallStartTime field in the ReportDefinition; this appears to be a long (public long callStartTime) in CallMetricsCallDetailsReportReportRow class. I obviously can’t override the type of this property.

 ReportUtilities utilities = new ReportUtilities(user, AdWordsVersion, definition);
 using (ReportResponse response = utilities.GetResponse())
 using (GZipStream gzipStream = new GZipStream(response.Stream, CompressionMode.Decompress))
 using (var report = new AwReport<CallMetricsCallDetailsReportReportRow>(new AwXmlTextReader(gzipStream), reportName))

Any suggestions would be appreciated! Stack trace below.

at Google.Api.Ads.AdWords.Util.Reports.AwReport`1.<>c.<.ctor>b__21_0(ColumnValuePair colVal, A record)
at Google.Api.Ads.AdWords.Util.Reports.ReportParserUtils.SetColumnValue[A](ColumnValuePair colVal, A record, Action`2 onError)
at Google.Api.Ads.AdWords.Util.Reports.AwReport`1.ParseCurrentRow()
at Google.Api.Ads.AdWords.Util.Reports.AwReport`1.get_Current()
at Google.Api.Ads.AdWords.Util.Reports.AwReport`1.GetRows()
at Google.Api.Ads.AdWords.Util.Reports.AwReport`1.get_Rows()

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
AnashOommencommented, Jan 25, 2018

As a temporary workaround, you can provide an OnError handler on the AwReport through the constructor. See the definition here:

https://github.com/googleads/googleads-dotnet-lib/blob/8d666a040a736eea200bbb7804adb95116788174/src/AdWords/Util/Reports/Parser/AwReport.cs#L118

You can see the default implementation on line 137 below, which simply throws an InvalidOperationException. You can adapt this logic something like this (syntax not checked, I don’t have access to an IDE right now):

using (var report = new AwReport<CallMetricsCallDetailsReportReportRow>(new AwXmlTextReader(gzipStream), reportName), delegate(colVal, record) {
      if (colVal.Name ==  "CallStartTime") {
        // Parse from datetime to long using DateTime class.
      } else {
        throw new InvalidOperationException("Could not set the member "
            + colVal.ColName + " with value " + colVal.Value);
        }
      }
) {
  // Your code goes here.
}
0reactions
AnashOommencommented, Mar 8, 2018

Closing this issue, since this is actually an API issue, and that there is a workaround for it.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Call Metrics Call Details Report | AdWords API (Deprecated )
The Call Metrics Call Details report includes data for call tracking of call-only ads or call extensions.
Read more >
Google AdWords Call Tracking Reporting: The Call Details ...
The Google AdWords call detail report offers data around AdWords-enabled call tracking via call metrics or AdWords call extensions.
Read more >
Get Phone impressions and Phone Calls by Ad using ...
The data for call tracking of call-only ads or call extensions can be extracted using Call Metrics Call Details Report. If this is...
Read more >
Call Detail Reporting - IR Community - Integrated Research
Call Detail Report to me sounds like reviewing single calls but let us please know more ... -4:00 16 - Normal call clearing...
Read more >
Reports: Call Details - TechDocs - Broadcom Inc.
The Call Details report provides in-depth metrics for the calls in the Calls Overview and the Watched Calls reports.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found