def recruit(self, n=1):
        """Recruit n new participants to an existing HIT"""
        logger.info("Recruiting {} MTurk participants".format(n))
        if not self.config.get("auto_recruit"):
            logger.info("auto_recruit is False: recruitment suppressed")
            return

        hit_id = self.current_hit_id()
        if hit_id is None:
            logger.info("no HIT in progress: recruitment aborted")
            return

        try:
            return self.mturkservice.extend_hit(
                hit_id, number=n, duration_hours=self.config.get("duration")
            )
        except MTurkServiceException as ex:
            logger.exception(str(ex))
def recruit ( self , n = 1 ) : logger . info ( "Recruiting {} MTurk participants" . format ( n ) ) if not self . config . get ( "auto_recruit" ) : logger . info ( "auto_recruit is False: recruitment suppressed" ) return hit_id = self . current_hit_id ( ) if hit_id is None : logger . info ( "no HIT in progress: recruitment aborted" ) return try : return self . mturkservice . extend_hit ( hit_id , number = n , duration_hours = self . config . get ( "duration" ) ) except MTurkServiceException as ex : logger . exception ( str ( ex ) )
Recruit n new participants to an existing HIT