@click.command(u'show-pending-jobs')
@click.option(u'--site', help=u'site name')
@pass_context
def show_pending_jobs(context, site=None):
 from frappe.utils.doctor import pending_jobs as _pending_jobs
 if (not site):
  site = get_site(context)
 with frappe.init_site(site):
  pending_jobs = _pending_jobs(site=site)
 return pending_jobs

@ click . command ( u'show-pending-jobs' ) @ click . option ( u'--site' , help = u'site name' ) @ pass_context def show_pending_jobs ( context , site = None ) : from frappe . utils . doctor import pending_jobs as _pending_jobs if ( not site ) : site = get_site ( context ) with frappe . init_site ( site ) : pending_jobs = _pending_jobs ( site = site ) return pending_jobs
get diagnostic info about background jobs .