Skip to content

Commit 22957e3

Browse files
authored
Merge pull request #383 from light-curve/numpy-v2
Numpy v2 support
2 parents 006802c + d6d7f9b commit 22957e3

File tree

3 files changed

+16
-12
lines changed

3 files changed

+16
-12
lines changed

CHANGELOG.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
2525

2626
### Fixed
2727

28-
--
28+
- Small bug fix in MagnitudeNNotDetBeforeFd for numpy v2.0
2929

3030
### Security
3131

light-curve/light_curve/light_curve_py/features/magnitude_n_not_det_before_fd.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ class MagnitudeNNotDetBeforeFd(BaseSingleBandFeature):
2929
P. Sánchez-Sáez et al 2021, [DOI:10.3847/1538-3881/abd5c1](https://doi.org/10.3847/1538-3881/abd5c1)
3030
"""
3131

32-
sigma_non_detection: float = dataclass_field(default=np.Inf, kw_only=True)
32+
sigma_non_detection: float = dataclass_field(default=np.inf, kw_only=True)
3333
strictly_fainter: bool = dataclass_field(default=False, kw_only=True)
3434

3535
def _eval_single_band(self, t, m, sigma=None):

light-curve/pyproject.toml

Lines changed: 14 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -108,15 +108,6 @@ exclude = '''
108108

109109
[tool.ruff]
110110
line-length = 120
111-
select = [
112-
# Pyflakes
113-
"F",
114-
# Pycodestyle
115-
"E",
116-
"W",
117-
# isort
118-
"I001"
119-
]
120111
exclude = [
121112
"docs",
122113
"dist",
@@ -132,7 +123,20 @@ exclude = [
132123
]
133124
target-version = "py38"
134125

135-
[tool.ruff.per-file-ignores]
126+
[tool.ruff.lint]
127+
select = [
128+
# Pyflakes
129+
"F",
130+
# Pycodestyle
131+
"E",
132+
"W",
133+
# isort
134+
"I001",
135+
# Numpy v2.0 compatibility
136+
"NPY201",
137+
]
138+
139+
[tool.ruff.lint.per-file-ignores]
136140
# Unused and star imports
137141
"light_curve/__init__.py" = ["F401", "F403", "I001"]
138142
"light_curve/light_curve_ext.py" = ["F403", "F405"]

0 commit comments

Comments
 (0)