mirror of
https://github.com/astral-sh/ruff.git
synced 2025-08-03 10:23:11 +00:00
Update trapz
and in1d
deprecation for NPY201 (#11948)
This commit is contained in:
parent
3ab7a8da73
commit
9fd84e63bc
1 changed files with 16 additions and 0 deletions
|
@ -306,6 +306,14 @@ pub(crate) fn numpy_2_0_deprecation(checker: &mut Checker, expr: &Expr) {
|
|||
guideline: Some("Use the `np.errstate` context manager instead."),
|
||||
},
|
||||
}),
|
||||
["numpy", "in1d"] => Some(Replacement {
|
||||
existing: "in1d",
|
||||
details: Details::AutoImport {
|
||||
path: "numpy",
|
||||
name: "isin",
|
||||
compatibility: Compatibility::BackwardsCompatible,
|
||||
},
|
||||
}),
|
||||
["numpy", "INF"] => Some(Replacement {
|
||||
existing: "INF",
|
||||
details: Details::AutoImport {
|
||||
|
@ -536,6 +544,14 @@ pub(crate) fn numpy_2_0_deprecation(checker: &mut Checker, expr: &Expr) {
|
|||
compatibility: Compatibility::BackwardsCompatible,
|
||||
},
|
||||
}),
|
||||
["numpy", "trapz"] => Some(Replacement {
|
||||
existing: "trapz",
|
||||
details: Details::AutoImport {
|
||||
path: "numpy",
|
||||
name: "trapezoid",
|
||||
compatibility: Compatibility::Breaking,
|
||||
},
|
||||
}),
|
||||
["numpy", "unicode_"] => Some(Replacement {
|
||||
existing: "unicode_",
|
||||
details: Details::AutoImport {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue