Disable Google App Measurement debug logging
On Xcode 7.2, how can I disable these debug/app measurements intempestive displays :
2016-01-07 11:52:53.085 MyApp[1457:] <GMR/INFO> App measurement v.1302000 started 2016-01-07 11:52:53.091 MyApp[1457:] <GMR/INFO> To enable debug logging set the following application argument: -GMRDebugEnabled (see http://goo.gl/Y0Yjwu) 2016-01-07 11:52:53.091 MyApp[1457:] <GMR/DEBUG> Debug logging enabled 2016-01-07 11:52:53.092 MyApp[1457:] <GMR/DEBUG> App measurement is monitoring the network status 2016-01-07 11:52:53.188 MyApp[1457:] <GMR/DEBUG> App measurement is ready to receive events 2016-01-07 11:52:53.201 MyApp[1457:] <GMR/DEBUG> No network. Upload task will not be scheduled 2016-01-07 11:52:53.202 MyApp[1457:] <GMR/DEBUG> Scheduling user engagement timer 2016-01-07 11:52:53.202 MyApp[1457:] <GMR/DEBUG> Timer scheduled to fire in approx. (s): 3600 2016-01-07 11:52:53.203 MyApp[1457:] <GMR/INFO> App measurement enabled 2016-01-07 11:52:53.237 MyApp[1457:] <GMR/DEBUG> Scheduling user engagement timer 2016-01-07 11:52:53.242 MyApp[1457:] <GMR/DEBUG> Canceling active timer 2016-01-07 11:52:53.245 MyApp[1457:] <GMR/DEBUG> Timer scheduled to fire in approx. (s): 3600 2016-01-07 11:52:53.270 MyApp[1457:] <GMR/DEBUG> Network status has changed. code, status: 3, Connected 2016-01-07 11:52:53.272 MyApp[1457:] <GMR/DEBUG> Timer scheduled to fire in approx. (s): 1614.930058836937 2016-01-07 11:52:53.272 MyApp[1457:] <GMR/DEBUG> Upload task scheduled to be executed in approx. (s): 1614.930058836937
It bothers me since a while…
Edit : I tried the –
noGMRDebugEnabled flag, reinstalling the app without –
GMRDebugEnabled, reset Content and settings, restarting Xcode … nothing works 🙁
3 Solutions Collect From Internet About “Disable Google App Measurement debug logging”
In Swift to disable the Google Measurements I’ve added in the UIApplicationDelegate launch :
Finally, I found it in the Google API docs.
In the GoogleService-Info.plist file, you have to add a key named
IS_MEASUREMENT_ENABLED, set it as a boolean, and select NO value.
This will disable App measurement feature and display in the console :
2016-07-03 10:51:38.522 MyApp[313:] <GMR/INFO> App measurement disabled
Thanks for all your answers !
To remove the debug mode, you can delete the UserDefault entry using the following call (you only need to run it once):
[[NSUserDefaults standardUserDefaults] removeObjectForKey:@"/google/measurement/debug_mode"];
- Cocoa-Touch, NSManagedObject: Exception when setting a property
- Error : CoreData: error: Failed to call designated initializer on NSManagedObject class 'Product'
- Scrolling two UITableViews together
- Game Center Multiplayer using GKMatch but seems can't be connected
- PDF Generation Swift
- How to create a back button in a view controller to go to parent view controller
- How do I check when a UITextField changes?
- Access Photo Library via Objective-C/Xcode in iOS
- Swift 3: convert a null-terminated UnsafePointer<UInt8> to a string
- Image within PFFile will be uploaded to parse instead of being saved into the local datastorage
- CAShapeLayer mask view
- MonoTouch.Dialog: Responding to a RadioGroup Choice
- Could Not Launch Appium Inspector
- Determine MIME Type of NSData Loaded From a File
- How to call class methods in the iOS simulator with lldb?