Skip to content

Commit

Permalink
Added check for Python 2 or Python 3
Browse files Browse the repository at this point in the history
  • Loading branch information
zunzun committed Dec 17, 2016
1 parent c9e5a50 commit 25fe026
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions __init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@




# pyeq3 is a collection of equations expressed as Python classes
#
# Copyright (C) 2013 James R. Phillips
Expand All @@ -12,6 +9,11 @@
#
# License: BSD-style (see LICENSE.txt in main source directory)

import sys
ver = sys.version_info[0]
if ver < 3:
raise Exception('Python 3 is required to use pyeq3')

from . import DataCache
from . import Services
from . import ExtendedVersionHandlers
Expand All @@ -22,4 +24,4 @@
dataConvertorService = Services.DataConverterService.DataConverterService
solverService = Services.SolverService.SolverService
outputSourceCodeService = Services.OutputSourceCodeService.OutputSourceCodeService
dataCache = DataCache.DataCache.DataCache
dataCache = DataCache.DataCache.DataCache

0 comments on commit 25fe026

Please sign in to comment.