We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 86ab8d4 commit f38b0a6Copy full SHA for f38b0a6
filter_plugins/slurm_conf.py
@@ -108,7 +108,10 @@ def config2dict(lines):
108
if '=' not in line: # ditch blank/info lines
109
continue
110
else:
111
- k, v = (x.strip() for x in line.split('='))
+ parts = [x.strip() for x in line.split('=', maxsplit=1)] # maxplit handles '=' in values
112
+ if len(parts) != 2:
113
+ raise errors.AnsibleFilterError(f'line {line} cannot be split into key=value')
114
+ k, v = parts
115
small_v = v.lower()
116
if small_v == '(null)':
117
v = None
0 commit comments