Use sys.exit instead of exit

This commit is contained in:
vrde 2016-04-11 11:29:42 +02:00
parent a59797c491
commit ab8113a91c
No known key found for this signature in database
GPG Key ID: 6581C7C39B3D397D

View File

@ -2,6 +2,7 @@
import os
import sys
import logging
import argparse
import copy
@ -102,8 +103,7 @@ def run_start(args):
except DatabaseAlreadyExists:
pass
except KeypairNotFoundException:
print('Cannot start BigchainDB, no keypair found. Did you run `bigchaindb configure`?')
exit(1)
sys.exit('Cannot start BigchainDB, no keypair found. Did you run `bigchaindb configure`?')
processes = Processes()
logger.info('Start bigchaindb main process')