diff --git a/src/aiida_quantumespresso/workflows/pw/base.py b/src/aiida_quantumespresso/workflows/pw/base.py index 4c31dc292..cfea4d4a9 100644 --- a/src/aiida_quantumespresso/workflows/pw/base.py +++ b/src/aiida_quantumespresso/workflows/pw/base.py @@ -198,6 +198,10 @@ def get_builder_from_protocol( parameter_overrides = overrides.get('pw', {}).get('parameters', {}) parameters = recursive_merge(parameters, parameter_overrides) + # if tot_magnetization in overrides , remove starting_magnetization from parameters + if parameters.get('SYSTEM', {}).get('tot_magnetization') is not None: + parameters.setdefault('SYSTEM', {}).pop('starting_magnetization', None) + pseudos_overrides = overrides.get('pw', {}).get('pseudos', {}) pseudos = recursive_merge(pseudos, pseudos_overrides)