quick and dirty parser for version number in legacy-defaults#435
Conversation
control/config.py
Outdated
| first_digit = int(version[0]) | ||
| second_digit = int(version[2]) | ||
| if second_digit < 8: |
There was a problem hiding this comment.
Will break with >=0.10.0
Maybe use setuptool's packaging.version.parse?
There was a problem hiding this comment.
I found I could make a quick change that addresses this concern - does what I came up with look ok? alternatively, are you sure a dependency on the module you proposed ok to have? (is it always included in python?)
There was a problem hiding this comment.
It is an edge case. setuptools should not really be needed after install, or if you get the package from something else. The other option mentioned in that SO question is undocumented but standard lib distutils.version. python-control already uses that within the test suite.
Although your quick solution works, too. I would be fine with it. (Not to imply that I have any authority. I am only here to contribute unwarranted suggestions. 😉)
follows issue #432