cherrypick from master pin Sphinx to 1.2.3

Fixes #669 and #1068