From b222693d98273609bcfdf3c95b0639847fb7fd60 Mon Sep 17 00:00:00 2001 From: "Grant T. Olson" Date: Thu, 15 Aug 2013 11:37:23 -0400 Subject: [PATCH] Have OSX check run before we import classes and error out --- src/bitmessagemain.py | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/src/bitmessagemain.py b/src/bitmessagemain.py index cae8daeb..fd233bd5 100755 --- a/src/bitmessagemain.py +++ b/src/bitmessagemain.py @@ -23,6 +23,14 @@ import json import singleton import os +# OSX python version check +import sys +if sys.platform == 'darwin': + if float("{1}.{2}".format(*sys.version_info)) < 7.5: + print "You should use python 2.7.5 or greater." + print "Your version: {0}.{1}.{2}".format(*sys.version_info) + sys.exit(0) + # Classes from class_sqlThread import * from class_singleCleaner import * @@ -34,13 +42,6 @@ from class_addressGenerator import * # Helper Functions import helper_bootstrap -import sys -if sys.platform == 'darwin': - if float("{1}.{2}".format(*sys.version_info)) < 7.5: - print "You should use python 2.7.5 or greater." - print "Your version: {0}.{1}.{2}".format(*sys.version_info) - sys.exit(0) - def connectToStream(streamNumber): selfInitiatedConnections[streamNumber] = {} if sys.platform[0:3] == 'win':