<commit_before>#!/usr/bin/env python

import os
import sys 
import time
lib_path = os.path.abspath('../../mdwf_lib')
sys.path.append(lib_path)
import mdwf_functions as mdwf

""" A python script to help with post-processing of data of a MD simulation."""

jobid   = sys.argv[1]
jobtype = sys.argv[2]


## generic name of working MD files, (must be the same in .conf files). 
filename = "current_MD_run_files"

def main():
##  update local job details file: 
    mdwf.update_local_job_details( "JobFinishTime", time.time() )
    mdwf.check_job_runtime()       

    timestamp = "Finished: " + time.strftime("%d%b:%H:%M", time.localtime())
    mdwf.update_local_job_details("JobMessage", timestamp )
    mdwf.update_local_job_details("JobStatus", stopped )

    mdwf.redirect_namd_output(filename, jobtype)  # -redirect output
    mdwf.check_run_counter()                      # -check job counter
    mdwf.post_jobrun_cleanup()                    # -cleanup files 

if __name__ == "__main__":<commit_msg>Fixed bug with jobstatus call.<commit_after>#!/usr/bin/env python

import os
import sys 
import time
lib_path = os.path.abspath('../../mdwf_lib')
sys.path.append(lib_path)
import mdwf_functions as mdwf

""" A python script to help with post-processing of data of a MD simulation."""

jobid   = sys.argv[1]
jobtype = sys.argv[2]


## generic name of working MD files, (must be the same in .conf files). 
filename = "current_MD_run_files"

def main():
##  update local job details file: 
    mdwf.update_local_job_details( "JobFinishTime", time.time() )
    mdwf.check_job_runtime()       

    timestamp = "Finished: " + time.strftime("%d%b:%H:%M", time.localtime())
    mdwf.update_local_job_details("JobMessage", timestamp )
    mdwf.update_local_job_details("JobStatus", "stopped" )

    mdwf.redirect_namd_output(filename, jobtype)  # -redirect output
    mdwf.check_run_counter()                      # -check job counter
    mdwf.post_jobrun_cleanup()                    # -cleanup files 

if __name__ == "__main__":
{'fraction_non_alphanumeric': 0.12209589718240237, 'fraction_numerical': 0.001977261492832427, 'mean_word_length': 3.458149779735683, 'pattern_counts': {'":': 2, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3816432', 'n_tokens_mistral': 689, 'n_tokens_neox': 654, 'n_words': 163}