diff --git a/mxcubecore/HardwareObjects/DESY/P11Collect.py b/mxcubecore/HardwareObjects/DESY/P11Collect.py index b5de66e9a2..12f8e31593 100644 --- a/mxcubecore/HardwareObjects/DESY/P11Collect.py +++ b/mxcubecore/HardwareObjects/DESY/P11Collect.py @@ -340,11 +340,11 @@ def collect_characterisation( self.omega_mv(start_angle, self.default_speed) for img_no in range(nimages): - print("collecting image %s" % img_no) + logging.info("collecting image %s" % img_no) start_at = start_angle + angle_inc * img_no stop_angle = start_at + img_range * 1.0 - print("collecting image %s, angle %f" % (img_no, start_at)) + logging.info("collecting image %s, angle %f" % (img_no, start_at)) if start_at >= stop_angle: init_pos = start_at @@ -681,7 +681,7 @@ def trigger_auto_processing(self, process_event=None, frame_number=None): mosflm_path_local.split("/gpfs/current/processed/")[1] + "\n" ) except: - print(sys.exc_info()) + logging.info(sys.exc_info()) # create call # btHelper.user_sshkey = btHelper.user_sshkey.replace("/gpfs/current",triggerUtils.get_beamtime_metadata()[2]) @@ -773,7 +773,7 @@ def trigger_auto_processing(self, process_event=None, frame_number=None): xdsapp_path_local.split("/gpfs/current/processed/")[1] + "\n" ) except RuntimeError: - print(sys.exc_info()) + logging.info(sys.exc_info()) # create call ssh = btHelper.get_ssh_command() @@ -990,12 +990,12 @@ def check_path(self, path=None, force=False): try: os.mkdir(path, mode=0o777) except RuntimeError: - print("mkdir failed:", str(sys.exc_info())) + logging.info("mkdir failed:", str(sys.exc_info())) return False else: - print("dir not found:", str(sys.exc_info())) + logging.info("dir not found:", str(sys.exc_info())) return False if not os.access(path, os.W_OK): - print("dir not writeable:", str(sys.exc_info())) + logging.info("dir not writeable:", str(sys.exc_info())) return False return path diff --git a/mxcubecore/HardwareObjects/DESY/P11EDNACharacterisation.py b/mxcubecore/HardwareObjects/DESY/P11EDNACharacterisation.py index 52e57d1a7c..ae5c9ac5de 100644 --- a/mxcubecore/HardwareObjects/DESY/P11EDNACharacterisation.py +++ b/mxcubecore/HardwareObjects/DESY/P11EDNACharacterisation.py @@ -130,7 +130,7 @@ def edna_maxwell(self, process_directory, inputxml, outputxml): ) ) - print( + logging.info( '{ssh:s} "{sbatch:s} --wrap \\"{cmd:s}"\\"'.format( ssh=ssh, sbatch=sbatch, cmd=cmd ) @@ -268,18 +268,18 @@ def input_from_params(self, data_collection, char_params): path_template = data_collection.acquisitions[0].path_template # Make sure there is a proper path conversion between different mount points - print( - "======= Characterisation path template ====", path_template.directory - ) # /gpfs/current/raw + logging.info( + "======= Characterisation path template ====%s", path_template.directory + ) image_dir = path_template.directory.replace( "/gpfs/current", triggerUtils.get_beamtime_metadata()[2] ) - print(image_dir) + logging.info(image_dir) path_str = os.path.join(image_dir, path_template.get_image_file_name()) - print(path_template.xds_dir) + logging.info(path_template.xds_dir) characterisation_dir = path_template.xds_dir.replace( "/autoprocessing_", "/characterisation_"