'returns an array of the queued jobs, values stored in dictionary'

def get_queued_jobs(self):

    queued = []
    for j in self.jobs:
        if ((j['job_state'] == u'pending') and (j['state'] == u'qw')):
            queued.append(j)
    return queued
