Sync from master in preparation of v1.2