Closed roman-dubrovsky closed 1 year ago
Faced with this error
Infinite loop detected in /Users/romandubrovsky/Work/dealmaker-rails/spec/policies/deal_policy_spec.rb and caused by Layout/ArrayAlignmentExtended -> Layout/FirstArrayElementIndentation /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/runner.rb:304:in `check_for_infinite_loop' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/runner.rb:287:in `block in iterate_until_no_changes' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/runner.rb:286:in `loop' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/runner.rb:286:in `iterate_until_no_changes' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/runner.rb:255:in `do_inspection_loop' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/runner.rb:132:in `block in file_offenses' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/runner.rb:157:in `file_offense_cache' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/runner.rb:131:in `file_offenses' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/runner.rb:122:in `process_file' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/runner.rb:101:in `block in each_inspected_file' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/runner.rb:100:in `each' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/runner.rb:100:in `reduce' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/runner.rb:100:in `each_inspected_file' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/runner.rb:86:in `inspect_files' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/runner.rb:47:in `run' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/cli/command/execute_runner.rb:26:in `block in execute_runner' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/cli/command/execute_runner.rb:52:in `with_redirect' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/cli/command/execute_runner.rb:25:in `execute_runner' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/cli/command/execute_runner.rb:17:in `run' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/cli/command.rb:11:in `run' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/cli/environment.rb:18:in `run' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/cli.rb:65:in `run_command' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/cli.rb:72:in `execute_runners' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/lib/rubocop/cli.rb:41:in `run' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/exe/rubocop:13:in `block in <top (required)>' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/2.7.0/benchmark.rb:308:in `realtime' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/rubocop-1.10.0/exe/rubocop:12:in `<top (required)>' /Users/romandubrovsky/.rbenv/versions/2.7.2/bin/rubocop:23:in `load' /Users/romandubrovsky/.rbenv/versions/2.7.2/bin/rubocop:23:in `<top (required)>' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/2.7.0/bundler/cli/exec.rb:63:in `load' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/2.7.0/bundler/cli/exec.rb:63:in `kernel_load' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/2.7.0/bundler/cli/exec.rb:28:in `run' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/2.7.0/bundler/cli.rb:476:in `exec' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/2.7.0/bundler/vendor/thor/lib/thor/command.rb:27:in `run' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/2.7.0/bundler/vendor/thor/lib/thor/invocation.rb:127:in `invoke_command' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/2.7.0/bundler/vendor/thor/lib/thor.rb:399:in `dispatch' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/2.7.0/bundler/cli.rb:30:in `dispatch' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/2.7.0/bundler/vendor/thor/lib/thor/base.rb:476:in `start' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/2.7.0/bundler/cli.rb:24:in `start' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/bundler-2.1.4/libexec/bundle:46:in `block in <top (required)>' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/2.7.0/bundler/friendly_errors.rb:123:in `with_friendly_errors' /Users/romandubrovsky/.rbenv/versions/2.7.2/lib/ruby/gems/2.7.0/gems/bundler-2.1.4/libexec/bundle:34:in `<top (required)>' /Users/romandubrovsky/.rbenv/versions/2.7.2/bin/bundle:23:in `load' /Users/romandubrovsky/.rbenv/versions/2.7.2/bin/bundle:23:in `<main>'
Seems like we have it in this line of code
it 'returns himself and his investor' do is_expected.to match_array([ unaffiliated_investor, broker_investor ]) end
For fixing , just need to setup this rule
Layout/FirstArrayElementIndentation: EnforcedStyle: consistent
Faced with this error
Seems like we have it in this line of code
For fixing , just need to setup this rule