rubocop 1.77.0 → 1.80.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (84) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +1 -3
  3. data/config/default.yml +36 -20
  4. data/exe/rubocop +1 -8
  5. data/lib/rubocop/cli.rb +17 -1
  6. data/lib/rubocop/config_loader.rb +1 -38
  7. data/lib/rubocop/cop/correctors/alignment_corrector.rb +6 -3
  8. data/lib/rubocop/cop/correctors/for_to_each_corrector.rb +7 -2
  9. data/lib/rubocop/cop/internal_affairs/example_description.rb +1 -1
  10. data/lib/rubocop/cop/internal_affairs/node_type_group.rb +3 -2
  11. data/lib/rubocop/cop/internal_affairs/useless_restrict_on_send.rb +1 -1
  12. data/lib/rubocop/cop/layout/empty_lines_after_module_inclusion.rb +101 -0
  13. data/lib/rubocop/cop/layout/empty_lines_around_arguments.rb +8 -29
  14. data/lib/rubocop/cop/layout/empty_lines_around_class_body.rb +1 -1
  15. data/lib/rubocop/cop/layout/multiline_operation_indentation.rb +2 -0
  16. data/lib/rubocop/cop/layout/space_around_keyword.rb +6 -1
  17. data/lib/rubocop/cop/layout/space_around_operators.rb +8 -0
  18. data/lib/rubocop/cop/lint/duplicate_methods.rb +25 -4
  19. data/lib/rubocop/cop/lint/duplicate_regexp_character_class_element.rb +5 -42
  20. data/lib/rubocop/cop/lint/literal_as_condition.rb +15 -1
  21. data/lib/rubocop/cop/lint/missing_cop_enable_directive.rb +1 -2
  22. data/lib/rubocop/cop/lint/numeric_operation_with_constant_result.rb +1 -0
  23. data/lib/rubocop/cop/lint/redundant_safe_navigation.rb +101 -2
  24. data/lib/rubocop/cop/lint/redundant_type_conversion.rb +4 -4
  25. data/lib/rubocop/cop/lint/require_range_parentheses.rb +1 -1
  26. data/lib/rubocop/cop/lint/rescue_type.rb +1 -1
  27. data/lib/rubocop/cop/lint/self_assignment.rb +5 -4
  28. data/lib/rubocop/cop/lint/uri_escape_unescape.rb +2 -0
  29. data/lib/rubocop/cop/lint/useless_numeric_operation.rb +1 -0
  30. data/lib/rubocop/cop/lint/utils/nil_receiver_checker.rb +121 -0
  31. data/lib/rubocop/cop/mixin/end_keyword_alignment.rb +1 -7
  32. data/lib/rubocop/cop/naming/method_name.rb +127 -13
  33. data/lib/rubocop/cop/naming/predicate_method.rb +30 -4
  34. data/lib/rubocop/cop/security/eval.rb +2 -1
  35. data/lib/rubocop/cop/security/open.rb +1 -0
  36. data/lib/rubocop/cop/style/access_modifier_declarations.rb +1 -1
  37. data/lib/rubocop/cop/style/accessor_grouping.rb +13 -1
  38. data/lib/rubocop/cop/style/arguments_forwarding.rb +11 -17
  39. data/lib/rubocop/cop/style/array_intersect.rb +98 -34
  40. data/lib/rubocop/cop/style/bitwise_predicate.rb +8 -1
  41. data/lib/rubocop/cop/style/block_delimiters.rb +1 -1
  42. data/lib/rubocop/cop/style/conditional_assignment.rb +1 -1
  43. data/lib/rubocop/cop/style/dig_chain.rb +1 -1
  44. data/lib/rubocop/cop/style/exponential_notation.rb +1 -0
  45. data/lib/rubocop/cop/style/hash_conversion.rb +8 -9
  46. data/lib/rubocop/cop/style/infinite_loop.rb +1 -1
  47. data/lib/rubocop/cop/style/inverse_methods.rb +1 -1
  48. data/lib/rubocop/cop/style/it_assignment.rb +69 -12
  49. data/lib/rubocop/cop/style/it_block_parameter.rb +3 -1
  50. data/lib/rubocop/cop/style/map_to_hash.rb +1 -3
  51. data/lib/rubocop/cop/style/map_to_set.rb +1 -3
  52. data/lib/rubocop/cop/style/method_call_with_args_parentheses/omit_parentheses.rb +2 -4
  53. data/lib/rubocop/cop/style/method_call_with_args_parentheses.rb +16 -0
  54. data/lib/rubocop/cop/style/parallel_assignment.rb +32 -20
  55. data/lib/rubocop/cop/style/redundant_begin.rb +34 -0
  56. data/lib/rubocop/cop/style/redundant_condition.rb +1 -1
  57. data/lib/rubocop/cop/style/redundant_fetch_block.rb +1 -9
  58. data/lib/rubocop/cop/style/redundant_freeze.rb +1 -1
  59. data/lib/rubocop/cop/style/redundant_line_continuation.rb +1 -1
  60. data/lib/rubocop/cop/style/redundant_parentheses.rb +28 -11
  61. data/lib/rubocop/cop/style/safe_navigation.rb +20 -1
  62. data/lib/rubocop/cop/style/single_line_methods.rb +7 -4
  63. data/lib/rubocop/cop/style/sole_nested_conditional.rb +30 -1
  64. data/lib/rubocop/cop/style/stabby_lambda_parentheses.rb +1 -1
  65. data/lib/rubocop/cop/style/string_concatenation.rb +17 -13
  66. data/lib/rubocop/cop/style/symbol_array.rb +1 -1
  67. data/lib/rubocop/cop/variable_force/variable.rb +1 -1
  68. data/lib/rubocop/cop/variable_force.rb +25 -8
  69. data/lib/rubocop/cops_documentation_generator.rb +1 -0
  70. data/lib/rubocop/formatter/disabled_config_formatter.rb +18 -5
  71. data/lib/rubocop/formatter/markdown_formatter.rb +1 -0
  72. data/lib/rubocop/formatter/pacman_formatter.rb +1 -0
  73. data/lib/rubocop/lsp/routes.rb +35 -6
  74. data/lib/rubocop/pending_cops_reporter.rb +56 -0
  75. data/lib/rubocop/result_cache.rb +14 -12
  76. data/lib/rubocop/runner.rb +6 -4
  77. data/lib/rubocop/server/cache.rb +4 -2
  78. data/lib/rubocop/server/client_command/base.rb +10 -0
  79. data/lib/rubocop/server/client_command/exec.rb +2 -1
  80. data/lib/rubocop/server/client_command/start.rb +11 -1
  81. data/lib/rubocop/target_finder.rb +9 -9
  82. data/lib/rubocop/version.rb +1 -1
  83. data/lib/rubocop.rb +3 -0
  84. metadata +9 -6
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rubocop
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.77.0
4
+ version: 1.80.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Bozhidar Batsov
@@ -9,7 +9,7 @@ authors:
9
9
  - Yuji Nakayama
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2025-06-20 00:00:00.000000000 Z
12
+ date: 2025-09-03 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: json
@@ -127,7 +127,7 @@ dependencies:
127
127
  requirements:
128
128
  - - ">="
129
129
  - !ruby/object:Gem::Version
130
- version: 1.45.1
130
+ version: 1.46.0
131
131
  - - "<"
132
132
  - !ruby/object:Gem::Version
133
133
  version: '2.0'
@@ -137,7 +137,7 @@ dependencies:
137
137
  requirements:
138
138
  - - ">="
139
139
  - !ruby/object:Gem::Version
140
- version: 1.45.1
140
+ version: 1.46.0
141
141
  - - "<"
142
142
  - !ruby/object:Gem::Version
143
143
  version: '2.0'
@@ -342,6 +342,7 @@ files:
342
342
  - lib/rubocop/cop/layout/empty_line_after_multiline_condition.rb
343
343
  - lib/rubocop/cop/layout/empty_line_between_defs.rb
344
344
  - lib/rubocop/cop/layout/empty_lines.rb
345
+ - lib/rubocop/cop/layout/empty_lines_after_module_inclusion.rb
345
346
  - lib/rubocop/cop/layout/empty_lines_around_access_modifier.rb
346
347
  - lib/rubocop/cop/layout/empty_lines_around_arguments.rb
347
348
  - lib/rubocop/cop/layout/empty_lines_around_attribute_accessor.rb
@@ -572,6 +573,7 @@ files:
572
573
  - lib/rubocop/cop/lint/useless_ruby2_keywords.rb
573
574
  - lib/rubocop/cop/lint/useless_setter_call.rb
574
575
  - lib/rubocop/cop/lint/useless_times.rb
576
+ - lib/rubocop/cop/lint/utils/nil_receiver_checker.rb
575
577
  - lib/rubocop/cop/lint/void.rb
576
578
  - lib/rubocop/cop/message_annotator.rb
577
579
  - lib/rubocop/cop/metrics/abc_size.rb
@@ -1040,6 +1042,7 @@ files:
1040
1042
  - lib/rubocop/name_similarity.rb
1041
1043
  - lib/rubocop/options.rb
1042
1044
  - lib/rubocop/path_util.rb
1045
+ - lib/rubocop/pending_cops_reporter.rb
1043
1046
  - lib/rubocop/platform.rb
1044
1047
  - lib/rubocop/plugin.rb
1045
1048
  - lib/rubocop/plugin/configuration_integrator.rb
@@ -1087,9 +1090,9 @@ licenses:
1087
1090
  - MIT
1088
1091
  metadata:
1089
1092
  homepage_uri: https://rubocop.org/
1090
- changelog_uri: https://github.com/rubocop/rubocop/releases/tag/v1.77.0
1093
+ changelog_uri: https://github.com/rubocop/rubocop/releases/tag/v1.80.2
1091
1094
  source_code_uri: https://github.com/rubocop/rubocop/
1092
- documentation_uri: https://docs.rubocop.org/rubocop/1.77/
1095
+ documentation_uri: https://docs.rubocop.org/rubocop/1.80/
1093
1096
  bug_tracker_uri: https://github.com/rubocop/rubocop/issues
1094
1097
  rubygems_mfa_required: 'true'
1095
1098
  rdoc_options: []