~launchpad-pqm/launchpad/devel

« back to all changes in this revision

Viewing changes to lib/lp/services/job/runner.py

  • Committer: Aaron Bentley
  • Date: 2011-08-18 17:36:23 UTC
  • mto: This revision was merged to the branch mainline in revision 13737.
  • Revision ID: aaron@canonical.com-20110818173623-agkfx7o4nnxunie2
Use JobCronScript.log_twisted.

Show diffs side-by-side

added added

removed removed

Lines of Context:
583
583
        self._runner_class = runner_class
584
584
        super(JobCronScript, self).__init__(
585
585
            name=name, dbuser=None, test_args=test_args)
 
586
        self.log_twisted = getattr(self.options, 'log_twisted', False)
586
587
        if not commandline_config:
587
588
            return
588
589
        self.config_name = self.args[0]
624
625
            errorlog.globalErrorUtility.configure(self.config_name)
625
626
        job_source = getUtility(self.source_interface)
626
627
        kwargs = {}
627
 
        if getattr(self.options, 'log_twisted', False):
 
628
        if self.log_twisted:
628
629
            kwargs['_log_twisted'] = True
629
630
        runner = self.runner_class.runFromSource(
630
631
            job_source, self.dbuser, self.logger, **kwargs)