<commit_before>import {DeploymentStrategyRegistry} from 'core/deploymentStrategy/deploymentStrategy.registry';

DeploymentStrategyRegistry.registerStrategy({
  label: 'Rolling Red/Black (Experimental)',
  description: `Creates a new version of this server group, then incrementally resizes the new server group while disabling the same percentage in the previous server group.`,
  key: 'rollingredblack',
  providerRestricted: true,
  additionalFields: ['targetPercentages'],
  additionalFieldsTemplateUrl: require('./additionalFields.html'),
  initializationMethod: (command) => {
    command.targetPercentages = [50, 100];
  }
});<commit_msg>fix(core): do not overwrite target percentages on rolling red/black (#4025)<commit_after>import {DeploymentStrategyRegistry} from 'core/deploymentStrategy/deploymentStrategy.registry';

DeploymentStrategyRegistry.registerStrategy({
  label: 'Rolling Red/Black (Experimental)',
  description: `Creates a new version of this server group, then incrementally resizes the new server group while disabling the same percentage in the previous server group.`,
  key: 'rollingredblack',
  providerRestricted: true,
  additionalFields: ['targetPercentages'],
  additionalFieldsTemplateUrl: require('./additionalFields.html'),
  initializationMethod: (command) => {
    if (!command.targetPercentages) {
      command.targetPercentages = [50, 100];
    }
  }
});
{'fraction_non_alphanumeric': 0.1010028653295129, 'fraction_numerical': 0.01002865329512894, 'mean_word_length': 6.276041666666667, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7397180', 'n_tokens_mistral': 367, 'n_tokens_neox': 346, 'n_words': 107}