From b21198c6b67f5d1c6a2070a24a8a9480f4db92fd Mon Sep 17 00:00:00 2001 From: Janosh Riebesell Date: Fri, 22 Nov 2024 14:26:11 -0500 Subject: [PATCH] fix ruff PYI063 Use PEP 570 syntax for positional-only parameters --- src/atomate2/ase/schemas.py | 2 +- src/atomate2/forcefields/schemas.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/atomate2/ase/schemas.py b/src/atomate2/ase/schemas.py index 3bce7e443d..b9a426135a 100644 --- a/src/atomate2/ase/schemas.py +++ b/src/atomate2/ase/schemas.py @@ -99,7 +99,7 @@ class AseBaseModel(BaseModel): ) molecule: Optional[Molecule] = Field(None, description="The molecule at this step.") - def model_post_init(self, __context: Any) -> None: + def model_post_init(self, _context: Any) -> None: """Establish alias to structure and molecule fields.""" if self.structure is None and isinstance(self.mol_or_struct, Structure): self.structure = self.mol_or_struct diff --git a/src/atomate2/forcefields/schemas.py b/src/atomate2/forcefields/schemas.py index a66785b8b8..2d448d92ee 100644 --- a/src/atomate2/forcefields/schemas.py +++ b/src/atomate2/forcefields/schemas.py @@ -22,7 +22,7 @@ class ForcefieldResult(AseResult): None, description="The structure in the final trajectory frame." ) - def model_post_init(self, __context: Any) -> None: + def model_post_init(self, _context: Any) -> None: """Populate final_structure attr.""" self.final_structure = getattr( self, "final_structure", self.final_mol_or_struct