Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed error related to lingering KFFiles when rerunning jobs #247

Merged
merged 1 commit into from
May 28, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions src/tcutility/job/ams.py
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,11 @@ def _setup_job(self):
'''
os.makedirs(self.rundir, exist_ok=True)

for file in os.listdir(self.rundir):
p = os.path.join(self.rundir, file)
if p.endswith('.rkf'):
os.remove(p)

if not self._molecule and not self._molecule_path and 'atoms' not in self.settings.input.ams.system:
log.error(f'You did not supply a molecule for this job. Call the {self.__class__.__name__}.molecule method to add one.')
return
Expand Down
Loading