Пример #1
0
 def _get_sorted_processing_worklists(self):
     """
     If the job is processed first me must fetch potential buffer worklists
     from the ISO request worklists as well.
     """
     return LAB_ISO_ORDERS.get_sorted_worklists_for_job(self.entity,
                                             self._processing_order)
Пример #2
0
 def _get_sorted_processing_worklists(self):
     """
     If the job is processed first me must fetch potential buffer worklists
     from the ISO request worklists as well.
     """
     return LAB_ISO_ORDERS.get_sorted_worklists_for_job(
         self.entity, self._processing_order)
Пример #3
0
 def _get_sorted_processing_worklists(self):
     """
     If the job is processed first me must remove potential buffer worklists
     from the ISO request worklists because these have already been handled
     before by the job.
     """
     return LAB_ISO_ORDERS.get_sorted_worklists_for_iso(
         self.entity, self._processing_order)
Пример #4
0
 def _get_sorted_processing_worklists(self):
     """
     If the job is processed first me must remove potential buffer worklists
     from the ISO request worklists because these have already been handled
     before by the job.
     """
     return LAB_ISO_ORDERS.get_sorted_worklists_for_iso(self.entity,
                                             self._processing_order)
Пример #5
0
 def _get_sample_type_str(self):
     if self.executor.ENTITY_CLS == IsoJob:
         return self.SAMPLE_TYPE_CONTROLS
     processing_order = LAB_ISO_ORDERS.get_order(self.executor.entity)
     if processing_order == LAB_ISO_ORDERS.NO_ISO:
         return self.SAMPLE_TYPE_CONTROLS
     pool_set = self.executor.entity.molecule_design_pool_set
     if pool_set is None:
         return self.SAMPLE_TYPE_CONTROLS
     if processing_order == LAB_ISO_ORDERS.NO_JOB:
         # but we do have a pool set
         return self.SAMPLE_TYPE_BOTH
     else:
         return self.SAMPLE_TYPE_SAMPLES
Пример #6
0
 def _get_sample_type_str(self):
     if self.executor.ENTITY_CLS == IsoJob:
         return self.SAMPLE_TYPE_CONTROLS
     processing_order = LAB_ISO_ORDERS.get_order(self.executor.entity)
     if processing_order == LAB_ISO_ORDERS.NO_ISO:
         return self.SAMPLE_TYPE_CONTROLS
     pool_set = self.executor.entity.molecule_design_pool_set
     if pool_set is None:
         return self.SAMPLE_TYPE_CONTROLS
     if processing_order == LAB_ISO_ORDERS.NO_JOB:
         # but we do have a pool set
         return self.SAMPLE_TYPE_BOTH
     else:
         return self.SAMPLE_TYPE_SAMPLES
Пример #7
0
 def __get_processing_order(self):
     # Returns the order of ISO processing for the associated entity.
     self._processing_order = LAB_ISO_ORDERS.get_order(self.entity)
     alt_entity_cls = None
     if (self._ENTITY_CLS == LabIso and \
         self._processing_order == LAB_ISO_ORDERS.NO_ISO):
         alt_entity_cls = IsoJob
     elif (self._ENTITY_CLS == IsoJob and \
          self._processing_order == LAB_ISO_ORDERS.NO_JOB):
         alt_entity_cls = LabIso
     if alt_entity_cls is not None:
         msg = 'The %s does not need to be processed. Please proceed with ' \
               'the %s processing.' \
                % (get_entity_cls_displayname(self._ENTITY_CLS),
                   get_entity_cls_displayname(alt_entity_cls))
         self.add_error(msg)
Пример #8
0
 def __get_processing_order(self):
     # Returns the order of ISO processing for the associated entity.
     self._processing_order = LAB_ISO_ORDERS.get_order(self.entity)
     alt_entity_cls = None
     if (self._ENTITY_CLS == LabIso and \
         self._processing_order == LAB_ISO_ORDERS.NO_ISO):
         alt_entity_cls = IsoJob
     elif (self._ENTITY_CLS == IsoJob and \
          self._processing_order == LAB_ISO_ORDERS.NO_JOB):
         alt_entity_cls = LabIso
     if alt_entity_cls is not None:
         msg = 'The %s does not need to be processed. Please proceed with ' \
               'the %s processing.' \
                % (get_entity_cls_displayname(self._ENTITY_CLS),
                   get_entity_cls_displayname(alt_entity_cls))
         self.add_error(msg)
Пример #9
0
    def __check_iso_status(self):
        """
        Checks the status of the involved ISOs.
        The rack status are checked later.
        """
        self.add_debug('Check ISO status ...')

        self._processing_order = LAB_ISO_ORDERS.get_order(self.entity)
        self._get_expected_iso_status()
        if not self._expected_iso_status is None:
            invalid_status = []
            for iso in self.__final_layouts.keys():
                if not iso.status == self._expected_iso_status:
                    info = '%s (expected: %s, found: %s)' % (
                        iso.label, self._expected_iso_status.replace(
                            '_', ' '), iso.status.replace('_', ' '))
                    invalid_status.append(info)

            if len(invalid_status) > 0:
                msg = 'Unexpected ISO status: %s!' \
                      % (', '.join(sorted(invalid_status)))
                self.add_error(msg)
Пример #10
0
    def __check_iso_status(self):
        """
        Checks the status of the involved ISOs.
        The rack status are checked later.
        """
        self.add_debug('Check ISO status ...')

        self._processing_order = LAB_ISO_ORDERS.get_order(self.entity)
        self._get_expected_iso_status()
        if not self._expected_iso_status is None:
            invalid_status = []
            for iso in self.__final_layouts.keys():
                if not iso.status == self._expected_iso_status:
                    info = '%s (expected: %s, found: %s)' % (iso.label,
                            self._expected_iso_status.replace('_', ' '),
                            iso.status.replace('_', ' '))
                    invalid_status.append(info)

            if len(invalid_status) > 0:
                msg = 'Unexpected ISO status: %s!' \
                      % (', '.join(sorted(invalid_status)))
                self.add_error(msg)