merging in some of the changes from the agenda branch