From edb60e4b842036fd4678feb2f84d41627fd84b59 Mon Sep 17 00:00:00 2001 From: Graeme Winter Date: Tue, 26 Nov 2024 08:31:39 +0000 Subject: [PATCH] TQDM -> stdout (#775) * Reinstate tqdm -> stdout --- newsfragments/775.bugfix | 1 + src/dxtbx/model/experiment_list.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) create mode 100644 newsfragments/775.bugfix diff --git a/newsfragments/775.bugfix b/newsfragments/775.bugfix new file mode 100644 index 000000000..450b4bd4a --- /dev/null +++ b/newsfragments/775.bugfix @@ -0,0 +1 @@ +``dials.import``: set tqdm output to stdout (again) diff --git a/src/dxtbx/model/experiment_list.py b/src/dxtbx/model/experiment_list.py index 9916636f5..4ab93b966 100644 --- a/src/dxtbx/model/experiment_list.py +++ b/src/dxtbx/model/experiment_list.py @@ -677,7 +677,7 @@ def from_filenames( format_kwargs = {} if os.isatty and len(filenames) > 1 and "DIALS_NOBANNER" not in os.environ: - filename_iter = tqdm(to_process, total=len(filenames)) + filename_iter = tqdm(to_process, total=len(filenames), file=sys.stdout) else: filename_iter = to_process