NEW: Subscribe to Hacking with Swift+ and accelerate your learning! >>

SOLVED: Apple's Unified Log System (OSLog)

Forums > Swift

Hi! I have been studying about os log that is provided by apple and wanted to ask a few things.

  1. Is using OSLog beneficial or print statements will do the job?
  2. If I keep statements of os_log with log type .debug in release builds, does it impact performance of the app?


  1. I do prefer OSLog! You can view your log messages inside the console app. This is far more flexible than print.
  2. Actually there's a bug. You won't see .debug at all inside console :-( But you don't need to worry about performance.


Thanks @oliverepper


Hacking with Swift is sponsored by Paw

SPONSORED Use Paw to build, test and describe web APIs. Paw has a lightning fast native macOS interface to compose requests, collaborate in real-time on API specs, and generate client code for your applications. You can import and export API definitions.

Discover Paw for Mac

Sponsor Hacking with Swift and reach the world's largest Swift community!

Reply to this topic…

You need to create an account or log in to reply.

All interactions here are governed by our code of conduct.

Unknown user

Not logged in

Log in

Link copied to your pasteboard.