3

The documentation states

"Important Log message lines greater than the system’s maximum message length are truncated when stored by the logging system. Complete messages are visible when using the log command-line tool to view a live stream of activity. Bear in mind, however, that streaming log data is an expensive activity."

but when using

log stream

in terminal i get only partial logs... how to get the full logs, without lines truncated?

Antwane
  • 20,760
  • 7
  • 51
  • 84
Peter Lapisu
  • 19,915
  • 16
  • 123
  • 179

1 Answers1

0

You'll likely want to include --level and possibly --type and/or --source:

log stream --level debug --type log --source

The last two arguments are optional, although it might help you narrow things down if debugging.

--level default | info | debug Shows messages at specified level and below. The level is a hierarchy. Specifying debug implies debug, info and default.

--type activity | log | trace Dictates the type of events to stream from a process. By default all types are streamed unless otherwise specified. Pass an appropriate --type for each requested type of event.

--source Include symbol names and source line numbers for messages, if available.

In terminal you can get more information by using man log

l'L'l
  • 44,951
  • 10
  • 95
  • 146
  • 3
    but the log stream doesn't display the full output, but truncated messages – Peter Lapisu Feb 15 '17 at 19:55
  • Could you provide an example? I'm not able to reproduce the issue; I get no truncated output. – l'L'l Feb 15 '17 at 20:50
  • When the output is larger than 1024 http://stackoverflow.com/questions/39584707/nslog-on-devices-in-ios-10-xcode-8-seems-to-truncate-why – Peter Lapisu Feb 15 '17 at 21:00
  • Nah, it can't be that (as it's specific to iOS); I've had no issues getting full output far above 1024 bytes, so it must be something else causing the issue for you. – l'L'l Feb 16 '17 at 01:14
  • i did encounter the same behaviour for macos too (note that you must compile the project under the 10.12 SDK) – Peter Lapisu Feb 16 '17 at 11:46