about summary refs log tree commit diff stats
path: root/transect/Readme
diff options
context:
space:
mode:
authorKartik Agaram <vc@akkartik.com>2019-03-03 11:02:11 -0800
committerKartik Agaram <vc@akkartik.com>2019-03-03 11:55:23 -0800
commit8359e5798993b4c2d2b5da7b03b38ead5c0f32ca (patch)
tree5e0d86491f06cc3eb06ddb08fba22e81324afe69 /transect/Readme
parent6bcdfa87a71c00a12a918a0f6e7dad814b6a087a (diff)
downloadmu-8359e5798993b4c2d2b5da7b03b38ead5c0f32ca.tar.gz
4994
Bring back support for incrementally printing the trace to the screen (stderr).

I previously thought I didn't need this as long as I'm always incrementally
saving to the 'last_run' trace file. But I quickly ran into a use for it:
when I want to see a complete trace including switching into the sandbox's
trace and back out again.

So there are now two separate commandline flags:
  --trace to save the trace to file
  --dump to print the trace to screen
The former won't handle sandbox traces. But the latter will.

I'm deemphasizing --dump in the help message since it should be rarely
used.

One other situation where I've used stderr in the past is for just raw
convenience. But trying to always use the trace was a foolish consistency.
Conclusion:
  a) For simple debugging, feel free to just use cout/cerr. Delete them
  before committing.
  b) If the prints get too complex, switch to the trace and browse_trace
  tool.
  c) If using nested sandboxes, emit to stderr, redirect to file, and browse_trace.

I've gone back and forth on these questions in the past; now I'm trying
to be a little more rigorous about capturing reasoning.
Diffstat (limited to 'transect/Readme')
0 files changed, 0 insertions, 0 deletions