@@ -36,9 +36,7 @@ dependencies = [
3636
3737[project .optional-dependencies ]
3838dev = [
39- " black" ,
4039 " bumpversion" ,
41- " flake8" ,
4240 " jupyter" ,
4341 " pre-commit" ,
4442 " twine" ,
@@ -67,14 +65,16 @@ version.source = "vcs"
6765build.hooks.vcs.version-file = " src/mplhep/_version.py"
6866
6967
70- [tool .nbqa .mutate ]
71- pyupgrade = 1
72-
73- [tool .nbqa .addopts ]
74- pyupgrade = [" --py38-plus" ]
68+ [tool .uv ]
69+ environments = [
70+ " python_version >= '3.10'" ,
71+ ]
72+ dev-dependencies = [
73+ " mplhep[test]" ,
74+ ]
7575
7676
77- [tools .mypy ]
77+ [tool .mypy ]
7878files = [" src" ]
7979python_version = 3.8
8080warn_unused_configs = true
@@ -85,7 +85,7 @@ allow_redefinition = true
8585# disallow_untyped_calls = true
8686# disallow_untyped_defs = true
8787# disallow_incomplete_defs = true
88- check_untyped_defs = true
88+ check_untyped_defs = false
8989# disallow_untyped_decorators = true
9090# no_implicit_optional = true
9191# warn_redundant_casts = true
@@ -106,5 +106,41 @@ testpaths = ["tests"]
106106python_files = " test*.py"
107107
108108
109- [tool .isort ]
110- profile = " black"
109+ [tool .ruff .lint ]
110+ extend-select = [
111+ " B" , # flake8-bugbear
112+ " I" , # isort
113+ " ARG" , # flake8-unused-arguments
114+ " C4" , # flake8-comprehensions
115+ " EM" , # flake8-errmsg
116+ " ICN" , # flake8-import-conventions
117+ " G" , # flake8-logging-format
118+ " PGH" , # pygrep-hooks
119+ " PIE" , # flake8-pie
120+ " PL" , # pylint
121+ " PT" , # flake8-pytest-style
122+ " RET" , # flake8-return
123+ " RUF" , # Ruff-specific
124+ " SIM" , # flake8-simplify
125+ " T20" , # flake8-print
126+ " UP" , # pyupgrade
127+ " YTT" , # flake8-2020
128+ " EXE" , # flake8-executable
129+ " NPY" , # NumPy specific rules
130+ " PD" , # pandas-vet
131+ " FURB" , # refurb
132+ " PYI" , # flake8-pyi
133+ ]
134+ ignore = [
135+ " PLR09" , # Too many <...>
136+ " PLR2004" , # Magic value used in comparison
137+ " ISC001" , # Conflicts with formatter
138+ " NPY002" , # np.random.Generator
139+ " G004" , # Logging with f-string
140+ " PD011" , # .values vs .to_numpy can get confused
141+ " PT013" , # Import from pytest
142+ ]
143+
144+ [tool .ruff .lint .per-file-ignores ]
145+ "tests/**" = [" T20" ]
146+ "docs/conf.py" = [" T20" ]
0 commit comments