ggonnella / gfapy

Gfapy: a flexible and extensible software library for handling sequence graphs in Python
Other
65 stars 7 forks source link

Minimum Python version #1

Closed sjackman closed 7 years ago

sjackman commented 7 years ago

pip install gfapy with Python 2.x works, but then running the program gives the error:

❯❯❯ gfapy-convert --help
Traceback (most recent call last):
  File "/Users/sjackman/.homebrew/bin/gfapy-convert", line 8, in <module>
    from gfapy import Gfa
  File "/usr/local/Cellar/python/2.7.13/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/gfapy/__init__.py", line 6, in <module>
    from gfapy.field_array import FieldArray
  File "/usr/local/Cellar/python/2.7.13/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/gfapy/field_array.py", line 30
    def validate(self, fieldname : str = None) -> None:
                                 ^
SyntaxError: invalid syntax

Is it possible to indicate the minimum Python version in the package so that the user receives a meaningful error message with Python 2.x?

ggonnella commented 7 years ago

Good Idea. I added a python version check in setup.py, which outputs a meaningful error msg.

sjackman commented 7 years ago

Thanks, Giorgio.