diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 50032cc..356ed40 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -20,7 +20,7 @@ repos: - id: trailing-whitespace - repo: https://github.com/astral-sh/ruff-pre-commit - rev: "v0.8.6" + rev: "v0.9.9" hooks: - id: ruff args: ["--fix", "--show-fixes"] diff --git a/src/pylhe/__init__.py b/src/pylhe/__init__.py index e185f39..19732e2 100644 --- a/src/pylhe/__init__.py +++ b/src/pylhe/__init__.py @@ -248,7 +248,7 @@ def _indent(elem, level=0): class LHEInit(dict): """Store the block as dict.""" - fieldnames = ["initInfo", "procInfo" "weightgroup", "LHEVersion"] + fieldnames = ["initInfo", "procInfoweightgroup", "LHEVersion"] def __init__(self, *args, **kwargs): super().__init__(*args, **kwargs) @@ -377,9 +377,7 @@ def write(self, output_stream, rwgt=True, weights=False): """ Write the LHE file to an output stream. """ - output_stream.write( - f"\n" - ) + output_stream.write(f'\n') output_stream.write(self.init.tolhe() + "\n") for e in self.events: output_stream.write(e.tolhe(rwgt=rwgt, weights=weights) + "\n")