Permalink
Browse files

More stuff in readme

  • Loading branch information...
1 parent dc094c8 commit eefe9a199d8b58c2484e67187932f81dcc572fa7 @ggreer committed Feb 2, 2012
Showing with 6 additions and 1 deletion.
  1. +6 −1 README.md
View
@@ -3,4 +3,9 @@
watcher = HangWatcher(0.1, 0.5) # these params are optional. They have sane defaults
watcher.start()
-Stuff will magically get printed out if the main thread hangs for more than MAX_DELAY seconds. If you want more info, look at the dict returned by `watcher.stats()`.
+Stuff will magically get printed out if the main thread hangs for more than MAX_DELAY seconds. If you want more info, add something like this after the lines above:
+
+ from twisted.internet import task
+ # Print stats every 60 seconds
+ lc = task.LoopingCall(watcher.print_stats)
+ lc.start(60)

0 comments on commit eefe9a1

Please sign in to comment.