Skip to content

Commit

Permalink
small changes to correct linting errors
Browse files Browse the repository at this point in the history
  • Loading branch information
rdguha1995 committed Jan 22, 2024
1 parent 2c19eb2 commit d1ca84a
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 12 deletions.
7 changes: 4 additions & 3 deletions src/atomate2/qchem/flows/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,15 @@

from jobflow import Flow, Maker

from atomate2.qchem.jobs.base import BaseQCMaker
from atomate2.qchem.jobs.core import FreqMaker, OptMaker, TransitionStateMaker

if TYPE_CHECKING:
from pathlib import Path

from pymatgen.core.structure import Molecule

from atomate2.qchem.jobs.base import BaseQCMaker

# from atomate2.qchem.schemas.calculation import VaspObject
# from atomate2.vasp.sets.core import HSEBSSetGenerator, NonSCFSetGenerator

Expand Down Expand Up @@ -95,7 +96,7 @@ def make(

@classmethod
def from_freq_and_opt_maker(
cls, freq_maker: BaseQCMaker, opt_maker=BaseQCMaker
cls, freq_maker: BaseQCMaker, opt_maker: BaseQCMaker
) -> Maker:
"""
Instantiate the FrequencyFlatteningOptimizeMaker with a Freq and an Opt maker.
Expand Down Expand Up @@ -179,7 +180,7 @@ def make(

@classmethod
def from_freq_and_ts_maker(
cls, freq_maker: BaseQCMaker, ts_maker=BaseQCMaker
cls, freq_maker: BaseQCMaker, ts_maker: BaseQCMaker
) -> Maker:
"""
Instantiate the FrequencyFlatteningOptimizeMaker with a Freq and a TS maker.
Expand Down
4 changes: 1 addition & 3 deletions tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@

from atomate2.utils.log import initialize_logger

# print(sys.executable)


@pytest.fixture(scope="session")
def test_dir():
Expand Down Expand Up @@ -46,7 +44,7 @@ def clean_dir(debug_mode):
os.chdir(new_path)
yield
if debug_mode:
print(f"Tests ran in {new_path}")
print(f"Tests ran in {new_path}") # noqa: T201
else:
os.chdir(old_cwd)
shutil.rmtree(new_path)
Expand Down
9 changes: 3 additions & 6 deletions tests/qchem/jobs/test_core.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,11 @@

from atomate2.qchem.jobs.core import FreqMaker, OptMaker, SinglePointMaker

# curr_dir = Path(os.path.dirname(sys.argv[0]))

# Specify the file name
file_name = "H2O.xyz"
# Find parent directory
current_directory = Path(__file__).resolve().parent
file_name = current_directory / "H2O.xyz"

# Construct the full path
mol_path = Path("tests/qchem/jobs/H2O.xyz")
# H2O_structure = Molecule.from_file(mol_path)
H2O_structure = Molecule.from_file(file_name)


Expand Down

0 comments on commit d1ca84a

Please sign in to comment.