Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Google Analytics not receiving data

I'm having problems with Google Analytics in my app. The website doesn't seem to be receiving any data, but the app seems to send it rightfully. I'm following this Ray Wenderlich tutorial, and the point where you run the app, there should be 1 visitor in the Real-Time Overview. It keeps saying 0.

My AppDelegate.m

[GAI sharedInstance].trackUncaughtExceptions = YES;
[GAI sharedInstance].dispatchInterval = 20;
[[[GAI sharedInstance] logger] setLogLevel:kGAILogLevelVerbose];
[[GAI sharedInstance] trackerWithTrackingId:@"UA-********-2"];

My ViewController.m

- (void)viewDidLoad
{
    [super viewDidLoad];-
    self.screenName = @"ScreenZero";
//more
}

My Console

2014-10-17 15:07:52.479 Wheels[25548:2342406] idfa class missing, won't collect idfa
2014-10-17 15:07:52.513 Wheels[25548:2342437] CoreData: warning: Unable to load class named 'GAIProperty' for entity 'GAIProperty'.  Class not found, using default NSManagedObject instead.
2014-10-17 15:07:52.923 Wheels[25548:2342406] INFO: GoogleAnalytics 3.09 -[GAIReachabilityChecker reachabilityFlagsChanged:] (GAIReachabilityChecker.m:159): Reachability flags update: 0X000002
2014-10-17 15:07:52.962 Wheels[25548:2342437] CoreData: warning: Unable to load class named 'GAIHit' for entity 'GAIHit'.  Class not found, using default NSManagedObject instead.
2014-10-17 15:07:52.978 Wheels[25548:2342437] VERBOSE: GoogleAnalytics 3.09 -[GAIBatchingDispatcher persist:] (GAIBatchingDispatcher.m:431): Saved hit: {
    parameters =     {
        "&_crc" = 0;
        "&_u" = ".etno";
        "&_v" = "mi3.0.9";
        "&a" = 730280959;
        "&aid" = "com.samvandamme.Wheels";
        "&an" = Wheels;
        "&av" = "0.1";
        "&cd" = ScreenZero;
        "&cid" = "7deb1f6d-3407-47e6-8303-7bc6305cd706";
        "&sr" = 1024x768;
        "&t" = appview;
        "&tid" = "UA-********-2";
        "&ul" = en;
        "&v" = 1;
        "&z" = 15854684929669144728;
        gaiVersion = "3.09";
    };
    timestamp = "2014-10-17 13:07:52 +0000";
}
2014-10-17 15:08:12.537 Wheels[25548:2342437] VERBOSE: GoogleAnalytics 3.09 -[GAIRequestBuilder requestGetUrl:payload:] (GAIRequestBuilder.m:195): building URLRequest for https://ssl.google-analytics.com/collect
2014-10-17 15:08:12.538 Wheels[25548:2342437] VERBOSE: GoogleAnalytics 3.09 -[GAIBatchingDispatcher dispatchWithCompletionHandler:] (GAIBatchingDispatcher.m:536): Sending hit(s) GET: https://ssl.google-analytics.com/collect?av=0.1&a=730280959&cd=ScreenZero&t=appview&_crc=0&ul=en&_u=.etno&tid=UA-********-2&cid=7deb1f6d-3407-47e6-8303-7bc6305cd706&sr=1024x768&v=1&aid=com.samvandamme.Wheels&an=Wheels&_v=mi3.0.9&ht=1413551272962&qt=19574&z=15854684929669144728
2014-10-17 15:08:12.815 Wheels[25548:2342406] INFO: GoogleAnalytics 3.09 -[GAIBatchingDispatcher didSendHits:response:data:error:completionHandler:] (GAIBatchingDispatcher.m:161): Hit(s) dispatched: HTTP status 200
2014-10-17 15:08:12.816 Wheels[25548:2342437] INFO: GoogleAnalytics 3.09 -[GAIBatchingDispatcher deleteHits:] (GAIBatchingDispatcher.m:443): hit(s) Successfully dispatched
2014-10-17 15:08:12.821 Wheels[25548:2342437] INFO: GoogleAnalytics 3.09 -[GAIBatchingDispatcher didSendHits:sendMore:] (GAIBatchingDispatcher.m:174): 1 hit(s) sent

My Google Analytics Problem

So nothing gets sent to GA. Any ideas?

like image 898
Yoko Avatar asked Oct 31 '22 15:10

Yoko


1 Answers

I am having a similar issue to the one you are having but I don't think it is related to missing libraries. It looks like your core data class might be missing. To fix this problem try importing the framework and let me know how it goes.

Try doing this:

Go to: Build Phases > Link Binary With Libraries > (Click the plus button) > Search for CoreData.Framework
like image 55
Kevin Pimentel Avatar answered Nov 08 '22 09:11

Kevin Pimentel