Message backup

This PR makes all of the messages persistent so every message gets sent (unless that particular run was run with --local). In addition, it collects information on the grading and unlock protocols so that the server can display progress bars and stuff to the end user.

@sharadmv - maybe take a look at this to see what's going on.

Also, don't merge this yet- I want to test it with trends to make sure that nothing breaks. I'll let you know when everything's good.
After changing the default arg to `None`, you should rewrite this line to either be

    self._analytics = analytics if analytics else {}

or

    self._analytics = analytics or {}