Skip to content

Commit 36d1e2e

Browse files
[pre-commit.ci] pre-commit autoupdate (#559)
<!--pre-commit.ci start--> updates: - [github.com/psf/black: 23.9.1 → 23.10.0](psf/black@23.9.1...23.10.0) - [github.com/astral-sh/ruff-pre-commit: v0.0.292 → v0.1.1](astral-sh/ruff-pre-commit@v0.0.292...v0.1.1) <!--pre-commit.ci end--> --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
1 parent dbe2bc9 commit 36d1e2e

File tree

2 files changed

+3
-7
lines changed

2 files changed

+3
-7
lines changed

.pre-commit-config.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,12 @@ repos:
1818
- id: check-toml
1919
# Python
2020
- repo: https://github.com/psf/black
21-
rev: 23.9.1
21+
rev: 23.10.0
2222
hooks:
2323
- id: black-jupyter
2424
- repo: https://github.com/astral-sh/ruff-pre-commit
2525
# Ruff version.
26-
rev: v0.0.292
26+
rev: v0.1.1
2727
hooks:
2828
- id: ruff
2929
args: ["--fix"]

dpdata/system.py

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -752,11 +752,7 @@ def replace(self, initial_atom_type, end_atom_type, replace_num):
752752

753753
if replace_num > max_replace_num:
754754
raise RuntimeError(
755-
"not enough {initial_atom_type} atom, only {max_replace_num} available, less than {replace_num}.Please check.".format(
756-
initial_atom_type=initial_atom_type,
757-
max_replace_num=max_replace_num,
758-
replace_num=replace_num,
759-
)
755+
f"not enough {initial_atom_type} atom, only {max_replace_num} available, less than {replace_num}.Please check."
760756
)
761757

762758
may_replace_indices = [

0 commit comments

Comments
 (0)