def new_job(self, rule, targetfile=None, format_wildcards=None):
    'Create new job for given rule and (optional) targetfile.\n        This will reuse existing jobs with the same wildcards.'
    key = (rule, targetfile)
    if (key in self.job_cache):
        assert (targetfile is not None)
        return self.job_cache[key]
    wildcards_dict = rule.get_wildcards(targetfile)
    job = self.job_factory.new(rule, self, wildcards_dict=wildcards_dict, format_wildcards=format_wildcards, targetfile=targetfile)
    self.cache_job(job)
    return job
Create new job for given rule and (optional) targetfile.
This will reuse existing jobs with the same wildcards.
def new_job(self, rule, targetfile=None, format_wildcards=None):
    'Create new job for given rule and (optional) targetfile.\n        This will reuse existing jobs with the same wildcards.'
    key = (rule, targetfile)
    if (key in self.job_cache):
        assert (targetfile is not None)
        return self.job_cache[key]
    wildcards_dict = rule.get_wildcards(targetfile)
    job = self.job_factory.new(rule, self, wildcards_dict=wildcards_dict, format_wildcards=format_wildcards, targetfile=targetfile)
    self.cache_job(job)
    return job