merge 3.1 (with 3.1.5rc1 release tag)