diff --git a/blacs/experiment_queue.py b/blacs/experiment_queue.py index f98875e..dce7efd 100644 --- a/blacs/experiment_queue.py +++ b/blacs/experiment_queue.py @@ -15,6 +15,7 @@ import os import threading import time +import datetime import sys import shutil from collections import defaultdict @@ -722,7 +723,7 @@ def restart_function(device_name): # A Queue for event-based notification of when the experiment has finished. experiment_finished_queue = queue.Queue() logger.debug('About to start the master pseudoclock') - run_time = time.localtime() + run_time = datetime.datetime.now() ########################################################################################################################################## # Plugin callbacks # @@ -850,7 +851,7 @@ def restart_function(device_name): data_group = hdf5_file['/'].create_group('data') # stamp with the run time of the experiment - hdf5_file.attrs['run time'] = time.strftime('%Y%m%dT%H%M%S',run_time) + hdf5_file.attrs['run time'] = run_time.strftime('%Y%m%dT%H%M%S.%f') error_condition = False response_list = {}