0

I use a pod "Charts (3.0.1)" in my project, I found it alway produce a lot of errors in debug windows, like that:

Feb  2 20:03:01  KeepHealth[1641] <Error>: If you want to see the backtrace, please set CG_NUMERICS_SHOW_BACKTRACE environmental variable.  
2017-02-02 20:03:01.470339 KeepHealth[1641:449073] CGContextAddLineToPoint: no current point.  
Feb  2 20:03:01  KeepHealth[1641] <Error>: CGContextAddLineToPoint: no current point.  
2017-02-02 20:03:01.470362 KeepHealth[1641:449073] Error: this application, or a library it uses, has passed an invalid numeric value (NaN, or not-a-number) to CoreGraphics API and this value is being ignored. Please fix this problem.  
Feb  2 20:03:01  KeepHealth[1641] <Error>: Error: this application, or a library it uses, has passed an invalid numeric value (NaN, or not-a-number) to CoreGraphics API and this value is being ignored. Please fix this problem.  
2017-02-02 20:03:01.470377 KeepHealth[1641:449073] If you want to see the backtrace, please set CG_NUMERICS_SHOW_BACKTRACE environmental variable.  

Feb  2 20:03:01  KeepHealth[1641] <Error>: If you want to see the backtrace, please set CG_NUMERICS_SHOW_BACKTRACE environmental variable.  
2017-02-02 20:03:01.470393 KeepHealth[1641:449073] CGContextAddLineToPoint: no current point.  
Feb  2 20:03:01  KeepHealth[1641] <Error>: CGContextAddLineToPoint: no current point.  
2017-02-02 20:03:01.470532 KeepHealth[1641:449073] Error: this application, or a library it uses, has passed an invalid numeric value (NaN, or not-a-number) to CoreGraphics API and this value is being ignored. Please fix this problem.  
Feb  2 20:03:01  KeepHealth[1641] <Error>: Error: this application, or a library it uses, has passed an invalid numeric value (NaN, or not-a-number) to CoreGraphics API and this value is being ignored. Please fix this problem.  
2017-02-02 20:03:01.470547 KeepHealth[1641:449073] If you want to see the backtrace, please set CG_NUMERICS_SHOW_BACKTRACE environmental variable.  

There are a lot of this, every time, every where, so I almost can not find NSLog made by myself. But in fact, this pod function pretty well, so I just want hide this kind debug information cause by it, can I do this?

Tinyfool
  • 1,460
  • 2
  • 18
  • 40

2 Answers2

0

This will probably do the trick:

https://medium.com/@adinugroho/disable-os-logging-in-xcode-8-ec6d38502532#.2d1hpl49d

Anna Dickinson
  • 3,307
  • 24
  • 43
0

Add this to your podfile and execute pod install

platform :ios

# ignore all warnings from all pods
inhibit_all_warnings!

# ignore warnings from a specific pod
pod 'Charts (3.0.1)', :inhibit_warnings => true

For further clearance please check this.

Community
  • 1
  • 1
Mithun kumar
  • 662
  • 3
  • 7