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
6 changes: 3 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ repos:
hooks:
- id: reuse
- repo: https://github.com/codespell-project/codespell
rev: v2.4.2
rev: v2.4.3
hooks:
- id: codespell
- repo: https://github.com/adamchainz/blacken-docs
Expand All @@ -28,7 +28,7 @@ repos:
- id: blacken-docs
args: [-l 100]
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.15.21
rev: v0.17.1
hooks:
- id: ruff
args: [--fix, --show-fixes]
Expand Down Expand Up @@ -76,7 +76,7 @@ repos:
- id: trailing-whitespace
exclude: \.svg$
- repo: https://github.com/editorconfig-checker/editorconfig-checker.python
rev: "3.6.1"
rev: "3.11.1"
hooks:
- id: editorconfig-checker
alias: ec
5 changes: 3 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ build-backend = "flit_core.buildapi"
requires = ["flit_core >=3.2,<5"]

[project]
authors = [{name = "Kevin Meagher"}]
authors = [{ name = "Kevin Meagher" }]
classifiers = [
'Development Status :: 4 - Beta',
'Intended Audience :: Science/Research',
Expand All @@ -26,7 +26,7 @@ classifiers = [
dependencies = ["numpy>=2", "scipy"]
dynamic = ["version", "description"]
keywords = ["python", "science", "astronomy", "astrophysics", "IceCube", "neutrino", "simulation"]
license = {file = "LICENSES/BSD-2-Clause.txt"}
license = { file = "LICENSES/BSD-2-Clause.txt" }
name = "simweights"
readme = "README.rst"
requires-python = "~=3.10"
Expand Down Expand Up @@ -83,6 +83,7 @@ namespace-packages = ["examples", "contrib", "docs"]
fixable = ["I", "Q"]
ignore = [
"ANN401", # any-type
"CPY001", # Missing copyright notice at top of file
"S101", # assert-used
"COM812", # conflicts with ruff formatter
"PLR0911", # Too many return statement
Expand Down
2 changes: 1 addition & 1 deletion src/simweights/_weighter.py
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ def __add__(self: Weighter, other: Weighter | int) -> Weighter:
def __radd__(self: Weighter, other: Weighter | int) -> Weighter:
return self + other

def tostring(self: Weighter, flux: None | object | Callable[[Any], ArrayLike] | ArrayLike = None) -> str:
def tostring(self: Weighter, flux: object | Callable[[Any], ArrayLike] | ArrayLike | None = None) -> str:
"""Creates a string with important information about this weighting object.

Generation surface, event map, number of events, and effective area.
Expand Down
Loading