Only mark parameter set when value field modified
@@ -114,6 +114,7 @@ class Schema:
value = Schema._check_and_normalize(value, cfg['type'], field)
cfg[field] = value
+ if field == 'value':
cfg['set'] = True
return True
@@ -143,6 +144,7 @@ class Schema:
value = Schema._check_and_normalize(value, cfg['type'], field)
cfg[field].extend(value)
+ if field == 'value':
cfg['set'] = True
return True
@@ -314,10 +316,6 @@ class Schema:
raise TypeError(f'Invalid value {value} for {field}: expected str')
return value
- if value is None:
- # None is always acceptable for scalars
- return value
-
if field == 'scope':
# Restricted allowed values
if not (isinstance(value, str) and value in ('global', 'job', 'scratch')):
