bugged
stringlengths
4
228k
fixed
stringlengths
0
96.3M
__index_level_0__
int64
0
481k
def failed(): fn = '.stgit-failed.patch' f = file(fn, 'w') f.write(edit.patch_desc(stack.repository, cd, options.diff, options.diff_flags, failed_diff)) f.close() out.error('Edited patch did not apply.', 'It has been saved to "%s".' % fn) return utils.STGIT_COMMAND_ERROR
def failed(): fn = '.stgit-failed.patch' f = file(fn, 'w') f.write(edit.patch_desc(stack.repository, cd, options.diff, options.diff_flags, failed_diff)) f.close() out.error('Edited patch did not apply.', 'It has been saved to "%s".' % fn) return utils.STGIT_COMMAND_ERROR
448,500
def patch_name_from_msg(msg): """Return a string to be used as a patch name. This is generated from the top line of the string passed as argument.""" if not msg: return None name_len = config.getint('stgit.namelength') if not name_len: name_len = 30 subject_line = msg.split('\n', 1)[0].lstrip().lower() return re.sub(...
def patch_name_from_msg(msg): """Return a string to be used as a patch name. This is generated from the top line of the string passed as argument.""" if not msg: return None name_len = config.getint('stgit.namelength') if not name_len: name_len = 30 subject_line = msg.split('\n', 1)[0].lstrip().lower() words = re.sub...
448,501
def __send_message_smtp(smtpserver, from_addr, to_addr_list, msg, options): """Send the message using the given SMTP server """ smtppassword = options.smtp_password or config.get('stgit.smtppassword') smtpuser = options.smtp_user or config.get('stgit.smtpuser') smtpusetls = options.smtp_tls or config.get('stgit.smtptls...
__smtp_credentials = None def __set_smtp_credentials(options): """Set the (smtpuser, smtppassword, smtpusetls) credentials if the method of sending is SMTP. """ global __smtp_credentials smtpserver = options.smtp_server or config.get('stgit.smtpserver') if options.mbox or options.git or smtpserver.startswith('/'): re...
448,502
def clean(self,): cleaned_data = self.cleaned_data debut = cleaned_data.get("debut") fin = cleaned_data.get("fin") if debut > fin: raise forms.ValidationError("La date de fin ne doit pas être antérieure à la date de début") return cleaned_data
def clean(self,): cleaned_data = self.cleaned_data debut = cleaned_data.get("debut") fin = cleaned_data.get("fin") if debut and fin and debut > fin: raise forms.ValidationError("La date de fin ne doit pas être antérieure à la date de début") return cleaned_data
448,503
def sep_search (page, q, data): f = page * configuration['resultats_par_page'] t = f + 8 s = SEP () matches = s.search (q) data['last_page'] = math.ceil (float(len (matches)) / \ float(configuration['resultats_par_page'])) - 1 set = s.get (matches[f:t]) regexp = make_regexp (q) for r in set: uri = r.get ("source", "")...
def sep_search (page, q, data): f = page * configuration['resultats_par_page'] t = f + 8 s = SEP () matches = s.search (q) data['last_page'] = math.ceil (float(len (matches)) / \ float(configuration['resultats_par_page'])) - 1 set = s.get (matches[f:t]) regexp = make_regexp (q) for r in set: uri = r.get ("source", "")...
448,504
def highlight(text, regexp, autoescape=None): """Met en évidence les parties du texte qui correspondent à l'expression régulière passée en argument.""" if autoescape: text = conditional_escape(text) if regexp: text = regexp.sub(r'<b>\g<0></b>', text) return mark_safe(text)
def highlight(text, regexp=None, autoescape=None): """Met en évidence les parties du texte qui correspondent à l'expression régulière passée en argument.""" if autoescape: text = conditional_escape(text) if regexp: text = regexp.sub(r'<b>\g<0></b>', text) return mark_safe(text)
448,505
def save(self): if self.is_valid():
def save(self): if self.is_valid():
448,506
def __unicode__ (self): return "%s" % (self.titre)
def __unicode__ (self): return "%s" % (self.titre)
448,507
def get_query_set(self): """Retourne l'ensemble des actualités qui correspondent aux valeurs entrées dans le formulaire.""" actualites = Actualite.objects.filter(visible=True) if self.is_valid(): query = self.cleaned_data['q'] if query: actualites = actualites.search(query) date_min = self.cleaned_data['date_min'] if d...
def get_query_set(self): """Retourne l'ensemble des actualités qui correspondent aux valeurs entrées dans le formulaire.""" actualites = Actualite.objects.filter(visible=True) if self.is_valid(): query = self.cleaned_data['q'] if query: actualites = actualites.search(query) date_min = self.cleaned_data['date_min'] if d...
448,508
def get_new_password_code(self): return hashlib.md5(smart_str(u.courriel+u.encrypted_password)).hexdigest()[0:6]
def get_new_password_code(self): return hashlib.md5(smart_str(u.courriel+u.encrypted_password)).hexdigest()[0:6]
448,509
def __init__(self, *args, **kwargs):
def __init__(self, *args, **kwargs):
448,510
def __init__(self, *args, **kwargs):
def __init__(self, *args, **kwargs):
448,511
def evenements(): rc = [] client = caldav.DAVClient(configuration['calendrier']) cal = caldav.Calendar(client, url = configuration['calendrier']) start = datetime.datetime.now().strftime("%Y%m%dT%H%M%S%z") events = cal.date_search(start) for e in events: rc.append(e.instance.vevent) rc.sort(lambda x,y: cmp(time.mkti...
def evenements(): rc = [] client = caldav.DAVClient(configuration['calendrier']) cal = caldav.Calendar(client, url = configuration['calendrier']) start = datetime.datetime.now() events = cal.date_search(start) for e in events: rc.append(e.instance.vevent) rc.sort(lambda x,y: cmp(time.mktime(x.dtstart.value.timetuple...
448,512
def ressource_retrieve(request, id, discipline=None, region=None): """Notice OAI de la ressource""" ressource = get_object_or_404(Record, id=id) return render_to_response( "savoirs/ressource_retrieve.html", dict(ressource=ressource, disciplines=resource.disciplines.all(), regions=ressource.regions.all()), context_insta...
def ressource_retrieve(request, id, discipline=None, region=None): """Notice OAI de la ressource""" ressource = get_object_or_404(Record, id=id) return render_to_response( "savoirs/ressource_retrieve.html", dict(ressource=ressource, disciplines=ressource.disciplines.all(), regions=ressource.regions.all()), context_inst...
448,513
def get_query_set(self): """Retourne l'ensemble des ressources qui correspondent aux valeurs entrées dans le formulaire.""" records = Record.objects.validated() if self.is_valid(): query = self.cleaned_data['q'] if query: records = records.search(query) auteur = self.cleaned_data['auteur'] if auteur: records = records....
def get_query_set(self): """Retourne l'ensemble des ressources qui correspondent aux valeurs entrées dans le formulaire.""" records = Record.objects.validated() if self.is_valid(): query = self.cleaned_data['q'] if query: records = records.search(query) auteur = self.cleaned_data['auteur'] if auteur: records = records....
448,514
def edit(request): """Edition d'un chercheur""" context_instance = RequestContext(request) chercheur = context_instance['user_chercheur'] #GroupeFormset = inlineformset_factory(Chercheur, ChercheurGroupe) if request.method == 'POST': personne_form = PersonneEditForm(request.POST, prefix="personne", instance=chercheur....
def edit(request): """Edition d'un chercheur""" context_instance = RequestContext(request) chercheur = context_instance['user_chercheur'] #GroupeFormset = inlineformset_factory(Chercheur, ChercheurGroupe) if request.method == 'POST': personne_form = PersonneEditForm(request.POST, prefix="personne", instance=chercheur....
448,515
def index(request): """Répertoire des chercheurs""" chercheurs = chercheur_queryset (request) repertoire_form = RepertoireSearchForm (request.GET) nb_chercheurs = chercheurs.count() variables = { 'chercheurs': chercheurs, 'nb_chercheurs': nb_chercheurs, 'repertoire_form': repertoire_form, } return render_to_response ...
def index(request): """Répertoire des chercheurs""" chercheurs = chercheur_queryset (request) repertoire_form = RepertoireSearchForm (request.GET) nb_chercheurs = chercheurs.count() variables = { 'chercheurs': chercheurs, 'nb_chercheurs': nb_chercheurs, 'repertoire_form': repertoire_form, } return render_to_response ...
448,516
def order_by_nom(self, direction=''): return self.order_by(direction + 'personne__nom', direction + 'personne__prenom', '-date_modification')
def order_by_nom(self, direction=''): return self.order_by(direction + 'personne__nom', direction + 'personne__prenom', '-date_modification')
448,517
def a_propos (request): return render_to_response ("savoirs/a-propos.html", \ Context ({'count': len(sep.conf.RESOURCES)}), \ context_instance = RequestContext(request))
def a_propos (request): return render_to_response ("savoirs/a-propos.html", \ Context ({'count': len(backend_config.RESOURCES)}), \ context_instance = RequestContext(request))
448,518
def informations (request): s = sep.SEP() t = s.logs() resources = copy.deepcopy (sep.conf.RESOURCES) for k in t.keys (): resources[k]['logs'] = { 'date': t[k][0], 'count': t[k][1] } return render_to_response ("savoirs/informations.html", \ Context ({'r': resources}), \ context_instance = RequestContext(request))
def informations (request): s = sep.SEP() t = s.logs() resources = copy.deepcopy (backend_config.RESOURCES) for k in t.keys (): resources[k]['logs'] = { 'date': t[k][0], 'count': t[k][1] } return render_to_response ("savoirs/informations.html", \ Context ({'r': resources}), \ context_instance = RequestContext(request))...
448,519
def informations (request): s = sep.SEP() t = s.logs() resources = copy.deepcopy (sep.conf.RESOURCES) for k in t.keys (): resources[k]['logs'] = { 'date': t[k][0], 'count': t[k][1] } return render_to_response ("savoirs/informations.html", \ Context ({'r': resources}), \ context_instance = RequestContext(request))
def informations (request): s = sep.SEP() t = s.logs() resources = copy.deepcopy (sep.conf.RESOURCES) for k in t.keys (): try: resources[k]['logs'] = { 'date': t[k][0], 'count': t[k][1] } except: pass return render_to_response ("savoirs/informations.html", \ Context ({'r': resources}), \ context_instance = RequestConte...
448,520
def index (request): delta = datetime.timedelta (days = 90) oldest = datetime.date.today () - delta articles = Actualite.objects.filter (visible = '1', date__gt = oldest) articles = articles[0:configuration['accueil_actualite']] try: events = evenements()[0:configuration['accueil_evenement']] except: events = [] cherch...
def index (request): delta = datetime.timedelta (days = 90) oldest = datetime.date.today () - delta articles = Actualite.objects.filter (visible = '1', date__gt = oldest) articles = articles[0:configuration['accueil_actualite']] events = evenements()[0:configuration['accueil_evenement']] chercheurs = Chercheur.objects....
448,521
def informations (request): s = sep.SEP() t = s.logs() resources = copy.deepcopy (backend_config.RESOURCES) for k in t.keys (): try: resources[k]['logs'] = { 'date': t[k][0], 'count': t[k][1] } except: pass return render_to_response ("savoirs/informations.html", \ Context ({'r': resources}), \ context_instance = Reques...
def informations (request): s = sep.SEP() resources = copy.deepcopy (backend_config.RESOURCES) for k in t.keys (): try: resources[k]['logs'] = { 'date': t[k][0], 'count': t[k][1] } except: pass return render_to_response ("savoirs/informations.html", \ Context ({'r': resources}), \ context_instance = RequestContext(requ...
448,522
def informations (request): s = sep.SEP() t = s.logs() resources = copy.deepcopy (backend_config.RESOURCES) for k in t.keys (): try: resources[k]['logs'] = { 'date': t[k][0], 'count': t[k][1] } except: pass return render_to_response ("savoirs/informations.html", \ Context ({'r': resources}), \ context_instance = Reques...
def informations (request): s = sep.SEP() t = s.logs() resources = copy.deepcopy (backend_config.RESOURCES) for k in backend_config.RESOURCES.keys (): try: resources[k]['logs'] = { 'date': t[k][0], 'count': t[k][1] } except: pass return render_to_response ("savoirs/informations.html", \ Context ({'r': resources}), \ co...
448,523
def make_regexp (q): words = [] w = re.compile (r'\W+', re.U) for k in q.keys (): if k != 'operator': words.extend(w.split (smart_str(q[k]).decode("utf-8"))) words = filter (lambda x: len(x)>2, words) words.sort (lambda x,y: len(y)-len(x)) patt = "|".join (words) patt = "(" + patt + ")" return re.compile (patt, re.I|r...
def make_regexp (q): words = [] w = re.compile (r'\W+', re.U) for k in q.keys (): if k != 'operator': words.extend(w.split (smart_str(q[k]).decode("utf-8"))) words = filter (lambda x: len(x)>2, words) words.sort (lambda x,y: len(y)-len(x)) patt = "|".join (words) patt = "([\W]{1})(" + patt + ")([\W]{1})" return re.com...
448,524
def hl (r, string): if string is not None: return r.sub (r'<b>\1</b>', string) return None
def hl (r, string): if string is not None: return r.sub (r'\1<b>\2</b>\3', string) return None
448,525
def test_suite(): import z3c.ptcompat.tests path = z3c.ptcompat.tests.__path__[0] globs = dict( os=os, path=path, interface=zope.interface, component=zope.component) return unittest.TestSuite([ doctest.DocFileSuite( "zcml.txt", optionflags=OPTIONFLAGS, globs=globs, setUp=setUp, tearDown=tearDown, package="z3c.ptcompa...
def test_suite(): import z3c.ptcompat.tests path = z3c.ptcompat.tests.__path__[0] globs = dict( os=os, path=path, interface=zope.interface, component=zope.component) return unittest.TestSuite([ doctest.DocFileSuite( "zcml.txt", optionflags=OPTIONFLAGS, globs=globs, setUp=setUp, tearDown=tearDown, package="z3c.ptcompa...
448,526
def test_suite(): import z3c.ptcompat.tests path = z3c.ptcompat.tests.__path__[0] globs = dict( os=os, path=path, interface=zope.interface, component=zope.component) return unittest.TestSuite([ doctest.DocFileSuite( "zcml.txt", optionflags=OPTIONFLAGS, globs=globs, setUp=setUp, tearDown=tearDown, package="z3c.ptcompa...
def test_suite(): import z3c.ptcompat.tests path = z3c.ptcompat.tests.__path__[0] globs = dict( os=os, path=path, interface=zope.interface, component=zope.component) return unittest.TestSuite([ doctest.DocFileSuite( "zcml.txt", optionflags=OPTIONFLAGS, globs=globs, setUp=setUp, tearDown=tearDown, package="z3c.ptcompa...
448,527
def url(dialog, link, data=None): pass
def url(dialog, link, data=None): pass
448,528
def quit(self): ### Do anything that needs to be done before quitting. logging.info("Caffeine is preparing to quit")
def quit(self): ### Do anything that needs to be done before quitting. logging.info("Caffeine is preparing to quit")
448,529
def __init__(self): self.Core = core.Caffeine()
def __init__(self): self.Core = core.Caffeine()
448,530
def on_about_button_clicked (self, button, data=None):
def on_about_button_clicked (self, button, data=None):
448,531
def on_time_submenuitem_activate(self, menuitem, time):
def on_time_submenuitem_activate(self, menuitem, time):
448,532
def _run_dialog(self): response = self.about_dialog.run() self.about_dialog.destroy() return False
def on_about_menuitem_activate(self, menuitem, data=None): if appindicator_avail: gtk.gdk.threads_enter() self.about_dialog.set_position (gtk.WIN_POS_CENTER_ALWAYS) response = self.about_dialog.run() self.about_dialog.destroy() return False
448,533
def _run_dialog(self): response = self.about_dialog.run() self.about_dialog.destroy() return False
def _run_dialog(self): response = self.about_dialog.run() self.about_dialog.destroy() return False
448,534
def _check_for_Flash(self): try: tmp = "/tmp" ## look for filenames that begin with 'Flash' for file in os.listdir(tmp): try: if file.startswith("Flash"): filepath = os.path.join(tmp, file) duration = utils.getFLVLength(filepath)
def _check_for_Flash(self): try: tmp = "/tmp" ## look for filenames that begin with 'Flash' for file in os.listdir(tmp): try: if file.startswith("Flash"): filepath = os.path.join(tmp, file) duration = utils.getFLVLength(filepath)
448,535
def _check_for_Flash(self): try: tmp = "/tmp" ## look for filenames that begin with 'Flash' for file in os.listdir(tmp): try: if file.startswith("Flash"): filepath = os.path.join(tmp, file) duration = utils.getFLVLength(filepath)
def _check_for_Flash(self): try: tmp = "/tmp" ## look for filenames that begin with 'Flash' for file in os.listdir(tmp): try: if file.startswith("Flash"): filepath = os.path.join(tmp, file) duration = utils.getFLVLength(filepath)
448,536
def copy_required_modules(dst_prefix): for modname in REQUIRED_MODULES: if modname in sys.builtin_module_names: logger.notify("Ignoring built-in bootstrap module: %s" % mod) continue try: mod = __import__(modname) except ImportError: logger.notify("Cannot import bootstrap module: %s" % modname) else: filename = mod.__f...
def copy_required_modules(dst_prefix): for modname in REQUIRED_MODULES: if modname in sys.builtin_module_names: logger.notify("Ignoring built-in bootstrap module: %s" % mod) continue try: mod = __import__(modname) except ImportError: logger.notify("Cannot import bootstrap module: %s" % modname) else: filename = mod.__f...
448,537
def _install_req(py_executable, unzip=False, distribute=False): if not distribute: setup_fn = 'setuptools-0.6c11-py%s.egg' % sys.version[:3] project_name = 'setuptools' bootstrap_script = EZ_SETUP_PY source = None else: setup_fn = None source = 'distribute-0.6.8.tar.gz' project_name = 'distribute' bootstrap_script = DI...
def _install_req(py_executable, unzip=False, distribute=False): if not distribute: setup_fn = 'setuptools-0.6c11-py%s.egg' % sys.version[:3] project_name = 'setuptools' bootstrap_script = EZ_SETUP_PY source = None else: setup_fn = None source = 'distribute-0.6.14.tar.gz' project_name = 'distribute' bootstrap_script = D...
448,538
def _install_req(py_executable, unzip=False, distribute=False): if not distribute: setup_fn = 'setuptools-0.6c11-py%s.egg' % sys.version[:3] project_name = 'setuptools' bootstrap_script = EZ_SETUP_PY source = None else: setup_fn = None source = 'distribute-0.6.8.tar.gz' project_name = 'distribute' bootstrap_script = DI...
def _install_req(py_executable, unzip=False, distribute=False): if not distribute: setup_fn = 'setuptools-0.6c11-py%s.egg' % sys.version[:3] project_name = 'setuptools' bootstrap_script = EZ_SETUP_PY source = None else: setup_fn = None source = 'distribute-0.6.8.tar.gz' project_name = 'distribute' bootstrap_script = DI...
448,539
def _filter_ez_setup(line): return filter_ez_setup(line, project_name)
def _filter_ez_setup(line): return filter_ez_setup(line, project_name)
448,540
def _filter_ez_setup(line): return filter_ez_setup(line, project_name)
def _filter_ez_setup(line): return filter_ez_setup(line, project_name)
448,541
def fixup_pth_and_egg_link(home_dir): """Makes .pth and .egg-link files use relative paths""" home_dir = os.path.normcase(os.path.abspath(home_dir)) for path in sys.path: if not path: path = '.' if not os.path.isdir(path): continue path = os.path.normcase(os.path.abspath(path)) if not path.startswith(home_dir): logger....
def fixup_pth_and_egg_link(home_dir, sys_path=None): """Makes .pth and .egg-link files use relative paths""" home_dir = os.path.normcase(os.path.abspath(home_dir)) for path in sys.path: if not path: path = '.' if not os.path.isdir(path): continue path = os.path.normcase(os.path.abspath(path)) if not path.startswith(hom...
448,542
def fixup_pth_and_egg_link(home_dir): """Makes .pth and .egg-link files use relative paths""" home_dir = os.path.normcase(os.path.abspath(home_dir)) for path in sys.path: if not path: path = '.' if not os.path.isdir(path): continue path = os.path.normcase(os.path.abspath(path)) if not path.startswith(home_dir): logger....
def fixup_pth_and_egg_link(home_dir): """Makes .pth and .egg-link files use relative paths""" home_dir = os.path.normcase(os.path.abspath(home_dir)) if sys_path is None: sys_path = sys.path for path in sys_path: if not path: path = '.' if not os.path.isdir(path): continue path = os.path.normcase(os.path.abspath(path)) ...
448,543
def fixup_scripts(home_dir): # This is what we expect at the top of scripts: shebang = '#!%s/bin/python' % os.path.normcase(os.path.abspath(home_dir)) # This is what we'll put: new_shebang = '#!/usr/bin/env python%s' % sys.version[:3] activate = "import os; activate_this=os.path.join(os.path.dirname(__file__), 'activat...
def fixup_scripts(home_dir): # This is what we expect at the top of scripts: shebang = '#!%s/bin/python' % os.path.normcase(os.path.abspath(home_dir)) # This is what we'll put: new_shebang = '#!/usr/bin/env python%s' % sys.version[:3] activate = "import os; activate_this=os.path.join(os.path.dirname(__file__), 'activat...
448,544
def change_prefix(filename, dst_prefix): prefixes = [sys.prefix] if hasattr(sys, 'real_prefix'): prefixes.append(sys.real_prefix) prefixes = map(os.path.abspath, prefixes) filename = os.path.abspath(filename) for src_prefix in prefixes: if filename.startswith(src_prefix): _, relpath = filename.split(src_prefix, 1) asse...
def change_prefix(filename, dst_prefix): prefixes = [sys.prefix] if hasattr(sys, 'real_prefix'): prefixes.append(sys.real_prefix) prefixes = map(os.path.abspath, prefixes) filename = os.path.abspath(filename) for src_prefix in prefixes: if filename.startswith(src_prefix): _, relpath = filename.split(src_prefix, 1) asse...
448,545
def call_subprocess(cmd, show_stdout=True, filter_stdout=None, cwd=None, raise_on_returncode=True, extra_env=None): cmd_parts = [] for part in cmd: if len(part) > 40: part = part[:30]+"..."+part[-5:] if ' ' in part or '\n' in part or '"' in part or "'" in part: part = '"%s"' % part.replace('"', '\\"') cmd_parts.append(...
def call_subprocess(cmd, show_stdout=True, filter_stdout=None, cwd=None, raise_on_returncode=True, extra_env=None, remove_from_env=None): cmd_parts = [] for part in cmd: if len(part) > 40: part = part[:30]+"..."+part[-5:] if ' ' in part or '\n' in part or '"' in part or "'" in part: part = '"%s"' % part.replace('"', '\...
448,546
def call_subprocess(cmd, show_stdout=True, filter_stdout=None, cwd=None, raise_on_returncode=True, extra_env=None): cmd_parts = [] for part in cmd: if len(part) > 40: part = part[:30]+"..."+part[-5:] if ' ' in part or '\n' in part or '"' in part or "'" in part: part = '"%s"' % part.replace('"', '\\"') cmd_parts.append(...
def call_subprocess(cmd, show_stdout=True, filter_stdout=None, cwd=None, raise_on_returncode=True, extra_env=None): cmd_parts = [] for part in cmd: if len(part) > 40: part = part[:30]+"..."+part[-5:] if ' ' in part or '\n' in part or '"' in part or "'" in part: part = '"%s"' % part.replace('"', '\\"') cmd_parts.append(...
448,547
def call_subprocess(cmd, show_stdout=True, filter_stdout=None, cwd=None, raise_on_returncode=True, extra_env=None): cmd_parts = [] for part in cmd: if len(part) > 40: part = part[:30]+"..."+part[-5:] if ' ' in part or '\n' in part or '"' in part or "'" in part: part = '"%s"' % part.replace('"', '\\"') cmd_parts.append(...
def call_subprocess(cmd, show_stdout=True, filter_stdout=None, cwd=None, raise_on_returncode=True, extra_env=None): cmd_parts = [] for part in cmd: if len(part) > 40: part = part[:30]+"..."+part[-5:] if ' ' in part or '\n' in part or '"' in part or "'" in part: part = '"%s"' % part.replace('"', '\\"') cmd_parts.append(...
448,548
def install_python(home_dir, lib_dir, inc_dir, bin_dir, site_packages, clear): """Install just the base environment, no distutils patches etc""" if sys.executable.startswith(bin_dir): print 'Please use the *system* python to run this script' return if clear: rmtree(lib_dir) ## FIXME: why not delete it? ## Maybe it sho...
def install_python(home_dir, lib_dir, inc_dir, bin_dir, site_packages, clear): """Install just the base environment, no distutils patches etc""" if sys.executable.startswith(bin_dir): print 'Please use the *system* python to run this script' return if clear: rmtree(lib_dir) ## FIXME: why not delete it? ## Maybe it sho...
448,549
def install_pip(py_executable): filenames = [] for dir in file_search_dirs(): filenames.extend([join(dir, fn) for fn in os.listdir(dir) if _pip_re.search(fn)]) filenames.sort(key=lambda x: os.path.basename(x).lower()) if not filenames: filename = 'pip' else: filename = filenames[-1] easy_install_script = 'easy_install'...
def install_pip(py_executable): filenames = [] for dir in file_search_dirs(): filenames.extend([join(dir, fn) for fn in os.listdir(dir) if _pip_re.search(fn)]) filenames = [(os.path.basename(filename).lower(), i, filename) for i, filename in enumerate(filenames)] filenames.sort() filenames = [filename for basename, i, ...
448,550
def main(): parser = optparse.OptionParser( version=virtualenv_version, usage="%prog [OPTIONS] DEST_DIR") parser.add_option( '-v', '--verbose', action='count', dest='verbose', default=0, help="Increase verbosity") parser.add_option( '-q', '--quiet', action='count', dest='quiet', default=0, help='Decrease verbosity') ...
def main(): parser = optparse.OptionParser( version=virtualenv_version, usage="%prog [OPTIONS] DEST_DIR") parser.add_option( '-v', '--verbose', action='count', dest='verbose', default=0, help="Increase verbosity") parser.add_option( '-q', '--quiet', action='count', dest='quiet', default=0, help='Decrease verbosity') ...
448,551
def create_environment(home_dir, site_packages=True, clear=False, unzip_setuptools=False, use_distribute=False): """ Creates a new environment in ``home_dir``. If ``site_packages`` is true (the default) then the global ``site-packages/`` directory will be on the path. If ``clear`` is true (default False) then the env...
def create_environment(home_dir, site_packages=True, clear=False, unzip_setuptools=False, use_distribute=False, prompt=None): """ Creates a new environment in ``home_dir``. If ``site_packages`` is true (the default) then the global ``site-packages/`` directory will be on the path. If ``clear`` is true (default False)...
448,552
def create_environment(home_dir, site_packages=True, clear=False, unzip_setuptools=False, use_distribute=False): """ Creates a new environment in ``home_dir``. If ``site_packages`` is true (the default) then the global ``site-packages/`` directory will be on the path. If ``clear`` is true (default False) then the env...
def create_environment(home_dir, site_packages=True, clear=False, unzip_setuptools=False, use_distribute=False): """ Creates a new environment in ``home_dir``. If ``site_packages`` is true (the default) then the global ``site-packages/`` directory will be on the path. If ``clear`` is true (default False) then the env...
448,553
def install_activate(home_dir, bin_dir): if sys.platform == 'win32' or is_jython and os._name == 'nt': files = {'activate.bat': ACTIVATE_BAT, 'deactivate.bat': DEACTIVATE_BAT} if os.environ.get('OS') == 'Windows_NT' and os.environ.get('OSTYPE') == 'cygwin': files['activate'] = ACTIVATE_SH else: files = {'activate': ACT...
def install_activate(home_dir, bin_dir, prompt=None): if sys.platform == 'win32' or is_jython and os._name == 'nt': files = {'activate.bat': ACTIVATE_BAT, 'deactivate.bat': DEACTIVATE_BAT} if os.environ.get('OS') == 'Windows_NT' and os.environ.get('OSTYPE') == 'cygwin': files['activate'] = ACTIVATE_SH else: files = {'a...
448,554
def install_activate(home_dir, bin_dir): if sys.platform == 'win32' or is_jython and os._name == 'nt': files = {'activate.bat': ACTIVATE_BAT, 'deactivate.bat': DEACTIVATE_BAT} if os.environ.get('OS') == 'Windows_NT' and os.environ.get('OSTYPE') == 'cygwin': files['activate'] = ACTIVATE_SH else: files = {'activate': ACT...
def install_activate(home_dir, bin_dir): if sys.platform == 'win32' or is_jython and os._name == 'nt': files = {'activate.bat': ACTIVATE_BAT, 'deactivate.bat': DEACTIVATE_BAT} if os.environ.get('OS') == 'Windows_NT' and os.environ.get('OSTYPE') == 'cygwin': files['activate'] = ACTIVATE_SH else: files = {'activate': ACT...
448,555
def after_install(options, home_dir): subprocess.call([join(home_dir, 'bin', 'easy_install'), 'MyPackage']) subprocess.call([join(home_dir, 'bin', 'my-package-script'), 'setup', home_dir])
def after_install(options, home_dir): subprocess.call([join(home_dir, 'bin', 'easy_install'), 'MyPackage']) subprocess.call([join(home_dir, 'bin', 'my-package-script'), 'setup', home_dir])
448,556
def after_install(options, home_dir): subprocess.call([join(home_dir, 'bin', 'easy_install'), 'MyPackage']) subprocess.call([join(home_dir, 'bin', 'my-package-script'), 'setup', home_dir])
def after_install(options, home_dir): subprocess.call([join(home_dir, 'bin', 'easy_install'), 'MyPackage']) subprocess.call([join(home_dir, 'bin', 'my-package-script'), 'setup', home_dir])
448,557
def after_install(options, home_dir): subprocess.call([join(home_dir, 'bin', 'easy_install'), 'MyPackage']) subprocess.call([join(home_dir, 'bin', 'my-package-script'), 'setup', home_dir])
def after_install(options, home_dir): subprocess.call([join(home_dir, 'bin', 'easy_install'), 'MyPackage']) subprocess.call([join(home_dir, 'bin', 'my-package-script'), 'setup', home_dir])
448,558
def after_install(options, home_dir): subprocess.call([join(home_dir, 'bin', 'easy_install'), 'MyPackage']) subprocess.call([join(home_dir, 'bin', 'my-package-script'), 'setup', home_dir])
def after_install(options, home_dir): subprocess.call([join(home_dir, 'bin', 'easy_install'), 'MyPackage']) subprocess.call([join(home_dir, 'bin', 'my-package-script'), 'setup', home_dir])
448,559
def after_install(options, home_dir): subprocess.call([join(home_dir, 'bin', 'easy_install'), 'MyPackage']) subprocess.call([join(home_dir, 'bin', 'my-package-script'), 'setup', home_dir])
def after_install(options, home_dir): subprocess.call([join(home_dir, 'bin', 'easy_install'), 'MyPackage']) subprocess.call([join(home_dir, 'bin', 'my-package-script'), 'setup', home_dir])
448,560
def after_install(options, home_dir): subprocess.call([join(home_dir, 'bin', 'easy_install'), 'MyPackage']) subprocess.call([join(home_dir, 'bin', 'my-package-script'), 'setup', home_dir])
def after_install(options, home_dir): subprocess.call([join(home_dir, 'bin', 'easy_install'), 'MyPackage']) subprocess.call([join(home_dir, 'bin', 'my-package-script'), 'setup', home_dir])
448,561
def make_environment_relocatable(home_dir): """ Makes the already-existing environment use relative paths, and takes out the #!-based environment selection in scripts. """ activate_this = os.path.join(home_dir, 'bin', 'activate_this.py') if not os.path.exists(activate_this): logger.fatal( 'The environment doesn\'t have...
def make_environment_relocatable(home_dir): """ Makes the already-existing environment use relative paths, and takes out the #!-based environment selection in scripts. """ home_dir, lib_dir, inc_dir, bin_dir = path_locations(home_dir) activate_this = os.path.join(bin_dir, 'activate_this.py') if not os.path.exists(activ...
448,562
def change_prefix(filename, src_prefix, dst_prefix): assert filename.startswith(src_prefix) _, relpath = filename.split(src_prefix, 1) assert relpath[0] == '/' relpath = relpath[1:] return join(dst_prefix, relpath)
def change_prefix(filename, src_prefix, dst_prefix): assert filename.startswith(src_prefix) _, relpath = filename.split(src_prefix, 1) assert relpath[0] == '/' relpath = relpath[1:] return join(dst_prefix, relpath)
448,563
def copy_required_modules(src_prefix, dst_prefix): for modname in REQUIRED_MODULES: if modname in sys.builtin_module_names: logger.notify("Ignoring built-in bootstrap module: %s" % mod) continue try: mod = __import__(modname) except ImportError: logger.notify("Cannot import bootstrap module: %s" % modname) else: filena...
def copy_required_modules(src_prefix, dst_prefix): for modname in REQUIRED_MODULES: if modname in sys.builtin_module_names: logger.notify("Ignoring built-in bootstrap module: %s" % mod) continue try: mod = __import__(modname) except ImportError: logger.notify("Cannot import bootstrap module: %s" % modname) else: filena...
448,564
def install_python(home_dir, lib_dir, inc_dir, bin_dir, site_packages, clear): """Install just the base environment, no distutils patches etc""" if sys.executable.startswith(bin_dir): print 'Please use the *system* python to run this script' return if clear: rmtree(lib_dir) ## FIXME: why not delete it? ## Maybe it sho...
def install_python(home_dir, lib_dir, inc_dir, bin_dir, site_packages, clear): """Install just the base environment, no distutils patches etc""" if sys.executable.startswith(bin_dir): print 'Please use the *system* python to run this script' return if clear: rmtree(lib_dir) ## FIXME: why not delete it? ## Maybe it sho...
448,565
def install_python(home_dir, lib_dir, inc_dir, bin_dir, site_packages, clear): """Install just the base environment, no distutils patches etc""" if sys.executable.startswith(bin_dir): print 'Please use the *system* python to run this script' return if clear: rmtree(lib_dir) ## FIXME: why not delete it? ## Maybe it sho...
def install_python(home_dir, lib_dir, inc_dir, bin_dir, site_packages, clear): """Install just the base environment, no distutils patches etc""" if sys.executable.startswith(bin_dir): print 'Please use the *system* python to run this script' return if clear: rmtree(lib_dir) ## FIXME: why not delete it? ## Maybe it sho...
448,566
def main(): parser = optparse.OptionParser( version=virtualenv_version, usage="%prog [OPTIONS] DEST_DIR") parser.add_option( '-v', '--verbose', action='count', dest='verbose', default=0, help="Increase verbosity") parser.add_option( '-q', '--quiet', action='count', dest='quiet', default=0, help='Decrease verbosity') ...
def main(): parser = optparse.OptionParser( version=virtualenv_version, usage="%prog [OPTIONS] DEST_DIR") parser.add_option( '-v', '--verbose', action='count', dest='verbose', default=0, help="Increase verbosity") parser.add_option( '-q', '--quiet', action='count', dest='quiet', default=0, help='Decrease verbosity') ...
448,567
def install_python(home_dir, lib_dir, inc_dir, bin_dir, site_packages, clear): """Install just the base environment, no distutils patches etc""" if sys.executable.startswith(bin_dir): print 'Please use the *system* python to run this script' return if clear: rmtree(lib_dir) ## FIXME: why not delete it? ## Maybe it sho...
def install_python(home_dir, lib_dir, inc_dir, bin_dir, site_packages, clear): """Install just the base environment, no distutils patches etc""" if sys.executable.startswith(bin_dir): print 'Please use the *system* python to run this script' return if clear: rmtree(lib_dir) ## FIXME: why not delete it? ## Maybe it sho...
448,568
def main(): parser = optparse.OptionParser( version=virtualenv_version, usage="%prog [OPTIONS] DEST_DIR") parser.add_option( '-v', '--verbose', action='count', dest='verbose', default=0, help="Increase verbosity") parser.add_option( '-q', '--quiet', action='count', dest='quiet', default=0, help='Decrease verbosity') ...
def main(): parser = optparse.OptionParser( version=virtualenv_version, usage="%prog [OPTIONS] DEST_DIR") parser.add_option( '-v', '--verbose', action='count', dest='verbose', default=0, help="Increase verbosity") parser.add_option( '-q', '--quiet', action='count', dest='quiet', default=0, help='Decrease verbosity') ...
448,569
def __call__(self): request = self.request container = self.context.context image = request.form.get('image', '')
def __call__(self): request = self.request container = self.context.context image = request.form.get('image', '')
448,570
def __call__(self): request = self.request container = self.context.context image = request.form.get('image', '')
def __call__(self): request = self.request container = self.context.context image = request.form.get('image', '')
448,571
def __call__(self): request = self.request container = self.context.context media = request.form.get('image', '') description = request.form.get('description', '') if not media: return encoder.encode({'success': 'false', 'message': ''})
def __call__(self): request = self.request container = self.context.context media = request.form.get('image', '') description = request.form.get('description', '') if not media: return encoder.encode({'success': 'false', 'message': ''})
448,572
def __call__(self): request = self.request container = self.context.context media = request.form.get('image', '') description = request.form.get('description', '') if not media: return encoder.encode({'success': 'false', 'message': ''})
def __call__(self): request = self.request container = self.context.context media = request.form.get('image', '') description = request.form.get('description', '') if not media: return encoder.encode({'success': 'false', 'message': ''})
448,573
def main(): parser = OptionParser() parser.add_option("-c", "--config", help="Full path to config file to use") parser.add_option("-f", "--foreground", default=False, action="store_true", help="run in foreground (do not spawn a daemon)") parser.add_option("-p", "--pid-file", help="specify a pid file") (opts, args) = pa...
def main(): parser = OptionParser() parser.add_option("-c", "--config", help="Full path to config file to use") parser.add_option("-f", "--foreground", default=False, action="store_true", help="run in foreground (do not spawn a daemon)") parser.add_option("-p", "--pid-file", help="specify a pid file") (opts, args) = pa...
448,574
def __init__(self): self.__remotes = {} ExtBackend.__init__(self) self.def_port = config.get_conf('beah-backend').get('DEFAULT', 'PORT')
def __init__(self): self.__remotes = {} ExtBackend.__init__(self) self.def_port = config.get_conf('beah-backend').get('DEFAULT', 'PORT')
448,575
def remote_backend(self, dest): dest_s = '%s:%s' % dest rb = self.__remotes.get(dest_s, None) if rb is None: rb = _RemoteBackend(self, dest) start_backend(rb, host=dest[0], port=dest[1]) self.__remotes[dest_s] = rb return rb
def remote_backend(self, dest): dest_s = '%s:%s' % dest rb = self.__remotes.get(dest_s, None) if rb is None: rb = _RemoteBackend(self, dest) start_backend(rb, host=dest[0], port=dest[1], byef=lambda evt: None) self.__remotes[dest_s] = rb return rb
448,576
def remote_backend(self, dest): dest_s = '%s:%s' % dest rb = self.__remotes.get(dest_s, None) if rb is None: rb = _RemoteBackend(self, dest) start_backend(rb, host=dest[0], port=dest[1]) self.__remotes[dest_s] = rb return rb
def remote_backend(self, dest): dest_s = '%s:%s' % dest rb = self.__remotes.get(dest_s, None) if rb is None: rb = _RemoteBackend(self, dest) start_backend(rb, host=dest[0], port=dest[1]) self.__remotes[dest_s] = rb return rb
448,577
def __init__(self, caller, dest, queue=None, pending=None): self.__caller = caller self.__dest = dest self.__queue = queue or [] self.__pending = pending or {} self.__status = self._NEW ExtBackend.__init__(self)
def __init__(self, caller, dest, queue=None, pending=None): self.__caller = caller self.__dest = dest self.__queue = queue or [] self.__pending = pending or {} self.__status = self._NEW ExtBackend.__init__(self)
448,578
def clone(self): return _RemoteBackend(self.__caller, self.__dest, self.__queue, self.__pending)
def clone(self): return _RemoteBackend(self.__caller, self.__dest, self.__queue, self.__pending)
448,579
def main(): config.backend_conf( defaults={'NAME':'beah_forwarder_backend'}, overrides=config.backend_opts()) log_handler() start_forwarder_backend() reactor.run()
def main(): config.backend_conf( defaults={'NAME':'beah_forwarder_backend'}, overrides=config.backend_opts()) log_handler() start_forwarder_backend() reactor.run()
448,580
def test_recipe_elements_in_different_order(self): self.assert_valid(''' <job> <recipeSet retention_tag="scratch"> <recipe kernel_options="" kernel_options_post="" ks_meta="" role="None" whiteboard=""> <partitions/> <task name="/distribution/install" role="STANDALONE"/> <repos/> <ks_appends/> <hostRequires> <system_typ...
def test_recipe_elements_in_different_order(self): self.assert_valid(''' <job> <recipeSet retention_tag="scratch"> <recipe kernel_options="" kernel_options_post="" ks_meta="" role="None" whiteboard=""> <partitions/> <task name="/distribution/install" role="STANDALONE"/> <repos/> <ks_appends/> <hostRequires> <system_typ...
448,581
def test_duplicate_elements(self): self.assert_not_valid(''' <job> <recipeSet retention_tag="scratch"> <recipe kernel_options="" kernel_options_post="" ks_meta="" role="None" whiteboard=""> <autopick random="True"/> <autopick random="False"/> <watchdog panic="None"/> <watchdog panic="always"/> <packages/> <packages/> <...
def test_duplicate_elements(self): self.assert_not_valid(''' <job> <recipeSet retention_tag="scratch"> <recipe kernel_options="" kernel_options_post="" ks_meta="" role="None" whiteboard=""> <autopick random="true"/> <autopick random="false"/> <watchdog panic="None"/> <watchdog panic="always"/> <packages/> <packages/> <...
448,582
def test_duplicate_elements(self): self.assert_not_valid(''' <job> <recipeSet retention_tag="scratch"> <recipe kernel_options="" kernel_options_post="" ks_meta="" role="None" whiteboard=""> <autopick random="True"/> <autopick random="False"/> <watchdog panic="None"/> <watchdog panic="always"/> <packages/> <packages/> <...
def test_duplicate_elements(self): self.assert_not_valid(''' <job> <recipeSet retention_tag="scratch"> <recipe kernel_options="" kernel_options_post="" ks_meta="" role="None" whiteboard=""> <autopick random="True"/> <autopick random="False"/> <watchdog panic="None"/> <watchdog panic="always"/> <packages/> <packages/> <...
448,583
def parse_recipe_xml(input_xml, hostname): root = minidom.parseString(input_xml) for er in root.getElementsByTagName('recipe'): system = xml_attr(er, 'system') if system == hostname: break else: for er in root.getElementsByTagName('guestrecipe'): system = xml_attr(er, 'system') if system == hostname: break else: log.i...
def parse_recipe_xml(input_xml, hostname): root = minidom.parseString(input_xml) for er in root.getElementsByTagName('recipe'): system = xml_attr(er, 'system') if system == hostname: break else: for er in root.getElementsByTagName('guestrecipe'): system = xml_attr(er, 'system') if system == hostname: break else: log.i...
448,584
def main_loop(conf=None, foreground=False): """infinite daemon loop""" # define custom signal handlers signal.signal(signal.SIGTERM, daemon_shutdown) config = kobo.conf.PyConfigParser() # load default config default_config = os.path.abspath(os.path.join(os.path.dirname(__file__), "default.conf")) config.load_from_fi...
def main_loop(conf=None, foreground=False): """infinite daemon loop""" # define custom signal handlers signal.signal(signal.SIGTERM, daemon_shutdown) config = kobo.conf.PyConfigParser() # load default config default_config = os.path.abspath(os.path.join(os.path.dirname(__file__), "default.conf")) config.load_from_fi...
448,585
def parse_recipe_xml(input_xml, hostname): root = minidom.parseString(input_xml) for er in root.getElementsByTagName('recipe'): system = xml_attr(er, 'system') if system == hostname: break else: log.info("parse_recipe_xml: No recipe for %s." % hostname) return None task_env = {} rs = xml_attr(er, 'status') if rs not ...
def parse_recipe_xml(input_xml, hostname): root = minidom.parseString(input_xml) for er in root.getElementsByTagName('recipe'): system = xml_attr(er, 'system') if system == hostname: break else: log.info("parse_recipe_xml: No recipe for %s." % hostname) return None task_env = {} rs = xml_attr(er, 'status') if rs not ...
448,586
def test_can_sort_by_id(self): self.check_column_sort(1)
def test_can_sort_by_id(self): self.check_column_sort(1)
448,587
def process_taskinfo(self, raw_taskinfo): tinfo = testinfo.parse_string(raw_taskinfo['desc'])
def process_taskinfo(self, raw_taskinfo): tinfo = testinfo.parse_string(raw_taskinfo['desc'])
448,588
def process_taskinfo(self, raw_taskinfo): tinfo = testinfo.parse_string(raw_taskinfo['desc'])
def process_taskinfo(self, raw_taskinfo): tinfo = testinfo.parse_string(raw_taskinfo['desc'])
448,589
def get_search_options(self,table_field,**kw): return_dict = {} search = su.System.search.search_on(table_field #Determine what field type we are dealing with. If it is Boolean, convert our values to 0 for False # and 1 for True col_type = su.System.search.field_type(table_field) if col_type.lower() == 'boolean': se...
def get_search_options(self,table_field,**kw): return_dict = {} search = su.System.search.search_on(table_field) #Determine what field type we are dealing with. If it is Boolean, convert our values to 0 for False # and 1 for True col_type = su.System.search.field_type(table_field) if col_type.lower() == 'boolean': s...
448,590
#def _build_grid(self,data,**kw):
#def _build_grid(self,data,**kw):
448,591
def arch_stat_getter(cls,x): s = 'Pass:%s Fail:%s Warn:%s' % (x.Pass,x.Fail,x.Warn) return s
def arch_stat_getter(cls,x): s = 'Pass:%s Fail:%s Warn:%s' % (x.Pass,x.Fail,x.Warn) return s
448,592
def generate(self,**kw): grid_data = self.generate_data(**kw) grid = DataGrid(fields = self._job_grid_fields()) return {'grid' : grid, 'data' : grid_data }
def generate(self,**kw): grid_data = self.generate_data(**kw) arches_used = {} for grid in grid_data: arches_used[grid.arch] = 1 grid = DataGrid(fields = self._job_grid_fields(arches_used.keys())) return {'grid' : grid, 'data' : grid_data }
448,593
def generate_data(self,**kw): jobs = [] whiteboard_data = {} if 'job_ids' in kw: jobs = kw['job_ids'].split() elif 'whiteboard' in kw: job_query = model.Job.query().filter(model.Job.whiteboard == kw['whiteboard']) for job in job_query: jobs.append(job.id) else: pass #raise AssertionError('Incorrect or no filter passed ...
def generate_data(self,**kw): jobs = [] whiteboard_data = {} if 'job_ids' in kw: jobs = kw['job_ids'].split() elif 'whiteboard' in kw: job_query = model.Job.query().filter(model.Job.whiteboard == kw['whiteboard']) for job in job_query: jobs.append(job.id) else: pass #raise AssertionError('Incorrect or no filter passed ...
448,594
def generate_data(self,**kw): jobs = [] whiteboard_data = {} if 'job_ids' in kw: jobs = kw['job_ids'].split() elif 'whiteboard' in kw: job_query = model.Job.query().filter(model.Job.whiteboard == kw['whiteboard']) for job in job_query: jobs.append(job.id) else: pass #raise AssertionError('Incorrect or no filter passed ...
def generate_data(self,**kw): jobs = [] whiteboard_data = {} if 'job_ids' in kw: jobs = kw['job_ids'].split() elif 'whiteboard' in kw: job_query = model.Job.query().filter(model.Job.whiteboard == kw['whiteboard']) for job in job_query: jobs.append(job.id) else: pass #raise AssertionError('Incorrect or no filter passed ...
448,595
def generate_data(self,**kw): jobs = [] whiteboard_data = {} if 'job_ids' in kw: jobs = kw['job_ids'].split() elif 'whiteboard' in kw: job_query = model.Job.query().filter(model.Job.whiteboard == kw['whiteboard']) for job in job_query: jobs.append(job.id) else: pass #raise AssertionError('Incorrect or no filter passed ...
def generate_data(self,**kw): jobs = [] whiteboard_data = {} if 'job_ids' in kw: jobs = kw['job_ids'].split() elif 'whiteboard' in kw: job_query = model.Job.query().filter(model.Job.whiteboard == kw['whiteboard']) for job in job_query: jobs.append(job.id) else: pass #raise AssertionError('Incorrect or no filter passed ...
448,596
def generate_data(self,**kw): jobs = [] whiteboard_data = {} if 'job_ids' in kw: jobs = kw['job_ids'].split() elif 'whiteboard' in kw: job_query = model.Job.query().filter(model.Job.whiteboard == kw['whiteboard']) for job in job_query: jobs.append(job.id) else: pass #raise AssertionError('Incorrect or no filter passed ...
def class OuterDynamo(object): pass result_data = [] my_hash = {} generate_data(self,**kw): class OuterDynamo(object): pass result_data = [] my_hash = {} jobs class OuterDynamo(object): pass result_data = [] my_hash = {} = class OuterDynamo(object): pass result_data = [] my_hash = {} [] class OuterDynamo(objec...
448,597
def generate_data(self,**kw): jobs = [] whiteboard_data = {} if 'job_ids' in kw: jobs = kw['job_ids'].split() elif 'whiteboard' in kw: job_query = model.Job.query().filter(model.Job.whiteboard == kw['whiteboard']) for job in job_query: jobs.append(job.id) else: pass #raise AssertionError('Incorrect or no filter passed ...
def generate_data(self,**kw): jobs = [] whiteboard_data = {} if 'job_ids' in kw: jobs = kw['job_ids'].split() elif 'whiteboard' in kw: job_query = model.Job.query().filter(model.Job.whiteboard == kw['whiteboard']) for job in job_query: jobs.append(job.id) else: pass #raise AssertionError('Incorrect or no filter passed ...
448,598
def suspicious_abort(self): if self.type != SystemType.by_name(u'Machine'): return # Since its last status change, has this system had an # uninterrupted run of aborted recipes leading up to this one, with # at least two different STABLE distros? outer_recipe = recipe_table.alias() status_change_subquery = select([func...
def suspicious_abort(self): if self.type != SystemType.by_name(u'Machine'): return # Since its last status change, has this system had an # uninterrupted run of aborted recipes leading up to this one, with # at least two different STABLE distros? status_change_subquery = select([func.max(activity_table.c.created)], fro...
448,599