From 91c0f30412b7058c5ad8bede8554045f99073294 Mon Sep 17 00:00:00 2001 From: Koichi ITO Date: Sat, 24 Aug 2024 17:07:07 +0900 Subject: [PATCH] Update Changelog --- CHANGELOG.md | 28 +++++++++++++++++++ ..._compact_blank_to_handle_select_present.md | 1 - ...action_filter_option_multiple_callbacks.md | 1 - ...ge_make_rails_where_equals_aware_of_not.md | 1 - ...methods_to_detect_offenses_on_dir_index.md | 1 - .../fix_error_rails_bulk_change_table.md | 1 - ..._error_rails_render_plain_text_constant.md | 1 - changelog/fix_error_rails_validation.md | 1 - ...rror_rails_where_not_no_second_argument.md | 1 - ...r_action_controller_flash_before_render.md | 1 - ..._false_positive_for_rails_compact_blank.md | 1 - ...ndant_presence_validation_on_belongs_to.md | 1 - ...ke_pluralization_grammar_aware_of_bytes.md | 1 - ...tyle_collection_compact_aware_of_params.md | 1 - changelog/fix_where_equals_error.md | 1 - .../new_add_new_rails_enum_syntax_cop.md | 1 - ..._rails_7_syntax_for_rails_enum_hash_cop.md | 1 - ..._7_syntax_for_rails_enum_uniqueness_cop.md | 1 - 18 files changed, 28 insertions(+), 17 deletions(-) delete mode 100644 changelog/change_compact_blank_to_handle_select_present.md delete mode 100644 changelog/change_ignored_skip_action_filter_option_multiple_callbacks.md delete mode 100644 changelog/change_make_rails_where_equals_aware_of_not.md delete mode 100644 changelog/change_rails_root_pathname_methods_to_detect_offenses_on_dir_index.md delete mode 100644 changelog/fix_error_rails_bulk_change_table.md delete mode 100644 changelog/fix_error_rails_render_plain_text_constant.md delete mode 100644 changelog/fix_error_rails_validation.md delete mode 100644 changelog/fix_error_rails_where_not_no_second_argument.md delete mode 100644 changelog/fix_false_negatives_for_action_controller_flash_before_render.md delete mode 100644 changelog/fix_false_positive_for_rails_compact_blank.md delete mode 100644 changelog/fix_false_positive_for_rails_redundant_presence_validation_on_belongs_to.md delete mode 100644 changelog/fix_make_pluralization_grammar_aware_of_bytes.md delete mode 100644 changelog/fix_make_style_collection_compact_aware_of_params.md delete mode 100644 changelog/fix_where_equals_error.md delete mode 100644 changelog/new_add_new_rails_enum_syntax_cop.md delete mode 100644 changelog/new_support_rails_7_syntax_for_rails_enum_hash_cop.md delete mode 100644 changelog/new_support_rails_7_syntax_for_rails_enum_uniqueness_cop.md diff --git a/CHANGELOG.md b/CHANGELOG.md index 902e57e4e7..b960820286 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,6 +9,32 @@ ## master (unreleased) +### New features + +* [#1238](https://github.com/rubocop/rubocop-rails/issues/1238): Add new `Rails/EnumSyntax` cop. ([@maxprokopiev][], [@koic][]) +* [#1309](https://github.com/rubocop/rubocop-rails/pull/1309): Support Rails 7 syntax for `Rails/EnumHash` cop. ([@ytjmt][]) +* [#1298](https://github.com/rubocop/rubocop-rails/pull/1298): Support Rails 7 syntax for `Rails/EnumUniqueness` cop. ([@ytjmt][]) + +### Bug fixes + +* [#1335](https://github.com/rubocop/rubocop-rails/pull/1335): Fix an error for `Rails/BulkChangeTable` when the block for `change_table` is empty. ([@earlopain][]) +* [#1325](https://github.com/rubocop/rubocop-rails/pull/1325): Fix an error for `Rails/RenderPlainText` when the content type is passed as a constant. ([@earlopain][]) +* [#1337](https://github.com/rubocop/rubocop-rails/pull/1337): Fix an error for `Rails/Validation` when passing no arguments. ([@earlopain][]) +* [#1330](https://github.com/rubocop/rubocop-rails/pull/1330): Fix an error for `Rails/WhereNot` when using placeholder without second argument. ([@earlopain][]) +* [#1311](https://github.com/rubocop/rubocop-rails/pull/1311): Fix false negatives for `Rails/ActionControllerFlashBeforeRender` when using implicit render or rescue blocks. ([@tldn0718][]) +* [#1313](https://github.com/rubocop/rubocop-rails/pull/1313): Fix false positives for `Rails/CompactBlank` when using `collection.reject!`. ([@koic][]) +* [#1319](https://github.com/rubocop/rubocop-rails/issues/1319): Fix a false positive for `Rails/RedundantPresenceValidationOnBelongsTo` when removing `presence` would leave other non-validation options like `allow_blank` without validations. ([@earlopain][]) +* [#1306](https://github.com/rubocop/rubocop-rails/pull/1306): Make `Rails/PluralizationGrammar` aware of byte methods. ([@earlopain][]) +* [#1302](https://github.com/rubocop/rubocop-rails/pull/1302): Allow `params` receiver by default for `Style/CollectionMethods`. ([@koic][]) +* [#1321](https://github.com/rubocop/rubocop-rails/pull/1321): Fix an error for `Rails/WhereEquals` when the second argument is not yet typed (`where("foo = ?", )`). ([@earlopain][]) + +### Changes + +* [#1308](https://github.com/rubocop/rubocop-rails/issues/1308): Change `Rails/CompactBlank` to handle `select(&:present?)`. ([@fatkodima][]) +* [#1303](https://github.com/rubocop/rubocop-rails/pull/1303): Change `Rails/IgnoredSkipActionFilterOption` to handle multiple callbacks. ([@fatkodima][]) +* [#1199](https://github.com/rubocop/rubocop-rails/issues/1199): Make `Rails/WhereEquals` aware of `where.not(...)`. ([@earlopain][]) +* [#1003](https://github.com/rubocop/rubocop-rails/pull/1003): Change `Rails/RootPathnameMethods` to detect offenses on `Dir.[]`. ([@r7kamura][]) + ## 2.25.1 (2024-06-29) ### Bug fixes @@ -1098,3 +1124,5 @@ [@lukasfroehlich1]: https://github.com/lukasfroehlich1 [@ChaelCodes]: https://github.com/ChaelCodes [@fwolfst]: https://github.com/fwolfst +[@maxprokopiev]: https://github.com/maxprokopiev +[@ytjmt]: https://github.com/ytjmt diff --git a/changelog/change_compact_blank_to_handle_select_present.md b/changelog/change_compact_blank_to_handle_select_present.md deleted file mode 100644 index cec5b9b4f2..0000000000 --- a/changelog/change_compact_blank_to_handle_select_present.md +++ /dev/null @@ -1 +0,0 @@ -* [#1308](https://github.com/rubocop/rubocop-rails/issues/1308): Change `Rails/CompactBlank` to handle `select(&:present?)`. ([@fatkodima][]) diff --git a/changelog/change_ignored_skip_action_filter_option_multiple_callbacks.md b/changelog/change_ignored_skip_action_filter_option_multiple_callbacks.md deleted file mode 100644 index 8bbf59d754..0000000000 --- a/changelog/change_ignored_skip_action_filter_option_multiple_callbacks.md +++ /dev/null @@ -1 +0,0 @@ -* [#1303](https://github.com/rubocop/rubocop-rails/pull/1303): Change `Rails/IgnoredSkipActionFilterOption` to handle multiple callbacks. ([@fatkodima][]) diff --git a/changelog/change_make_rails_where_equals_aware_of_not.md b/changelog/change_make_rails_where_equals_aware_of_not.md deleted file mode 100644 index 1a61ab42f3..0000000000 --- a/changelog/change_make_rails_where_equals_aware_of_not.md +++ /dev/null @@ -1 +0,0 @@ -* [#1199](https://github.com/rubocop/rubocop-rails/issues/1199): Make `Rails/WhereEquals` aware of `where.not(...)`. ([@earlopain][]) diff --git a/changelog/change_rails_root_pathname_methods_to_detect_offenses_on_dir_index.md b/changelog/change_rails_root_pathname_methods_to_detect_offenses_on_dir_index.md deleted file mode 100644 index 30a32029f1..0000000000 --- a/changelog/change_rails_root_pathname_methods_to_detect_offenses_on_dir_index.md +++ /dev/null @@ -1 +0,0 @@ -* [#1003](https://github.com/rubocop/rubocop-rails/pull/1003): Change `Rails/RootPathnameMethods` to detect offenses on `Dir.[]`. ([@r7kamura][]) diff --git a/changelog/fix_error_rails_bulk_change_table.md b/changelog/fix_error_rails_bulk_change_table.md deleted file mode 100644 index 3b01fd4dbe..0000000000 --- a/changelog/fix_error_rails_bulk_change_table.md +++ /dev/null @@ -1 +0,0 @@ -* [#1335](https://github.com/rubocop/rubocop-rails/pull/1335): Fix an error for `Rails/BulkChangeTable` when the block for `change_table` is empty. ([@earlopain][]) diff --git a/changelog/fix_error_rails_render_plain_text_constant.md b/changelog/fix_error_rails_render_plain_text_constant.md deleted file mode 100644 index 0fbab1d458..0000000000 --- a/changelog/fix_error_rails_render_plain_text_constant.md +++ /dev/null @@ -1 +0,0 @@ -* [#1325](https://github.com/rubocop/rubocop-rails/pull/1325): Fix an error for `Rails/RenderPlainText` when the content type is passed as a constant. ([@earlopain][]) diff --git a/changelog/fix_error_rails_validation.md b/changelog/fix_error_rails_validation.md deleted file mode 100644 index 024d4bf8b9..0000000000 --- a/changelog/fix_error_rails_validation.md +++ /dev/null @@ -1 +0,0 @@ -* [#1337](https://github.com/rubocop/rubocop-rails/pull/1337): Fix an error for `Rails/Validation` when passing no arguments. ([@earlopain][]) diff --git a/changelog/fix_error_rails_where_not_no_second_argument.md b/changelog/fix_error_rails_where_not_no_second_argument.md deleted file mode 100644 index 437da24eb6..0000000000 --- a/changelog/fix_error_rails_where_not_no_second_argument.md +++ /dev/null @@ -1 +0,0 @@ -* [#1330](https://github.com/rubocop/rubocop-rails/pull/1330): Fix an error for `Rails/WhereNot` when using placeholder without second argument. ([@earlopain][]) diff --git a/changelog/fix_false_negatives_for_action_controller_flash_before_render.md b/changelog/fix_false_negatives_for_action_controller_flash_before_render.md deleted file mode 100644 index 6d253ae144..0000000000 --- a/changelog/fix_false_negatives_for_action_controller_flash_before_render.md +++ /dev/null @@ -1 +0,0 @@ -* [#1311](https://github.com/rubocop/rubocop-rails/pull/1311): Fix false negatives for `Rails/ActionControllerFlashBeforeRender` when using implicit render or rescue blocks. ([@tldn0718][]) diff --git a/changelog/fix_false_positive_for_rails_compact_blank.md b/changelog/fix_false_positive_for_rails_compact_blank.md deleted file mode 100644 index 9718f82438..0000000000 --- a/changelog/fix_false_positive_for_rails_compact_blank.md +++ /dev/null @@ -1 +0,0 @@ -* [#1313](https://github.com/rubocop/rubocop-rails/pull/1313): Fix false positives for `Rails/CompactBlank` when using `collection.reject!`. ([@koic][]) diff --git a/changelog/fix_false_positive_for_rails_redundant_presence_validation_on_belongs_to.md b/changelog/fix_false_positive_for_rails_redundant_presence_validation_on_belongs_to.md deleted file mode 100644 index 2af6991677..0000000000 --- a/changelog/fix_false_positive_for_rails_redundant_presence_validation_on_belongs_to.md +++ /dev/null @@ -1 +0,0 @@ -* [#1319](https://github.com/rubocop/rubocop-rails/issues/1319): Fix a false positive for `Rails/RedundantPresenceValidationOnBelongsTo` when removing `presence` would leave other non-validation options like `allow_blank` without validations. ([@earlopain][]) diff --git a/changelog/fix_make_pluralization_grammar_aware_of_bytes.md b/changelog/fix_make_pluralization_grammar_aware_of_bytes.md deleted file mode 100644 index 1c34bf1259..0000000000 --- a/changelog/fix_make_pluralization_grammar_aware_of_bytes.md +++ /dev/null @@ -1 +0,0 @@ -* [#1306](https://github.com/rubocop/rubocop-rails/pull/1306): Make `Rails/PluralizationGrammar` aware of byte methods. ([@earlopain][]) diff --git a/changelog/fix_make_style_collection_compact_aware_of_params.md b/changelog/fix_make_style_collection_compact_aware_of_params.md deleted file mode 100644 index f9e7223366..0000000000 --- a/changelog/fix_make_style_collection_compact_aware_of_params.md +++ /dev/null @@ -1 +0,0 @@ -* [#1302](https://github.com/rubocop/rubocop-rails/pull/1302): Allow `params` receiver by default for `Style/CollectionMethods`. ([@koic][]) diff --git a/changelog/fix_where_equals_error.md b/changelog/fix_where_equals_error.md deleted file mode 100644 index 2e1ccc7309..0000000000 --- a/changelog/fix_where_equals_error.md +++ /dev/null @@ -1 +0,0 @@ -* [#1321](https://github.com/rubocop/rubocop-rails/pull/1321): Fix an error for `Rails/WhereEquals` when the second argument is not yet typed (`where("foo = ?", )`). ([@earlopain][]) diff --git a/changelog/new_add_new_rails_enum_syntax_cop.md b/changelog/new_add_new_rails_enum_syntax_cop.md deleted file mode 100644 index 19909d3b66..0000000000 --- a/changelog/new_add_new_rails_enum_syntax_cop.md +++ /dev/null @@ -1 +0,0 @@ -* [#1238](https://github.com/rubocop/rubocop-rails/issues/1238): Add new `Rails/EnumSyntax` cop. ([@maxprokopiev][], [@koic][]) diff --git a/changelog/new_support_rails_7_syntax_for_rails_enum_hash_cop.md b/changelog/new_support_rails_7_syntax_for_rails_enum_hash_cop.md deleted file mode 100644 index 355a76dd25..0000000000 --- a/changelog/new_support_rails_7_syntax_for_rails_enum_hash_cop.md +++ /dev/null @@ -1 +0,0 @@ -* [#1309](https://github.com/rubocop/rubocop-rails/pull/1309): Support Rails 7 syntax for `Rails/EnumHash` cop. ([@ytjmt][]) diff --git a/changelog/new_support_rails_7_syntax_for_rails_enum_uniqueness_cop.md b/changelog/new_support_rails_7_syntax_for_rails_enum_uniqueness_cop.md deleted file mode 100644 index a1707d6c81..0000000000 --- a/changelog/new_support_rails_7_syntax_for_rails_enum_uniqueness_cop.md +++ /dev/null @@ -1 +0,0 @@ -* [#1298](https://github.com/rubocop/rubocop-rails/pull/1298): Support Rails 7 syntax for `Rails/EnumUniqueness` cop. ([@ytjmt][])