Check python version >= 2.7 or 3.2

1. Bugfix: Check minor version instead of micro version
2. UF_HIDDEN is available since Python 2.7 & 3.2