mirror of
https://github.com/samsonjs/vdirsyncer.git
synced 2026-04-03 10:25:51 +00:00
Check Python version at runtime
This commit is contained in:
parent
e4c3dafe4a
commit
6ab6d1ddfd
1 changed files with 5 additions and 0 deletions
|
|
@ -4,6 +4,11 @@ import sys
|
|||
|
||||
PY2 = sys.version_info[0] == 2
|
||||
|
||||
if sys.version_info < (3, 3) and sys.version_info[:2] != (2, 7):
|
||||
raise RuntimeError(
|
||||
'vdirsyncer only works on Python versions 2.7.x and 3.3+'
|
||||
)
|
||||
|
||||
|
||||
if PY2: # pragma: no cover
|
||||
import urlparse
|
||||
|
|
|
|||
Loading…
Reference in a new issue