File tree Expand file tree Collapse file tree 3 files changed +6
-9
lines changed
Expand file tree Collapse file tree 3 files changed +6
-9
lines changed Original file line number Diff line number Diff line change @@ -67,7 +67,6 @@ def run_abinit(
6767 process .terminate ()
6868
6969 process .wait ()
70- return
7170
7271
7372def run_mrgddb (
@@ -114,7 +113,6 @@ def run_mrgddb(
114113 process .terminate ()
115114
116115 process .wait ()
117- return
118116
119117
120118def run_anaddb (
@@ -162,4 +160,3 @@ def run_anaddb(
162160 process .terminate ()
163161
164162 process .wait ()
165- return
Original file line number Diff line number Diff line change @@ -251,7 +251,7 @@ def from_abinit_files(
251251 abinit_log_file : Path | str = LOG_FILE_NAME ,
252252 abinit_abort_file : Path | str = MPIABORTFILE ,
253253 abinit_out_file : Path | str = OUTPUT_FILE_NAME ,
254- ) -> tuple [Calculation , dict [AbinitObject , dict ]]:
254+ ) -> tuple [Self , dict [AbinitObject , dict ]]:
255255 """
256256 Create an Abinit calculation document from a directory and file paths.
257257
@@ -319,15 +319,14 @@ def from_abinit_files(
319319 msg = f"{ cls } exception while parsing event_report:\n { exc } "
320320 logger .critical (msg )
321321
322- return (
323- cls (
322+ instance = cls (
324323 dir_name = str (dir_name ),
325324 task_name = task_name ,
326325 abinit_version = abinit_out .version ,
327326 has_abinit_completed = has_abinit_completed ,
328327 completed_at = completed_at ,
329328 output = output_doc ,
330329 event_report = report ,
331- ),
332- None , # abinit_objects,
333- )
330+ )
331+
332+ return instance , None # abinit_objects,
Original file line number Diff line number Diff line change 1414from pydantic import BaseModel , Field
1515from pymatgen .core import Structure
1616from pymatgen .io .abinit .pseudos import AbinitPseudo
17+ from typing_extensions import Self
1718
1819from atomate2 .abinit .files import load_abinit_input
1920from atomate2 .abinit .schemas .calculation import AbinitObject , Calculation , TaskState
You can’t perform that action at this time.
0 commit comments