diff --git a/tedana/tests/test_integration.py b/tedana/tests/test_integration.py index e8bb0c422..89cb3b105 100644 --- a/tedana/tests/test_integration.py +++ b/tedana/tests/test_integration.py @@ -37,8 +37,8 @@ def check_integration_outputs(fname, outpath): # Checks for log file log_regex = ('^tedana_' - '[12][0-9]{3}-[0-9]{2}-[0-9]{2}T[0-9]{2}:' - '[0-9]{2}:[0-9]{2}.tsv$') + '[12][0-9]{3}-[0-9]{2}-[0-9]{2}T[0-9]{2}' + '[0-9]{2}[0-9]{2}.tsv$') logfiles = [out for out in existing if re.match(log_regex, out)] assert len(logfiles) == 1 diff --git a/tedana/workflows/tedana.py b/tedana/workflows/tedana.py index 4696f0a98..1fb809762 100644 --- a/tedana/workflows/tedana.py +++ b/tedana/workflows/tedana.py @@ -330,8 +330,8 @@ def tedana_workflow(data, tes, out_dir='.', mask=None, # create logfile name basename = 'tedana_' extension = 'tsv' - isotime = datetime.datetime.now().replace(microsecond=0).isoformat() - logname = op.join(out_dir, (basename + isotime + '.' + extension)) + start_time = datetime.datetime.now().strftime('%Y-%m-%dT%H%M%S') + logname = op.join(out_dir, (basename + start_time + '.' + extension)) # set logging format log_formatter = logging.Formatter(