From 20399b934820ddaa37e746f983854304eb06bb66 Mon Sep 17 00:00:00 2001 From: Shawn Davis Date: Tue, 22 Dec 2020 12:22:07 -0500 Subject: [PATCH] Fixed issue where a command with no arguments would fail to parse. --- VERSION.txt | 2 +- scripttease/parsers/ini.py | 14 +++++++++----- scripttease/version.py | 6 +++--- 3 files changed, 13 insertions(+), 9 deletions(-) diff --git a/VERSION.txt b/VERSION.txt index f0e13c5..1d42024 100644 --- a/VERSION.txt +++ b/VERSION.txt @@ -1 +1 @@ -6.7.0 +6.7.1 \ No newline at end of file diff --git a/scripttease/parsers/ini.py b/scripttease/parsers/ini.py index 45f3b1a..3385a43 100644 --- a/scripttease/parsers/ini.py +++ b/scripttease/parsers/ini.py @@ -49,11 +49,15 @@ class Config(Parser): command_name = key # Arguments surrounded by quotes are considered to be one argument. All others are split into a - # list to be passed to the callback. - if value[0] == '"': - args.append(value.replace('"', "")) - else: - args = value.split(" ") + # list to be passed to the callback. It is also possible that this is a call where no arguments are + # present, so the whole thing is wrapped to protect against an index error. + try: + if value[0] == '"': + args.append(value.replace('"', "")) + else: + args = value.split(" ") + except IndexError: + pass else: _key, _value = self._get_key_value(key, value) diff --git a/scripttease/version.py b/scripttease/version.py index 385f5e6..0303ce4 100644 --- a/scripttease/version.py +++ b/scripttease/version.py @@ -1,5 +1,5 @@ -DATE = "2020-10-06" -VERSION = "6.7.0" +DATE = "2020-12-16" +VERSION = "6.7.1" MAJOR = 6 MINOR = 7 -PATCH = 0 +PATCH = 1