Cherry picked googlecode 2 github changes