integrate 3.0.12 branch and adapt for 3.0.12 release