Update to py-hgtools 4.0