account for weird context jumping (need to refactor all of this later)