Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Add row_stack to NumPy 2.0 migration rule #10646

Merged
merged 1 commit into from
Mar 28, 2024

Conversation

mtsokol
Copy link
Contributor

@mtsokol mtsokol commented Mar 28, 2024

Hi!

I left out one of the functions in the migration rule which became deprecated/removed in NumPy 2.0 (numpy/numpy#26032 (comment)).

cc @anntzer

@mtsokol mtsokol force-pushed the row_stack-numpy-rule branch 2 times, most recently from b0845e5 to 47bc199 Compare March 28, 2024 10:14
Copy link
Contributor

ruff-ecosystem results

Linter (stable)

✅ ecosystem check detected no linter changes.

Linter (preview)

ℹ️ ecosystem check detected linter changes. (+11 -36 violations, +0 -0 fixes in 1 projects; 43 projects unchanged)

pandas-dev/pandas (+11 -36 violations, +0 -0 fixes)

ruff check --no-cache --exit-zero --ignore RUF9 --output-format concise --preview

+ pandas/tests/frame/methods/test_quantile.py:119:9: PLR6301 Method `test_axis_numeric_only_true` could be a function, class method, or static method
- pandas/tests/frame/methods/test_quantile.py:121:9: PLR6301 Method `test_axis_numeric_only_true` could be a function, class method, or static method
+ pandas/tests/frame/methods/test_quantile.py:133:9: PLR6301 Method `test_quantile_date_range` could be a function, class method, or static method
- pandas/tests/frame/methods/test_quantile.py:135:9: PLR6301 Method `test_quantile_date_range` could be a function, class method, or static method
+ pandas/tests/frame/methods/test_quantile.py:149:9: PLR6301 Method `test_quantile_axis_mixed` could be a function, class method, or static method
- pandas/tests/frame/methods/test_quantile.py:151:9: PLR6301 Method `test_quantile_axis_mixed` could be a function, class method, or static method
+ pandas/tests/frame/methods/test_quantile.py:173:9: PLR6301 Method `test_quantile_axis_parameter` could be a function, class method, or static method
- pandas/tests/frame/methods/test_quantile.py:175:9: PLR6301 Method `test_quantile_axis_parameter` could be a function, class method, or static method
+ pandas/tests/frame/methods/test_quantile.py:211:9: PLR6301 Method `test_quantile_interpolation` could be a function, class method, or static method
- pandas/tests/frame/methods/test_quantile.py:213:9: PLR6301 Method `test_quantile_interpolation` could be a function, class method, or static method
+ pandas/tests/frame/methods/test_quantile.py:221:9: F821 Undefined name `ex`
- pandas/tests/frame/methods/test_quantile.py:22:1: PLR0904 Too many public methods (29 > 20)
- pandas/tests/frame/methods/test_quantile.py:270:9: PLR6301 Method `test_quantile_interpolation_datetime` could be a function, class method, or static method
- pandas/tests/frame/methods/test_quantile.py:278:9: PLR6301 Method `test_quantile_interpolation_int` could be a function, class method, or static method
- pandas/tests/frame/methods/test_quantile.py:291:9: PLR6301 Method `test_quantile_multi` could be a function, class method, or static method
- pandas/tests/frame/methods/test_quantile.py:304:9: PLR6301 Method `test_quantile_multi_axis_1` could be a function, class method, or static method
- pandas/tests/frame/methods/test_quantile.py:317:9: PLR6301 Method `test_quantile_multi_empty` could be a function, class method, or static method
- pandas/tests/frame/methods/test_quantile.py:327:9: PLR6301 Method `test_quantile_datetime` could be a function, class method, or static method
- pandas/tests/frame/methods/test_quantile.py:389:9: PLR6301 Method `test_quantile_dt64_empty` could be a function, class method, or static method
... 29 additional changes omitted for rule PLR6301

Changes by rule (3 rules affected)

code total + violation - violation + fix - fix
PLR6301 45 10 35 0 0
F821 1 1 0 0 0
PLR0904 1 0 1 0 0

@charliermarsh charliermarsh added the rule Implementing or modifying a lint rule label Mar 28, 2024
@charliermarsh charliermarsh merged commit a0263ab into astral-sh:main Mar 28, 2024
17 checks passed
@charliermarsh
Copy link
Member

Thanks!

@mtsokol mtsokol deleted the row_stack-numpy-rule branch March 28, 2024 13:56
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
rule Implementing or modifying a lint rule
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants