WIP backport of 1.5.2 dimensions