Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@ updates:
labels: [⬆️ Lock]
multi-ecosystem-group: lock
patterns: ["*"]
- package-ecosystem: pre-commit
directory: "/"
labels: [⬆️ Lock]
multi-ecosystem-group: lock
patterns: ["*"]
- package-ecosystem: uv
directory: "/"
labels: [⬆️ Lock]
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-drafter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,6 @@ jobs:
update_release_draft:
runs-on: ubuntu-slim
steps:
- uses: release-drafter/release-drafter@v6
- uses: release-drafter/release-drafter@v7
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
15 changes: 8 additions & 7 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ repos:
- id: check-useless-excludes

- repo: https://github.com/ComPWA/policy
rev: 0.8.7
rev: 0.8.9
hooks:
- id: check-dev-files
args:
Expand Down Expand Up @@ -59,7 +59,7 @@ repos:
metadata.vscode

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.15.2
rev: v0.15.10
hooks:
- id: ruff-check
args: [--fix]
Expand Down Expand Up @@ -106,14 +106,14 @@ repos:
- id: taplo-format

- repo: https://github.com/pappasam/toml-sort
rev: v0.24.3
rev: v0.24.4
hooks:
- id: toml-sort
args:
- --in-place

- repo: https://github.com/python-jsonschema/check-jsonschema
rev: 0.36.2
rev: 0.37.1
hooks:
- id: check-jsonschema
name: Check CITATION.cff
Expand All @@ -126,12 +126,13 @@ repos:
pass_filenames: false

- repo: https://github.com/streetsidesoftware/cspell-cli
rev: v9.7.0
rev: v10.0.0
hooks:
- id: cspell
language_version: 25.9.0

- repo: https://github.com/editorconfig-checker/editorconfig-checker.python
rev: 3.6.0
rev: 3.6.1
hooks:
- id: editorconfig-checker
name: editorconfig
Expand All @@ -152,6 +153,6 @@ repos:
types_or: [python, pyi, jupyter]

- repo: https://github.com/astral-sh/uv-pre-commit
rev: 0.10.5
rev: 0.11.6
hooks:
- id: uv-lock
4 changes: 2 additions & 2 deletions docs/analyticity/integration-algorithms.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -467,7 +467,7 @@
"\n",
"w.jslink((sliders[\"disable_limit\"], \"value\"), (sliders[\"limit\"], \"disabled\"))\n",
"sliders[\"algorithm_name\"].observe(on_algorithm_change, names=\"value\")\n",
"sliders[\"algorithm_name\"].value = \"romberg\" # ty:ignore[invalid-assignment] # trigger changes\n",
"sliders[\"algorithm_name\"].value = \"romberg\" # trigger changes\n",
"timer_box = cast(\"w.ValueWidget\", w.HTML())\n",
"ui = w.VBox([\n",
" tabs := w.Tab([\n",
Expand Down Expand Up @@ -766,7 +766,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.13.12"
"version": "3.13.13"
}
},
"nbformat": 4,
Expand Down
4 changes: 2 additions & 2 deletions src/ampform/dynamics/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ class EnergyDependentWidth(sp.Expr):
meson_radius: Any
phsp_factor: PhaseSpaceFactorProtocol = argument(
default=PhaseSpaceFactor, sympify=False
)
) # ty:ignore[invalid-assignment]
name: str | None = argument(default=None, kw_only=True, sympify=False)

def evaluate(self) -> sp.Expr:
Expand Down Expand Up @@ -93,7 +93,7 @@ def relativistic_breit_wigner_with_ff( # noqa: PLR0917
m_b,
angular_momentum,
meson_radius,
phsp_factor: PhaseSpaceFactorProtocol = PhaseSpaceFactor,
phsp_factor: PhaseSpaceFactorProtocol = PhaseSpaceFactor, # ty:ignore[invalid-parameter-default]
) -> sp.Expr:
"""Relativistic Breit–Wigner with `.FormFactor`.

Expand Down
4 changes: 2 additions & 2 deletions src/ampform/dynamics/builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ def __init__(
phsp_factor: PhaseSpaceFactorProtocol | None = None,
) -> None:
if phsp_factor is None:
phsp_factor = PhaseSpaceFactor
phsp_factor = PhaseSpaceFactor # ty:ignore[invalid-assignment]
self.phsp_factor = phsp_factor
self.energy_dependent_width = energy_dependent_width
self.form_factor = form_factor
Expand Down Expand Up @@ -211,7 +211,7 @@ def __create_form_factor(
angular_momentum=variable_pool.angular_momentum,
meson_radius=meson_radius,
)
parameter_defaults = {
parameter_defaults: dict[sp.Symbol, float | int] = {
meson_radius: 1,
}
return form_factor, parameter_defaults
Expand Down
6 changes: 3 additions & 3 deletions src/ampform/dynamics/kmatrix.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ def formulate( # noqa: D417
n_poles,
parametrize: bool = True,
return_t_hat: bool = False,
phsp_factor: PhaseSpaceFactorProtocol = PhaseSpaceFactor,
phsp_factor: PhaseSpaceFactorProtocol = PhaseSpaceFactor, # ty:ignore[invalid-parameter-default]
angular_momentum=0,
meson_radius=1,
**kwargs,
Expand Down Expand Up @@ -118,7 +118,7 @@ def parametrization( # noqa: PLR0917
pole_id,
angular_momentum=0,
meson_radius=1,
phsp_factor: PhaseSpaceFactorProtocol = PhaseSpaceFactor,
phsp_factor: PhaseSpaceFactorProtocol = PhaseSpaceFactor, # ty:ignore[invalid-parameter-default]
) -> sp.Expr:
def residue_function(pole_id, i) -> sp.Expr:
return residue_constant[pole_id, i] * sp.sqrt(
Expand Down Expand Up @@ -298,7 +298,7 @@ def formulate( # noqa: D417
n_poles,
parametrize: bool = True,
return_f_hat: bool = False,
phsp_factor: PhaseSpaceFactorProtocol = PhaseSpaceFactor,
phsp_factor: PhaseSpaceFactorProtocol = PhaseSpaceFactor, # ty:ignore[invalid-parameter-default]
angular_momentum=0,
meson_radius=1,
**kwargs,
Expand Down
4 changes: 2 additions & 2 deletions src/ampform/helicity/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -185,15 +185,15 @@ def rename_symbols(
for amp, expr in self.amplitudes.items()
},
parameter_defaults={
symbol_mapping.get(par, par): value
symbol_mapping.get(par, par): value # ty:ignore[no-matching-overload]
for par, value in self.parameter_defaults.items()
},
components={
name: expr.xreplace(symbol_mapping)
for name, expr in self.components.items()
},
kinematic_variables={
symbol_mapping.get(var, var): expr.xreplace(symbol_mapping)
symbol_mapping.get(var, var): expr.xreplace(symbol_mapping) # ty:ignore[no-matching-overload]
for var, expr in self.kinematic_variables.items()
},
)
Expand Down
2 changes: 1 addition & 1 deletion tests/helicity/test_helicity.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ def test_formulate(
def test_stable_final_state_ids(self, reaction: ReactionInfo):
builder: HelicityAmplitudeBuilder = get_builder(reaction)
assert builder.config.stable_final_state_ids is None
builder.config.stable_final_state_ids = (1, 2) # ty:ignore[invalid-assignment]
builder.config.stable_final_state_ids = (1, 2)
assert builder.config.stable_final_state_ids == {1, 2}

def test_scalar_initial_state(self, reaction: ReactionInfo):
Expand Down
4 changes: 2 additions & 2 deletions tests/sympy/decorator/test_helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,9 +53,9 @@ class MyExpr(sp.Expr):
with pytest.raises(
ValueError, match=r"^Expecting 3 positional arguments \(a, b, c\), but got 4$"
):
MyExpr(1, 2, 3, 4) # ty:ignore[too-many-positional-arguments]
MyExpr(1, 2, 3, 4)
with pytest.raises(ValueError, match=r"^Missing constructor arguments: c$"):
MyExpr(1, 2) # ty:ignore[missing-argument]
MyExpr(1, 2)
expr = MyExpr(1, 2, 3)
assert expr.args == (1, 2, 3)
expr = MyExpr(1, b=2, c=3)
Expand Down
Loading
Loading