def finalize(self, success_or_fail, message=''):
        """
        :param success_or_fail: string that is 'success' or 'fail'
        :param message:
        """
        self.logit.debug('String OutputPorts: %s' % self.__string_output_ports)
        if self.__string_output_ports:
            with open(os.path.join(self.output_path, 'ports.json'), 'w') as opf:
                json.dump(self.__string_output_ports, opf, indent=4)
            self.logit.debug('Ports.json written to %s' % os.path.join(self.output_path, 'ports.json'))

        with open(os.path.join(self.base_path, 'status.json'), 'w') as sf:
            json.dump({'status': success_or_fail, 'reason': message}, sf, indent=4)
def finalize(self, success_or_fail, message=''):
        """
        :param success_or_fail: string that is 'success' or 'fail'
        :param message:
        """
        self.logit.debug('String OutputPorts: %s' % self.__string_output_ports)
        if self.__string_output_ports:
            with open(os.path.join(self.output_path, 'ports.json'), 'w') as opf:
                json.dump(self.__string_output_ports, opf, indent=4)
            self.logit.debug('Ports.json written to %s' % os.path.join(self.output_path, 'ports.json'))

        with open(os.path.join(self.base_path, 'status.json'), 'w') as sf:
            json.dump({'status': success_or_fail, 'reason': message}, sf, indent=4)
def finalize ( self , success_or_fail , message = '' ) : self . logit . debug ( 'String OutputPorts: %s' % self . __string_output_ports ) if self . __string_output_ports : with open ( os . path . join ( self . output_path , 'ports.json' ) , 'w' ) as opf : json . dump ( self . __string_output_ports , opf , indent = 4 ) self . logit . debug ( 'Ports.json written to %s' % os . path . join ( self . output_path , 'ports.json' ) ) with open ( os . path . join ( self . base_path , 'status.json' ) , 'w' ) as sf : json . dump ( { 'status' : success_or_fail , 'reason' : message } , sf , indent = 4 )
:param success_or_fail: string that is 'success' or 'fail'
        :param message:
: param success_or_fail : string that is success or fail : param message :