fixing to work with python3 and export enums