context getter and more minor changes