Skip to content
This repository was archived by the owner on Nov 22, 2024. It is now read-only.

Commit ec0a1cc

Browse files
committed
2.8.5 release
1 parent a3bd103 commit ec0a1cc

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

CloudFlare/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
""" Cloudflare v4 API"""
22
from __future__ import absolute_import
33

4-
__version__ = '2.8.4'
4+
__version__ = '2.8.5'
55

66
from .cloudflare import CloudFlare
77

cli4/cli4.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -380,7 +380,10 @@ def do_it(args):
380380
#value = json.loads(value) - changed to yaml code to remove unicode string issues
381381
if yaml is None:
382382
sys.exit('cli4: install yaml support')
383-
value = yaml.safe_load(value_string)
383+
try:
384+
value = yaml.safe_load(value_string)
385+
except yaml.parser.ParserError as e:
386+
raise ValueError
384387
except ValueError:
385388
sys.exit('cli4: %s="%s" - can\'t parse json value' % (tag_string, value_string))
386389
elif value_string[0] == '@':
@@ -404,10 +407,8 @@ def do_it(args):
404407
if tag_string == '':
405408
# There's no tag; it's just an unnamed list
406409
if params is None:
407-
params = []
408-
try:
409-
params.append(value)
410-
except AttributeError:
410+
params = value
411+
else:
411412
sys.exit('cli4: %s=%s - param error. Can\'t mix unnamed and named list' %
412413
(tag_string, value_string))
413414
else:

0 commit comments

Comments
 (0)