Skip to content

Commit

Permalink
main: bail if python 3.6 or below
Browse files Browse the repository at this point in the history
closes #964
  • Loading branch information
williballenthin authored and mr-tz committed Apr 7, 2022
1 parent 8dd383c commit e5c210b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions capa/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -870,7 +870,7 @@ def handle_common_args(args):
# disable vivisect-related logging, it's verbose and not relevant for capa users
set_vivisect_log_level(logging.CRITICAL)

# Since Python 3.8 cp65001 is an alias to utf_8, but not for Pyhton < 3.8
# Since Python 3.8 cp65001 is an alias to utf_8, but not for Python < 3.8
# TODO: remove this code when only supporting Python 3.8+
# https://stackoverflow.com/a/3259271/87207
import codecs
Expand Down Expand Up @@ -942,8 +942,8 @@ def handle_common_args(args):


def main(argv=None):
if sys.version_info < (3, 6):
raise UnsupportedRuntimeError("This version of capa can only be used with Python 3.6+")
if sys.version_info < (3, 7):
raise UnsupportedRuntimeError("This version of capa can only be used with Python 3.7+")

if argv is None:
argv = sys.argv[1:]
Expand Down

0 comments on commit e5c210b

Please sign in to comment.