bugged
stringlengths
4
228k
fixed
stringlengths
0
96.3M
__index_level_0__
int64
0
481k
def htmlify(match): div, mod = divmod(len(match.group(0)), 2) return div * '  ' + mod * ' '
def htmlify(match): div, mod = divmod(len(match.group(0)), 2) return div * '  ' + mod * ' '
25,400
def htmlify(match): div, mod = divmod(len(match.group(0)), 2) return div * '  ' + mod * ' '
def htmlify(match): div, mod = divmod(len(match.group(0)), 2) return div * '  ' + mod * ' '
25,401
def htmlify(match): div, mod = divmod(len(match.group(0)), 2) return div * '  ' + mod * ' '
def htmlify(match): div, mod = divmod(len(match.group(0)), 2) return div * '  ' + mod * ' '
25,402
def process_newticket_request(self, req): req.perm.require('TICKET_CREATE') data = {} db = self.env.get_db_cnx()
def process_newticket_request(self, req): req.perm.require('TICKET_CREATE') data = {} db = self.env.get_db_cnx()
25,403
def process_newticket_request(self, req): req.perm.require('TICKET_CREATE') data = {} db = self.env.get_db_cnx()
def process_newticket_request(self, req): req.perm.require('TICKET_CREATE') data = {} db = self.env.get_db_cnx()
25,404
def process_newticket_request(self, req): req.perm.require('TICKET_CREATE') data = {} db = self.env.get_db_cnx()
def process_newticket_request(self, req): req.perm.require('TICKET_CREATE') data = {} db = self.env.get_db_cnx()
25,405
def process_ticket_request(self, req): req.perm.require('TICKET_VIEW') data = {}
def process_ticket_request(self, req): req.perm.require('TICKET_VIEW') data = {}
25,406
def _do_create(self, req, db): if 'summary' not in req.args: raise TracError('Tickets must contain a summary.')
def _do_create(self, req, db): if 'field_summary' not in req.args: raise TracError('Tickets must contain a summary.')
25,407
def _do_create(self, req, db): if 'summary' not in req.args: raise TracError('Tickets must contain a summary.')
def _do_create(self, req, db): if 'summary' not in req.args: raise TracError('Tickets must contain a summary.')
25,408
def _do_save(self, req, db, ticket): if 'TICKET_CHGPROP' in req.perm: # TICKET_CHGPROP gives permission to edit the ticket if not req.args.get('summary'): raise TracError('Tickets must contain summary.')
def _do_save(self, req, db, ticket): if 'TICKET_CHGPROP' in req.perm: # TICKET_CHGPROP gives permission to edit the ticket if not req.args.get('field_summary'): raise TracError('Tickets must contain summary.')
25,409
def _do_save(self, req, db, ticket): if 'TICKET_CHGPROP' in req.perm: # TICKET_CHGPROP gives permission to edit the ticket if not req.args.get('summary'): raise TracError('Tickets must contain summary.')
def _do_save(self, req, db, ticket): if 'TICKET_CHGPROP' in req.perm: # TICKET_CHGPROP gives permission to edit the ticket if not req.args.get('summary'): raise TracError('Tickets must contain summary.')
25,410
def _do_save(self, req, db, ticket): if 'TICKET_CHGPROP' in req.perm: # TICKET_CHGPROP gives permission to edit the ticket if not req.args.get('summary'): raise TracError('Tickets must contain summary.')
def _do_save(self, req, db, ticket): if 'TICKET_CHGPROP' in req.perm: # TICKET_CHGPROP gives permission to edit the ticket if not req.args.get('summary'): raise TracError('Tickets must contain summary.')
25,411
def quote_original(author, original, link): if 'comment' not in req.args: # i.e. the comment was not yet edited data['comment'] = '\n'.join( ['Replying to [%s %s]:' % (link, author)] + ['> %s' % line for line in original.splitlines()] + [''])
def quote_original(author, original, link): if 'comment' not in req.args: # i.e. the comment was not yet edited data['comment'] = '\n'.join( ['Replying to [%s %s]:' % (link, author)] + ['> %s' % line for line in original.splitlines()] + [''])
25,412
def process_request(self, req): req.perm.assert_permission(perm.REPORT_VIEW)
def process_request(self, req): req.perm.assert_permission(perm.REPORT_VIEW)
25,413
def _heading_formatter(self, match, fullmatch): match = match.strip() self.close_table() self.close_paragraph() self.close_indentation() self.close_list() self.close_def_list()
def _heading_formatter(self, match, fullmatch): match = match.strip() self.close_table() self.close_paragraph() self.close_indentation() self.close_list() self.close_def_list()
25,414
def render (self): perm.assert_permission (perm.CHANGESET_VIEW) if self.args.has_key('rev'): self.rev = int(self.args['rev']) else: self.rev = fs.youngest_rev(self.fs_ptr, self.pool)
def render (self): perm.assert_permission (perm.CHANGESET_VIEW) if self.args.has_key('rev'): self.rev = int(self.args['rev']) else: self.rev = fs.youngest_rev(self.fs_ptr, self.pool)
25,415
def _do_component_set_owner(self, name, owner): cnx = self.db_open() cursor = cnx.cursor () cursor.execute('SELECT name FROM component WHERE name=%s', name) data = cursor.fetchone() if not data: raise Exception("No such component '%s'" % name) data = self.db_execsql("UPDATE component SET owner='%s' WHERE name='%s'" % (...
def _do_component_set_owner(self, name, owner): cnx = self.db_open() cursor = cnx.cursor () cursor.execute('SELECT name FROM component WHERE name=%s', name) data = cursor.fetchone() if not data: raise Exception("No such component '%s'" % name) data = self.db_execsql("UPDATE component SET owner='%s' WHERE name='%s'" % (...
25,416
def do_permission(self, line): arg = self.arg_tokenize(line) try: if arg[0] == 'list': self._do_permission_list() elif arg[0] == 'add' and len(arg) >= 3: user = arg[1] for action in arg[2:]: self._do_permission_add(user, action) elif arg[0] == 'remove' and len(arg) >= 3: user = arg[1] for action in arg[2:]: self._do_...
def do_permission(self, line): arg = self.arg_tokenize(line) try: if arg[0] == 'list': user = None if len(arg) > 1: user = arg[1] self._do_permission_list(user) elif arg[0] == 'add' and len(arg) >= 3: user = arg[1] for action in arg[2:]: self._do_permission_add(user, action) elif arg[0] == 'remove' and len(arg) >= 3:...
25,417
def do_permission(self, line): arg = self.arg_tokenize(line) try: if arg[0] == 'list': self._do_permission_list() elif arg[0] == 'add' and len(arg) >= 3: user = arg[1] for action in arg[2:]: self._do_permission_add(user, action) elif arg[0] == 'remove' and len(arg) >= 3: user = arg[1] for action in arg[2:]: self._do_...
def do_permission(self, line): arg = self.arg_tokenize(line) try: if arg[0] == 'list': self._do_permission_list() elif arg[0] == 'add' and len(arg) >= 3: user = arg[1] for action in arg[2:]: self._do_permission_add(user, action) elif arg[0] == 'remove' and len(arg) >= 3: user = arg[1] for action in arg[2:]: self._do_...
25,418
def _do_permission_list(self): data = self.db_execsql('SELECT username, action FROM permission ' \ 'ORDER BY username, action') self.print_listing(['User', 'Action'], data) print print 'Available actions:' actions = perm.permissions + perm.meta_permissions.keys() actions.sort() text = ', '.join(actions) print util.wrap...
def _do_permission_list(self, user=None): if user: data = self.db_execsql("SELECT username, action FROM permission " "WHERE username='%s' ORDER BY action" % user) else: data = self.db_execsql("SELECT username, action FROM permission " "ORDER BY username, action") self.print_listing(['User', 'Action'], data) print print...
25,419
def render (self): self.perm.assert_permission(perm.TIMELINE_VIEW)
def render (self): self.perm.assert_permission(perm.TIMELINE_VIEW)
25,420
def match_request(self, req): match = re.match(r'^/(raw-)?attachment/([^/]+)(?:[/:](.*))?$', req.path_info) if match: req.args['format'] = match.group(1) and 'raw' or '' req.args['type'] = match.group(2) req.args['path'] = match.group(3).replace(':', '/') return True
def match_request(self, req): match = re.match(r'^/(raw-)?attachment/([^/]+)(?:[/:](.*))?$', req.path_info) if match: if match.group(1): req.args['format'] = 'raw' req.args['type'] = match.group(2) req.args['path'] = match.group(3).replace(':', '/') return True
25,421
def shorten_line(text, maxlen = 75): if len(text or '') < maxlen: return text shortline = text[:maxlen] cut = shortline.rfind(' ') + 1 or shortline.rfind('\n') + 1 or maxlen shortline = text[:cut]+' ...' return shortline
def shorten_line(text, maxlen=75): if len(text or '') < maxlen: return text shortline = text[:maxlen] cut = shortline.rfind(' ') + 1 or shortline.rfind('\n') + 1 or maxlen shortline = text[:cut]+' ...' return shortline
25,422
def wrap(t, cols=75, initial_indent='', subsequent_indent='', linesep=os.linesep): try: import textwrap t = t.strip().replace('\r\n', '\n').replace('\r', '\n') wrapper = textwrap.TextWrapper(cols, replace_whitespace = 0, break_long_words = 0, initial_indent = initial_indent, subsequent_indent = subsequent_indent) wrapp...
def wrap(t, cols=75, initial_indent='', subsequent_indent='', linesep=os.linesep): try: import textwrap t = t.strip().replace('\r\n', '\n').replace('\r', '\n') wrapper = textwrap.TextWrapper(cols, replace_whitespace=0, break_long_words=0, initial_indent=initial_indent, subsequent_indent=subsequent_indent) wrappedLines ...
25,423
def __init__(self, path, create=False, options=[]): """Initialize the Trac environment. @param path: the absolute path to the Trac environment @param create: if `True`, the environment is created and populated with default data; otherwise, the environment is expected to already exist. @param options: A list of `(sec...
def __init__(self, path, create=False, options=[]): """Initialize the Trac environment. @param path: the absolute path to the Trac environment @param create: if `True`, the environment is created and populated with default data; otherwise, the environment is expected to already exist. @param options: A list of `(sec...
25,424
def _create_file(fname, data=None): fd = open(fname, 'w') if data: fd.write(data) fd.close()
def _create_file(fname, data=None): fd = open(fname, 'w') if data: fd.write(data) fd.close()
25,425
def setup_config(self): """Load the configuration file.""" self.config = Configuration(os.path.join(self.path, 'conf', 'trac.ini'))
def setup_config(self, load_defaults=False): """Load the configuration file.""" self.config = Configuration(os.path.join(self.path, 'conf', 'trac.ini'))
25,426
def do_resync(self, line): print 'Resyncing repository history...' cnx = self.db_open() cursor = cnx.cursor() cursor.execute("DELETE FROM revision") cursor.execute("DELETE FROM node_change") repos = self.__env.get_repository() cursor.execute("DELETE FROM system WHERE name='repository_dir'") repos.sync() print 'Done.'
def do_resync(self, line): print 'Resyncing repository history...' cnx = self.db_open() cursor = cnx.cursor() cursor.execute("DELETE FROM revision") cursor.execute("DELETE FROM node_change") cursor.execute("DELETE FROM system WHERE name='repository_dir'") repos.sync() print 'Done.'
25,427
def do_resync(self, line): print 'Resyncing repository history...' cnx = self.db_open() cursor = cnx.cursor() cursor.execute("DELETE FROM revision") cursor.execute("DELETE FROM node_change") repos = self.__env.get_repository() cursor.execute("DELETE FROM system WHERE name='repository_dir'") repos.sync() print 'Done.'
def do_resync(self, line): print 'Resyncing repository history...' cnx = self.db_open() cursor = cnx.cursor() cursor.execute("DELETE FROM revision") cursor.execute("DELETE FROM node_change") repos = self.__env.get_repository() cursor.execute("DELETE FROM system WHERE name='repository_dir'") repos = self.__env.get_repos...
25,428
def render_macro(self, req, name, content): prefix = limit = None if content: argv = [arg.strip() for arg in content.split(',')] if len(argv) > 0: prefix = argv[0].replace('\'', '\'\'') if len(argv) > 1: limit = int(argv[1])
def render_macro(self, req, name, content): prefix = limit = None if content: argv = [arg.strip() for arg in content.split(',')] if len(argv) > 0: prefix = argv[0].replace('\'', '\'\'') if len(argv) > 1: limit = int(argv[1])
25,429
def render_macro(self, req, name, content): prefix = limit = None if content: argv = [arg.strip() for arg in content.split(',')] if len(argv) > 0: prefix = argv[0].replace('\'', '\'\'') if len(argv) > 1: limit = int(argv[1])
def render_macro(self, req, name, content): prefix = limit = None if content: argv = [arg.strip() for arg in content.split(',')] if len(argv) > 0: prefix = argv[0].replace('\'', '\'\'') if len(argv) > 1: limit = int(argv[1])
25,430
def render_macro(self, req, name, content): prefix = limit = None if content: argv = [arg.strip() for arg in content.split(',')] if len(argv) > 0: prefix = argv[0].replace('\'', '\'\'') if len(argv) > 1: limit = int(argv[1])
def render_macro(self, req, name, content): prefix = limit = None if content: argv = [arg.strip() for arg in content.split(',')] if len(argv) > 0: prefix = argv[0].replace('\'', '\'\'') if len(argv) > 1: limit = int(argv[1])
25,431
def save(self, author, comment, remote_addr, t=time.time(), db=None): if not db: db = self.env.get_db_cnx() handle_ta = True else: handle_ta = False
def save(self, author, comment, remote_addr, t=None, db=None): if not db: db = self.env.get_db_cnx() handle_ta = True else: handle_ta = False
25,432
def render(self): FileCommon.render(self) rev = self.args.get('rev', None) self.path = self.args.get('path', '/') if not rev: rev_specified = 0 rev = svn.fs.youngest_rev(self.fs_ptr, self.pool) else: rev_specified = 1 try: rev = int(rev) except ValueError: rev_specified = 0 rev = svn.fs.youngest_rev(self.fs_ptr, self....
def render(self): FileCommon.render(self) rev = self.args.get('rev', None) self.path = self.args.get('path', '/') if not rev: rev_specified = 0 rev = svn.fs.youngest_rev(self.fs_ptr, self.pool) else: rev_specified = 1 try: rev = int(rev) except ValueError: rev_specified = 0 rev = svn.fs.youngest_rev(self.fs_ptr, self....
25,433
def render(self): FileCommon.render(self) rev = self.args.get('rev', None) self.path = self.args.get('path', '/') if not rev: rev_specified = 0 rev = svn.fs.youngest_rev(self.fs_ptr, self.pool) else: rev_specified = 1 try: rev = int(rev) except ValueError: rev_specified = 0 rev = svn.fs.youngest_rev(self.fs_ptr, self....
def render(self): FileCommon.render(self) rev = self.args.get('rev', None) self.path = self.args.get('path', '/') if not rev: rev_specified = 0 rev = svn.fs.youngest_rev(self.fs_ptr, self.pool) else: rev_specified = 1 try: rev = int(rev) except ValueError: rev_specified = 0 rev = svn.fs.youngest_rev(self.fs_ptr, self....
25,434
def render(self): FileCommon.render(self) rev = self.args.get('rev', None) self.path = self.args.get('path', '/') if not rev: rev_specified = 0 rev = svn.fs.youngest_rev(self.fs_ptr, self.pool) else: rev_specified = 1 try: rev = int(rev) except ValueError: rev_specified = 0 rev = svn.fs.youngest_rev(self.fs_ptr, self....
def render(self): FileCommon.render(self) rev = self.args.get('rev', None) self.path = self.args.get('path', '/') if not rev: rev_specified = 0 rev = svn.fs.youngest_rev(self.fs_ptr, self.pool) else: rev_specified = 1 try: rev = int(rev) except ValueError: rev_specified = 0 rev = svn.fs.youngest_rev(self.fs_ptr, self....
25,435
def _do_wiki_export(self, page, filename=''): data = self.db_query("SELECT text FROM wiki WHERE name='%s' " "ORDER BY version DESC LIMIT 1" % page) text = data[0][0] if not filename: print text else: if os.path.isfile(filename): raise Exception("File '%s' exists" % filename) f = open(filename,'w') f.write(text) f.close...
def _do_wiki_export(self, page, filename=''): data = self.db_query("SELECT text FROM wiki WHERE name='%s' " "ORDER BY version DESC LIMIT 1" % page) text = data.next()[0] if not filename: print text else: if os.path.isfile(filename): raise Exception("File '%s' exists" % filename) f = open(filename,'w') f.write(text) f.c...
25,436
def render_macro(self, req, name, content): query_string = '' compact = 0 argv = content.split(',') if len(argv) > 0: query_string = argv[0] if len(argv) > 1: if argv[1].strip().lower() == 'compact': compact = 1 try: from cStringIO import StringIO except NameError: from StringIO import StringIO buf = StringIO()
def render_macro(self, req, name, content): query_string = '' compact = 0 argv = content.split(',') if len(argv) > 0: query_string = argv[0] if len(argv) > 1: if argv[1].strip().lower() == 'compact': compact = 1 try: from cStringIO import StringIO except NameError: from StringIO import StringIO buf = StringIO()
25,437
def render_macro(self, req, name, content): query_string = '' compact = 0 argv = content.split(',') if len(argv) > 0: query_string = argv[0] if len(argv) > 1: if argv[1].strip().lower() == 'compact': compact = 1 try: from cStringIO import StringIO except NameError: from StringIO import StringIO buf = StringIO()
def render_macro(self, req, name, content): query_string = '' compact = 0 argv = content.split(',') if len(argv) > 0: query_string = argv[0] if len(argv) > 1: if argv[1].strip().lower() == 'compact': compact = 1 try: from cStringIO import StringIO except NameError: from StringIO import StringIO buf = StringIO()
25,438
def validate_ticket(req, ticket): for manipulator in self.ticket_manipulators: for field, message in manipulator.validate_ticket(req, ticket): if field: raise TracError("The ticket %s field is invalid: %s" % (field, message)) else: raise TracError("Invalid ticket: %s" % message)
def _validate_ticket(self, req, ticket): for manipulator in self.ticket_manipulators: for field, message in manipulator.validate_ticket(req, ticket): if field: raise TracError("The ticket %s field is invalid: %s" % (field, message)) else: raise TracError("Invalid ticket: %s" % message)
25,439
def process_request(self, req): req.perm.assert_permission('TICKET_CREATE')
def process_request(self, req): req.perm.assert_permission('TICKET_CREATE')
25,440
def _do_create(self, req, db): if not req.args.get('summary'): raise TracError('Tickets must contain a summary.')
def _do_create(self, req, db): if not req.args.get('summary'): raise TracError('Tickets must contain a summary.')
25,441
def process_request(self, req): req.perm.assert_permission('TICKET_VIEW')
def process_request(self, req): req.perm.assert_permission('TICKET_VIEW')
25,442
def _do_save(self, req, db, ticket): if req.perm.has_permission('TICKET_CHGPROP'): # TICKET_CHGPROP gives permission to edit the ticket if not req.args.get('summary'): raise TracError('Tickets must contain summary.')
def _do_save(self, req, db, ticket): if req.perm.has_permission('TICKET_CHGPROP'): # TICKET_CHGPROP gives permission to edit the ticket if not req.args.get('summary'): raise TracError('Tickets must contain summary.')
25,443
def _listitem_formatter(self, match, fullmatch): depth = int((len(fullmatch.group('ldepth')) + 1) / 2) #self.out.write('depth:%d' % depth) type = ['ol', 'ul'][match[depth * 2 - 1] == '*'] self._li_open = 1 self._set_list_depth(depth, type) return '<li>' #return '<li>%s</li>' % match[depth * 2 + 1:]
def _listitem_formatter(self, match, fullmatch): ldepth = len(fullmatch.group('ldepth')) depth = int((ldepth + 1) / 2) #self.out.write('depth:%d' % depth) type = ['ol', 'ul'][match[depth * 2 - 1] == '*'] self._li_open = 1 self._set_list_depth(depth, type) return '<li>' #return '<li>%s</li>' % match[depth * 2 + 1:]
25,444
def _listitem_formatter(self, match, fullmatch): depth = int((len(fullmatch.group('ldepth')) + 1) / 2) #self.out.write('depth:%d' % depth) type = ['ol', 'ul'][match[depth * 2 - 1] == '*'] self._li_open = 1 self._set_list_depth(depth, type) return '<li>' #return '<li>%s</li>' % match[depth * 2 + 1:]
def _listitem_formatter(self, match, fullmatch): depth = int((len(fullmatch.group('ldepth')) + 1) / 2) #self.out.write('depth:%d' % depth) type = ['ol', 'ul'][match[ldepth] == '*'] self._li_open = 1 self._set_list_depth(depth, type) return '<li>' #return '<li>%s</li>' % match[depth * 2 + 1:]
25,445
def __init__(self, env, constraints=None, order=None, desc=0, group=None, groupdesc = 0, verbose=0): self.env = env self.constraints = constraints or {} self.order = order self.desc = desc self.group = group self.groupdesc = groupdesc self.verbose = verbose self.fields = TicketSystem(self.env).get_ticket_fields() self....
def __init__(self, env, constraints=None, order=None, desc=0, group=None, groupdesc = 0, verbose=0): self.env = env self.constraints = constraints or {} self.order = order self.desc = desc self.group = group self.groupdesc = groupdesc self.verbose = verbose self.fields = TicketSystem(self.env).get_ticket_fields() self....
25,446
def get_info(self, req, start, stop, maxrows, filters=AVAILABLE_FILTERS): perm_map = {'ticket': perm.TICKET_VIEW, 'changeset': perm.CHANGESET_VIEW, 'wiki': perm.WIKI_VIEW, 'milestone': perm.MILESTONE_VIEW} filters = list(filters) # copy list so we can make modifications for k,v in perm_map.items(): if k in filters and ...
def get_info(self, req, start, stop, maxrows, filters=AVAILABLE_FILTERS): perm_map = {'ticket': perm.TICKET_VIEW, 'changeset': perm.CHANGESET_VIEW, 'wiki': perm.WIKI_VIEW, 'milestone': perm.MILESTONE_VIEW} filters = list(filters) # copy list so we can make modifications for k,v in perm_map.items(): if k in filters and ...
25,447
def _render_changeset(self, req, item): absurls = req.args.get('format') == 'rss' href = self.env.href if absurls: href = self.env.abs_href
def _render_changeset(self, req, item): absurls = req.args.get('format') == 'rss' href = self.env.href if absurls: href = self.env.abs_href
25,448
def _render_changeset(self, req, item): absurls = req.args.get('format') == 'rss' href = self.env.href if absurls: href = self.env.abs_href
def _render_changeset(self, req, item): absurls = req.args.get('format') == 'rss' href = self.env.href if absurls: href = self.env.abs_href
25,449
def _render_changeset(self, req, item): absurls = req.args.get('format') == 'rss' href = self.env.href if absurls: href = self.env.abs_href
def _render_changeset(self, req, item): absurls = req.args.get('format') == 'rss' href = self.env.href if absurls: href = self.env.abs_href
25,450
def populate_hdf(hdf, env, db, req): sql_to_hdf(db, "SELECT name FROM enum WHERE type='priority' " "ORDER BY value", hdf, 'enums.priority') sql_to_hdf(db, "SELECT name FROM enum WHERE type='severity' " "ORDER BY value", hdf, 'enums.severity') htdocs_location = env.get_config('trac', 'htdocs_location') if htdocs_locati...
def populate_hdf(hdf, env, db, req): sql_to_hdf(db, "SELECT name FROM enum WHERE type='priority' " "ORDER BY value", hdf, 'enums.priority') sql_to_hdf(db, "SELECT name FROM enum WHERE type='severity' " "ORDER BY value", hdf, 'enums.severity') htdocs_location = env.get_config('trac', 'htdocs_location') if htdocs_locati...
25,451
def insert(self, filename, fileobj, size, time=time.time(), db=None): if not db: db = self.env.get_db_cnx() handle_ta = True else: handle_ta = False
def insert(self, filename, fileobj, size, t=None, db=None): if not db: db = self.env.get_db_cnx() handle_ta = True else: handle_ta = False
25,452
def insert(self, filename, fileobj, size, time=time.time(), db=None): if not db: db = self.env.get_db_cnx() handle_ta = True else: handle_ta = False
def insert(self, filename, fileobj, size, time=time.time(), db=None): if not db: db = self.env.get_db_cnx() handle_ta = True else: handle_ta = False
25,453
def htmlify(match): m = match.group('spaces') if m: div, mod = divmod(len(m), 2) return div * '&nbsp; ' + mod * '&nbsp;' return (match.group('tag') or '') + '&nbsp;'
def htmlify(match): m = match.group('spaces') if m: div, mod = divmod(len(m), 2) return div * '&nbsp; ' + mod * '&nbsp;' return (match.group('tag') or '') + '&nbsp;'
25,454
def save(self, author, comment, remote_addr, t=time.time(), db=None): if not db: db = self.env.get_db_cnx() handle_ta = True else: handle_ta = False
def save(self, author, comment, remote_addr, t=time.time(), db=None): if not db: db = self.env.get_db_cnx() handle_ta = True else: handle_ta = False
25,455
def finalize(self): """ The rename detection is deferred until the end of edition, as 'delete' and 'add' notifications can happen in any order. """ for node_type, path, old_path, old_rev, action in self.additions: if self.deletions.has_key(old_path): # normal rename self.deletions.pop(old_path) action = 'R' elif self.d...
def finalize(self): """ The rename detection is deferred until the end of edition, as 'delete' and 'add' notifications can happen in any order. """ for node_type, path, old_path, old_rev, action in self.additions: if self.deletions.has_key(old_path): # normal rename del self.deletions[old_path] action = 'R' elif self.d...
25,456
def finalize(self): """ The rename detection is deferred until the end of edition, as 'delete' and 'add' notifications can happen in any order. """ for node_type, path, old_path, old_rev, action in self.additions: if self.deletions.has_key(old_path): # normal rename self.deletions.pop(old_path) action = 'R' elif self.d...
def finalize(self): """ The rename detection is deferred until the end of edition, as 'delete' and 'add' notifications can happen in any order. """ for node_type, path, old_path, old_rev, action in self.additions: if self.deletions.has_key(old_path): # normal rename self.deletions.pop(old_path) action = 'R' elif self.d...
25,457
def match_request(self, req): return re.match('/(login|logout)/?', req.path_info)
def match_request(self, req): return re.match('/(login|logout)/?', req.path_info)
25,458
def produce((id, ts, author, type, summary), status, fields, comment, cid): if status == 'edit': if 'ticket_details' in filters: info = '' if len(fields) > 0: info = ', '.join(['<i>%s</i>' % f for f in \ fields.keys()]) + ' changed<br />' else: return None elif 'ticket' in filters: if status == 'closed' and fields.has_...
def produce((id, ts, author, type, summary), status, fields, comment, cid): if status == 'edit': if 'ticket_details' in filters: if len(fields) > 0: info = ', '.join(['<i>%s</i>' % f for f in \ fields.keys()]) + ' changed<br />' else: return None elif 'ticket' in filters: if status == 'closed' and fields.has_key('resol...
25,459
def produce((id, ts, author, type, summary), status, fields, comment, cid): if status == 'edit': if 'ticket_details' in filters: info = '' if len(fields) > 0: info = ', '.join(['<i>%s</i>' % f for f in \ fields.keys()]) + ' changed<br />' else: return None elif 'ticket' in filters: if status == 'closed' and fields.has_...
def produce((id, ts, author, type, summary), status, fields, comment, cid): if status == 'edit': if 'ticket_details' in filters: info = '' if len(fields) > 0: keys = fields.keys() info = html([[html.i(f), ', '] for f in keys[:-1]], html.i(keys[-1]), ' changed', html.br()) else: return None elif 'ticket' in filters: if ...
25,460
def produce((id, ts, author, type, summary), status, fields, comment, cid): if status == 'edit': if 'ticket_details' in filters: info = '' if len(fields) > 0: info = ', '.join(['<i>%s</i>' % f for f in \ fields.keys()]) + ' changed<br />' else: return None elif 'ticket' in filters: if status == 'closed' and fields.has_...
def produce((id, ts, author, type, summary), status, fields, comment, cid): if status == 'edit': if 'ticket_details' in filters: info = '' if len(fields) > 0: info = ', '.join(['<i>%s</i>' % f for f in \ fields.keys()]) + ' changed<br />' else: return None elif 'ticket' in filters: if status == 'closed' and fields.has_...
25,461
def produce((id, ts, author, type, summary), status, fields, comment, cid): if status == 'edit': if 'ticket_details' in filters: info = '' if len(fields) > 0: info = ', '.join(['<i>%s</i>' % f for f in \ fields.keys()]) + ' changed<br />' else: return None elif 'ticket' in filters: if status == 'closed' and fields.has_...
def produce((id, ts, author, type, summary), status, fields, comment, cid): if status == 'edit': if 'ticket_details' in filters: info = '' if len(fields) > 0: info = ', '.join(['<i>%s</i>' % f for f in \ fields.keys()]) + ' changed<br />' else: return None elif 'ticket' in filters: if status == 'closed' and fields.has_...
25,462
def produce((id, ts, author, type, summary), status, fields, comment, cid): if status == 'edit': if 'ticket_details' in filters: info = '' if len(fields) > 0: info = ', '.join(['<i>%s</i>' % f for f in \ fields.keys()]) + ' changed<br />' else: return None elif 'ticket' in filters: if status == 'closed' and fields.has_...
def produce((id, ts, author, type, summary), status, fields, comment, cid): if status == 'edit': if 'ticket_details' in filters: info = '' if len(fields) > 0: info = ', '.join(['<i>%s</i>' % f for f in \ fields.keys()]) + ' changed<br />' else: return None elif 'ticket' in filters: if status == 'closed' and fields.has_...
25,463
def produce((id, ts, author, type, summary), status, fields, comment, cid): if status == 'edit': if 'ticket_details' in filters: info = '' if len(fields) > 0: info = ', '.join(['<i>%s</i>' % f for f in \ fields.keys()]) + ' changed<br />' else: return None elif 'ticket' in filters: if status == 'closed' and fields.has_...
def produce((id, ts, author, type, summary), status, fields, comment, cid): if status == 'edit': if 'ticket_details' in filters: info = '' if len(fields) > 0: info = ', '.join(['<i>%s</i>' % f for f in \ fields.keys()]) + ' changed<br />' else: return None elif 'ticket' in filters: if status == 'closed' and fields.has_...
25,464
def writeline(self, text): if text[0:2] in ['++', '--']: return match = line_re.search(text) if match: self.print_block() self.changeno += 1 self.blockno = 0 self.offset_base = int(match.group(1)) - 1 self.offset_changed = int(match.group(3)) - 1 return ttype = text[0] text = text[1:] text = text.expandtabs(self.tabwid...
def writeline(self, text): match = line_re.search(text) if match: self.print_block() self.changeno += 1 self.blockno = 0 self.offset_base = int(match.group(1)) - 1 self.offset_changed = int(match.group(3)) - 1 return ttype = text[0] text = text[1:] text = text.expandtabs(self.tabwidth) if ttype == self.ttype: self.bloc...
25,465
def writeline(self, text): if text[0:2] in ['++', '--']: return match = line_re.search(text) if match: self.print_block() self.changeno += 1 self.blockno = 0 self.offset_base = int(match.group(1)) - 1 self.offset_changed = int(match.group(3)) - 1 return ttype = text[0] text = text[1:] text = text.expandtabs(self.tabwid...
def writeline(self, text): if text[0:2] in ['++', '--']: return match = line_re.search(text) if match: self.print_block() self.changeno += 1 self.blockno = 0 self.offset_base = int(match.group(1)) - 1 self.offset_changed = int(match.group(3)) - 1 return elif not self.changeno: return ttype, text = text[0], text[1:].ex...
25,466
def send_project_index(environ, start_response, parent_dir=None, env_paths=None): from trac.config import default_dir req = Request(environ, start_response) loadpaths = [default_dir('templates')] if req.environ.get('trac.env_index_template'): tmpl_path, template = os.path.split(req.environ['trac.env_index_template'])...
def send_project_index(environ, start_response, parent_dir=None, env_paths=None): from trac.config import default_dir req = Request(environ, start_response) loadpaths = [default_dir('templates')] if req.environ.get('trac.env_index_template'): tmpl_path, template = os.path.split(req.environ['trac.env_index_template'])...
25,467
def render(self): name = self.args.get('page', 'WikiStart') author = self.args.get('author', get_reporter_id(self.req)) edit_version = self.args.get('edit_version', None) delete_ver = self.args.get('delete_ver', None) delete_page = self.args.get('delete_page', None) comment = self.args.get('comment', '') save = self.ar...
def render(self): name = self.args.get('page', 'WikiStart') author = self.args.get('author', get_reporter_id(self.req)) edit_version = self.args.get('edit_version', None) delete_ver = self.args.get('delete_ver', None) delete_page = self.args.get('delete_page', None) comment = self.args.get('comment', '') save = self.ar...
25,468
def _render_view(self, req, db, id): """ uses a user specified sql query to extract some information from the database and presents it as a html table. """ actions = {'create': perm.REPORT_CREATE, 'delete': perm.REPORT_DELETE, 'modify': perm.REPORT_MODIFY} for action in [k for k,v in actions.items() if req.perm.has_per...
def _render_view(self, req, db, id): """ uses a user specified sql query to extract some information from the database and presents it as a html table. """ actions = {'create': perm.REPORT_CREATE, 'delete': perm.REPORT_DELETE, 'modify': perm.REPORT_MODIFY} for action in [k for k,v in actions.items() if req.perm.has_per...
25,469
def sql_sub_vars(self, req, sql, args): m = re.search(dynvars_re, sql) if not m: return sql aname=m.group()[1:] try: arg = args[aname] except KeyError: raise util.TracError("Dynamic variable '$%s' not defined." % aname) req.hdf['report.var.' + aname] = arg sql = m.string[:m.start()] + arg + m.string[m.end():] return se...
def sql_sub_vars(self, req, sql, args): m = re.search(dynvars_re, sql) if not m: return sql aname=m.group()[1:] try: arg = args[aname] except KeyError: raise util.TracError("Dynamic variable '$%s' not defined." % aname) req.hdf['report.var.' + aname] = arg sql = m.string[:m.start()] + arg + m.string[m.end():] return se...
25,470
def verify(self): """Verify that the provided path points to a valid Trac environment directory.""" try: fd = open(os.path.join(self.path, 'VERSION'), 'r') assert fd.read(26) == 'Trac Environment Version 1' finally: fd.close()
def verify(self): """Verify that the provided path points to a valid Trac environment directory.""" try: fd = open(os.path.join(self.path, 'VERSION'), 'r') assert fd.read(26) == 'Trac Environment Version 1' finally: fd.close()
25,471
def __init__(self, path): self.env = trac.env.Environment(path) self._db = self.env.get_db_cnx() self._db.autocommit = False self.loginNameCache = {} self.fieldNameCache = {}
def __init__(self, path): self.env = Environment(path) self._db = self.env.get_db_cnx() self._db.autocommit = False self.loginNameCache = {} self.fieldNameCache = {}
25,472
def hasTickets(self): c = self.db().cursor() c.execute('''SELECT count(*) FROM Ticket''') return int(c.fetchall()[0][0]) > 0
def hasTickets(self): c = self.db().cursor() c.execute("SELECT count(*) FROM Ticket") return int(c.fetchall()[0][0]) > 0
25,473
def setSeverityList(self, s): """Remove all severities, set them to `s`""" self.assertNoTickets() c = self.db().cursor() c.execute("""DELETE FROM enum WHERE type='severity'""") for value, i in s: print "inserting severity ", value, " ", i c.execute("""INSERT INTO enum (type, name, value) VALUES (%s, %s, %s)""", "sever...
def setSeverityList(self, s): """Remove all severities, set them to `s`""" self.assertNoTickets() c = self.db().cursor() c.execute("DELETE FROM enum WHERE type='severity'") for value, i in s: print "inserting severity ", value, " ", i c.execute("""INSERT INTO enum (type, name, value) VALUES (%s, %s, %s)""", "severity"...
25,474
def setSeverityList(self, s): """Remove all severities, set them to `s`""" self.assertNoTickets() c = self.db().cursor() c.execute("""DELETE FROM enum WHERE type='severity'""") for value, i in s: print "inserting severity ", value, " ", i c.execute("""INSERT INTO enum (type, name, value) VALUES (%s, %s, %s)""", "sever...
def setSeverityList(self, s): """Remove all severities, set them to `s`""" self.assertNoTickets() c = self.db().cursor() c.execute("""DELETE FROM enum WHERE type='severity'""") for value, i in s: print " inserting severity '%s' - '%s'" % (value, i) c.execute("""INSERT INTO enum (type, name, value) VALUES (%s, %s, %s)...
25,475
def setPriorityList(self, s): """Remove all priorities, set them to `s`""" self.assertNoTickets() c = self.db().cursor() c.execute("""DELETE FROM enum WHERE type='priority'""") for value, i in s: print "inserting priority ", value, " ", i c.execute("""INSERT INTO enum (type, name, value) VALUES (%s, %s, %s)""", "prior...
def setPriorityList(self, s): """Remove all priorities, set them to `s`""" self.assertNoTickets() c = self.db().cursor() c.execute("DELETE FROM enum WHERE type='priority'") for value, i in s: print "inserting priority ", value, " ", i c.execute("""INSERT INTO enum (type, name, value) VALUES (%s, %s, %s)""", "priority"...
25,476
def setPriorityList(self, s): """Remove all priorities, set them to `s`""" self.assertNoTickets() c = self.db().cursor() c.execute("""DELETE FROM enum WHERE type='priority'""") for value, i in s: print "inserting priority ", value, " ", i c.execute("""INSERT INTO enum (type, name, value) VALUES (%s, %s, %s)""", "prior...
def setPriorityList(self, s): """Remove all priorities, set them to `s`""" self.assertNoTickets() c = self.db().cursor() c.execute("""DELETE FROM enum WHERE type='priority'""") for value, i in s: print " inserting priority '%s' - '%s'" % (value, i) c.execute("""INSERT INTO enum (type, name, value) VALUES (%s, %s, %s)...
25,477
def setComponentList(self, l, key): """Remove all components, set them to `l`""" self.assertNoTickets() c = self.db().cursor() c.execute("""DELETE FROM component""") for comp in l: print "inserting component '",comp[key],"', owner", comp['owner'] c.execute("""INSERT INTO component (name, owner) VALUES (%s, %s)""", co...
def setComponentList(self, l, key): """Remove all components, set them to `l`""" self.assertNoTickets() c = self.db().cursor() c.execute("DELETE FROM component") for comp in l: print "inserting component '",comp[key],"', owner", comp['owner'] c.execute("""INSERT INTO component (name, owner) VALUES (%s, %s)""", comp[k...
25,478
def setComponentList(self, l, key): """Remove all components, set them to `l`""" self.assertNoTickets() c = self.db().cursor() c.execute("""DELETE FROM component""") for comp in l: print "inserting component '",comp[key],"', owner", comp['owner'] c.execute("""INSERT INTO component (name, owner) VALUES (%s, %s)""", co...
def setComponentList(self, l, key): """Remove all components, set them to `l`""" self.assertNoTickets() c = self.db().cursor() c.execute("""DELETE FROM component""") for comp in l: print " inserting component '%s', owner '%s'" % \ (comp[key], comp['owner']) c.execute("INSERT INTO component (name, owner) VALUES (%s, %...
25,479
def setVersionList(self, v, key): """Remove all versions, set them to `v`""" self.assertNoTickets() c = self.db().cursor() c.execute("""DELETE FROM version""") for vers in v: print "inserting version ", vers[key] c.execute("""INSERT INTO version (name) VALUES (%s)""", vers[key].encode('utf-8')) self.db().commit()
def setVersionList(self, v, key): """Remove all versions, set them to `v`""" self.assertNoTickets() c = self.db().cursor() c.execute("DELETE FROM version") for vers in v: print "inserting version ", vers[key] c.execute("""INSERT INTO version (name) VALUES (%s)""", vers[key].encode('utf-8')) self.db().commit()
25,480
def setVersionList(self, v, key): """Remove all versions, set them to `v`""" self.assertNoTickets() c = self.db().cursor() c.execute("""DELETE FROM version""") for vers in v: print "inserting version ", vers[key] c.execute("""INSERT INTO version (name) VALUES (%s)""", vers[key].encode('utf-8')) self.db().commit()
def setVersionList(self, v, key): """Remove all versions, set them to `v`""" self.assertNoTickets() c = self.db().cursor() c.execute("""DELETE FROM version""") for vers in v: print " inserting version '%s'" % (vers[key]) c.execute("INSERT INTO version (name) VALUES (%s)", (vers[key],)) self.db().commit()
25,481
def setMilestoneList(self, m, key): """Remove all milestones, set them to `m`""" self.assertNoTickets() c = self.db().cursor() c.execute("""DELETE FROM milestone""") for ms in m: print "inserting milestone ", ms[key] c.execute("""INSERT INTO milestone (name) VALUES (%s)""", ms[key].encode('utf-8')) self.db().commit()
def setMilestoneList(self, m, key): """Remove all milestones, set them to `m`""" self.assertNoTickets() c = self.db().cursor() c.execute("DELETE FROM milestone") for ms in m: print "inserting milestone ", ms[key] c.execute("""INSERT INTO milestone (name) VALUES (%s)""", ms[key].encode('utf-8')) self.db().commit()
25,482
def setMilestoneList(self, m, key): """Remove all milestones, set them to `m`""" self.assertNoTickets() c = self.db().cursor() c.execute("""DELETE FROM milestone""") for ms in m: print "inserting milestone ", ms[key] c.execute("""INSERT INTO milestone (name) VALUES (%s)""", ms[key].encode('utf-8')) self.db().commit()
def setMilestoneList(self, m, key): """Remove all milestones, set them to `m`""" self.assertNoTickets() c = self.db().cursor() c.execute("""DELETE FROM milestone""") for ms in m: milestone = ms[key] print " inserting milestone '%s'" % (milestone) c.execute("INSERT INTO milestone (name) VALUES (%s)", (milestone.encode...
25,483
def addTicket(self, id, time, changetime, component, severity, priority, owner, reporter, cc, version, milestone, status, resolution, summary, description, keywords): c = self.db().cursor() desc = description.encode('utf-8') if PREFORMAT_COMMENTS: desc = '{{{\n%s\n}}}' % desc
def addTicket(self, id, time, changetime, component, severity, priority, owner, reporter, cc, version, milestone, status, resolution, summary, description, keywords): c = self.db().cursor() desc = description.encode('utf-8') if PREFORMAT_COMMENTS: desc = '{{{\n%s\n}}}' % desc
25,484
def addTicket(self, id, time, changetime, component, severity, priority, owner, reporter, cc, version, milestone, status, resolution, summary, description, keywords): c = self.db().cursor() desc = description.encode('utf-8') if PREFORMAT_COMMENTS: desc = '{{{\n%s\n}}}' % desc
def addTicket(self, id, time, changetime, component, severity, priority, owner, reporter, cc, version, milestone, status, resolution, summary, description, keywords): c = self.db().cursor() desc = description.encode('utf-8') if PREFORMAT_COMMENTS: desc = '{{{\n%s\n}}}' % desc
25,485
def addTicket(self, id, time, changetime, component, severity, priority, owner, reporter, cc, version, milestone, status, resolution, summary, description, keywords): c = self.db().cursor() desc = description.encode('utf-8') if PREFORMAT_COMMENTS: desc = '{{{\n%s\n}}}' % desc
def addTicket(self, id, time, changetime, component, severity, priority, owner, reporter, cc, version, milestone, status, resolution, summary, description, keywords): c = self.db().cursor() desc = description.encode('utf-8') if PREFORMAT_COMMENTS: desc = '{{{\n%s\n}}}' % desc
25,486
def addTicketComment(self, ticket, time, author, value): comment = value.encode('utf-8') if PREFORMAT_COMMENTS: comment = '{{{\n%s\n}}}' % comment
def addTicketComment(self, ticket, time, author, value): comment = value.encode('utf-8') if PREFORMAT_COMMENTS: comment = '{{{\n%s\n}}}' % comment
25,487
def addTicketChange(self, ticket, time, author, field, oldvalue, newvalue): c = self.db().cursor() c.execute("""INSERT INTO ticket_change (ticket, time, author, field, oldvalue, newvalue) VALUES (%s, %s, %s, %s, %s, %s)""", ticket, time.strftime('%s'), author, field, oldvalue.encode('utf-8'), newvalue.encode('ut...
def addTicketChange(self, ticket, time, author, field, oldvalue, newvalue): c = self.db().cursor() if field == "priority": if PRIORITIES_MAP.has_key(oldvalue.lower()): oldvalue = PRIORITIES_MAP[oldvalue.lower()] if PRIORITIES_MAP.has_key(newvalue.lower()): newvalue = PRIORITIES_MAP[newvalue.lower()] if oldvalue == n...
25,488
def addAttachment(self, id, attachment, description, author): print 'inserting attachment for ticket %s -- %s' % (id, description) attachment.filename = attachment.filename.encode('utf-8') self.env.create_attachment(self.db(), 'ticket', str(id), attachment, description.encode('utf-8'), author, 'unknown')
def addAttachment(self, author, a): description = a['description'].encode('utf-8') id = a['bug_id'] filename = a['filename'].encode('utf-8') filedata = StringIO.StringIO(a['thedata'].tostring()) filesize = len(filedata.getvalue()) time = a['creation_ts'] print " ->inserting attachment '%s' for ticket %s -- %s" % \ (...
25,489
def getLoginName(self, cursor, userid): if userid not in self.loginNameCache: cursor.execute("SELECT * FROM profiles WHERE userid = %s" % userid) loginName = cursor.fetchall()
def getLoginName(self, cursor, userid): if userid not in self.loginNameCache: cursor.execute("SELECT * FROM profiles WHERE userid = %s", (userid)) loginName = cursor.fetchall()
25,490
def getLoginName(self, cursor, userid): if userid not in self.loginNameCache: cursor.execute("SELECT * FROM profiles WHERE userid = %s" % userid) loginName = cursor.fetchall()
def getLoginName(self, cursor, userid): if userid not in self.loginNameCache: cursor.execute("SELECT * FROM profiles WHERE userid = %s" % userid) loginName = cursor.fetchall()
25,491
def getFieldName(self, cursor, fieldid): if fieldid not in self.fieldNameCache: cursor.execute("SELECT * FROM fielddefs WHERE fieldid = %s" % fieldid) fieldName = cursor.fetchall()
def getFieldName(self, cursor, fieldid): if fieldid not in self.fieldNameCache: cursor.execute("SELECT * FROM fielddefs WHERE fieldid = %s", (fieldid)) fieldName = cursor.fetchall()
25,492
def getFieldName(self, cursor, fieldid): if fieldid not in self.fieldNameCache: cursor.execute("SELECT * FROM fielddefs WHERE fieldid = %s" % fieldid) fieldName = cursor.fetchall()
def getFieldName(self, cursor, fieldid): if fieldid not in self.fieldNameCache: cursor.execute("SELECT * FROM fielddefs WHERE fieldid = %s" % fieldid) fieldName = cursor.fetchall()
25,493
def productFilter(fieldName, products): first = True result = '' for product in products: if not first: result += " or " first = False result += "%s = '%s'" % (fieldName, product) return result
def makeWhereClause(fieldName, values, negative=False): if not values: return '' if negative: connector, op = ' AND ', '!=' else: connector, op = ' OR ', '=' clause = connector.join(["%s %s '%s'" % (fieldName, op, value) for value in values]) return ' ' + clause
25,494
def convert(_db, _host, _user, _password, _env, _force): activityFields = FieldTranslator() # account for older versions of bugzilla if BZ_VERSION == '2.11': print 'Using Buzvilla v%s schema.' % BZ_VERSION activityFields['removed'] = 'oldvalue' activityFields['added'] = 'newvalue' # init Bugzilla environment print "B...
def convert(_db, _host, _user, _password, _env, _force): activityFields = FieldTranslator() # account for older versions of bugzilla print "Using Bugzilla v%s schema." % BZ_VERSION if BZ_VERSION == 2110: activityFields['removed'] = "oldvalue" activityFields['added'] = "newvalue" # init Bugzilla environment print "Bug...
25,495
def convert(_db, _host, _user, _password, _env, _force): activityFields = FieldTranslator() # account for older versions of bugzilla if BZ_VERSION == '2.11': print 'Using Buzvilla v%s schema.' % BZ_VERSION activityFields['removed'] = 'oldvalue' activityFields['added'] = 'newvalue' # init Bugzilla environment print "B...
def convert(_db, _host, _user, _password, _env, _force): activityFields = FieldTranslator() # account for older versions of bugzilla if BZ_VERSION == '2.11': print 'Using Buzvilla v%s schema.' % BZ_VERSION activityFields['removed'] = 'oldvalue' activityFields['added'] = 'newvalue' # init Bugzilla environment print "B...
25,496
def convert(_db, _host, _user, _password, _env, _force): activityFields = FieldTranslator() # account for older versions of bugzilla if BZ_VERSION == '2.11': print 'Using Buzvilla v%s schema.' % BZ_VERSION activityFields['removed'] = 'oldvalue' activityFields['added'] = 'newvalue' # init Bugzilla environment print "B...
def convert(_db, _host, _user, _password, _env, _force): activityFields = FieldTranslator() # account for older versions of bugzilla if BZ_VERSION == '2.11': print 'Using Buzvilla v%s schema.' % BZ_VERSION activityFields['removed'] = 'oldvalue' activityFields['added'] = 'newvalue' # init Bugzilla environment print "B...
25,497
def convert(_db, _host, _user, _password, _env, _force): activityFields = FieldTranslator() # account for older versions of bugzilla if BZ_VERSION == '2.11': print 'Using Buzvilla v%s schema.' % BZ_VERSION activityFields['removed'] = 'oldvalue' activityFields['added'] = 'newvalue' # init Bugzilla environment print "B...
def convert(_db, _host, _user, _password, _env, _force): activityFields = FieldTranslator() # account for older versions of bugzilla if BZ_VERSION == '2.11': print 'Using Buzvilla v%s schema.' % BZ_VERSION activityFields['removed'] = 'oldvalue' activityFields['added'] = 'newvalue' # init Bugzilla environment print "B...
25,498
def convert(_db, _host, _user, _password, _env, _force): activityFields = FieldTranslator() # account for older versions of bugzilla if BZ_VERSION == '2.11': print 'Using Buzvilla v%s schema.' % BZ_VERSION activityFields['removed'] = 'oldvalue' activityFields['added'] = 'newvalue' # init Bugzilla environment print "B...
def convert(_db, _host, _user, _password, _env, _force): activityFields = FieldTranslator() # account for older versions of bugzilla if BZ_VERSION == '2.11': print 'Using Buzvilla v%s schema.' % BZ_VERSION activityFields['removed'] = 'oldvalue' activityFields['added'] = 'newvalue' # init Bugzilla environment print "B...
25,499