Skip to content

Commit 64a7015

Browse files
authored
TYP: mypy upgrade (#187) (#1108)
Co-authored-by: Mike Lync <[email protected]>
1 parent 1d56753 commit 64a7015

File tree

17 files changed

+19
-19
lines changed

17 files changed

+19
-19
lines changed

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ dev = [
4040
"coverage>=7.6.1,<8.0",
4141
# style/linting
4242
"ruff>=0.6.3,<1.0",
43-
"mypy>=1.13,<1.18",
43+
"mypy>=1.13,<1.20",
4444
"pandas-stubs>2.0,<3.0",
4545
# doc building
4646
"sphinx>=8.0,<8.2",

python/rateslib/data/fixings.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2431,7 +2431,7 @@ def _maybe_get_rate_series_from_curve(
24312431
return rate_series
24322432

24332433

2434-
def _leg_fixings_to_list(rate_fixings: LegFixings, n_periods: int) -> list[PeriodFixings]: # type: ignore[type-var]
2434+
def _leg_fixings_to_list(rate_fixings: LegFixings, n_periods: int) -> list[PeriodFixings]:
24352435
"""Perform a conversion of 'LegRateFixings' into a list of PeriodFixings."""
24362436
if isinstance(rate_fixings, NoInput):
24372437
# NoInput is converted to a list of NoInputs

python/rateslib/instruments/bonds/float_rate_note.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,7 @@ def __init__(
191191
# rate params
192192
float_spread: DualTypes_ = NoInput(0),
193193
spread_compound_method: str_ = NoInput(0),
194-
rate_fixings: LegFixings = NoInput(0), # type: ignore[type-var]
194+
rate_fixings: LegFixings = NoInput(0),
195195
fixing_method: str_ = NoInput(0),
196196
method_param: int_ = NoInput(0),
197197
fixing_frequency: Frequency | str_ = NoInput(0),

python/rateslib/instruments/bonds/index_fixed_rate_bond.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,7 @@ def __init__(
198198
index_base: DualTypes_ = NoInput(0),
199199
index_lag: int_ = NoInput(0),
200200
index_method: IndexMethod | str_ = NoInput(0),
201-
index_fixings: LegFixings = NoInput(0), # type: ignore[type-var]
201+
index_fixings: LegFixings = NoInput(0),
202202
# rate parameters
203203
fixed_rate: DualTypes_ = NoInput(0),
204204
# meta parameters

python/rateslib/instruments/fra.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -309,7 +309,7 @@ def __init__(
309309
notional: DualTypes_ = NoInput(0),
310310
# rate parameters
311311
fixed_rate: DualTypes_ = NoInput(0),
312-
leg2_rate_fixings: FixingsRates_ = NoInput(0), # type: ignore[type-var]
312+
leg2_rate_fixings: FixingsRates_ = NoInput(0),
313313
leg2_method_param: int_ = NoInput(0),
314314
leg2_fixing_frequency: Frequency | str_ = NoInput(0),
315315
leg2_fixing_series: FloatRateSeries | str_ = NoInput(0),

python/rateslib/instruments/iirs.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -308,12 +308,12 @@ def __init__(
308308
index_base: DualTypes_ = NoInput(0),
309309
index_lag: int_ = NoInput(0),
310310
index_method: IndexMethod | str_ = NoInput(0),
311-
index_fixings: LegFixings = NoInput(0), # type: ignore[type-var]
311+
index_fixings: LegFixings = NoInput(0),
312312
# rate params
313313
fixed_rate: DualTypes_ = NoInput(0),
314314
leg2_float_spread: DualTypes_ = NoInput(0),
315315
leg2_spread_compound_method: str_ = NoInput(0),
316-
leg2_rate_fixings: FixingsRates_ = NoInput(0), # type: ignore[type-var]
316+
leg2_rate_fixings: FixingsRates_ = NoInput(0),
317317
leg2_fixing_method: str_ = NoInput(0),
318318
leg2_method_param: int_ = NoInput(0),
319319
# meta params

python/rateslib/instruments/irs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -294,7 +294,7 @@ def __init__(
294294
fixed_rate: DualTypes_ = NoInput(0),
295295
leg2_float_spread: DualTypes_ = NoInput(0),
296296
leg2_spread_compound_method: str_ = NoInput(0),
297-
leg2_rate_fixings: FixingsRates_ = NoInput(0), # type: ignore[type-var]
297+
leg2_rate_fixings: FixingsRates_ = NoInput(0),
298298
leg2_fixing_method: str_ = NoInput(0),
299299
leg2_method_param: int_ = NoInput(0),
300300
leg2_fixing_frequency: Frequency | str_ = NoInput(0),

python/rateslib/instruments/ndf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,7 @@ def __init__(
223223
eom: bool_ = NoInput(0),
224224
# rate
225225
fx_rate: DualTypes_ = NoInput(0),
226-
fx_fixings: PeriodFixings = NoInput(0), # type: ignore[type-var]
226+
fx_fixings: PeriodFixings = NoInput(0),
227227
leg2_fx_fixings: PeriodFixings = NoInput(0),
228228
reversed: bool = False, # noqa: A002
229229
leg2_reversed: bool = False,

python/rateslib/instruments/sbs.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -306,7 +306,7 @@ def __init__(
306306
# rate parameters
307307
float_spread: DualTypes_ = NoInput(0),
308308
spread_compound_method: str_ = NoInput(0),
309-
rate_fixings: LegFixings = NoInput(0), # type: ignore[type-var]
309+
rate_fixings: LegFixings = NoInput(0),
310310
fixing_method: str_ = NoInput(0),
311311
method_param: int_ = NoInput(0),
312312
fixing_frequency: Frequency | str_ = NoInput(0),

python/rateslib/instruments/stir_future.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,7 @@ def __init__(
314314
price: DualTypes_ = NoInput(0),
315315
leg2_float_spread: DualTypes_ = NoInput(0),
316316
leg2_spread_compound_method: str_ = NoInput(0),
317-
leg2_rate_fixings: FixingsRates_ = NoInput(0), # type: ignore[type-var]
317+
leg2_rate_fixings: FixingsRates_ = NoInput(0),
318318
leg2_fixing_method: str_ = NoInput(0),
319319
leg2_method_param: int_ = NoInput(0),
320320
leg2_fixing_frequency: Frequency | str_ = NoInput(0),

0 commit comments

Comments
 (0)