Skip to content

Commit

Permalink
Update known dunder methods for Python 3.13 (#14146)
Browse files Browse the repository at this point in the history
## Summary

Closes: #14145
  • Loading branch information
dhruvmanila authored Nov 7, 2024
1 parent cb003eb commit 5b500b8
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions crates/ruff_linter/src/rules/pylint/helpers.rs
Original file line number Diff line number Diff line change
Expand Up @@ -265,6 +265,7 @@ pub(super) fn is_known_dunder_method(method: &str) -> bool {
| "__reduce__"
| "__reduce_ex__"
| "__release_buffer__"
| "__replace__"
| "__repr__"
| "__reversed__"
| "__rfloordiv__"
Expand Down Expand Up @@ -297,6 +298,8 @@ pub(super) fn is_known_dunder_method(method: &str) -> bool {
| "__xor__"
// Overridable sunder names from the `Enum` class.
// See: https://docs.python.org/3/library/enum.html#supported-sunder-names
| "_add_alias_"
| "_add_value_alias_"
| "_name_"
| "_value_"
| "_missing_"
Expand Down

0 comments on commit 5b500b8

Please sign in to comment.