Showing 6 of 6 total issues
Function executeWithBlueprint
has a Cognitive Complexity of 50 (exceeds 5 allowed). Consider refactoring. Open
protected function executeWithBlueprint(Blueprint $blueprint, InputInterface $input, OutputInterface $output) { $dryRun = $input->getOption('dryrun'); if ($dryRun) { $formatter = new \Symfony\Component\Console\Helper\FormatterHelper();
- Read upRead up
Method executeWithBlueprint
has 122 lines of code (exceeds 25 allowed). Consider refactoring. Open
protected function executeWithBlueprint(Blueprint $blueprint, InputInterface $input, OutputInterface $output) { $dryRun = $input->getOption('dryrun'); if ($dryRun) { $formatter = new \Symfony\Component\Console\Helper\FormatterHelper();
Method configure
has 46 lines of code (exceeds 25 allowed). Consider refactoring. Open
protected function configure() { $this ->setName('blueprint:deploy') ->setAliases(['deploy'])
Similar blocks of code found in 3 locations. Consider refactoring. Open
case 'CREATE_FAILED': if ($questionHelper->ask($input, $output, new ConfirmationQuestion('Stack is in CREATE_FAILED state. Do you want to delete it first? [Y/n]'))) { $output->writeln('Deleting failed stack ' . $stackName); $stack->delete(); $observer = new Observer($stack, $stackFactory, $output);
- Read upRead up
Similar blocks of code found in 3 locations. Consider refactoring. Open
case 'UPDATE_ROLLBACK_FAILED': if ($questionHelper->ask($input, $output, new ConfirmationQuestion('Stack is in UPDATE_ROLLBACK_FAILED state. Do you want to continue the update rollback and deploy then? [Y/n]'))) { $output->writeln('Continuing update rollback for ' . $stackName); $stack->continueUpdateRollback(); $observer = new Observer($stack, $stackFactory, $output);
- Read upRead up
Similar blocks of code found in 3 locations. Consider refactoring. Open
case 'UPDATE_IN_PROGRESS': if ($questionHelper->ask($input, $output, new ConfirmationQuestion('Stack is in UPDATE_IN_PROGRESS state. Do you want to cancel the current update and deploy then? [Y/n]'))) { $output->writeln('Cancelling update for ' . $stackName); $stack->cancelUpdate(); $observer = new Observer($stack, $stackFactory, $output);
- Read upRead up