rem stringlengths 2 226k | add stringlengths 0 227k | context stringlengths 8 228k | meta stringlengths 156 215 | input_ids list | attention_mask list | labels list |
|---|---|---|---|---|---|---|
others += 1 self.download_tasks_seen = download_tasks_seen text = [_('Downloads')] if downloading + failed + finished + queued > 0: s = [] if downloading > 0: s.append(_('%d downloading') % downloading) if failed > 0: s.append(_('%d failed') % failed) if finished > 0: s.append(_('%d done') % finished) if queued > 0: s.append(_('%d queued') % queued) text.append(' (' + ', '.join(s)+')') self.labelDownloads.set_text(''.join(text)) if gpodder.interface == gpodder.MAEMO: sum = downloading + failed + finished + queued + others if sum: self.tool_downloads.set_label(_('Downloads (%d)') % sum) else: self.tool_downloads.set_label(_('Downloads')) title = [self.default_title] changed = [(task.url, task.podcast_url) for task in \ self.download_tasks_seen if task.status_changed] episode_urls = [episode_url for episode_url, channel_url in changed] channel_urls = [channel_url for episode_url, channel_url in changed] count = downloading + queued if count > 0: if count == 1: title.append( _('downloading one file')) elif count > 1: title.append( _('downloading %d files') % count) if total_size > 0: percentage = 100.0*done_size/total_size else: percentage = 0.0 total_speed = gl.format_filesize(total_speed) title[1] += ' (%d%%, %s/s)' % (percentage, total_speed) if self.tray_icon is not None: self.tray_icon.set_status(self.tray_icon.STATUS_DOWNLOAD_IN_PROGRESS, title[1]) self.tray_icon.draw_progress_bar(percentage/100.) elif self.last_download_count > 0: if self.tray_icon is not None: self.tray_icon.set_status() self.tray_icon.downloads_finished(self.download_tasks_seen) | episode_window_episode = None if model is None: model = () for row in model: self.download_status_manager.request_update(row.iter) task = row[self.download_status_manager.C_TASK] speed, size, status, progress = task.speed, task.total_size, task.status, task.progress total_size += size done_size += size*progress if episode_window_episode is not None and \ episode_window_episode.url == task.url: episode_window_progress = progress episode_window_speed = speed download_tasks_seen.add(task) if status == download.DownloadTask.DOWNLOADING: downloading += 1 total_speed += speed elif status == download.DownloadTask.FAILED: failed += 1 elif status == download.DownloadTask.DONE: finished += 1 elif status == download.DownloadTask.QUEUED: queued += 1 else: others += 1 self.download_tasks_seen = download_tasks_seen text = [_('Downloads')] if downloading + failed + finished + queued > 0: s = [] if downloading > 0: s.append(_('%d downloading') % downloading) if failed > 0: s.append(_('%d failed') % failed) if finished > 0: s.append(_('%d done') % finished) if queued > 0: s.append(_('%d queued') % queued) text.append(' (' + ', '.join(s)+')') self.labelDownloads.set_text(''.join(text)) | def update_downloads_list(self): model = self.treeDownloads.get_model() | ad78243bcfbba4097f2305f0d46872dc6dccc36d /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/12778/ad78243bcfbba4097f2305f0d46872dc6dccc36d/gui.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1089,
67,
7813,
87,
67,
1098,
12,
2890,
4672,
938,
273,
365,
18,
3413,
22141,
18,
588,
67,
2284,
1435,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1089,
67,
7813,
87,
67,
1098,
12,
2890,
4672,
938,
273,
365,
18,
3413,
22141,
18,
588,
67,
2284,
1435,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
self.processConfig() | self.autoloadImports() if not main_is_frozen(): self.autoloadStandardPlugins() self.autoloadSetuptoolsPlugins() self.parseConfigPlugins() | def OnInit(self): """Main application initialization. | 13dd876a66bf59a2d21987ccf64e24a367ed067f /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/11522/13dd876a66bf59a2d21987ccf64e24a367ed067f/main.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2755,
2570,
12,
2890,
4672,
3536,
6376,
2521,
10313,
18,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2755,
2570,
12,
2890,
4672,
3536,
6376,
2521,
10313,
18,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
def query_position (self, format = gst.FORMAT_BYTES): | def query_position(self, format=gst.FORMAT_BYTES): | def query_position (self, format = gst.FORMAT_BYTES): """Return the current position""" return 0 | 016aec4a85d3438c0d49f1f8b2012e23eb7805ec /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/2207/016aec4a85d3438c0d49f1f8b2012e23eb7805ec/audio.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
843,
67,
3276,
12,
2890,
16,
740,
33,
75,
334,
18,
7254,
67,
13718,
4672,
3536,
990,
326,
783,
1754,
8395,
327,
374,
225,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
843,
67,
3276,
12,
2890,
16,
740,
33,
75,
334,
18,
7254,
67,
13718,
4672,
3536,
990,
326,
783,
1754,
8395,
327,
374,
225,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
expr_re = re.sub(r"<lang>", '(?P<lang>[^/]+)', '.*%s' % expr_re) | expr_re = re.sub(r"<lang>", '(?P<lang>[^/]+)', '.*%s$' % expr_re) | def cmd_auto_find(argv, path_to_tx): "Automatically identify translation files." """ This command goes through all files in this directory and its subdirectories and tries to find matches to the expression given. The expression should contain '<lang>' to identify the language, or, if the --regex option is defined, should be a full regular expression. By default, the command will print `set_source_lang` and `set_translation` commands, which you can examine and run manually. If --execute is specified, the commands will be executed. """ usage="usage: %prog [tx_options] auto_find -r <resource> -l <language> [options] '<expression>'" description=("Walk through all files in subdirectories for files matching " "<expression> and auto-associate them with a language. You may " "use the keyword '<lang>' in your expression to signify the language " "locale, for example: 'po/<lang>.po'. Alternatively, you may use a " "full-powered regular expression with --regex.") parser = OptionParser(usage=usage, description=description) # Mandatory parser.add_option("-r","--resource", action="store", dest="resource_slug", default=None, help="Specify resource name") # Optional parser.add_option("-e","--execute", action="store_true", dest="execute", default=False, help="Execute the commands instead of just printing them.") parser.add_option("-E","--regex", action="store_true", dest="regex", default=False, help="Set if the expression is a POSIX regex.") parser.add_option("-l","--language", action="store", dest="slang", default="en", help="The language of the source file (default: 'en')") parser.add_option("-n","--no-source", action="store_true", dest="nosource", default=False, help="Disable searching for a source file.") (options, args) = parser.parse_args(argv) resource = options.resource_slug source_language = options.slang execute = options.execute if not resource: parser.error("Please specify a resource.") if len(args) != 1: parser.error("Please specify an expression.") expr = args[0] expr_re = '.*%s.*' % expr if not options.regex: # Force expr to be a valid regex expr (escaped) but keep <lang> intact expr_re = re.escape(expr) expr_re = re.sub(r"\\<lang\\>", '<lang>', expr_re) expr_re = re.sub(r"<lang>", '(?P<lang>[^/]+)', '.*%s' % expr_re) expr_rec = re.compile(expr_re) # The path everything will be relative to curpath = '.' if not execute: utils.MSG("Only printing the commands which will be run if the " "--execute switch is specified.") # First, let's construct a dictionary of all matching files. # Note: Only the last matching file of a language will be stored. source_file = None translation_files = {} for root, dirs, files in os.walk(curpath): for f in files: f_path = os.path.join(root, f) match = expr_rec.match(f_path) if match: lang = match.group('lang') if lang == source_language: source_file = f_path else: translation_files[lang] = f_path # The set_source_file commands needs to be handled first. # If source file search is enabled, go ahead and find it: if not options.nosource: if not source_file: parser.error( | c6baba017c0afac06b576744cee592be43b71243 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/11326/c6baba017c0afac06b576744cee592be43b71243/commands.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1797,
67,
6079,
67,
4720,
12,
19485,
16,
589,
67,
869,
67,
978,
4672,
315,
31910,
9786,
4794,
1390,
1199,
225,
3536,
1220,
1296,
13998,
3059,
777,
1390,
316,
333,
1867,
471,
2097,
31220,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1797,
67,
6079,
67,
4720,
12,
19485,
16,
589,
67,
869,
67,
978,
4672,
315,
31910,
9786,
4794,
1390,
1199,
225,
3536,
1220,
1296,
13998,
3059,
777,
1390,
316,
333,
1867,
471,
2097,
31220,... |
self._setLocale("en_US") | self._setLocale("en_US", ignoreError=True) | def setLocaleSet(self, localeSet=None, fallback=True): """ Resets the c{I18nManager locale set c{List}. | 56421d8e0e78b7cbb4f8e9fb940c24150df656c5 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/9228/56421d8e0e78b7cbb4f8e9fb940c24150df656c5/i18nmanager.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
19848,
694,
12,
2890,
16,
2573,
694,
33,
7036,
16,
5922,
33,
5510,
4672,
3536,
1124,
2413,
326,
276,
95,
45,
2643,
82,
1318,
2573,
444,
276,
95,
682,
5496,
2,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
19848,
694,
12,
2890,
16,
2573,
694,
33,
7036,
16,
5922,
33,
5510,
4672,
3536,
1124,
2413,
326,
276,
95,
45,
2643,
82,
1318,
2573,
444,
276,
95,
682,
5496,
2,
-100,
-100,
-100,
-100,
... |
req.log_error('FileSession cleanup: another process is already running.' % (fast_cleanup,verify_cleanup), | req.log_error('FileSession cleanup: another process is already running.', | def filesession_cleanup(data): # There is a small chance that a the cleanup for a given session file # may occur at the exact time that the session is being accessed by # another request. It is possible under certain circumstances for that # session file to be saved in another request only to immediately deleted # by the cleanup. To avoid this race condition, a session is allowed a # grace_period before it is considered for deletion by the cleanup. # As long as the grace_period is longer that the time it takes to complete # the request (which should normally be less than 1 second), the session will # not be mistakenly deleted by the cleanup. By doing this we also avoid the # need to lock individual sessions and bypass any potential deadlock # situations. req = data['req'] sessdir = data['sessdir'] fast_cleanup = data['fast_cleanup'] verify_cleanup = data['verify_cleanup'] timeout = data['timeout'] grace_period = data['grace_period'] cleanup_time_limit = data['cleanup_time_limit'] req.log_error('FileSession cleanup: (fast=%s, verify=%s) ...' % (fast_cleanup,verify_cleanup), apache.APLOG_NOTICE) lockfile = os.path.join(sessdir,'.mp_sess.lck') try: lockfp = os.open(lockfile, os.O_CREAT | os.O_EXCL | os.O_WRONLY, 0660) except: req.log_error('FileSession cleanup: another process is already running.' % (fast_cleanup,verify_cleanup), apache.APLOG_NOTICE) return try: status_file = file(os.path.join(sessdir, 'fs_status.txt'), 'r') d = status_file.readline() status_file.close() if not d.startswith(FS_STAT_VERSION): raise Exception, 'wrong status file version' parts = d.split() stat_version = parts[0] next_i = int(parts[1]) expired_file_count = int(parts[2]) total_file_count = int(parts[3]) total_time = float(parts[4]) except: stat_version = FS_STAT_VERSION next_i = 0 expired_file_count = 0 total_file_count = 0 total_time = 0.0 try: start_time = time.time() filelist = os.listdir(sessdir) dir_index = range(0,256)[next_i:] for i in dir_index: path = '%s/%s' % (sessdir,'%02x' % i) if not os.path.exists(path): continue filelist = os.listdir(path) total_file_count += len(filelist) for f in filelist: try: filename = os.path.join(path,f) if fast_cleanup: accessed = os.stat(filename).st_mtime if time.time() - accessed < (timeout + grace_period): continue if fast_cleanup and not verify_cleanup: delete_session = True else: try: fp = file(filename) dict = cPickle.load(fp) if (time.time() - dict['_accessed']) > (dict['_timeout'] + grace_period): delete_session = True else: delete_session = False finally: fp.close() if delete_session: os.unlink(filename) expired_file_count += 1 except: s = cStringIO.StringIO() traceback.print_exc(file=s) s = s.getvalue() req.log_error('FileSession cleanup error: %s' % (s), apache.APLOG_NOTICE) next_i = (i + 1) % 256 time_used = time.time() - start_time if (cleanup_time_limit > 0) and (time_used > cleanup_time_limit): break total_time += time.time() - start_time if next_i == 0: # next_i can only be 0 when the full cleanup has run to completion req.log_error("FileSession cleanup: deleted %d of %d in %.4f seconds" % (expired_file_count, total_file_count, total_time), apache.APLOG_NOTICE) expired_file_count = 0 total_file_count = 0 total_time = 0.0 else: req.log_error("FileSession cleanup incomplete: next cleanup will start at index %d (%02x)" % (next_i,), apache.APLOG_NOTICE) status_file = file(os.path.join(sessdir, 'fs_status.txt'), 'w') status_file.write('%s %d %d %d %f %d\n' % (stat_version,next_i,expired_file_count,total_file_count, total_time)) status_file.close() try: os.unlink(lockfile) except: pass finally: os.close(lockfp) | 4ff6855b6656236505cece21a979b885aa774e8d /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/10002/4ff6855b6656236505cece21a979b885aa774e8d/Session.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1390,
893,
67,
16732,
12,
892,
4672,
468,
6149,
353,
279,
5264,
17920,
716,
279,
326,
6686,
364,
279,
864,
1339,
585,
468,
2026,
3334,
622,
326,
5565,
813,
716,
326,
1339,
353,
3832,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1390,
893,
67,
16732,
12,
892,
4672,
468,
6149,
353,
279,
5264,
17920,
716,
279,
326,
6686,
364,
279,
864,
1339,
585,
468,
2026,
3334,
622,
326,
5565,
813,
716,
326,
1339,
353,
3832,
1... |
if no == WHITE: player.updateTime (self.chessclock.p0time/10., self.chessclock.p1time/10.) else: player.updateTime (self.chessclock.p1time/10., self.chessclock.p0time/10.) | if self.chessclock: if no == WHITE: player.updateTime (self.chessclock.p0time/10., self.chessclock.p1time/10.) else: player.updateTime (self.chessclock.p1time/10., self.chessclock.p0time/10.) | def _run (self): self.running = True while self.running: player, no = { WHITE: (self.player1, 0), BLACK: (self.player2, 1)} [self.history.curCol()] if self.chessclock: self.chessclock.player = no if player.__type__ == LOCAL: self.gmwidg.setTabReady(True) else: self.gmwidg.setTabReady(False) if no == WHITE: player.updateTime (self.chessclock.p0time/10., self.chessclock.p1time/10.) else: player.updateTime (self.chessclock.p1time/10., self.chessclock.p0time/10.) try: move = player.makeMove(self.history) except EngineDead: break if not self.running: break if not self.history.add(move,True): break for analyzer in self.analyzers: analyzer.makeMove(self.history) | 5fa536eeb8d9c4482d57dde710a6316171f0d76a /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/5339/5fa536eeb8d9c4482d57dde710a6316171f0d76a/Game.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
2681,
261,
2890,
4672,
365,
18,
8704,
273,
1053,
1323,
365,
18,
8704,
30,
7291,
16,
1158,
273,
288,
24353,
30,
261,
2890,
18,
14872,
21,
16,
374,
3631,
19238,
3649,
30,
261,
2890,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
2681,
261,
2890,
4672,
365,
18,
8704,
273,
1053,
1323,
365,
18,
8704,
30,
7291,
16,
1158,
273,
288,
24353,
30,
261,
2890,
18,
14872,
21,
16,
374,
3631,
19238,
3649,
30,
261,
2890,... |
plot_path = "%s_CHAIN%s_ALIGN.png" % (self.struct_id, chain.chain_id) plot.plot(plot_path) | plot_file = "%s_CHAIN%s_ALIGN.png" % (self.struct_id, chain.chain_id) plot.plot(plot_file) | def html_chain_alignment_plot(self, chain): """generate a plot comparing all segmentations """ plot = sequence_plot.TLSSegmentAlignmentPlot() for ntls, cpartition in chain.partition_collection.iter_ntls_chain_partitions(): plot.add_tls_segmentation(cpartition) | 81092918682cb3b404793cc6abd4020f9621498a /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/10674/81092918682cb3b404793cc6abd4020f9621498a/html.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1729,
67,
5639,
67,
14409,
67,
4032,
12,
2890,
16,
2687,
4672,
3536,
7163,
279,
3207,
17553,
777,
3267,
1012,
3536,
3207,
273,
3102,
67,
4032,
18,
5967,
1260,
9325,
11535,
11532,
1435,
2... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1729,
67,
5639,
67,
14409,
67,
4032,
12,
2890,
16,
2687,
4672,
3536,
7163,
279,
3207,
17553,
777,
3267,
1012,
3536,
3207,
273,
3102,
67,
4032,
18,
5967,
1260,
9325,
11535,
11532,
1435,
2... |
cmd = argv[1] args = '' if len(argv) > 2: args = argv[2] doQuery(wlib, args) | querytxt = '' if argv[1] == '-q': querytxt = argv[2] del argv[:2] tags = len(argv) > 1 and argv[1] or '' doQuery(wlib, querytxt, tags) | def main(argv): import store wlib = store.load() if len(argv) <= 1: show(wlib) sys.exit(0) cmd = argv[1] args = '' if len(argv) > 2: args = argv[2] doQuery(wlib, args) | 00582b690bc75d146383c379758cdb80f0b6a67c /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/2355/00582b690bc75d146383c379758cdb80f0b6a67c/__init__.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2774,
12,
19485,
4672,
225,
1930,
1707,
225,
341,
2941,
273,
1707,
18,
945,
1435,
225,
309,
562,
12,
19485,
13,
1648,
404,
30,
2405,
12,
91,
2941,
13,
2589,
18,
8593,
12,
20,
13,
225... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2774,
12,
19485,
4672,
225,
1930,
1707,
225,
341,
2941,
273,
1707,
18,
945,
1435,
225,
309,
562,
12,
19485,
13,
1648,
404,
30,
2405,
12,
91,
2941,
13,
2589,
18,
8593,
12,
20,
13,
225... |
return self.getRefs() | tool = getToolByName(self, REFERENCE_CATALOG) return tool.getReferences(self) | def getForwardReferences(self): """ AT forward references """ if self.haveATReferences(): return self.getRefs() else: return () | a4d703ae69ce3b9e5e8da748ebef530c388a167d /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/1807/a4d703ae69ce3b9e5e8da748ebef530c388a167d/Issue.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
8514,
8221,
12,
2890,
4672,
3536,
14464,
5104,
5351,
3536,
309,
365,
18,
21516,
789,
8221,
13332,
5226,
273,
336,
6364,
5911,
12,
2890,
16,
22898,
67,
14130,
18683,
13,
327,
5226,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
8514,
8221,
12,
2890,
4672,
3536,
14464,
5104,
5351,
3536,
309,
365,
18,
21516,
789,
8221,
13332,
5226,
273,
336,
6364,
5911,
12,
2890,
16,
22898,
67,
14130,
18683,
13,
327,
5226,
1... |
prob = 0.0 for i in xrange(nsamples): locus_times = duploss.sample_dup_times( locus_tree, stree, locus_recon, duprate, lossrate, pretime, premean, events=locus_events) treelib.set_dists_from_timestamps(locus_tree, locus_times) coal_prob = coal.prob_locus_coal_recon_topology( coal_tree, coal_recon, locus_tree, popsizes, daughters) prob += exp(coal_prob) prob = util.safelog(prob) return prob | if dlcoalc: return coal.prob_locus_coal_recon_topology_samples( coal_tree, coal_recon, locus_tree, locus_recon, locus_events, popsizes, stree, stimes, daughters, duprate, lossrate, nsamples, pretime, premean) else: prob = 0.0 for i in xrange(nsamples): locus_times = duploss.sample_dup_times( locus_tree, stree, locus_recon, duprate, lossrate, pretime, premean, events=locus_events) treelib.set_dists_from_timestamps(locus_tree, locus_times) coal_prob = prob_locus_coal_recon_topology( coal_tree, coal_recon, locus_tree, popsizes, daughters) prob += exp(coal_prob) prob = util.safelog(prob) return prob | def prob_locus_coal_recon_topology_samples( coal_tree, coal_recon, locus_tree, locus_recon, locus_events, popsizes, stree, stimes, daughters, duprate, lossrate, nsamples, pretime=None, premean=None): prob = 0.0 for i in xrange(nsamples): # sample duplication times locus_times = duploss.sample_dup_times( locus_tree, stree, locus_recon, duprate, lossrate, pretime, premean, events=locus_events) treelib.set_dists_from_timestamps(locus_tree, locus_times) # coal topology probability coal_prob = coal.prob_locus_coal_recon_topology( coal_tree, coal_recon, locus_tree, popsizes, daughters) prob += exp(coal_prob) prob = util.safelog(prob) return prob | 677344f2570ecf37ea7adddebf75ca85ff914c61 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/7683/677344f2570ecf37ea7adddebf75ca85ff914c61/__init__.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
3137,
67,
1829,
407,
67,
2894,
287,
67,
266,
591,
67,
25572,
67,
7319,
12,
1825,
287,
67,
3413,
16,
1825,
287,
67,
266,
591,
16,
22896,
67,
3413,
16,
22896,
67,
266,
591,
16,
22896,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
3137,
67,
1829,
407,
67,
2894,
287,
67,
266,
591,
67,
25572,
67,
7319,
12,
1825,
287,
67,
3413,
16,
1825,
287,
67,
266,
591,
16,
22896,
67,
3413,
16,
22896,
67,
266,
591,
16,
22896,
... |
def setInternalLink(self): if self.internally_connectable is not None: print "setting internal link on frontend id", self.frontend_id open("/proc/stb/frontend/%d/rf_switch" % self.frontend_id, "w").write("internal") def removeInternalLink(self): if self.internally_connectable is not None: print "removing internal link on frontend id", self.frontend_id open("/proc/stb/frontend/%d/rf_switch" % self.frontend_id, "w").write("external") | def setInternalLink(self): if self.internally_connectable is not None: print "setting internal link on frontend id", self.frontend_id open("/proc/stb/frontend/%d/rf_switch" % self.frontend_id, "w").write("internal") | 2a68b37033c4c08540523e6154ffe5614d4f24e9 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/6652/2a68b37033c4c08540523e6154ffe5614d4f24e9/NimManager.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
444,
3061,
2098,
12,
2890,
4672,
309,
365,
18,
267,
798,
1230,
67,
3612,
429,
353,
486,
599,
30,
1172,
315,
8920,
2713,
1692,
603,
15442,
612,
3113,
365,
18,
19960,
67,
350,
1696,
2932... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
444,
3061,
2098,
12,
2890,
4672,
309,
365,
18,
267,
798,
1230,
67,
3612,
429,
353,
486,
599,
30,
1172,
315,
8920,
2713,
1692,
603,
15442,
612,
3113,
365,
18,
19960,
67,
350,
1696,
2932... | |
''' | """ | def doubleclick(self, window_name, object_name): ''' Double click on the object @param window_name: Window name to look for, either full name, LDTP's name convention, or a Unix glob. @type window_name: string @param object_name: Object name to look for, either full name, LDTP's name convention, or a Unix glob. Or menu heirarchy @type object_name: string | 2840728a35706bfd7cd3e236c75533448a30fc1d /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/11266/2840728a35706bfd7cd3e236c75533448a30fc1d/mouse.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1645,
7475,
12,
2890,
16,
2742,
67,
529,
16,
733,
67,
529,
4672,
3536,
3698,
4682,
603,
326,
733,
225,
632,
891,
2742,
67,
529,
30,
6076,
508,
358,
2324,
364,
16,
3344,
1983,
508,
16... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1645,
7475,
12,
2890,
16,
2742,
67,
529,
16,
733,
67,
529,
4672,
3536,
3698,
4682,
603,
326,
733,
225,
632,
891,
2742,
67,
529,
30,
6076,
508,
358,
2324,
364,
16,
3344,
1983,
508,
16... |
self.runCmd("image dump symtab a.out") | self.runCmd("image dump symtab -s address a.out") | def order_file(self): """Test debug symbols follow the correct order by the order file.""" exe = os.path.join(os.getcwd(), "a.out") self.runCmd("file " + exe, CURRENT_EXECUTABLE_SET) | ac77d9064ea94d6ef1c1afe6c55bf77cbda74615 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/11986/ac77d9064ea94d6ef1c1afe6c55bf77cbda74615/TestOrderFile.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1353,
67,
768,
12,
2890,
4672,
3536,
4709,
1198,
7963,
2805,
326,
3434,
1353,
635,
326,
1353,
585,
12123,
15073,
273,
1140,
18,
803,
18,
5701,
12,
538,
18,
588,
11089,
9334,
315,
69,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1353,
67,
768,
12,
2890,
4672,
3536,
4709,
1198,
7963,
2805,
326,
3434,
1353,
635,
326,
1353,
585,
12123,
15073,
273,
1140,
18,
803,
18,
5701,
12,
538,
18,
588,
11089,
9334,
315,
69,
1... |
object = locate(key, forceload) except ErrorDuringImport, value: | object, name = resolve(thing, forceload) page = html.page(describe(object), html.document(object, name)) file = open(name + '.html', 'w') file.write(page) file.close() print 'wrote', name + '.html' except (ImportError, ErrorDuringImport), value: | def writedoc(key, forceload=0): """Write HTML documentation to a file in the current directory.""" try: object = locate(key, forceload) except ErrorDuringImport, value: print value else: if object: page = html.page(describe(object), html.document(object, object.__name__)) file = open(key + '.html', 'w') file.write(page) file.close() print 'wrote', key + '.html' else: print 'no Python documentation found for %s' % repr(key) | 8537f315144fcf91571d57f2b3f1efdd04cbfec8 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12029/8537f315144fcf91571d57f2b3f1efdd04cbfec8/pydoc.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2518,
329,
504,
12,
856,
16,
364,
2183,
6189,
33,
20,
4672,
3536,
3067,
3982,
7323,
358,
279,
585,
316,
326,
783,
1867,
12123,
775,
30,
733,
16,
508,
273,
2245,
12,
4274,
16,
364,
21... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2518,
329,
504,
12,
856,
16,
364,
2183,
6189,
33,
20,
4672,
3536,
3067,
3982,
7323,
358,
279,
585,
316,
326,
783,
1867,
12123,
775,
30,
733,
16,
508,
273,
2245,
12,
4274,
16,
364,
21... |
coordinates = addresslist = country_list = [] | coordinates = [] addresslist = [] country_list = [] | def get_kml(self, cr, uid, context={}): res = res_inv = res_cus = {} address = ' ' coordinates = addresslist = country_list = [] coordinates_text = ' ' number_customer = number_supplier = 0 colors = ['9f8080ff', '9f0000ff'] partner_obj = self.pool.get('res.partner') address_obj= self.pool.get('res.partner.address') partner_ids = partner_obj.search(cr, uid, []) partners = partner_obj.browse(cr, uid, partner_ids) for part in partners: if part.address and part.address[0].country_id and part.address[0].country_id.name: if not string.upper(part.address[0].country_id.name) in country_list: cntry = string.upper(str(part.address[0].country_id.name)) country_name = '' for char in cntry: if char == '&': country_name += 'AND' else: country_name += char country_list.append(country_name) map(lambda x:res.setdefault(x, 0.0), country_list) cr.execute("select sum(l.debit-l.credit), c.name from account_move_line l, res_country c, res_partner_address a, account_account act where l.partner_id = a.partner_id and c.id=a.country_id and l.account_id = act.id and act.type = 'receivable' group by c.name") res_partner = cr.fetchall() list_to = [] for part in res_partner: if part[1]: res[string.upper(part[1])] = part[0] list_to.append(part[0]) | aaaffb7a7ee3c7d260a070bf8a5e141e1c996850 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/7339/aaaffb7a7ee3c7d260a070bf8a5e141e1c996850/google_earth.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
67,
79,
781,
12,
2890,
16,
4422,
16,
4555,
16,
819,
12938,
4672,
400,
273,
400,
67,
5768,
273,
400,
67,
71,
407,
273,
2618,
1758,
273,
296,
296,
5513,
273,
5378,
1758,
1098,
273... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
67,
79,
781,
12,
2890,
16,
4422,
16,
4555,
16,
819,
12938,
4672,
400,
273,
400,
67,
5768,
273,
400,
67,
71,
407,
273,
2618,
1758,
273,
296,
296,
5513,
273,
5378,
1758,
1098,
273... |
verbose = 0 rexec = None if args and type(args[-1]) == type(0): verbose = args[-1] args = args[:-1] if args and hasattr(args[0], '__class__'): rexec = args[0] args = args[1:] if args: raise TypeError, "too many arguments" ihooks.Hooks.__init__(self, verbose) self.rexec = rexec | verbose = 0 rexec = None if args and type(args[-1]) == type(0): verbose = args[-1] args = args[:-1] if args and hasattr(args[0], '__class__'): rexec = args[0] args = args[1:] if args: raise TypeError, "too many arguments" ihooks.Hooks.__init__(self, verbose) self.rexec = rexec | def __init__(self, *args): | ce7c76df1b92a89c9b48d025af1313d1dcf28c4f /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12029/ce7c76df1b92a89c9b48d025af1313d1dcf28c4f/rexec.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
16,
380,
1968,
4672,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
16,
380,
1968,
4672,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
kernel = self.job.kernel(tarball, self.tmpdir, build_dir) | kernel = self.job.kernel(tarball, self.outputdir, self.tmpdir) | def __init_tree(self, build_dir, version = None): # # If we have a local copy of the 2.6.14 tarball use that # else let the kernel object use the defined mirrors # to obtain it. # # http://kernel.org/pub/linux/kernel/v2.6/linux-2.6.14.tar.bz2 # # On ia64, we default to 2.6.20, as it can't compile 2.6.14. if version: default_ver = version elif autotest_utils.get_current_kernel_arch() == 'ia64': default_ver = '2.6.20' else: default_ver = '2.6.14' | cf930711baa7c0a65cb83edf33467ad81202f763 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/12268/cf930711baa7c0a65cb83edf33467ad81202f763/kernbench.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
67,
3413,
12,
2890,
16,
1361,
67,
1214,
16,
1177,
273,
599,
4672,
468,
468,
971,
732,
1240,
279,
1191,
1610,
434,
326,
576,
18,
26,
18,
3461,
29441,
999,
716,
468,
469,
2... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
67,
3413,
12,
2890,
16,
1361,
67,
1214,
16,
1177,
273,
599,
4672,
468,
468,
971,
732,
1240,
279,
1191,
1610,
434,
326,
576,
18,
26,
18,
3461,
29441,
999,
716,
468,
469,
2... |
raise Error("Trying to read unknown variable " + name + ".\n") | raise Error("Trying to read unknown variable " + name + ".") | def value(self,name): '''returns the value of the workspace variable *name*. If the variable has no value yet, a prompt is displayed for it.''' if not name in self.environ: raise Error("Trying to read unknown variable " + name + ".\n") if (isinstance(self.environ[name],Variable) and self.environ[name].configure()): self.save() # recursively resolve any variables that might appear # in the variable value. We do this here and not while loading # the context because those names can have been defined later. value = str(self.environ[name]) look = re.match('(.*)\${(\S+)}(.*)',value) while look: indirect = '' if look.group(2) in self.environ: indirect = self.value(look.group(2)) elif look.group(2) in os.environ: indirect = os.environ[look.group(2)] value = look.group(1) + indirect + look.group(3) look = re.match('(.*)\${(\S+)}(.*)',value) return value | 3eb90d1f8ec09fc84ae921584bd73c951235b43d /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/1360/3eb90d1f8ec09fc84ae921584bd73c951235b43d/dws.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
460,
12,
2890,
16,
529,
4672,
9163,
6154,
326,
460,
434,
326,
6003,
2190,
380,
529,
11146,
971,
326,
2190,
711,
1158,
460,
4671,
16,
279,
6866,
353,
10453,
364,
518,
1093,
6309,
309,
4... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
460,
12,
2890,
16,
529,
4672,
9163,
6154,
326,
460,
434,
326,
6003,
2190,
380,
529,
11146,
971,
326,
2190,
711,
1158,
460,
4671,
16,
279,
6866,
353,
10453,
364,
518,
1093,
6309,
309,
4... |
else | else: | def __init__(data = None) if data == None: quickfix.StringField.__init__(self, 942) else quickfix.StringField.__init__(self, 942, data) | 484890147d4b23aac4b9d0e85e84fceab7e137c3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8819/484890147d4b23aac4b9d0e85e84fceab7e137c3/quickfix_fields.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
892,
273,
599,
13,
309,
501,
422,
599,
30,
9549,
904,
18,
780,
974,
16186,
2738,
972,
12,
2890,
16,
2468,
9452,
13,
469,
30,
9549,
904,
18,
780,
974,
16186,
2738... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
892,
273,
599,
13,
309,
501,
422,
599,
30,
9549,
904,
18,
780,
974,
16186,
2738,
972,
12,
2890,
16,
2468,
9452,
13,
469,
30,
9549,
904,
18,
780,
974,
16186,
2738... |
return http.Response(stream = message(s)) | return HTMLResponse(stream = message(s)) | def render(self, ctx): if ctx.args.has_key('button_cancel'): return http.RedirectResponse('/home/'+self.worksheet.filename()) if user_type(self.username) == 'admin' or \ self.worksheet.owner() == self.username \ or self.worksheet.user_is_collaborator(self.username): system = ctx.args['system'][0].strip().lower() self.worksheet.set_system(system) if system != 'sage': post = ' (%s)'%system n = self.worksheet.name() i = n.rfind('(') if i != -1: j = n.rfind(')') if j != -1: n = n[:i] n = n.strip() + post self.worksheet.set_name(n) return http.RedirectResponse('/home/'+ self.worksheet.filename()) else: s = 'You must be the owner of this worksheet to configure it.' return http.Response(stream = message(s)) | 2c1a5997a8830efcfb475993e5f1efb45ed121ea /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/9890/2c1a5997a8830efcfb475993e5f1efb45ed121ea/twist.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1743,
12,
2890,
16,
1103,
4672,
309,
1103,
18,
1968,
18,
5332,
67,
856,
2668,
5391,
67,
10996,
11,
4672,
327,
1062,
18,
5961,
1064,
2668,
19,
8712,
2473,
15,
2890,
18,
1252,
8118,
18,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1743,
12,
2890,
16,
1103,
4672,
309,
1103,
18,
1968,
18,
5332,
67,
856,
2668,
5391,
67,
10996,
11,
4672,
327,
1062,
18,
5961,
1064,
2668,
19,
8712,
2473,
15,
2890,
18,
1252,
8118,
18,
... |
ext.cxx + ["-shared"]) | cxx + ["-shared"]) | def build_extension(self, ext): """Work around distutils bug which uses the C compiler for C++ code. """ if hasattr(ext, "language") and ext.language == "c++": # fix for before 2.2 only -- need to set the compiler to C++ if hasattr(ext, "cxx"): self.compiler.set_executable("compiler", ext.cxx) self.compiler.set_executable("compiler_so", ext.cxx) self.compiler.set_executable("linker_so", ext.cxx + ["-shared"]) else: # fix for 2.3 self.compiler.compiler_so = self.compiler.compiler_cxx else: self.compiler.compiler_so = self._original_compiler_so | 930f61997ffa88dc280f57ba69c083f4921509b8 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/7167/930f61997ffa88dc280f57ba69c083f4921509b8/setup.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1361,
67,
6447,
12,
2890,
16,
1110,
4672,
3536,
2421,
6740,
2411,
5471,
7934,
1492,
4692,
326,
385,
5274,
364,
385,
9904,
981,
18,
3536,
309,
3859,
12,
408,
16,
315,
4923,
7923,
471,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1361,
67,
6447,
12,
2890,
16,
1110,
4672,
3536,
2421,
6740,
2411,
5471,
7934,
1492,
4692,
326,
385,
5274,
364,
385,
9904,
981,
18,
3536,
309,
3859,
12,
408,
16,
315,
4923,
7923,
471,
1... |
self.valueOf_ = valueOf_ if mixedclass_ is None: self.mixedclass_ = MixedContainer else: self.mixedclass_ = mixedclass_ if content_ is None: self.content_ = [] else: self.content_ = content_ self.valueOf_ = valueOf_ | def __init__(self, about=None, meta=None, label=None, id=None, network=None, tree=None, set=None, valueOf_=None, mixedclass_=None, content_=None): super(AbstractTrees, self).__init__(about, meta, label, id, valueOf_, mixedclass_, content_, ) if network is None: self.network = [] else: self.network = network if tree is None: self.tree = [] else: self.tree = tree if set is None: self.set = [] else: self.set = set self.valueOf_ = valueOf_ if mixedclass_ is None: self.mixedclass_ = MixedContainer else: self.mixedclass_ = mixedclass_ if content_ is None: self.content_ = [] else: self.content_ = content_ self.valueOf_ = valueOf_ | 9c12e50d449fa27d6f8f3415ece228ae97bb0266 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/14016/9c12e50d449fa27d6f8f3415ece228ae97bb0266/_nexml.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
16,
2973,
33,
7036,
16,
2191,
33,
7036,
16,
1433,
33,
7036,
16,
612,
33,
7036,
16,
2483,
33,
7036,
16,
2151,
33,
7036,
16,
444,
33,
7036,
16,
4323,
67,
3... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
16,
2973,
33,
7036,
16,
2191,
33,
7036,
16,
1433,
33,
7036,
16,
612,
33,
7036,
16,
2483,
33,
7036,
16,
2151,
33,
7036,
16,
444,
33,
7036,
16,
4323,
67,
3... | |
if port < 9: self.portstr = 'COM%d' % (port+1) else: self.portstr = r'\\.\COM%d' % (port+1) | self.portstr = device(port) | def __init__(self, port, #number of device, numbering starts at #zero. if everything fails, the user #can specify a device string, note #that this isn't portable anymore baudrate=9600, #baudrate bytesize=EIGHTBITS, #number of databits parity=PARITY_NONE, #enable parity checking stopbits=STOPBITS_ONE, #number of stopbits timeout=None, #set a timeout value, None for waiting forever xonxoff=0, #enable software flow control rtscts=0, #enable RTS/CTS flow control ): """initialize comm port""" | 4e83870a26948ca3f683dbc25aad005a26464698 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/2937/4e83870a26948ca3f683dbc25aad005a26464698/serialwin32.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
16,
1756,
16,
5375,
468,
2696,
434,
2346,
16,
1300,
310,
2542,
622,
468,
7124,
18,
309,
7756,
6684,
16,
326,
729,
468,
4169,
4800,
279,
2346,
533,
16,
4721,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
16,
1756,
16,
5375,
468,
2696,
434,
2346,
16,
1300,
310,
2542,
622,
468,
7124,
18,
309,
7756,
6684,
16,
326,
729,
468,
4169,
4800,
279,
2346,
533,
16,
4721,
... |
print exit_status, out_text | print exit_status, | def get_version(self): """Return the compiler version. If compiler is not available, return empty string.""" # XXX: Is there compilers that have no version? If yes, # this test will fail even if the compiler is available. if self.version is not None: # Finding version is expensive, so return previously found # version string. return self.version self.version = '' # works I think only for unix... print 'command:', self.ver_cmd exit_status, out_text = run_command(self.ver_cmd) print exit_status, out_text if not exit_status: m = re.match(self.ver_match,out_text) if m: self.version = m.group('version') return self.version | 40006b76c878853d4b2ed3be9c264071e6cea220 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/14925/40006b76c878853d4b2ed3be9c264071e6cea220/build_flib.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
67,
1589,
12,
2890,
4672,
3536,
990,
326,
5274,
1177,
18,
971,
5274,
353,
486,
2319,
16,
327,
1008,
533,
12123,
468,
11329,
30,
2585,
1915,
1161,
330,
414,
716,
1240,
1158,
1177,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
67,
1589,
12,
2890,
4672,
3536,
990,
326,
5274,
1177,
18,
971,
5274,
353,
486,
2319,
16,
327,
1008,
533,
12123,
468,
11329,
30,
2585,
1915,
1161,
330,
414,
716,
1240,
1158,
1177,
... |
if False: argsString = ", ".join( [ str( arg )[:20] for arg in args ] ) else: | if gConfig.getValue( "%s/MaskRequestParams" %self.serviceInfoDict[ 'serviceSectionPath' ], "y" ).lower() in ( "y", "yes", "true" ): | def __logRemoteQuery( self, method, args ): """ Log the contents of a remote query | d617f0ad9f2d75aeef80b6e3b19c7cb464301beb /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/12864/d617f0ad9f2d75aeef80b6e3b19c7cb464301beb/RequestHandler.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
1330,
5169,
1138,
12,
365,
16,
707,
16,
833,
262,
30,
3536,
1827,
326,
2939,
434,
279,
2632,
843,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
1330,
5169,
1138,
12,
365,
16,
707,
16,
833,
262,
30,
3536,
1827,
326,
2939,
434,
279,
2632,
843,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
if port.consumer_slot is not None: | if port.consumer_slot is not None and self.demultiplexer.slot: | def remove(self, port): with self._lock: if weakref.ref(port) not in self.ports: raise ValueError("port %r is not part of this bridge" % port) if port.consumer_slot is not None: self.mixer.disconnect_slots(self.demultiplexer.slot, port.consumer_slot) if port.producer_slot is not None: self.mixer.disconnect_slots(port.producer_slot, self.multiplexer.slot) for other in (wr() for wr in self.ports): if other is None: continue if other.producer_slot is not None and port.consumer_slot is not None: self.mixer.disconnect_slots(other.producer_slot, port.consumer_slot) if port.producer_slot is not None and other.consumer_slot is not None: self.mixer.disconnect_slots(port.producer_slot, other.consumer_slot) self.ports.remove(weakref.ref(port)) | 11e802b776a3fc4141fd4d168add5b621b82bfa2 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/5703/11e802b776a3fc4141fd4d168add5b621b82bfa2/audio.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1206,
12,
2890,
16,
1756,
4672,
598,
365,
6315,
739,
30,
309,
16046,
1734,
18,
1734,
12,
655,
13,
486,
316,
365,
18,
4363,
30,
1002,
2068,
2932,
655,
738,
86,
353,
486,
1087,
434,
33... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1206,
12,
2890,
16,
1756,
4672,
598,
365,
6315,
739,
30,
309,
16046,
1734,
18,
1734,
12,
655,
13,
486,
316,
365,
18,
4363,
30,
1002,
2068,
2932,
655,
738,
86,
353,
486,
1087,
434,
33... |
terms = ('"%s"' % string) + ' '.join(['"%s"' % ex for ex in [extra1, extra2, extra3, extra4, extra5] if ex]) | terms = ', '.join(['"%s"' % s for s in [string] + [extra1, extra2, extra3, extra4, extra5] if s]) | sage: 'divisors' in _search_src_or_doc('src', '^ *def prime', interact=False) | da758fd6e2806c153c3c54e8f34d6748d4878772 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9890/da758fd6e2806c153c3c54e8f34d6748d4878772/sagedoc.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
272,
410,
30,
296,
2892,
291,
1383,
11,
316,
389,
3072,
67,
4816,
67,
280,
67,
2434,
2668,
4816,
2187,
10731,
380,
536,
17014,
2187,
16592,
33,
8381,
13,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
272,
410,
30,
296,
2892,
291,
1383,
11,
316,
389,
3072,
67,
4816,
67,
280,
67,
2434,
2668,
4816,
2187,
10731,
380,
536,
17014,
2187,
16592,
33,
8381,
13,
2,
-100,
-100,
-100,
-100,
-100,
-10... |
os.symlink(string.strip(cp.get('hipe-cache','hipe-cache-path')), 'cache') | if len(string.strip(cp.get('hipe-cache','hipe-cache-path'))) > 0: os.symlink(string.strip(cp.get('hipe-cache','hipe-cache-path')), 'cache') else: pass | def __init__(self, options,cp, currentPath): UserDict.__init__(self) self.dir = os.listdir(os.getcwd()) self.options = options self.types = ['TMPLTBANK', 'TRIGBANK', 'INSPIRAL-', \ 'INSPIRAL_H', 'THINCA-', 'THINCA_'] self.iniNames = ['tmpltbank-path', 'trigbank-path', 'first-inspiral-path', \ 'second-inspiral-path', 'first-coinc-path', 'second-coinc-path'] self.iniNameMaps = map(None, self.iniNames, self.types) self.oNames = ['bank.cache', 'trigbank.cache', 'first_inspiral.cache', \ 'second_inspiral.cache', 'first_thinca.cache', 'second_thinca.cache'] self.nameMaps = map(None, self.oNames, self.types) self.ifoTypes = ['H1','H2','L1','H1H2','H1L1','H2L1','H1H2L1'] | f4579c67f99b15798056536d4fe83926eb293496 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/3592/f4579c67f99b15798056536d4fe83926eb293496/fu_utils.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
16,
702,
16,
4057,
16,
18027,
4672,
2177,
5014,
16186,
2738,
972,
12,
2890,
13,
365,
18,
1214,
273,
1140,
18,
1098,
1214,
12,
538,
18,
588,
11089,
10756,
365... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
16,
702,
16,
4057,
16,
18027,
4672,
2177,
5014,
16186,
2738,
972,
12,
2890,
13,
365,
18,
1214,
273,
1140,
18,
1098,
1214,
12,
538,
18,
588,
11089,
10756,
365... |
for term, query in specs: | for (term,query) in specs.items(): | def matchPackageNames(self, pkgspecs): """take a list strings and match the packages in the sack against it this will match against: name name.arch name-ver-rel.arch name-ver name-ver-rel epoch:name-ver-rel.arch name-epoch:ver-rel.arch return [exact matches], [glob matches], [unmatch search terms] """ # Setup match() for the search we're doing matched = [] exactmatch = [] unmatched = set(pkgspecs) | e4ce1684197fa41cf7b416fd6d8af702d694a9d3 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/5445/e4ce1684197fa41cf7b416fd6d8af702d694a9d3/packageSack.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
845,
2261,
1557,
12,
2890,
16,
16922,
705,
87,
4672,
3536,
22188,
279,
666,
2064,
471,
845,
326,
5907,
316,
326,
272,
484,
5314,
518,
333,
903,
845,
5314,
30,
508,
508,
18,
991,
508,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
845,
2261,
1557,
12,
2890,
16,
16922,
705,
87,
4672,
3536,
22188,
279,
666,
2064,
471,
845,
326,
5907,
316,
326,
272,
484,
5314,
518,
333,
903,
845,
5314,
30,
508,
508,
18,
991,
508,
... |
elif "border" in side: | elif border: | def render(context, grid, props): context.set_line_width(props.line["width"]) lines = grid.lines() for x, y, ltype, side in lines: sx = props.grid_to_screen_x(x, False) sy = props.grid_to_screen_y(y, False) # overestimate to accommodate for cells that are near the border of the puzzle bx = sx - props.line["width"] - props.border["width"] by = sy - props.line["width"] - props.border["width"] bsize = props.cell["size"] + 2 * props.border["width"] + 2 * props.line["width"] b = gtk.gdk.Rectangle(bx, by, bsize, bsize) if area is not None: i = b.intersect(self._determine_area(area)) else: i = b # only render when cell intersects the specified area if (i.x, i.y, i.width, i.height) != (0, 0, 0, 0): bar = grid.is_valid(x, y) and grid.has_bar(x, y, ltype) if ltype == "top": rx = sx if side == "normal": context.set_line_width(props.line["width"]) ry = sy - 0.5 * props.line["width"] rdx = props.cell["size"] elif "border" in side: context.set_line_width(props.border["width"]) if side == "outerborder": ry = sy - 0.5 * props.border["width"] elif side == "innerborder": ry = sy + 0.5 * props.border["width"] if not grid.is_available(x, y): ry -= props.line["width"] rdx = props.cell["size"] # adjust horizontal lines to fill empty spaces in corners dxl, dxr = get_adjustments(lines, props, x, y) rx -= dxl rdx += dxl rdx += dxr render_line(context, props, rx, ry, rdx, 0, bar) elif ltype == "left": if side == "normal": context.set_line_width(props.line["width"]) rx = sx - 0.5 * props.line["width"] rdy = props.cell["size"] elif "border" in side: context.set_line_width(props.border["width"]) if side == "outerborder": rx = sx - 0.5 * props.border["width"] elif side == "innerborder": rx = sx + 0.5 * props.border["width"] if not grid.is_available(x, y): rx -= props.line["width"] rdy = props.cell["size"] render_line(context, props, rx, sy, 0, rdy, bar) | ecd87a21ebde0b58512e2e83204dd5846ad8a497 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/6427/ecd87a21ebde0b58512e2e83204dd5846ad8a497/view.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1743,
12,
2472,
16,
3068,
16,
3458,
4672,
819,
18,
542,
67,
1369,
67,
2819,
12,
9693,
18,
1369,
9614,
2819,
6,
5717,
225,
2362,
273,
3068,
18,
3548,
1435,
364,
619,
16,
677,
16,
328,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1743,
12,
2472,
16,
3068,
16,
3458,
4672,
819,
18,
542,
67,
1369,
67,
2819,
12,
9693,
18,
1369,
9614,
2819,
6,
5717,
225,
2362,
273,
3068,
18,
3548,
1435,
364,
619,
16,
677,
16,
328,... |
if ((len(song.DisplayFilename) * self.GetCharWidth()) > self.MaxSecondColumnWidth): self.MaxSecondColumnWidth = len(song.DisplayFilename) * self.GetCharWidth() | if ((len(song.DisplayFilename) * self.GetCharWidth()) > self.MaxFileNamePerformerColumnWidth): self.MaxFileNamePerformerColumnWidth = len(song.DisplayFilename) * self.GetCharWidth() + self.GetCharWidth() | def DelItem( self, item_index ): # Update the max title width for column sizing, in case this was the largest one resize_needed = False if ((len(self.PlaylistSongStructList[item_index].DisplayFilename) * self.GetCharWidth()) == self.MaxSecondColumnWidth): resize_needed = True if ((len(self.PlaylistSongStructList[item_index].Title) * self.GetCharWidth()) == self.MaxTitleWidth): resize_needed = True | 7d6c2cead80b3d812ebc0d6027018fbc93b8714c /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/12653/7d6c2cead80b3d812ebc0d6027018fbc93b8714c/pykaraoke.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
6603,
1180,
12,
365,
16,
761,
67,
1615,
262,
30,
468,
2315,
326,
943,
2077,
1835,
364,
1057,
272,
6894,
16,
316,
648,
333,
1703,
326,
12756,
1245,
7041,
67,
17471,
273,
1083,
309,
1401... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
6603,
1180,
12,
365,
16,
761,
67,
1615,
262,
30,
468,
2315,
326,
943,
2077,
1835,
364,
1057,
272,
6894,
16,
316,
648,
333,
1703,
326,
12756,
1245,
7041,
67,
17471,
273,
1083,
309,
1401... |
self.messagequeue = Queue.Queue() self.messagehandler = threading.Thread(target=self.messagequeueworker) self.messagehandler.setDaemon(True) self.messagehandler.start() | def __init__(self, **kwargs): self._pluginData = {} self.state = b3.STATE_UNKNOWN self._data = {} self.messagequeue = Queue.Queue() self.messagehandler = threading.Thread(target=self.messagequeueworker) self.messagehandler.setDaemon(True) self.messagehandler.start() | 6ce7414417db4dd27c8e71c88381f1ffd3608f30 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12909/6ce7414417db4dd27c8e71c88381f1ffd3608f30/clients.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
16,
2826,
4333,
4672,
365,
6315,
4094,
751,
273,
2618,
365,
18,
2019,
273,
324,
23,
18,
7998,
67,
14737,
365,
6315,
892,
273,
2618,
365,
18,
2150,
4000,
273,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
16,
2826,
4333,
4672,
365,
6315,
4094,
751,
273,
2618,
365,
18,
2019,
273,
324,
23,
18,
7998,
67,
14737,
365,
6315,
892,
273,
2618,
365,
18,
2150,
4000,
273,... | |
return not self._vindex.get(version, 0) | self._lock_acquire() try: index=self._index file=self._file seek=file.seek read=file.read srcpos=self._vindex_get(version, 0) t=tstatus=None while srcpos: seek(srcpos) oid=read(8) if index[oid]==srcpos: return 0 h=read(50) tloc=h[16:24] if t != tloc: t=tloc seek(u64(t)+16) tstatus=read(1) if tstatus != 'u': return 1 spos=h[-8:] srcpos=u64(spos) return 1 finally: self._lock_release() | def versionEmpty(self, version): return not self._vindex.get(version, 0) | c717e4737d70d5e206ed68763b0a0252266215ca /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/10048/c717e4737d70d5e206ed68763b0a0252266215ca/FileStorage.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1177,
1921,
12,
2890,
16,
1177,
4672,
327,
486,
365,
6315,
90,
1615,
18,
588,
12,
1589,
16,
374,
13,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1177,
1921,
12,
2890,
16,
1177,
4672,
327,
486,
365,
6315,
90,
1615,
18,
588,
12,
1589,
16,
374,
13,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
sage: GenericDeclaration(x, 'rational').contradicts(y==pi) False sage: GenericDeclaration(x, 'rational').contradicts(y==pi) | sage: GenericDeclaration(x, 'rational').contradicts(x==pi) True sage: GenericDeclaration(x, 'irrational').contradicts(x!=pi) | def contradicts(self, soln): """ Returns ``True`` if this assumption is violated by the given variable assignment(s). EXAMPLES:: sage: from sage.symbolic.assumptions import GenericDeclaration sage: GenericDeclaration(x, 'integer').contradicts(x==4) False sage: GenericDeclaration(x, 'integer').contradicts(x==4.0) False sage: GenericDeclaration(x, 'integer').contradicts(x==4.5) True sage: GenericDeclaration(x, 'integer').contradicts(x==sqrt(17)) True sage: GenericDeclaration(x, 'noninteger').contradicts(x==sqrt(17)) False sage: GenericDeclaration(x, 'noninteger').contradicts(x==17) True sage: GenericDeclaration(x, 'even').contradicts(x==3) True sage: GenericDeclaration(x, 'complex').contradicts(x==3) False sage: GenericDeclaration(x, 'imaginary').contradicts(x==3) True sage: GenericDeclaration(x, 'imaginary').contradicts(x==I) False | ab6c6c39dcde5f4fab6d383714b672736e08a1ce /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/9890/ab6c6c39dcde5f4fab6d383714b672736e08a1ce/assumptions.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
16252,
361,
933,
87,
12,
2890,
16,
3704,
82,
4672,
3536,
2860,
12176,
5510,
10335,
309,
333,
24743,
353,
26889,
635,
326,
864,
2190,
6661,
12,
87,
2934,
225,
5675,
8900,
11386,
2866,
225... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
16252,
361,
933,
87,
12,
2890,
16,
3704,
82,
4672,
3536,
2860,
12176,
5510,
10335,
309,
333,
24743,
353,
26889,
635,
326,
864,
2190,
6661,
12,
87,
2934,
225,
5675,
8900,
11386,
2866,
225... |
if 'slice_ids' in node and slice_id in node['slice_ids']: | def remove_node(self, node, commit = True): """ Remove node from existing slice. """ | 25d0df2c73067b69bda924b8ddd0514d7fed5a51 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/7598/25d0df2c73067b69bda924b8ddd0514d7fed5a51/Slices.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1206,
67,
2159,
12,
2890,
16,
756,
16,
3294,
273,
1053,
4672,
3536,
3581,
756,
628,
2062,
2788,
18,
3536,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1206,
67,
2159,
12,
2890,
16,
756,
16,
3294,
273,
1053,
4672,
3536,
3581,
756,
628,
2062,
2788,
18,
3536,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... | |
self.__conductor = misc.mul([d.conductor() for d in self.decomposition()]) return self.__conductor | return misc.mul([d.conductor() for d in self.decomposition()]) | def conductor(self): """ Computes and returns the conductor of this character. EXAMPLES:: sage: G.<a,b> = DirichletGroup(20) sage: a.conductor() 4 sage: b.conductor() 5 sage: (a*b).conductor() 20 """ try: return self.__conductor except AttributeError: pass if self.modulus() == 1 or self.is_trivial(): self.__conductor = 1 return self.__conductor F = arith.factor(self.modulus()) if len(F) > 1: self.__conductor = misc.mul([d.conductor() for d in self.decomposition()]) return self.__conductor p = F[0][0] # When p is odd, and x =/= 1, the conductor is the smallest p**r such that # Order(x) divides EulerPhi(p**r) = p**(r-1)*(p-1). # For a given r, whether or not the above divisiblity holds # depends only on the factor of p**(r-1) on the right hand side. # Since p-1 is coprime to p, this smallest r such that the # divisibility holds equals Valuation(Order(x),p)+1. self.__conductor = p**(arith.valuation(self.order(),p) + 1) if p == 2 and F[0][1] > 2 and self.values_on_gens()[1].multiplicative_order() != 1: self.__conductor *= 2; return self.__conductor | 2d29bdbbd76a69f79b998867461156f2c290f64a /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9890/2d29bdbbd76a69f79b998867461156f2c290f64a/dirichlet.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
356,
1828,
280,
12,
2890,
4672,
3536,
14169,
281,
471,
1135,
326,
356,
1828,
280,
434,
333,
3351,
18,
225,
5675,
8900,
11386,
2866,
225,
272,
410,
30,
611,
22782,
69,
16,
70,
34,
273,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
356,
1828,
280,
12,
2890,
4672,
3536,
14169,
281,
471,
1135,
326,
356,
1828,
280,
434,
333,
3351,
18,
225,
5675,
8900,
11386,
2866,
225,
272,
410,
30,
611,
22782,
69,
16,
70,
34,
273,
... |
if not isinstance(ass_node, astng.Class) \ or self.not_show_builtin(ass_node): | if not (isinstance(ass_node, astng.Class) and self.show_node(ass_node)): | def get_associated(self, klass_node, level): """return associated nodes of a class node""" if level == 0: return for ass_nodes in klass_node.instance_attrs_type.values(): for ass_node in ass_nodes: if isinstance(ass_node, astng.Instance): ass_node = ass_node._proxied if not isinstance(ass_node, astng.Class) \ or self.not_show_builtin(ass_node): continue yield ass_node | e5bf91d422d3291a4aba46eec91c6252075b0609 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/928/e5bf91d422d3291a4aba46eec91c6252075b0609/diadefslib.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
67,
28441,
12,
2890,
16,
7352,
67,
2159,
16,
1801,
4672,
3536,
2463,
3627,
2199,
434,
279,
667,
756,
8395,
309,
1801,
422,
374,
30,
327,
364,
1551,
67,
4690,
316,
7352,
67,
2159,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
67,
28441,
12,
2890,
16,
7352,
67,
2159,
16,
1801,
4672,
3536,
2463,
3627,
2199,
434,
279,
667,
756,
8395,
309,
1801,
422,
374,
30,
327,
364,
1551,
67,
4690,
316,
7352,
67,
2159,
... |
xf = XmlPage (sys.argv[1]) | xf = XmlPage (os.path.join (CWD, sys.argv[1])) print 'Writing to ',os.path.join (os.getcwd(), sys.argv[2]) | def xmlStringToHtmlString (s): xmlfile = xmlsupport.AROSXmlFile () XML2HTML = Xml2HtmlProcessor () XML2HTML.toccount = [0, 0, 0, 0, 0] XML2HTML.toc = [] xmlfile.parseString (s) xmlfile.process (XML2HTML) # TODO There is no support for toc :-/ s = XML2HTML.fh.getvalue () XML2HTML.fh.close () return s | 7c487608428474e008d25895dcbf014be62baf73 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4747/7c487608428474e008d25895dcbf014be62baf73/xml2html.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2025,
23282,
4353,
780,
261,
87,
4672,
2025,
768,
273,
2025,
13261,
18,
985,
4618,
4432,
812,
1832,
225,
3167,
22,
4870,
273,
5714,
22,
4353,
5164,
1832,
3167,
22,
4870,
18,
1391,
1883,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2025,
23282,
4353,
780,
261,
87,
4672,
2025,
768,
273,
2025,
13261,
18,
985,
4618,
4432,
812,
1832,
225,
3167,
22,
4870,
273,
5714,
22,
4353,
5164,
1832,
3167,
22,
4870,
18,
1391,
1883,
... |
features.append([names[i][0] + ":" + fields[i],1]) | features.append([names[i][0] + ":" + fields[i], 1]) | def usage(): print "USAGE: %s --names <names-file> [options] <input_files>" % sys.argv[0] print "OPTIONS:" print " --names <names-file> feature type specification file" print " -N <text_expert> choose a text expert between fgram, ngram and sgram" print " -W <ngram_length> specify window length of text expert" print " --keep-empty-examples empty examples are removed by default" print " -o <feature-dict> output feature dictionary" print " -i <feature-dict> input feature dictionary" print " -e <output-extension> extension of output files (by concatenation, defaults to .svm)" print " --cutoff <freq> ignore nominal features occuring unfrequently" print " --ignore <columns> ignore a comma separated list of columns" print " --ignore-regex <regex> ignore columns that match a given regex" print " --only <columns> use only a comma separated list of columns" print " --only-regex <regex> use only columns that match a given regex" sys.exit(1) | cb340f3fb0986bc51c65615e88c299c19e2b1a5d /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/7747/cb340f3fb0986bc51c65615e88c299c19e2b1a5d/icsiboost_to_svm.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
4084,
13332,
1172,
315,
29550,
30,
738,
87,
1493,
1973,
411,
1973,
17,
768,
34,
306,
2116,
65,
411,
2630,
67,
2354,
2984,
738,
2589,
18,
19485,
63,
20,
65,
1172,
315,
12422,
2773,
1172... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
4084,
13332,
1172,
315,
29550,
30,
738,
87,
1493,
1973,
411,
1973,
17,
768,
34,
306,
2116,
65,
411,
2630,
67,
2354,
2984,
738,
2589,
18,
19485,
63,
20,
65,
1172,
315,
12422,
2773,
1172... |
if text==' ': text = ' ' | def fPrint(self, scanner, text): if text==' ': text = ' ' if self.__tmpElem is None: self.__tmpElem = ('print', '') (a,b) = self.__tmpElem self.__tmpElem = (a, b+text) | 401161b5bced3ceb6c6400437437a5bddaa5ac3d /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/8874/401161b5bced3ceb6c6400437437a5bddaa5ac3d/CLexer.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
284,
5108,
12,
2890,
16,
7683,
16,
977,
4672,
309,
365,
16186,
5645,
7498,
353,
599,
30,
365,
16186,
5645,
7498,
273,
7707,
1188,
2187,
28707,
261,
69,
16,
70,
13,
273,
365,
16186,
564... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
284,
5108,
12,
2890,
16,
7683,
16,
977,
4672,
309,
365,
16186,
5645,
7498,
353,
599,
30,
365,
16186,
5645,
7498,
273,
7707,
1188,
2187,
28707,
261,
69,
16,
70,
13,
273,
365,
16186,
564... | |
places.append(unicode(str(place[index]))) | places.append(unicode(place[index])) | def savePlacesSettings(self, ggroup, index, label): places = QStringList() for place in self.placesData: #place[0] is of type QUrl if index == 0: places.append(unicode(place[index].toString())) else: places.append(unicode(str(place[index]))) ggroup.writeEntry(label, QVariant(places)) | 16bc113b5d4a165648794338a2d7664bbd5d09e7 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/1729/16bc113b5d4a165648794338a2d7664bbd5d09e7/mainwindow.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1923,
24791,
2628,
12,
2890,
16,
314,
1655,
16,
770,
16,
1433,
4672,
12576,
273,
2238,
780,
682,
1435,
364,
3166,
316,
365,
18,
11350,
751,
30,
468,
964,
63,
20,
65,
353,
434,
618,
2... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1923,
24791,
2628,
12,
2890,
16,
314,
1655,
16,
770,
16,
1433,
4672,
12576,
273,
2238,
780,
682,
1435,
364,
3166,
316,
365,
18,
11350,
751,
30,
468,
964,
63,
20,
65,
353,
434,
618,
2... |
self.job.require_gcc() | def initialize(self): self.results = [] self.job.require_gcc() | c88906cbc110b7204613571b3f3b15ef0c1a35ed /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/12268/c88906cbc110b7204613571b3f3b15ef0c1a35ed/bonnie.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
4046,
12,
2890,
4672,
365,
18,
4717,
273,
5378,
365,
18,
4688,
18,
6528,
67,
75,
952,
1435,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
4046,
12,
2890,
4672,
365,
18,
4717,
273,
5378,
365,
18,
4688,
18,
6528,
67,
75,
952,
1435,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... | |
self.bossJob['taskId'], False ) | self.bossJob['taskId'], jobRange=None ) | def doBOSSSubmit(self): """ _doSubmit_ | ae518789e91669e80db09442e759a909e6b2d047 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/8887/ae518789e91669e80db09442e759a909e6b2d047/BossLiteBulkInterface.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
741,
5315,
1260,
11620,
12,
2890,
4672,
3536,
389,
2896,
11620,
67,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
741,
5315,
1260,
11620,
12,
2890,
4672,
3536,
389,
2896,
11620,
67,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
guid = os.path.join( forum_path, thread.object_id ), | guid = os.path.join( forum_path, ( forum_name == u"blog" ) and thread.friendly_id or thread.object_id ), | def __init__( self, user, notebooks, first_notebook, login_url, logout_url, rate_plan, groups, forum_name, threads, total_thread_count, start = 0, count = None, | c5a2765685129d71ba652e219a84c20ed8bed5cb /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/6754/c5a2765685129d71ba652e219a84c20ed8bed5cb/Forum_rss.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
365,
16,
729,
16,
4721,
12567,
16,
1122,
67,
24422,
16,
3925,
67,
718,
16,
12735,
67,
718,
16,
4993,
67,
7088,
16,
3252,
16,
11283,
67,
529,
16,
7403,
16,
2078,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
365,
16,
729,
16,
4721,
12567,
16,
1122,
67,
24422,
16,
3925,
67,
718,
16,
12735,
67,
718,
16,
4993,
67,
7088,
16,
3252,
16,
11283,
67,
529,
16,
7403,
16,
2078,
... |
sources['testing'][pkg_name] = sources[suite][pkg_name] | if not arch: sources['testing'][pkg_name] = sources[suite][pkg_name] | def doop_source(self, pkg): """Apply a change to the testing distribution as requested by `pkg` | b0ef0af3487c34142dce19457921f7cceb8b113e /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/2784/b0ef0af3487c34142dce19457921f7cceb8b113e/britney.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
741,
556,
67,
3168,
12,
2890,
16,
3475,
4672,
3536,
7001,
279,
2549,
358,
326,
7769,
7006,
487,
3764,
635,
1375,
10657,
68,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
741,
556,
67,
3168,
12,
2890,
16,
3475,
4672,
3536,
7001,
279,
2549,
358,
326,
7769,
7006,
487,
3764,
635,
1375,
10657,
68,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
"SELECT mytable.myid, mytable.name, max(mytable.description) FROM mytable \ | "SELECT mytable.myid, mytable.name, max(mytable.description) AS max_1 FROM mytable \ | def testunion(self): x = union( select([table1], table1.c.myid == 5), select([table1], table1.c.myid == 12), order_by = [table1.c.myid], ) | 64de56e55ebbc2c2ed5fc804cecbf10b24d094d7 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/1074/64de56e55ebbc2c2ed5fc804cecbf10b24d094d7/select.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1842,
18910,
12,
2890,
4672,
619,
273,
7812,
12,
2027,
3816,
2121,
21,
6487,
1014,
21,
18,
71,
18,
4811,
350,
422,
1381,
3631,
2027,
3816,
2121,
21,
6487,
1014,
21,
18,
71,
18,
4811,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1842,
18910,
12,
2890,
4672,
619,
273,
7812,
12,
2027,
3816,
2121,
21,
6487,
1014,
21,
18,
71,
18,
4811,
350,
422,
1381,
3631,
2027,
3816,
2121,
21,
6487,
1014,
21,
18,
71,
18,
4811,
... |
v v v v v v v | def complex(a, b): c = zeros(a.shape, dtype=complex_) | 59b4e95f7f51e2949dfc41d870520dd7f49c95eb /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12971/59b4e95f7f51e2949dfc41d870520dd7f49c95eb/test_numexpr.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
7233,
12,
69,
16,
324,
4672,
276,
273,
4922,
12,
69,
18,
4867,
16,
3182,
33,
14259,
67,
13,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
7233,
12,
69,
16,
324,
4672,
276,
273,
4922,
12,
69,
18,
4867,
16,
3182,
33,
14259,
67,
13,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... | |
self.recipe.winHelper.name = self.recipe.name self.recipe.winHelper.version = \ self.recipe.winHelper.platform = \ self.recipe.winHelper.productCode = \ self.recipe.winHelper.upgradeCode = m.contents['version'] | raise SourceError('MSI capsules cannot be added without a ' 'windowsBuildService defined in the conary ' 'configuration') | def doDownload(self): f = self._findSource() | f116ea0dd5d6fb42056761b0b8efee367153e3e1 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/8747/f116ea0dd5d6fb42056761b0b8efee367153e3e1/source.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
741,
7109,
12,
2890,
4672,
284,
273,
365,
6315,
4720,
1830,
1435,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
741,
7109,
12,
2890,
4672,
284,
273,
365,
6315,
4720,
1830,
1435,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,... |
self.file = file.file(name, "rw", 1536) | self.fileno = os.open(name, O_RDWR + O_NONBLOCK) | def __init__(self, name): """initialize a TapConnector object name - the name of a file or network interface to open """ try: # XXX This is a hack. Reads from a tap should really be # done in non-blocking mode as it uses an atomic I/O scheme, # 1 read 1 packet, so we set the buffer to the size of a # standard Ethernet frame and hope for the best. self.file = file.file(name, "rw", 1536) except: raise | 74c465b6f2a59893d314d13421f568c8966b5e0a /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/5910/74c465b6f2a59893d314d13421f568c8966b5e0a/__init__.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
16,
508,
4672,
3536,
11160,
279,
399,
438,
7487,
733,
508,
300,
326,
508,
434,
279,
585,
578,
2483,
1560,
358,
1696,
3536,
775,
30,
468,
11329,
1220,
353,
27... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
16,
508,
4672,
3536,
11160,
279,
399,
438,
7487,
733,
508,
300,
326,
508,
434,
279,
585,
578,
2483,
1560,
358,
1696,
3536,
775,
30,
468,
11329,
1220,
353,
27... |
test_and_expecation = parts[1].split('=') test = test_and_expecation[0].strip() | test_and_expectation = parts[1].split('=') test = test_and_expectation[0].strip() | def _GetPlatformUpdateAction(self, line, tests, platform): """Check the platform option and return the action needs to be taken. | f4907d6b405eda4f2c23302946e1a4dc9a146c10 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/5060/f4907d6b405eda4f2c23302946e1a4dc9a146c10/test_expectations.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
967,
8201,
1891,
1803,
12,
2890,
16,
980,
16,
7434,
16,
4072,
4672,
3536,
1564,
326,
4072,
1456,
471,
327,
326,
1301,
4260,
358,
506,
9830,
18,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
967,
8201,
1891,
1803,
12,
2890,
16,
980,
16,
7434,
16,
4072,
4672,
3536,
1564,
326,
4072,
1456,
471,
327,
326,
1301,
4260,
358,
506,
9830,
18,
2,
-100,
-100,
-100,
-100,
-100,
-1... |
self._columns[field].set(cr, self, id, field, vals[field], user, context=rel_context) | result += self._columns[field].set(cr, self, id, field, vals[field], user, context=rel_context) or [] | def write(self, cr, user, ids, vals, context=None): readonly = None for field in vals.copy(): fobj = None if field in self._columns: fobj = self._columns[field] else: fobj = self._inherit_fields[field][2] if not fobj: continue groups = fobj.write | dbc2adadf22d414d3fa5881293d5ee8c7ac71f2f /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/7397/dbc2adadf22d414d3fa5881293d5ee8c7ac71f2f/orm.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1045,
12,
2890,
16,
4422,
16,
729,
16,
3258,
16,
5773,
16,
819,
33,
7036,
4672,
17102,
273,
599,
364,
652,
316,
5773,
18,
3530,
13332,
24705,
273,
599,
309,
652,
316,
365,
6315,
5112,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1045,
12,
2890,
16,
4422,
16,
729,
16,
3258,
16,
5773,
16,
819,
33,
7036,
4672,
17102,
273,
599,
364,
652,
316,
5773,
18,
3530,
13332,
24705,
273,
599,
309,
652,
316,
365,
6315,
5112,
... |
print event | def eventhandler(self, event, menuw=None): """ Eventhandler for the media main menu. The menu must be regenerated when a disc in a rom drive changes """ if plugin.isevent(event): print event if not self.item_menu.visible: return True | d7b933a7208c8f3ec0e131f66381dd4aceb01569 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/11399/d7b933a7208c8f3ec0e131f66381dd4aceb01569/mediamenu.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
871,
4176,
12,
2890,
16,
871,
16,
3824,
91,
33,
7036,
4672,
3536,
2587,
4176,
364,
326,
3539,
2774,
3824,
18,
1021,
3824,
1297,
506,
960,
7489,
1347,
279,
19169,
316,
279,
24137,
14316,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
871,
4176,
12,
2890,
16,
871,
16,
3824,
91,
33,
7036,
4672,
3536,
2587,
4176,
364,
326,
3539,
2774,
3824,
18,
1021,
3824,
1297,
506,
960,
7489,
1347,
279,
19169,
316,
279,
24137,
14316,
... | |
MaximumValue = -9223372036854775808 MinimumValue = 9223372036854775807 | MinimumValue = -9223372036854775808 MaximumValue = 9223372036854775807 | def PythonToString (cls, value): return str(value) | 2d4060dcd2107ae475ac140a0864ce0c59a49340 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/7171/2d4060dcd2107ae475ac140a0864ce0c59a49340/datatypes.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
6600,
5808,
261,
6429,
16,
460,
4672,
327,
609,
12,
1132,
13,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
6600,
5808,
261,
6429,
16,
460,
4672,
327,
609,
12,
1132,
13,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
def_build = 'env CFLAGS="$RPM_OPT_FLAGS" python setup.py build' else: def_build = 'python setup.py build' | def_build = 'env CFLAGS="$RPM_OPT_FLAGS" ' + def_build | def _make_spec_file(self): """Generate the text of an RPM spec file and return it as a list of strings (one per line). """ # definitions and headers spec_file = [ '%define name ' + self.distribution.get_name(), '%define version ' + self.distribution.get_version(), '%define release ' + self.release, '', 'Summary: ' + self.distribution.get_description(), ] | d0e4b42ee241b29cc924b18f4c1efd29723c85cf /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8546/d0e4b42ee241b29cc924b18f4c1efd29723c85cf/bdist_rpm.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
6540,
67,
2793,
67,
768,
12,
2890,
4672,
3536,
4625,
326,
977,
434,
392,
534,
12728,
857,
585,
471,
327,
518,
487,
279,
666,
434,
2064,
261,
476,
1534,
980,
2934,
3536,
468,
6377,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
6540,
67,
2793,
67,
768,
12,
2890,
4672,
3536,
4625,
326,
977,
434,
392,
534,
12728,
857,
585,
471,
327,
518,
487,
279,
666,
434,
2064,
261,
476,
1534,
980,
2934,
3536,
468,
6377,... |
if self._col_animation and self._col_animation.is_playing: self._col_animation.stop() start = self._y0 - self._cy0 self._cell0[1] = col stop = self._cell0[1] * self._row_size | if self.__col_animation and self.__col_animation.is_playing: self.__col_animation.stop() self.items.cell0[1] = col y = self.items.cell0[1] * self._row_size + self.items.y - self.items.y0 | def scroll_to(self, (row, col), secs): """ Scroll to row / cell position | b47bb145b9afab8cd03f9ba37d4dcd175be8f666 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/11702/b47bb145b9afab8cd03f9ba37d4dcd175be8f666/grid.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
5532,
67,
869,
12,
2890,
16,
261,
492,
16,
645,
3631,
18043,
4672,
3536,
23134,
358,
1027,
342,
2484,
1754,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
5532,
67,
869,
12,
2890,
16,
261,
492,
16,
645,
3631,
18043,
4672,
3536,
23134,
358,
1027,
342,
2484,
1754,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
elif (sig.getAppearance() == FLASHYELLOW) : | elif (sigState == FLASHYELLOW) : | def cvtAppearanceIcon(self, sig) : rep = self.darkSignalIcon if (sig.getLit()) : if (sig.getAppearance() == RED) : rep = self.redSignalIcon elif (sig.getAppearance() == FLASHRED) : rep = self.redFlashSignalIcon elif (sig.getAppearance() == YELLOW) : rep = self.yellowSignalIcon elif (sig.getAppearance() == FLASHYELLOW) : rep = self.yellowFlashSignalIcon elif (sig.getAppearance() == GREEN) : rep = self.greenSignalIcon elif (sig.getAppearance() == FLASHGREEN) : rep = self.greenFlashSignalIcon else : rep = self.unknownSignalIcon #self.msgText("Found signal " + self.giveSignalName(sig) + " displaying: " + rep + "\n") return rep | ea0545abfec3c873ac30e3d94a5ae0a9a6e544ba /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/1660/ea0545abfec3c873ac30e3d94a5ae0a9a6e544ba/RobotThrottle2.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
8951,
88,
1294,
27668,
5554,
12,
2890,
16,
3553,
13,
294,
2071,
273,
365,
18,
25045,
11208,
5554,
309,
261,
7340,
18,
588,
23707,
10756,
294,
309,
261,
7340,
18,
588,
1294,
27668,
1435,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
8951,
88,
1294,
27668,
5554,
12,
2890,
16,
3553,
13,
294,
2071,
273,
365,
18,
25045,
11208,
5554,
309,
261,
7340,
18,
588,
23707,
10756,
294,
309,
261,
7340,
18,
588,
1294,
27668,
1435,
... |
macros['mkObjdir'] = '' macros['configure'] = './%s' % self.configureName | macros.mkObjdir = '' macros.configure = './%s' % self.configureName | def do(self, macros): | 9b13a7ba2c018154423580c815130d20d0fb4d24 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8747/9b13a7ba2c018154423580c815130d20d0fb4d24/build.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
741,
12,
2890,
16,
24302,
4672,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
741,
12,
2890,
16,
24302,
4672,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
elif self.javascript: | elif self.js_filter: | def startElement (self, tag, attrs): """We get a new start tag. New rules could be appended to the pending rules. No rules can be removed from the list.""" # default data item = [STARTTAG, tag, attrs] if self.state=='wait': return self.waitbuf.append(item) rulelist = [] filtered = 0 # look for filter rules which apply for rule in self.rules: if rule.match_tag(tag) and rule.match_attrs(attrs): debug(NIGHTMARE, "HtmlFilter: matched rule %s on tag %s" % (`rule.title`, `tag`)) if rule.start_sufficient: item = rule.filter_tag(tag, attrs) filtered = "True" # give'em a chance to replace more than one attribute if item[0]==STARTTAG and item[1]==tag: foo,tag,attrs = item continue else: break else: debug(NIGHTMARE, "HtmlFilter: put on buffer") rulelist.append(rule) if rulelist: # remember buffer position for end tag matching pos = len(self.buf) self.rulestack.append((pos, rulelist)) if filtered: self.buf_append_data(item) elif self.javascript: # if its not yet filtered, try filter javascript self.jsStartElement(tag, attrs) else: self.buf.append(item) # if rule stack is empty, write out the buffered data if not self.rulestack and not self.javascript: self.buf2data() | 475def66113a258d59f287a283585f27e07dd77a /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/3948/475def66113a258d59f287a283585f27e07dd77a/Rewriter.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
13591,
261,
2890,
16,
1047,
16,
3422,
4672,
3536,
3218,
336,
279,
394,
787,
1047,
18,
1166,
2931,
3377,
506,
12317,
358,
326,
4634,
2931,
18,
2631,
2931,
848,
506,
3723,
628,
326,
666,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
13591,
261,
2890,
16,
1047,
16,
3422,
4672,
3536,
3218,
336,
279,
394,
787,
1047,
18,
1166,
2931,
3377,
506,
12317,
358,
326,
4634,
2931,
18,
2631,
2931,
848,
506,
3723,
628,
326,
666,
... |
os.dup(fdesc.fileno()) os.dup(fdesc.fileno()) | os.dup2(fdesc.fileno(), 0) os.dup2(fdesc.fileno(), 1) | def forkPassingFD(exe, args, env, user, group, fdesc): """Run exe as a child process, passing fdesc as fd 0. This will also make sure that fdesc is removed from the parent's reactor. """ # This is half-cannibalised from twisted.internet.process.Process pid = os.fork() if pid == 0: # Child try: # Close stdin/stdout (we keep stderr from the parent to report # errors with) for fd in range(2): os.close(fd) # Make the socket be fd 0 # (and fd 1, although I'm not sure if that matters) os.dup(fdesc.fileno()) os.dup(fdesc.fileno()) # Close unused file descriptors for fd in range(3, 256): try: os.close(fd) except: pass # Set uid/gid os.setgid(group) os.setuid(user) # Start the new process os.execvpe(exe, args, env) except: # If anything goes wrong, just die. stderr = os.fdopen(2, 'w') stderr.write('Unable to spawn child:\n') traceback.print_exc(file=stderr) # Close the socket so the client doesn't think it's still # connected to a server try: s = socket.fromfd(0, socket.AF_INET, socket.SOCK_STREAM) s.shutdown(2) except: pass os._exit(1) else: # Parent reactor.removeReader(fdesc) reactor.removeWriter(fdesc) | da7ab085d7e2063ff941b368c889c9a5567edaf1 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12595/da7ab085d7e2063ff941b368c889c9a5567edaf1/inetd.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
12515,
6433,
310,
16894,
12,
14880,
16,
833,
16,
1550,
16,
729,
16,
1041,
16,
5194,
742,
4672,
3536,
1997,
15073,
487,
279,
1151,
1207,
16,
9588,
5194,
742,
487,
5194,
374,
18,
225,
12... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
12515,
6433,
310,
16894,
12,
14880,
16,
833,
16,
1550,
16,
729,
16,
1041,
16,
5194,
742,
4672,
3536,
1997,
15073,
487,
279,
1151,
1207,
16,
9588,
5194,
742,
487,
5194,
374,
18,
225,
12... |
a specially formatted filename that contains the VCS type, | a tuple containing 1) a specially formatted filename that contains the VCS type, | def GetVCSFilename(file, srcdir): """Given a full path to a file, and the top source directory, look for version control information about this file, and return a specially formatted filename that contains the VCS type, VCS location, relative filename, and revision number, formatted like: vcs:vcs location:filename:revision For example: cvs:cvs.mozilla.org/cvsroot:mozilla/browser/app/nsBrowserApp.cpp:1.36""" (path, filename) = os.path.split(file) if path == '' or filename == '': return file fileInfo = None if file in vcsFileInfoCache: # Already cached this info, use it. fileInfo = vcsFileInfoCache[file] else: if os.path.isdir(os.path.join(path, "CVS")): fileInfo = CVSFileInfo(file, srcdir) elif os.path.isdir(os.path.join(path, ".svn")) or \ os.path.isdir(os.path.join(path, "_svn")): fileInfo = SVNFileInfo(file); vcsFileInfoCache[file] = fileInfo if fileInfo: file = fileInfo.filename # we want forward slashes on win32 paths return file.replace("\\", "/") | 758a6b78450ffab940532ff75cb7103acc041684 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/13067/758a6b78450ffab940532ff75cb7103acc041684/symbolstore.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
968,
58,
4596,
5359,
12,
768,
16,
1705,
1214,
4672,
3536,
6083,
279,
1983,
589,
358,
279,
585,
16,
471,
326,
1760,
1084,
1867,
16,
2324,
364,
1177,
3325,
1779,
2973,
333,
585,
16,
471,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
968,
58,
4596,
5359,
12,
768,
16,
1705,
1214,
4672,
3536,
6083,
279,
1983,
589,
358,
279,
585,
16,
471,
326,
1760,
1084,
1867,
16,
2324,
364,
1177,
3325,
1779,
2973,
333,
585,
16,
471,... |
def SetFixup(ea, type, targetsel, targetoff, displ): | def SetFixup(ea, fixuptype, targetsel, targetoff, displ): | def SetFixup(ea, type, targetsel, targetoff, displ): """ Set fixup information @param ea: address to set fixup information about @param type: fixup type. see GetFixupTgtType() for possible fixup types. @param targetsel: target selector @param targetoff: target offset @param displ: displacement @return: none """ fd = idaapi.fixup_data_t() fd.type = type fd.sel = targetsel fd.off = targetoff fd.displacement = displ idaapi.set_fixup(ea, fd) | 244a3cd02a580c0095170004ec30e922f0d1a8a6 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/6984/244a3cd02a580c0095170004ec30e922f0d1a8a6/idc.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1000,
8585,
416,
12,
24852,
16,
2917,
3648,
388,
16,
1018,
1786,
16,
1018,
3674,
16,
1015,
412,
4672,
3536,
1000,
2917,
416,
1779,
225,
632,
891,
24164,
30,
1758,
358,
444,
2917,
416,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1000,
8585,
416,
12,
24852,
16,
2917,
3648,
388,
16,
1018,
1786,
16,
1018,
3674,
16,
1015,
412,
4672,
3536,
1000,
2917,
416,
1779,
225,
632,
891,
24164,
30,
1758,
358,
444,
2917,
416,
... |
os.path.join('hookbox', 'admin', 'static') | os.path.join('hookbox', 'admin', 'static'), os.path.join('hookbox', 'js_src') | def find_package_data(): targets = [ os.path.join('hookbox', 'static'), os.path.join('hookbox', 'admin', 'static') ] package_data = {'': reduce(list.__add__, [ '.git' not in d and [ os.path.join(d[len('hookbox/'):], e) for e in static_types ] or [] for (d, s, f) in reduce(list.__add__, [ [ i for i in os.walk(target) ] for target in targets ]) ]) } return package_data | 58e8dde56c91ffa1a38b32088c6f6f7f8ef1aa72 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/13219/58e8dde56c91ffa1a38b32088c6f6f7f8ef1aa72/setup.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1104,
67,
5610,
67,
892,
13332,
5774,
273,
306,
1140,
18,
803,
18,
5701,
2668,
4476,
2147,
2187,
296,
3845,
19899,
1140,
18,
803,
18,
5701,
2668,
4476,
2147,
2187,
296,
3666,
2187,
296,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1104,
67,
5610,
67,
892,
13332,
5774,
273,
306,
1140,
18,
803,
18,
5701,
2668,
4476,
2147,
2187,
296,
3845,
19899,
1140,
18,
803,
18,
5701,
2668,
4476,
2147,
2187,
296,
3666,
2187,
296,
... |
Run(Command + " " + Symbols + " " + SymbolsRoot) | Run(Command + " " + os.path.basename(Symbols) + " " + os.path.basename(SymbolsRoot)) | def Callback(Arg, Directory, Names): if (os.path.basename(Directory).endswith("-symbols")): return for Name in Names: Extension = os.path.splitext(Name)[1].lower() if (Extension == ".pdb"): shutil.move(os.path.join(Directory, Name), SymbolsRoot) elif (Extension == ".m3" or Extension == ".m3web" # Can be useful for bootstrapping standalone cm3.exe in future. #or Extension == ".sa ): DeleteFile(os.path.join(Directory, Name)) | 326b613458da299329bbd08040a5445180927c31 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/9328/326b613458da299329bbd08040a5445180927c31/make-dist.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
8444,
12,
4117,
16,
8930,
16,
5276,
4672,
309,
261,
538,
18,
803,
18,
13909,
12,
2853,
2934,
5839,
1918,
2932,
17,
15536,
6,
3719,
30,
327,
364,
1770,
316,
5276,
30,
10021,
273,
1140,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
8444,
12,
4117,
16,
8930,
16,
5276,
4672,
309,
261,
538,
18,
803,
18,
13909,
12,
2853,
2934,
5839,
1918,
2932,
17,
15536,
6,
3719,
30,
327,
364,
1770,
316,
5276,
30,
10021,
273,
1140,
... |
creeps.append(Creep(screen, 'graycreep.png', (randint(0,SCREEN_WIDTH),randint(0,SCREEN_HEIGHT)), randint(0,360), 2)) | creeps.append(Creep(screen, 'graycreep.png', (randint(0,SCREEN_WIDTH),randint(0,SCREEN_HEIGHT)), randint(0,360), CREEP_SPEED)) | def run_game(): SCREEN_WIDTH, SCREEN_HEIGHT = 300, 400 BG_COLOR = 150, 150, 80 N_CREEPS = 10 pygame.init() screen = pygame.display.set_mode((SCREEN_WIDTH, SCREEN_HEIGHT), 0, 32) clock = pygame.time.Clock() # Create N_CREEPS random creeps. creeps = [] for i in range(N_CREEPS): creeps.append(Creep(screen, 'graycreep.png', (randint(0,SCREEN_WIDTH),randint(0,SCREEN_HEIGHT)), randint(0,360), 2)) while True: clock.tick(40) for event in pygame.event.get(): if event.type == pygame.QUIT: sys.exit() screen.fill(BG_COLOR) for creep in creeps: creep.update() creep.blitme() pygame.display.flip() | 7a09d565d719141bf5936b9010c7d5ace7c1bcfe /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/14554/7a09d565d719141bf5936b9010c7d5ace7c1bcfe/creeps.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1086,
67,
13957,
13332,
348,
5458,
1157,
67,
10023,
16,
348,
5458,
1157,
67,
14595,
273,
11631,
16,
7409,
30609,
67,
10989,
273,
18478,
16,
18478,
16,
8958,
423,
67,
5458,
41,
5857,
273,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1086,
67,
13957,
13332,
348,
5458,
1157,
67,
10023,
16,
348,
5458,
1157,
67,
14595,
273,
11631,
16,
7409,
30609,
67,
10989,
273,
18478,
16,
18478,
16,
8958,
423,
67,
5458,
41,
5857,
273,... |
str("%8.2f (%i, %4.1f%s)"%(isi_n_abs,n_n_abs_viol, 100.0*float(n_n_abs_viol)/n_n_abs,'%' )), | str("%8.2f (%i, %4.1f%s)"%(isi_n_abs,n_n_abs_viol, 100.0*float(n_n_abs_viol)/max(1,n_n_abs),'%' )), | def check_conditions(self): table_text = """ | 6452ee7e3e0ec4993605b541988d52801a08c075 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/696/6452ee7e3e0ec4993605b541988d52801a08c075/absences.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
866,
67,
6381,
12,
2890,
4672,
1014,
67,
955,
273,
3536,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
866,
67,
6381,
12,
2890,
4672,
1014,
67,
955,
273,
3536,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
return d['ymax'] self._minmax_data['ymax'] = float(ymax) | return self.get_axes_range()['ymax'] else: self.set_axes_range(ymax=ymax) | def ymax(self, ymax=None): """ EXAMPLES: sage: g = line([(-1,1), (3,2)]) sage: g.ymax() 2.0 sage: g.ymax(10) sage: g.ymax() 10.0 """ d = self.get_minmax_data() if ymax is None: return d['ymax'] self._minmax_data['ymax'] = float(ymax) | 38e84fc4c8a2973b3412d548ce99e19dd9db26fb /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9890/38e84fc4c8a2973b3412d548ce99e19dd9db26fb/plot.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
15275,
12,
2890,
16,
15275,
33,
7036,
4672,
3536,
5675,
8900,
11386,
30,
272,
410,
30,
314,
273,
980,
3816,
19236,
21,
16,
21,
3631,
261,
23,
16,
22,
13,
5717,
272,
410,
30,
314,
18,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
15275,
12,
2890,
16,
15275,
33,
7036,
4672,
3536,
5675,
8900,
11386,
30,
272,
410,
30,
314,
273,
980,
3816,
19236,
21,
16,
21,
3631,
261,
23,
16,
22,
13,
5717,
272,
410,
30,
314,
18,... |
self.assertTrue(ignore.names('bar/baz.py', 'baz')) | self.assertTrue(ignore.names(jn('bar', 'baz.py'), 'baz')) | def test_ignored(self): ignore = trace.Ignore(['x', 'y.z'], ['/foo/bar']) self.assertTrue(ignore.names('x.py', 'x')) self.assertFalse(ignore.names('xy.py', 'xy')) self.assertFalse(ignore.names('y.py', 'y')) self.assertTrue(ignore.names('/foo/bar/baz.py', 'baz')) self.assertFalse(ignore.names('bar/z.py', 'z')) # Matched before. self.assertTrue(ignore.names('bar/baz.py', 'baz')) | a365c068616af01e71f3e8020273392d711dc81f /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/3187/a365c068616af01e71f3e8020273392d711dc81f/test_trace.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1842,
67,
24055,
12,
2890,
4672,
2305,
273,
2606,
18,
3777,
12,
3292,
92,
2187,
296,
93,
18,
94,
17337,
10228,
19,
11351,
19,
3215,
19486,
365,
18,
11231,
5510,
12,
6185,
18,
1973,
266... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1842,
67,
24055,
12,
2890,
4672,
2305,
273,
2606,
18,
3777,
12,
3292,
92,
2187,
296,
93,
18,
94,
17337,
10228,
19,
11351,
19,
3215,
19486,
365,
18,
11231,
5510,
12,
6185,
18,
1973,
266... |
self.input('mosaic %f' % (2.0 * mosaic)) | self.input('mosaic %f' % mosaic) | def _mosflm_refine_cell(self, set_spacegroup = None): '''Perform the refinement of the unit cell. This will populate all of the information needed to perform the integration.''' | d42e8c678d13e059588a4087b62445a57c0db677 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/3290/d42e8c678d13e059588a4087b62445a57c0db677/Mosflm.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
26719,
2242,
81,
67,
1734,
558,
67,
3855,
12,
2890,
16,
444,
67,
2981,
1655,
273,
599,
4672,
9163,
4990,
326,
25994,
820,
434,
326,
2836,
2484,
18,
1220,
903,
6490,
777,
434,
326,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
26719,
2242,
81,
67,
1734,
558,
67,
3855,
12,
2890,
16,
444,
67,
2981,
1655,
273,
599,
4672,
9163,
4990,
326,
25994,
820,
434,
326,
2836,
2484,
18,
1220,
903,
6490,
777,
434,
326,... |
return | return | def magicWord(self, replyTo, **kw): # This will process Magic Word requests # Currently the following words are supported: # ~aiobjectcount # ~aitaskmgr # ~aijobmgr # ~assignQuest # ~money # First we need to figure out which magic word is being called try: theMagicWord = kw['magicWord'] except KeyError: # MagicWord issue. Malformed URL replyTo.respond('<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">\n<html>\n<head>\n<meta content="text/html; charset=ISO-8859-1" http-equiv="content-type">\n<TITLE>Magic Word Error</title>\n</head><body>Please check the URL. Transaction could not be completed. Malformed URL.</BODY>\n</HTML>') return | c8c9b88190fa7c3cc0976a15590a6491e947cb7b /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/7242/c8c9b88190fa7c3cc0976a15590a6491e947cb7b/webAIInspector.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
8146,
3944,
12,
2890,
16,
30934,
16,
2826,
9987,
4672,
468,
1220,
903,
1207,
28496,
9926,
3285,
468,
15212,
326,
3751,
4511,
854,
3260,
30,
468,
4871,
69,
1594,
489,
1883,
468,
4871,
154... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
8146,
3944,
12,
2890,
16,
30934,
16,
2826,
9987,
4672,
468,
1220,
903,
1207,
28496,
9926,
3285,
468,
15212,
326,
3751,
4511,
854,
3260,
30,
468,
4871,
69,
1594,
489,
1883,
468,
4871,
154... |
dc = wx.PaintDC(self) | dc = wx.BufferedPaintDC(self) | def OnPaint(self, event): #dc = wx.BufferedPaintDC(self) dc = wx.PaintDC(self) self.Draw(dc) | 4f104826fba66f362ccfc626eab4eac49fda23a2 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/1831/4f104826fba66f362ccfc626eab4eac49fda23a2/GanttChart.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2755,
12699,
12,
2890,
16,
871,
4672,
468,
7201,
273,
7075,
18,
17947,
12699,
5528,
12,
2890,
13,
7201,
273,
7075,
18,
17947,
12699,
5528,
12,
2890,
13,
225,
365,
18,
6493,
12,
7201,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2755,
12699,
12,
2890,
16,
871,
4672,
468,
7201,
273,
7075,
18,
17947,
12699,
5528,
12,
2890,
13,
7201,
273,
7075,
18,
17947,
12699,
5528,
12,
2890,
13,
225,
365,
18,
6493,
12,
7201,
1... |
"""Determine if the portlet is available at all.""" return self.poi_view.can_add_tasks() | """Determine if the portlet is available at all. It is available when we are allowed to add a PoiTask here and there are open issues. """ return self.poi_view.can_add_tasks() and \ len(self.poi_view.get_open_issues_in_project()) > 0 | def available(self): """Determine if the portlet is available at all.""" return self.poi_view.can_add_tasks() | 1a0b761b602bcbf1233297f146ebc167ffeba940 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/10431/1a0b761b602bcbf1233297f146ebc167ffeba940/poi_creation.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2319,
12,
2890,
4672,
3536,
8519,
309,
326,
13114,
353,
2319,
622,
777,
12123,
327,
365,
18,
1631,
77,
67,
1945,
18,
4169,
67,
1289,
67,
9416,
1435,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2319,
12,
2890,
4672,
3536,
8519,
309,
326,
13114,
353,
2319,
622,
777,
12123,
327,
365,
18,
1631,
77,
67,
1945,
18,
4169,
67,
1289,
67,
9416,
1435,
2,
-100,
-100,
-100,
-100,
-100,
-1... |
self.viewDefviewAction.setText(self.__tr("&Default Views")) self.viewDefviewAction.setMenuText(self.__tr("&Default Views")) | self.viewDefviewAction.setText(self.__tr("Orientations")) self.viewDefviewAction.setMenuText(self.__tr("Orientations")) | def languageChange(self): self.setCaption(self.__tr("Atom")) self.fileNewAction.setText(self.__tr("New")) self.fileNewAction.setMenuText(self.__tr("&New")) self.fileNewAction.setAccel(self.__tr("Ctrl+N")) self.fileOpenAction.setText(self.__tr("Open")) self.fileOpenAction.setMenuText(self.__tr("&Open...")) self.fileOpenAction.setAccel(self.__tr("Ctrl+O")) self.fileSaveAction.setText(self.__tr("Save")) self.fileSaveAction.setMenuText(self.__tr("&Save")) self.fileSaveAction.setAccel(self.__tr("Ctrl+S")) self.fileSaveAsAction.setText(self.__tr("Save As")) self.fileSaveAsAction.setMenuText(self.__tr("Save &As...")) self.fileSaveAsAction.setAccel(QString.null) self.fileImageAction.setText(self.__tr("&Image...")) self.fileImageAction.setMenuText(self.__tr("&Image...")) self.fileImageAction.setAccel(self.__tr("Ctrl+I")) self.fileExitAction.setText(self.__tr("Exit")) self.fileExitAction.setMenuText(self.__tr("E&xit")) self.fileExitAction.setAccel(QString.null) self.editUndoAction.setText(self.__tr("Undo")) self.editUndoAction.setMenuText(self.__tr("&Undo")) self.editUndoAction.setAccel(self.__tr("Ctrl+Z")) self.editRedoAction.setText(self.__tr("Redo")) self.editRedoAction.setMenuText(self.__tr("&Redo")) self.editRedoAction.setAccel(self.__tr("Ctrl+Y")) self.editCutAction.setText(self.__tr("Cut")) self.editCutAction.setMenuText(self.__tr("&Cut")) self.editCutAction.setAccel(self.__tr("Ctrl+X")) self.editCopyAction.setText(self.__tr("Copy")) self.editCopyAction.setMenuText(self.__tr("C&opy")) self.editCopyAction.setAccel(self.__tr("Ctrl+C")) self.editPasteAction.setText(self.__tr("Paste")) self.editPasteAction.setMenuText(self.__tr("&Paste")) self.editPasteAction.setAccel(self.__tr("Ctrl+V")) self.editFindAction.setText(self.__tr("Find")) self.editFindAction.setMenuText(self.__tr("&Find...")) self.helpContentsAction.setText(self.__tr("Contents")) self.helpContentsAction.setMenuText(self.__tr("&Contents...")) self.helpContentsAction.setAccel(QString.null) self.helpIndexAction.setText(self.__tr("Index")) self.helpIndexAction.setMenuText(self.__tr("&Index...")) self.helpIndexAction.setAccel(QString.null) self.helpAboutAction.setText(self.__tr("About")) self.helpAboutAction.setMenuText(self.__tr("&About")) self.helpAboutAction.setAccel(QString.null) self.setViewFitToWindowAction.setText(self.__tr("Fit to Window")) self.setViewFitToWindowAction.setMenuText(self.__tr("&Fit to Window")) self.setViewFitToWindowAction.setToolTip(self.__tr("Fit to Window (Ctrl+F)")) self.setViewFitToWindowAction.setAccel(self.__tr("Ctrl+F")) self.fileCloseAction.setText(self.__tr("Close")) self.fileCloseAction.setMenuText(self.__tr("&Close")) self.viewDefviewAction.setText(self.__tr("&Default Views")) self.viewDefviewAction.setMenuText(self.__tr("&Default Views")) self.viewDefviewAction.setToolTip(self.__tr("Default Views")) self.dispBGColorAction.setText(self.__tr("Background Color...")) self.dispBGColorAction.setMenuText(self.__tr("&Background Color...")) self.selectAllAction.setText(self.__tr("All")) self.selectAllAction.setMenuText(self.__tr("&All")) self.selectAllAction.setToolTip(self.__tr("Select All (Ctrl+A)")) self.selectAllAction.setAccel(self.__tr("Ctrl+A")) self.selectNoneAction.setText(self.__tr("None")) self.selectNoneAction.setMenuText(self.__tr("&None")) self.selectNoneAction.setToolTip(self.__tr("Select None (Ctrl+D)")) self.selectNoneAction.setAccel(self.__tr("Ctrl+D")) self.selectInvertAction.setText(self.__tr("Invert")) self.selectInvertAction.setMenuText(self.__tr("&Invert")) self.selectInvertAction.setToolTip(self.__tr("Select Invert (Ctrl+Shift+I)")) self.selectInvertAction.setAccel(self.__tr("Ctrl+Shift+I")) self.toolsRevolveAction.setText(self.__tr("Revolve")) self.toolsRevolveAction.setMenuText(self.__tr("&Revolve")) self.toolsRevolveAction.setToolTip(self.__tr("Revolve")) self.toolsExtrudeAction.setText(self.__tr("Extrude")) self.toolsExtrudeAction.setMenuText(self.__tr("&Extrude")) self.toolsExtrudeAction.setToolTip(self.__tr("Extrude")) self.toolsCookieCutAction.setText(self.__tr("Cookie Cutter")) self.toolsCookieCutAction.setMenuText(self.__tr("&Cookie Cutter")) self.toolsCookieCutAction.setToolTip(self.__tr("Cookie Cutter")) self.toolsSimulatorAction.setText(self.__tr("Simulator")) self.toolsSimulatorAction.setMenuText(self.__tr("&Simulator...")) self.toolsSimulatorAction.setToolTip(self.__tr("Simulator")) self.ccAddLayerAction.setText(self.__tr("Add Layer")) self.ccAddLayerAction.setMenuText(self.__tr("Add Layer")) self.toolsDoneAction.setText(self.__tr("Done")) self.toolsDoneAction.setMenuText(self.__tr("Done")) self.toolsCancelAction.setText(self.__tr("Cancel")) self.toolsCancelAction.setMenuText(self.__tr("Cancel")) self.editDeleteAction.setText(self.__tr("Delete")) self.editDeleteAction.setMenuText(self.__tr("&Delete")) self.editDeleteAction.setToolTip(self.__tr("Delete (Del)")) self.editDeleteAction.setAccel(self.__tr("Del")) self.viewToolbarsAction.setText(self.__tr("Toolbars")) self.viewToolbarsAction.setMenuText(self.__tr("&Toolbars")) self.dispObjectColorAction.setText(self.__tr("Object Color...")) self.dispObjectColorAction.setMenuText(self.__tr("&Object Color...")) self.dispOpenBondsAction.setText(self.__tr("Display Open Bonds")) self.dispOpenBondsAction.setMenuText(self.__tr("Display Open Bonds")) self.modifyHydrogenateAction.setText(self.__tr("Hydrogenate")) self.modifyHydrogenateAction.setMenuText(self.__tr("&Hydrogenate")) self.modifyHydrogenateAction.setToolTip(self.__tr("Hydrogenate (Ctrl+H)")) self.modifyHydrogenateAction.setAccel(self.__tr("Ctrl+H")) self.modifyPassivateAction.setText(self.__tr("Passivate")) self.modifyPassivateAction.setMenuText(self.__tr("&Passivate")) self.modifyPassivateAction.setToolTip(self.__tr("Passivate (Ctrl+P)")) self.modifyPassivateAction.setAccel(self.__tr("Ctrl+P")) self.jigsMotorAction.setText(self.__tr("Rotary Motor")) self.jigsMotorAction.setMenuText(self.__tr("&Rotary Motor")) self.modifyMinimizeAction.setText(self.__tr("Minimize")) self.modifyMinimizeAction.setMenuText(self.__tr("&Minimize")) self.modifyMinimizeAction.setToolTip(self.__tr("Minimize (Ctrl+M)")) self.modifyMinimizeAction.setAccel(self.__tr("Ctrl+M")) self.elemChangePTableAction.setText(self.__tr("Atom Type")) self.elemChangePTableAction.setMenuText(self.__tr("Atom Type")) self.toolsMovieAction.setText(self.__tr("Movie")) self.toolsMovieAction.setMenuText(self.__tr("&Movie...")) self.toggleFileTbarAction.setText(self.__tr("File")) self.toggleFileTbarAction.setMenuText(self.__tr("File")) self.toggleEditTbarAction.setText(self.__tr("Edit")) self.toggleEditTbarAction.setMenuText(self.__tr("Edit")) self.toggleViewTbarAction.setText(self.__tr("View")) self.toggleViewTbarAction.setMenuText(self.__tr("View")) self.toggleModelDispTbarAction.setText(self.__tr("Model Display")) self.toggleModelDispTbarAction.setMenuText(self.__tr("Model Display")) self.toggleSelectTbarAction.setText(self.__tr("Select")) self.toggleSelectTbarAction.setMenuText(self.__tr("Select")) self.toggleToolsTbarAction.setText(self.__tr("Tools")) self.toggleToolsTbarAction.setMenuText(self.__tr("Tools")) self.fileSetWorkDirAction.setText(self.__tr("Set Working Directory...")) self.fileSetWorkDirAction.setMenuText(self.__tr("Set &Working Directory...")) self.dispTrihedronAction.setText(self.__tr("Trihedron")) self.dispTrihedronAction.setMenuText(self.__tr("Trihedron")) self.dispTrihedronAction.setToolTip(self.__tr("Display Trihedron")) self.dispDatumPlanesAction.setText(self.__tr("Display Datum Planes")) self.dispDatumPlanesAction.setMenuText(self.__tr("Display Datum Planes")) self.dispCsysAction.setText(self.__tr("Display Coordinate System")) self.dispCsysAction.setMenuText(self.__tr("Display Coordinate System")) self.dispDatumLinesAction.setText(self.__tr("Display Datum Lines")) self.dispDatumLinesAction.setMenuText(self.__tr("Display Datum Lines")) self.dispGridAction.setText(self.__tr("Display Grid")) self.dispGridAction.setMenuText(self.__tr("Display Grid")) self.selectConnectedAction.setText(self.__tr("Connected")) self.selectConnectedAction.setMenuText(self.__tr("&Connected")) self.selectConnectedAction.setToolTip(self.__tr("Select Connected")) self.selectConnectedAction.setAccel(self.__tr("Ctrl+Shift+C")) self.selectDoublyAction.setText(self.__tr("Doubly")) self.selectDoublyAction.setMenuText(self.__tr("&Doubly")) self.selectDoublyAction.setToolTip(self.__tr("Select Doubly")) self.selectDoublyAction.setAccel(self.__tr("Ctrl+Shift+D")) self.editPreferencesAction.setText(self.__tr("Preferences...")) self.editPreferencesAction.setMenuText(self.__tr("P&references...")) self.jigsBearingAction.setText(self.__tr("Bearing")) self.jigsBearingAction.setMenuText(self.__tr("&Bearing")) self.jigsSpringAction.setText(self.__tr("Spring")) self.jigsSpringAction.setMenuText(self.__tr("&Spring")) self.jigsDynoAction.setText(self.__tr("Dyno")) self.jigsDynoAction.setMenuText(self.__tr("&Dyno")) self.jigsHeatsinkAction.setText(self.__tr("Heatsin&k")) self.jigsHeatsinkAction.setMenuText(self.__tr("Heatsin&k")) self.setViewOrthoAction.setText(self.__tr("Ortho")) self.setViewOrthoAction.setMenuText(self.__tr("Or&tho")) self.setViewPerspecAction.setText(self.__tr("Perspective")) self.setViewPerspecAction.setMenuText(self.__tr("&Perspective")) self.jigsGroundAction.setText(self.__tr("Ground")) self.jigsGroundAction.setMenuText(self.__tr("&Ground")) self.jigsHandleAction.setText(self.__tr("Handle")) self.jigsHandleAction.setMenuText(self.__tr("&Handle")) self.modifySeparateAction.setText(self.__tr("Separate")) self.modifySeparateAction.setMenuText(self.__tr("&Separate")) self.toolsSketchAtomAction.setText(self.__tr("Sketch Atom")) self.toolsSketchAtomAction.setMenuText(self.__tr("Sketch &Atom")) self.ccGraphiteAction.setText(self.__tr("Graphite")) self.ccGraphiteAction.setMenuText(self.__tr("Graphite")) self.orient100Action.setText(self.__tr("Surface 100")) self.orient100Action.setMenuText(self.__tr("Surface 100")) self.orient110Action.setText(self.__tr("Surface 110")) self.orient110Action.setMenuText(self.__tr("Surface 110")) self.orient111Action.setText(self.__tr("Surface 111")) self.orient111Action.setMenuText(self.__tr("Surface 111")) self.setViewFrontAction.setText(self.__tr("Front View")) self.setViewFrontAction.setMenuText(self.__tr("&Front View")) self.setViewFrontAction.setToolTip(self.__tr("Front View")) self.setViewBackAction.setText(self.__tr("Back View")) self.setViewBackAction.setMenuText(self.__tr("&Back View")) self.setViewTopAction.setText(self.__tr("Top View")) self.setViewTopAction.setMenuText(self.__tr("&Top View")) self.setViewTopAction.setToolTip(self.__tr("Top View")) self.setViewBottomAction.setText(self.__tr("Bottom View")) self.setViewBottomAction.setMenuText(self.__tr("Botto&m View")) self.setViewRightAction.setText(self.__tr("Right View")) self.setViewRightAction.setMenuText(self.__tr("&Right View")) self.setViewRightAction.setToolTip(self.__tr("Right View")) self.setViewLeftAction.setText(self.__tr("Left View")) self.setViewLeftAction.setMenuText(self.__tr("&Left View")) self.setViewLeftAction.setToolTip(self.__tr("Left View")) self.setViewHomeAction.setText(self.__tr("Home")) self.setViewHomeAction.setMenuText(self.__tr("&Home")) self.setViewHomeAction.setToolTip(self.__tr("Home")) self.setViewHomeAction.setAccel(self.__tr("Home")) self.setViewRecenterAction.setText(self.__tr("Recenter")) self.setViewRecenterAction.setMenuText(self.__tr("&Recenter")) self.setViewRecenterAction.setToolTip(self.__tr("Recenter (Ctrl+R)")) self.setViewRecenterAction.setAccel(self.__tr("Ctrl+R")) self.jigsLinearMotorAction.setText(self.__tr("&Linear Motor")) self.jigsLinearMotorAction.setMenuText(self.__tr("&Linear Motor")) self.toggleModifyTbarAction.setText(self.__tr("Modify")) self.toggleModifyTbarAction.setMenuText(self.__tr("Modify")) self.toolsStartOverAction.setText(self.__tr("Start Over")) self.toolsStartOverAction.setMenuText(self.__tr("Start Over")) self.toolsBackUpAction.setText(self.__tr("Back Up")) self.toolsBackUpAction.setMenuText(self.__tr("Back Up")) self.modifyDeleteBondAction.setText(self.__tr("Delete Bond")) self.modifyDeleteBondAction.setMenuText(self.__tr("&Delete Bond")) self.fileClearAction.setText(self.__tr("Clear")) self.fileClearAction.setMenuText(self.__tr("C&lear")) self.modifyCopyBondAction.setText(self.__tr("Copy Bond")) self.modifyCopyBondAction.setMenuText(self.__tr("&Copy Bond")) self.modifyEdgeBondAction.setText(self.__tr("Edge Bond")) self.modifyEdgeBondAction.setMenuText(self.__tr("Ed&ge Bond")) self.modifyAddBondAction.setText(self.__tr("Add Bond")) self.modifyAddBondAction.setMenuText(self.__tr("&Add Bond")) self.modifyWeldMoleculeAction.setText(self.__tr("Weld Molecule")) self.modifyWeldMoleculeAction.setMenuText(self.__tr("&Weld Molecule")) self.toggleDatumDispTbarAction.setText(self.__tr("Datum Display")) self.toggleDatumDispTbarAction.setMenuText(self.__tr("Datum Display")) self.modifySetElementAction.setText(self.__tr("Change Element")) self.modifySetElementAction.setMenuText(self.__tr("Change &Element...")) self.modifySetElementAction.setAccel(self.__tr("Ctrl+E")) self.fileInsertAction.setText(self.__tr("Inser&t...")) self.fileInsertAction.setMenuText(self.__tr("Inser&t...")) self.modifyDehydrogenateAction.setText(self.__tr("Dehydrogenate")) self.modifyDehydrogenateAction.setMenuText(self.__tr("Dehydrogenate")) self.toggleGridsTbarAction.setText(self.__tr("Grids")) self.toggleGridsTbarAction.setMenuText(self.__tr("Grids")) self.selectModeActionGroup.setText(self.__tr("Select Mode")) self.selectAtomsAction.setText(self.__tr("Select Atoms Mode")) self.selectAtomsAction.setToolTip(self.__tr("Select Atoms")) self.selectAtomsAction.setMenuText(self.__tr("Select Atoms Mode")) self.selectPartsAction.setText(self.__tr("Select Part Mode")) self.selectPartsAction.setToolTip(self.__tr("Select Part")) self.selectPartsAction.setMenuText(self.__tr("Select Part Mode")) self.selectModeActionGroup.setMenuText(self.__tr("Select Mode")) self.dispCPKAction.setText(self.__tr("CPK")) self.dispCPKAction.setMenuText(self.__tr("CPK")) self.dispDefaultAction.setText(self.__tr("Default")) self.dispDefaultAction.setMenuText(self.__tr("Default")) self.dispInvisAction.setText(self.__tr("Invisible")) self.dispInvisAction.setMenuText(self.__tr("Invisible")) self.dispLinesAction.setText(self.__tr("Lines")) self.dispLinesAction.setMenuText(self.__tr("Lines")) self.dispTubesAction.setText(self.__tr("Tubes")) self.dispTubesAction.setMenuText(self.__tr("Tubes")) self.dispVdWAction.setText(self.__tr("VdW")) self.dispVdWAction.setMenuText(self.__tr("VdW")) self.fileToolbar.setLabel(self.__tr("File")) self.editToolbar.setLabel(self.__tr("Edit")) self.viewToolbar.setLabel(self.__tr("View")) self.gridsToolbar.setLabel(self.__tr("Grids")) self.molecularDispToolbar.setLabel(self.__tr("Molecular Display")) self.selectToolbar.setLabel(self.__tr("Select")) self.cookieCutterToolbar.setLabel(self.__tr("Cookie Cutter")) self.textLabel2.setText(self.__tr("Cookie Cut")) self.sketchAtomToolbar.setLabel(self.__tr("Sketch Atom")) self.sketchAtomLabel.setText(self.__tr("Sketch Atom")) self.elemChangeComboBox.clear() self.elemChangeComboBox.insertItem(self.__tr("Hydrogen")) self.elemChangeComboBox.insertItem(self.__tr("Helium")) self.elemChangeComboBox.insertItem(self.__tr("Boron")) self.elemChangeComboBox.insertItem(self.__tr("Carbon")) self.elemChangeComboBox.insertItem(self.__tr("Nitrogen")) self.elemChangeComboBox.insertItem(self.__tr("Oxygen")) self.elemChangeComboBox.insertItem(self.__tr("Fluorine")) self.elemChangeComboBox.insertItem(self.__tr("Neon")) self.elemChangeComboBox.insertItem(self.__tr("Aluminum")) self.elemChangeComboBox.insertItem(self.__tr("Silicon")) self.elemChangeComboBox.insertItem(self.__tr("Phosphorus")) self.elemChangeComboBox.insertItem(self.__tr("Sulfur")) self.elemChangeComboBox.insertItem(self.__tr("Chlorine")) self.elemChangeComboBox.insertItem(self.__tr("Argon")) self.elemChangeComboBox.insertItem(self.__tr("Germanium")) self.elemChangeComboBox.insertItem(self.__tr("Astatine")) self.elemChangeComboBox.insertItem(self.__tr("Selenium")) self.elemChangeComboBox.insertItem(self.__tr("Bromine")) self.elemChangeComboBox.insertItem(self.__tr("Krypton")) self.elemChangeComboBox.insertItem(self.__tr("Antimony")) self.elemChangeComboBox.insertItem(self.__tr("Tellurium")) self.elemChangeComboBox.insertItem(self.__tr("Iodine")) self.elemChangeComboBox.insertItem(self.__tr("Xenon")) self.modifyToolbar.setLabel(self.__tr("Modify")) self.toolsToolbar.setLabel(self.__tr("Tools")) self.datumDispToolbar.setLabel(self.__tr("Datum Display")) if self.MenuBar.findItem(2): self.MenuBar.findItem(2).setText(self.__tr("&File")) if self.MenuBar.findItem(3): self.MenuBar.findItem(3).setText(self.__tr("&Edit")) self.unnamed.changeItem(self.unnamed.idAt(7),self.__tr("&Default Views")) self.unnamed.changeItem(self.unnamed.idAt(9),self.__tr("&Toolbars")) if self.MenuBar.findItem(4): self.MenuBar.findItem(4).setText(self.__tr("&View")) if self.MenuBar.findItem(5): self.MenuBar.findItem(5).setText(self.__tr("&Select")) if self.MenuBar.findItem(6): self.MenuBar.findItem(6).setText(self.__tr("&Display")) if self.MenuBar.findItem(7): self.MenuBar.findItem(7).setText(self.__tr("&Jigs")) if self.MenuBar.findItem(8): self.MenuBar.findItem(8).setText(self.__tr("&Modify")) if self.MenuBar.findItem(9): self.MenuBar.findItem(9).setText(self.__tr("&Tools")) if self.MenuBar.findItem(10): self.MenuBar.findItem(10).setText(self.__tr("&Help")) | 85a9a33737cb03ea81f35e97e98d59f2314cc01d /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/11221/85a9a33737cb03ea81f35e97e98d59f2314cc01d/MainWindowUI.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2653,
3043,
12,
2890,
4672,
365,
18,
542,
21158,
12,
2890,
16186,
313,
2932,
3641,
6,
3719,
365,
18,
768,
1908,
1803,
18,
542,
1528,
12,
2890,
16186,
313,
2932,
1908,
6,
3719,
365,
18,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2653,
3043,
12,
2890,
4672,
365,
18,
542,
21158,
12,
2890,
16186,
313,
2932,
3641,
6,
3719,
365,
18,
768,
1908,
1803,
18,
542,
1528,
12,
2890,
16186,
313,
2932,
1908,
6,
3719,
365,
18,... |
preabstract = row[2] | preabstract = print_record(row[0], "hb") | def display_basket_content(uid, id_basket, basket_name): out = "" out_tmp="" # search for basket's items if (id_basket != '0') and (id_basket != 0): query_result = run_sql("SELECT br.id_record,br.nb_order, fmt.value "\ "FROM basket_record br, bibfmt fmt "\ "WHERE br.id_basket=%s AND br.id_record=fmt.id_bibrec AND fmt.format='hb'"\ "ORDER BY br.nb_order DESC ", (id_basket,)) if len(query_result) > 0: out += out_tmp # display the list of items out += """<FORM name="basketform" action="display" method="post">""" out += """<TABLE cellspacing="0" cellpadding="0">\n<TR><TD>""" out += """<TABLE border="0" cellpadding="0" cellspacing ="3" width="650">""" # display operations on the selected items: delete, copy or move out += """<TR><TD colspan="2">Selected items: """\ """<CODE class="blocknote"><INPUT class="formbutton" type="submit" name="action" value="REMOVE"></CODE>\n""" out += """ or <SELECT name="copy_move"><OPTION value="1">Copy</OPTION>"""\ """<OPTION value="2">Move</OPTION></SELECT>to""" # query the database for the list of baskets query_result1 = run_sql("SELECT b.id, b.name "\ "FROM basket b, user_basket ub "\ "WHERE ub.id_user=%s AND b.id=ub.id_basket AND b.id<>%s "\ "ORDER BY b.name ASC ", (uid,id_basket)) # display the list of baskets if len(query_result1) > 0: out +="""<SELECT name="to_basket"><OPTION value="0">- select basket -</OPTION>""" for row1 in query_result1 : out += """<OPTION value="%s">%s</OPTION>""" % (row1[0], row1[1]) out += """</SELECT>\n""" out +="""<CODE class="blocknote"><INPUT class="formbutton" type="submit" name="action" value="EXECUTE"></CODE><BR><BR></TD></TR>\n""" # display the list of items i = 1 preid = 0 preord = 0 for row in query_result : if i==1: out += """<TR valign="top"><TD width="60">%s<input type="checkbox" name="mark" value="%s">"""\ """<IMG src="%s/arrow_up.gif" border="0">""" % (i,row[0],imagesurl) else: # complete display previous item out += """<A href="display?id_basket=%s&action=ORDER&idup=%s&ordup=%s&iddown=%s&orddown=%s">"""\ """<IMG src="%s/arrow_down.gif" border="0"></A>"""\ """</TD>"""\ """<TD>%s</TD></TR>"""\ """<TR colspan="2"><TD></TD></TR>""" % (id_basket,row[0],row[1],preid,preord,imagesurl,zlib.decompress(preabstract)) # display current item out += """<TR valign="top"><TD width="60">%s<input type="checkbox" name="mark" value="%s">"""\ """<A href="display?id_basket=%s&action=ORDER&idup=%s&ordup=%s&iddown=%s&orddown=%s">"""\ """<IMG src="%s/arrow_up.gif" border="0"></A>""" % (i,row[0],id_basket,row[0],row[1],preid,preord,imagesurl) preid = row[0] preord = row[1] preabstract = row[2] i += 1 # complete display last item out += """<IMG src="%s/arrow_down.gif" border="0"></A>"""\ """</TD>"""\ """<TD>%s</TD></TR>"""\ """<TR colspan="2"><TD></TD></TR>""" % (imagesurl,zlib.decompress(preabstract)) # hidden parameters out += """<INPUT type="hidden" name="id_basket" value="%s"></TD></TR>""" % id_basket out += """</TABLE></TD></TR></TABLE></FORM>""" else: out += """<p>The basket <B>%s</B> is empty.""" % basket_name out += out_tmp return out | 3a8ea0fba4fda25139d10609e40e739373b11485 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12027/3a8ea0fba4fda25139d10609e40e739373b11485/webbasket.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2562,
67,
26219,
67,
1745,
12,
1911,
16,
612,
67,
26219,
16,
12886,
67,
529,
4672,
225,
596,
273,
1408,
596,
67,
5645,
1546,
6,
225,
468,
1623,
364,
12886,
1807,
1516,
309,
261,
350,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2562,
67,
26219,
67,
1745,
12,
1911,
16,
612,
67,
26219,
16,
12886,
67,
529,
4672,
225,
596,
273,
1408,
596,
67,
5645,
1546,
6,
225,
468,
1623,
364,
12886,
1807,
1516,
309,
261,
350,
... |
info['path'] = getPythonPath(factory.factory) | info['path'] = getPythonPath(factory) | def getViewFactoryData(factory): """Squeeze some useful information out of the view factory""" info = {'path': None, 'url': None, 'template': None, 'resource': None, 'referencable': True} if hasattr(factory, '__name__') and \ factory.__name__.startswith('SimpleViewClass'): # In the case of a SimpleView, the base is really what we are # interested in. Usually the first listed class is the interesting one. base = factory.__bases__[0] info['path'] = base.__module__ + '.' + base.__name__ info['template'] = relativizePath(factory.index.filename) elif isinstance(factory, (str, unicode, float, int, list, tuple)): info['referencable'] = False elif factory.__module__.startswith('zope.app.publisher.browser.viewmeta'): info['path'] = getPythonPath(factory.__bases__[0]) elif hasattr(factory, '__class__') and \ factory.__class__.__name__ == 'ProxyView': factory = factory.factory info['path'] = factory.__module__ + '.' + factory.__name__ elif not hasattr(factory, '__name__'): info['path'] = getPythonPath(factory.__class__) elif type(factory) in (type, ClassType): info['path'] = getPythonPath(factory) elif isinstance(factory, FunctionType): info['path'] = getPythonPath(factory.factory) else: info['path'] = getPythonPath(factory) if info['referencable']: info['url'] = info['path'].replace('.', '/') if isinstance(factory, IconViewFactory): info['resource'] = factory.rname return info | 3709a4f778be8ae7d94e074186e57862d67bc868 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/9672/3709a4f778be8ae7d94e074186e57862d67bc868/presentation.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
8893,
1733,
751,
12,
6848,
4672,
3536,
55,
14652,
2690,
5301,
1779,
596,
434,
326,
1476,
3272,
8395,
1123,
273,
13666,
803,
4278,
599,
16,
296,
718,
4278,
599,
16,
296,
3202,
4278,
599,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
8893,
1733,
751,
12,
6848,
4672,
3536,
55,
14652,
2690,
5301,
1779,
596,
434,
326,
1476,
3272,
8395,
1123,
273,
13666,
803,
4278,
599,
16,
296,
718,
4278,
599,
16,
296,
3202,
4278,
599,
... |
mac = md5.new(secret + `issued` + `expires`).digest() | mac = sha.new(secret + `issued` + `expires`).hexdigest() | def CheckCookie(self, key): cookiedata = os.environ.get('HTTP_COOKIE') if not cookiedata: return 0 # # TBD: At least some versions of MS Internet Explorer stores cookies # without the double quotes. This has been verified for MSIE 4.01, # although MSIE 5 is fixed. The bug (see PR#80) is that if these # double quotes are missing, the cookie data does not unpickle into # the list that we expect. The kludge given here (slightly modified) # was initially provided by Evaldas Auryla <evaldas.auryla@pheur.org> # keylen = len(key) try: if cookiedata[keylen+1] <> '"' and cookiedata[-1] <> '"': cookiedata = key + '="' + cookiedata[keylen+1:] + '"' except IndexError: # cookiedata got truncated somehow; just let it fail normally pass c = Cookie.Cookie(cookiedata) if not c.has_key(key): return 0 cookie = c[key].value if type(cookie) <> ListType or len(cookie) <> 3: raise Errors.MMInvalidCookieError now = time.time() [issued, expires, received_mac] = cookie if now < issued: raise Errors.MMInvalidCookieError if now > expires: raise Errors.MMExpiredCookieError secret = self.password mac = md5.new(secret + `issued` + `expires`).digest() if mac <> received_mac: raise Errors.MMInvalidCookieError return 1 | 2daf1c8f2e33b4b2eb08ebd8afc7bb627fb6a7a6 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/2120/2daf1c8f2e33b4b2eb08ebd8afc7bb627fb6a7a6/SecurityManager.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2073,
6151,
12,
2890,
16,
498,
4672,
15860,
2092,
396,
273,
1140,
18,
28684,
18,
588,
2668,
3693,
67,
13584,
6134,
309,
486,
15860,
2092,
396,
30,
327,
374,
468,
468,
399,
18096,
30,
2... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2073,
6151,
12,
2890,
16,
498,
4672,
15860,
2092,
396,
273,
1140,
18,
28684,
18,
588,
2668,
3693,
67,
13584,
6134,
309,
486,
15860,
2092,
396,
30,
327,
374,
468,
468,
399,
18096,
30,
2... |
if status == 'scheduled' and self.recorder: | if status == 'scheduled' and self.recorder[1]: | def __str__(self): """ A simple string representation for a recording for debugging in the recordserver. """ channel = self.channel if len(channel) > 10: channel = channel[:10] diff = (self.stop - self.start) / 60 name = self.name if len(name) > 23: name = name[:20] + u'...' name = u'"' + name + u'"' status = self.status if status == 'scheduled' and self.recorder: status = self.recorder[0].name return '%3d %10s %-25s %4d %s-%s %s' % \ (self.id, String(channel), String(name), self.priority, _int2time(self.start)[4:], _int2time(self.stop)[9:], String(status)) | 03ac724bb7db2615c86c45282da9e5e42d761db8 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/11399/03ac724bb7db2615c86c45282da9e5e42d761db8/recording.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
701,
972,
12,
2890,
4672,
3536,
432,
4143,
533,
4335,
364,
279,
14949,
364,
10450,
316,
326,
1409,
3567,
18,
3536,
1904,
273,
365,
18,
4327,
309,
562,
12,
4327,
13,
405,
1728,
30... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
701,
972,
12,
2890,
4672,
3536,
432,
4143,
533,
4335,
364,
279,
14949,
364,
10450,
316,
326,
1409,
3567,
18,
3536,
1904,
273,
365,
18,
4327,
309,
562,
12,
4327,
13,
405,
1728,
30... |
bin1.size.offsets.update(offset_vector) bin2.size.offsets.update(offset_vector) thisseglistdict.offsets.update(offset_vector) if not coinc1 and bin1.size.is_coincident(thisseglistdict, keys = offset_vector.keys()): | if cache_entry.segment.protract(cafepacker.max_gap).disjoint(bin.extent): continue cache_entry_segs = cache_entry.to_segmentlistdict() for offset_vector in cafepacker.offset_vectors: cache_entry_segs.offsets.update(offset_vector) | def split_bins(cafepacker, extentlimit): """ Split bins of stored in CafePacker until each bin has an extent no longer than extentlimit. """ # # loop overall the bins in cafepacker.bins. we pop items out of # cafepacker.bins and append new ones to the end so need a while loop # checking the extent of each bin in cafepacker.bins until all bins are # done being split # idx = 0 while idx < len(cafepacker.bins): if abs(cafepacker.bins[idx].extent) <= extentlimit: # # bin doesn't need splitting so move to next # idx += 1 continue # # split this bin so pop it out of the list # bigbin = cafepacker.bins.pop(idx) # # calculate the central time of the union of all the input # files in the bin # splittime = lsctables.LIGOTimeGPS(bigbin.extent[0] + (bigbin.extent[1] - bigbin.extent[0])/2) # # split the segmentlistdict at this time # splitseglistdict = segments.segmentlistdict() for key in bigbin.size.keys(): splitseglistdict[key] = segments.segmentlist([segments.segment(-segments.infinity(),splittime)]) # # create bins for the first and second halves # bin1 = LALCacheBin() bin1.size = bigbin.size & splitseglistdict bin1.extent = bigbin.extent & splitseglistdict.values()[0][0] bin2 = LALCacheBin() bin2.size = bigbin.size & ~splitseglistdict bin2.extent = bigbin.extent & (~splitseglistdict.values()[0])[0] # # remove unused keys from the smaller bins' segmentlistdicts # newsize = segments.segmentlistdict() for key in bin1.size.keys(): if len(bin1.size[key]): newsize[key] = bin1.size[key] bin1.size = newsize newsize = segments.segmentlistdict() for key in bin2.size.keys(): if len(bin2.size[key]): newsize[key] = bin2.size[key] bin2.size = newsize # # find which of the objects in bigbin.objects intersect the two # smaller bins # for cache in bigbin.objects: thisseglistdict = cache.to_segmentlistdict() coinc1 = 0 coinc2 = 0 for offset_vector in cafepacker.offset_vectors: # # loop over offset vectors updating the smaller # bins and the object we are checking # bin1.size.offsets.update(offset_vector) bin2.size.offsets.update(offset_vector) thisseglistdict.offsets.update(offset_vector) if not coinc1 and bin1.size.is_coincident(thisseglistdict, keys = offset_vector.keys()): # # object is coicident with bin1 # coinc1 = 1 bin1.objects.append(cache) if not coinc2 and bin2.size.is_coincident(thisseglistdict, keys = offset_vector.keys()): # # object is coincident with bin2 # coinc2 = 1 bin2.objects.append(cache) # # end loop if known to be coincident with both # bins # if coinc1 and coinc2: break # # clear offsets applied to object # thisseglistdict.offsets.clear() # # clear offsets applied to bins # bin1.size.offsets.clear() bin2.size.offsets.clear() # # append smaller bins to list of bins # cafepacker.bins.append(bin1) cafepacker.bins.append(bin2) # # do not increment idx as we popped the large bin out of # cafepacker.bins # # # sort the bins in cafepacker # cafepacker.bins.sort() return cafepacker | b726e6b93ab3eca6e0cab29241e6a54f9ac3e9ed /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/3592/b726e6b93ab3eca6e0cab29241e6a54f9ac3e9ed/ligolw_cafe.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1416,
67,
11862,
12,
71,
1727,
881,
484,
264,
16,
11933,
3595,
4672,
3536,
5385,
8963,
434,
4041,
316,
385,
2513,
4420,
264,
3180,
1517,
4158,
711,
392,
11933,
1158,
7144,
2353,
11933,
3... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1416,
67,
11862,
12,
71,
1727,
881,
484,
264,
16,
11933,
3595,
4672,
3536,
5385,
8963,
434,
4041,
316,
385,
2513,
4420,
264,
3180,
1517,
4158,
711,
392,
11933,
1158,
7144,
2353,
11933,
3... |
cfg = "./configure --prefix=%s" % self.prefix | cfg = "./configure --disable-strip --prefix=%s" % self.prefix | def __build(self): os.chdir(self.srcdir) cfg = "./configure --prefix=%s" % self.prefix if self.repo_type == 1: steps = [cfg, "make clean", "make -j %s" % utils.count_cpus()] if not os.path.exists('qemu/pc-bios/bios.bin'): steps.append("make -C bios") steps.append("make -C extboot") steps.append("cp -f bios/BIOS-bochs-latest" " qemu/pc-bios/bios.bin") steps.append("cp -f vgabios/VGABIOS-lgpl-latest.bin" " qemu/pc-bios/vgabios.bin") steps.append("cp -f vgabios/VGABIOS-lgpl-latest.cirrus.bin" " qemu/pc-bios/vgabios-cirrus.bin") steps.append("cp -f extboot/extboot.bin" " qemu/pc-bios/extboot.bin") elif self.repo_type == 2: steps = [cfg, "make clean", "make -j %s" % utils.count_cpus()] | 85436fd96dfb1c4e10a5d137db3ef18ec6977fe9 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/12268/85436fd96dfb1c4e10a5d137db3ef18ec6977fe9/kvm_install.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
3510,
12,
2890,
4672,
1140,
18,
343,
1214,
12,
2890,
18,
4816,
1214,
13,
282,
2776,
273,
25165,
14895,
1493,
8394,
17,
6406,
1493,
3239,
5095,
87,
6,
738,
365,
18,
3239,
309,
365... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
3510,
12,
2890,
4672,
1140,
18,
343,
1214,
12,
2890,
18,
4816,
1214,
13,
282,
2776,
273,
25165,
14895,
1493,
8394,
17,
6406,
1493,
3239,
5095,
87,
6,
738,
365,
18,
3239,
309,
365... |
def body(self, id): | def body(self, id, fileHandle=None): | def body(self, id): """Process a BODY command. Argument: - id: article number or message id Returns: - resp: server response if successful - nr: article number - id: message id - list: the lines of the article's body""" | 443dfbd0e8b6719520c49960538dfa3309a1c2f9 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/3187/443dfbd0e8b6719520c49960538dfa3309a1c2f9/nntplib.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1417,
12,
2890,
16,
612,
16,
26662,
33,
7036,
4672,
3536,
2227,
279,
30580,
1296,
18,
225,
5067,
30,
300,
612,
30,
7559,
1300,
578,
883,
612,
2860,
30,
300,
1718,
30,
1438,
766,
309,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1417,
12,
2890,
16,
612,
16,
26662,
33,
7036,
4672,
3536,
2227,
279,
30580,
1296,
18,
225,
5067,
30,
300,
612,
30,
7559,
1300,
578,
883,
612,
2860,
30,
300,
1718,
30,
1438,
766,
309,
... |
if oleitem.bIsDispatch: | if oleitem.bWritten: | def do_gen_child_item(self, oleitem): moduleDoc = self.typelib.GetDocumentation(-1) docDesc = "" if moduleDoc[1]: docDesc = moduleDoc[1] self.progress.Starting(docDesc) self.progress.SetDescription("Building definitions from type library...") self.do_gen_file_header() oleitem.WriteClass(self) if oleitem.bIsDispatch: print >> self.file, 'win32com.client.CLSIDToClass.RegisterCLSID( "%s", %s )' % (oleitem.clsid, oleitem.python_name) | fd594dd3d924d07ca777cfbaa3f8bc198446c77e /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/677/fd594dd3d924d07ca777cfbaa3f8bc198446c77e/genpy.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
741,
67,
4507,
67,
3624,
67,
1726,
12,
2890,
16,
320,
298,
1726,
4672,
1605,
1759,
273,
365,
18,
12846,
30575,
18,
967,
18905,
19236,
21,
13,
997,
4217,
273,
1408,
309,
1605,
1759,
63,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
741,
67,
4507,
67,
3624,
67,
1726,
12,
2890,
16,
320,
298,
1726,
4672,
1605,
1759,
273,
365,
18,
12846,
30575,
18,
967,
18905,
19236,
21,
13,
997,
4217,
273,
1408,
309,
1605,
1759,
63,... |
def __init__(data = None) | def __init__(data = None): | def __init__(data = None) if data == None: quickfix.IntField.__init__(self, 401) else quickfix.IntField.__init__(self, 401, data) | 484890147d4b23aac4b9d0e85e84fceab7e137c3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8819/484890147d4b23aac4b9d0e85e84fceab7e137c3/quickfix_fields.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
892,
273,
599,
4672,
309,
501,
422,
599,
30,
9549,
904,
18,
1702,
974,
16186,
2738,
972,
12,
2890,
16,
14052,
13,
469,
9549,
904,
18,
1702,
974,
16186,
2738,
972,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
892,
273,
599,
4672,
309,
501,
422,
599,
30,
9549,
904,
18,
1702,
974,
16186,
2738,
972,
12,
2890,
16,
14052,
13,
469,
9549,
904,
18,
1702,
974,
16186,
2738,
972,
... |
def exclude_pattern (self, files, pattern, anchor=1, prefix=None): | def exclude_pattern (self, files, pattern, anchor=1, prefix=None, is_regex=0): | def exclude_pattern (self, files, pattern, anchor=1, prefix=None): """Remove strings (presumably filenames) from 'files' that match 'pattern'. 'pattern', 'anchor', 'and 'prefix' are the same as for 'select_pattern()', above. The list 'files' is modified in place. """ pattern_re = translate_pattern (pattern, anchor, prefix) self.debug_print("exclude_pattern: applying regex r'%s'" % pattern_re.pattern) for i in range (len(files)-1, -1, -1): if pattern_re.search (files[i]): self.debug_print(" removing " + files[i]) del files[i] | 05c2c5b74977a8486266e964446ec88b9abf1508 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8125/05c2c5b74977a8486266e964446ec88b9abf1508/sdist.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
4433,
67,
4951,
261,
2890,
16,
1390,
16,
1936,
16,
6984,
33,
21,
16,
1633,
33,
7036,
16,
353,
67,
7584,
33,
20,
4672,
3536,
3288,
2064,
261,
12202,
379,
6906,
9066,
13,
628,
296,
235... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
4433,
67,
4951,
261,
2890,
16,
1390,
16,
1936,
16,
6984,
33,
21,
16,
1633,
33,
7036,
16,
353,
67,
7584,
33,
20,
4672,
3536,
3288,
2064,
261,
12202,
379,
6906,
9066,
13,
628,
296,
235... |
return 1 | return | def contextAction(self, action, p, session, chanid, current=None): '''p = user, who clicked, session = target of clicker...''' global st_user if (action == "stdel"): #Remove a user out of ST list. | 0bd68dcf1e730aa91168427241a9bf9741e01f63 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/14990/0bd68dcf1e730aa91168427241a9bf9741e01f63/sticky.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
819,
1803,
12,
2890,
16,
1301,
16,
293,
16,
1339,
16,
3861,
350,
16,
783,
33,
7036,
4672,
9163,
84,
273,
729,
16,
10354,
17688,
16,
1339,
273,
1018,
434,
4682,
264,
7821,
6309,
2552,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
819,
1803,
12,
2890,
16,
1301,
16,
293,
16,
1339,
16,
3861,
350,
16,
783,
33,
7036,
4672,
9163,
84,
273,
729,
16,
10354,
17688,
16,
1339,
273,
1018,
434,
4682,
264,
7821,
6309,
2552,
... |
Modular Symbols subspace of dimension 2 of Modular Symbols space of dimension 10 for Gamma_0(10) of weight 4 with sign 0 over Rational Field Modular Symbols subspace of dimension 4 of Modular Symbols space of dimension 10 for Gamma_0(10) of weight 4 with sign 0 over Rational Field, | Modular Symbols subspace of dimension 2 of Modular Symbols space of dimension 10 for Gamma_0(10) of weight 4 with sign 0 over Rational Field, Modular Symbols subspace of dimension 4 of Modular Symbols space of dimension 10 for Gamma_0(10) of weight 4 with sign 0 over Rational Field | def degeneracy_map(self, level, t=1): """ The t-th degeneracy map from self to the space of ambient modular symbols of the given level. The level of self must be a divisor or multiple of level, and t must be a divisor of the quotient. INPUT: level -- int, the level of the codomain of the map (positive int). t -- int, the parameter of the degeneracy map, i.e., the map is related to f(q) |--> f(q^t). OUTPUT: A linear function from self to the space of modular symbols of given level with the same weight, character, sign, etc., as this space. | 0e4cff67d82f4da0c25bfb7dc59e4b2e345396ee /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/9890/0e4cff67d82f4da0c25bfb7dc59e4b2e345396ee/submodule.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
443,
3441,
3505,
67,
1458,
12,
2890,
16,
1801,
16,
268,
33,
21,
4672,
3536,
1021,
268,
17,
451,
443,
3441,
3505,
852,
628,
365,
358,
326,
3476,
434,
13232,
1979,
681,
2490,
7963,
434,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
443,
3441,
3505,
67,
1458,
12,
2890,
16,
1801,
16,
268,
33,
21,
4672,
3536,
1021,
268,
17,
451,
443,
3441,
3505,
852,
628,
365,
358,
326,
3476,
434,
13232,
1979,
681,
2490,
7963,
434,
... |
if not self._is_raise_block(link.target): anyHandler = True anyHandler = anyHandler or not self.auto_propagate_exceptions | anyHandler = anyHandler or \ not self._auto_propagate(link, block) | def render_exc_handling_block(self, block): # renders all ops but the last one for op in block.operations[:-1]: self._render_op(op) | 4fedbf6cf6660fa7a729620c426121490ebb9b64 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/6934/4fedbf6cf6660fa7a729620c426121490ebb9b64/function.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1743,
67,
10075,
67,
26822,
67,
2629,
12,
2890,
16,
1203,
4672,
468,
19567,
777,
6727,
1496,
326,
1142,
1245,
364,
1061,
316,
1203,
18,
17542,
10531,
17,
21,
14542,
365,
6315,
5902,
67,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1743,
67,
10075,
67,
26822,
67,
2629,
12,
2890,
16,
1203,
4672,
468,
19567,
777,
6727,
1496,
326,
1142,
1245,
364,
1061,
316,
1203,
18,
17542,
10531,
17,
21,
14542,
365,
6315,
5902,
67,
... |
self.threeDlocEventErrY, self.threeDlocEventZ, self.threeDlocEventErrZ), va = 'top', | self.threeDlocEventErrY, self.threeDlocEventZ * 1000, self.threeDlocEventErrZ * 1000), va = 'top', | def show3dlocEventMap(self): self.load3dlocData() self.calculateStationMagnitudes() self.updateNetworkMag() #print self.dicts[0] self.fig3dloc = plt.figure() self.ax3dloc = self.fig3dloc.add_subplot(111) self.ax3dloc.scatter([self.threeDlocEventLon], [self.threeDlocEventLat], 30, color = 'red', marker = 'o') errLon, errLat = utlLonLat(self.threeDlocEventLon, self.threeDlocEventLat, self.threeDlocEventErrX, self.threeDlocEventErrY) errLon -= self.threeDlocEventLon errLat -= self.threeDlocEventLat self.ax3dloc.text(self.threeDlocEventLon, self.threeDlocEventLat, ' %2.3f +/- %0.2fkm\n %2.3f +/- %0.2fkm\n %im +/- %im' % (self.threeDlocEventLon, self.threeDlocEventErrX, self.threeDlocEventLat, self.threeDlocEventErrY, self.threeDlocEventZ, self.threeDlocEventErrZ), va = 'top', family = 'monospace') self.netMagText = self.ax3dloc.text(self.threeDlocEventLon, self.threeDlocEventLat, self.netMagLabel, va = 'top', color = 'green', family = 'monospace') errorell = Ellipse(xy = [self.threeDlocEventLon, self.threeDlocEventLat], width = errLon, height = errLat, angle = 0, fill = False) self.ax3dloc.add_artist(errorell) self.scatterMagIndices = [] self.scatterMagLon = [] self.scatterMagLat = [] for i in range(len(self.streams)): if self.dicts[i].has_key('3DlocPLon'): self.ax3dloc.scatter([self.dicts[i]['3DlocPLon']], [self.dicts[i]['3DlocPLat']], s = 150, marker = 'v', color = '', edgecolor = 'black') self.ax3dloc.text(self.dicts[i]['StaLon'], self.dicts[i]['StaLat'], ' ' + self.dicts[i]['Station'], va = 'top', family = 'monospace') self.ax3dloc.text(self.dicts[i]['StaLon'], self.dicts[i]['StaLat'], self.dicts[i]['3DlocPResInfo'], va = 'top', family = 'monospace', color = self.dictPhaseColors['P']) if self.dicts[i].has_key('3DlocSLon'): self.ax3dloc.scatter([self.dicts[i]['StaLon']], [self.dicts[i]['StaLat']], s = 150, marker = 'v', color = '', edgecolor = 'black') self.ax3dloc.text(self.dicts[i]['StaLon'], self.dicts[i]['StaLat'], ' ' + self.dicts[i]['Station'], va = 'top', family = 'monospace') self.ax3dloc.text(self.dicts[i]['StaLon'], self.dicts[i]['StaLat'], self.dicts[i]['3DlocSResInfo'], va = 'top', family = 'monospace', color = self.dictPhaseColors['S']) if self.dicts[i].has_key('Mag'): self.scatterMagIndices.append(i) self.scatterMagLon.append(self.dicts[i]['StaLon']) self.scatterMagLat.append(self.dicts[i]['StaLat']) self.ax3dloc.text(self.dicts[i]['StaLon'], self.dicts[i]['StaLat'], ' ' + self.dicts[i]['Station'], va = 'top', family = 'monospace') self.ax3dloc.text(self.dicts[i]['StaLon'], self.dicts[i]['StaLat'], '\n\n\n\n %0.2f' % self.dicts[i]['Mag'], va = 'top', family = 'monospace', color = self.dictPhaseColors['Mag']) if len(self.scatterMagLon) > 0 : self.scatterMag = self.ax3dloc.scatter(self.scatterMagLon, self.scatterMagLat, s = 150, marker = 'v', color = '', edgecolor = 'black', picker = 10) #if len(self.threeDlocSNames) > 0: # #self.ax3dloc.scatter(self.threeDlocSLons, self.threeDlocSLats, s = 440, # # color = self.dictPhaseColors['S'], marker = 'v', # # edgecolor = 'black') # for i in range(len(self.threeDlocSNames)): # self.ax3dloc.scatter(self.threeDlocSLons, self.threeDlocSLats, s = 150, # marker = 'v', color = '', edgecolor = 'black') # #self.ax3dloc.text(self.threeDlocSLons[i], self.threeDlocSLats[i], # # ' ' + self.threeDlocSNames[i], va = 'top') # self.ax3dloc.text(self.threeDlocSLons[i], self.threeDlocSLats[i], # self.threeDlocSNames[i], va = 'top', # family = 'monospace') # self.ax3dloc.text(self.threeDlocSLons[i], self.threeDlocSLats[i], # self.threeDlocSResInfo[i], va = 'top', # family = 'monospace', # color = self.dictPhaseColors['S']) #if len(self.threeDlocPNames) > 0: # #self.ax3dloc.scatter(self.threeDlocPLons, self.threeDlocPLats, s = 180, # # color = self.dictPhaseColors['P'], marker = 'v', # # edgecolor = 'black') # for i in range(len(self.threeDlocPNames)): # self.ax3dloc.scatter(self.threeDlocPLons, self.threeDlocPLats, s = 150, # marker = 'v', color = '', edgecolor = 'black', picker = 10) # #self.ax3dloc.scatter(self.threeDlocPLons, self.threeDlocPLats, s = 150, # # marker = 'v', color = '', edgecolor = 'black', picker = True) # #self.ax3dloc.text(self.threeDlocPLons[i], self.threeDlocPLats[i], # # ' ' + self.threeDlocPNames[i], va = 'top') # self.ax3dloc.text(self.threeDlocPLons[i], self.threeDlocPLats[i], # self.threeDlocPNames[i], va = 'top', # family = 'monospace') # self.ax3dloc.text(self.threeDlocPLons[i], self.threeDlocPLats[i], # self.threeDlocPResInfo[i], va = 'top', # family = 'monospace', # color = self.dictPhaseColors['P']) self.ax3dloc.set_xlabel('Longitude') self.ax3dloc.set_ylabel('Latitude') self.ax3dloc.set_title(self.threeDlocEventTime) lines = open(self.threeDlocOutfile).readlines() infoEvent = lines[0].rstrip() infoPicks = '' for line in lines[1:]: infoPicks += line self.ax3dloc.text(0.02, 0.95, infoEvent, transform = self.ax3dloc.transAxes, fontsize = 12, verticalalignment = 'top', family = 'monospace') self.ax3dloc.text(0.02, 0.90, infoPicks, transform = self.ax3dloc.transAxes, fontsize = 10, verticalalignment = 'top', family = 'monospace') self.fig3dloc.canvas.mpl_connect('pick_event', self.selectMagnitudes) try: self.scatterMag.set_facecolors(self.eventMapColors) except: pass plt.show() | e3cbfd70f9175004acca4efdf96cb210893ee944 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/10346/e3cbfd70f9175004acca4efdf96cb210893ee944/obspyck.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2405,
23,
72,
1829,
1133,
863,
12,
2890,
4672,
365,
18,
945,
23,
72,
1829,
751,
1435,
365,
18,
11162,
16672,
11372,
82,
24751,
1435,
365,
18,
2725,
3906,
11372,
1435,
468,
1188,
365,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2405,
23,
72,
1829,
1133,
863,
12,
2890,
4672,
365,
18,
945,
23,
72,
1829,
751,
1435,
365,
18,
11162,
16672,
11372,
82,
24751,
1435,
365,
18,
2725,
3906,
11372,
1435,
468,
1188,
365,
1... |
def add_encounter(session, context, xml_encounter): ctx = context a = xml_encounter.attrib slot = int(a['slot']) | def insert_encounters(session, ctx, encounters): for e in encounters: encounter = make_encounter(e, ctx) session.add(encounter) session.flush() def make_encounter(obj, ctx): """Make an db.Encounter object from a dict""" def get_terrain_id(terrain): return session.query(EncounterTerrain.id).filter_by(identifier=terrain).one()[0] def get_method_id(method): return session.query(EncounterMethod.id).filter_by(identifier=method).one()[0] def get_or_create_encounter_slot(slot, method_id, version_group_id, terrain_id=None): q = session.query(EncounterSlot).filter_by( slot=slot, version_group_id=version_group_id, encounter_method_id=method_id, encounter_terrain_id=terrain_id, ) try: x = q.one() except NoResultFound: x = EncounterSlot() x.slot=slot x.version_group_id=version_group_id x.encounter_method_id=method_id x.encounter_terrain_id=terrain_id return x | def add_encounter(session, context, xml_encounter): ctx = context a = xml_encounter.attrib slot = int(a['slot']) e = Encounter() e.pokemon_id = int(a['pokemon_id']) #e.form_id = int(a['form_id']) e.slot = int(a['slot']) e.version_id = ctx['version_id'] e.terrain_id = ctx['terrain_id'] e.method_id = ctx['method_id'] #encounter_add_condition(e, ) session.add(e) | 1ec52fd9893cb0d899811c9a5eb3f9dfd97e98a6 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/13524/1ec52fd9893cb0d899811c9a5eb3f9dfd97e98a6/import-xml.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2243,
67,
1331,
2096,
87,
12,
3184,
16,
1103,
16,
27516,
4672,
364,
425,
316,
27516,
30,
8273,
273,
1221,
67,
1331,
2096,
12,
73,
16,
1103,
13,
1339,
18,
1289,
12,
1331,
2096,
13,
13... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2243,
67,
1331,
2096,
87,
12,
3184,
16,
1103,
16,
27516,
4672,
364,
425,
316,
27516,
30,
8273,
273,
1221,
67,
1331,
2096,
12,
73,
16,
1103,
13,
1339,
18,
1289,
12,
1331,
2096,
13,
13... |
sys.stdout.write(text) | sys.stdout.write(text.decode('ascii')) | def interact(self): """Interaction function, emulates a very dumb telnet client.""" if sys.platform == "win32": self.mt_interact() return while 1: rfd, wfd, xfd = select.select([self, sys.stdin], [], []) if self in rfd: try: text = self.read_eager() except EOFError: print('*** Connection closed by remote host ***') break if text: sys.stdout.write(text) sys.stdout.flush() if sys.stdin in rfd: line = sys.stdin.readline() if not line: break self.write(line) | a69ff7792116218bfddc90e5e2776d431495b39b /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/3187/a69ff7792116218bfddc90e5e2776d431495b39b/telnetlib.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
16592,
12,
2890,
4672,
3536,
17419,
445,
16,
801,
17099,
279,
8572,
302,
3592,
20666,
2758,
1004,
12123,
309,
2589,
18,
9898,
422,
315,
8082,
1578,
6877,
365,
18,
1010,
67,
2761,
621,
14... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
16592,
12,
2890,
4672,
3536,
17419,
445,
16,
801,
17099,
279,
8572,
302,
3592,
20666,
2758,
1004,
12123,
309,
2589,
18,
9898,
422,
315,
8082,
1578,
6877,
365,
18,
1010,
67,
2761,
621,
14... |
sys.exit(*args, **kwargs) | print >>sys.stderr, 'panic:', string sys.exit(1) | def panic(*args, **kwargs): sys.exit(*args, **kwargs) | 89ba024b9843719bf06a9c3efaaf1b137dee2a12 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/6787/89ba024b9843719bf06a9c3efaaf1b137dee2a12/m5config.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
3933,
30857,
1968,
16,
2826,
4333,
4672,
1172,
1671,
9499,
18,
11241,
16,
296,
7355,
335,
30,
2187,
533,
2589,
18,
8593,
12,
21,
13,
225,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
3933,
30857,
1968,
16,
2826,
4333,
4672,
1172,
1671,
9499,
18,
11241,
16,
296,
7355,
335,
30,
2187,
533,
2589,
18,
8593,
12,
21,
13,
225,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
pywikibot.output(u"NOTE: Performing a recursive query first to save time....") | pywikibot.output( u"NOTE: Performing a recursive query first to save time....") | def replaceLinks(self, page, newPages, bot): """ Returns True if saving was successful. """ if globalvar.localonly: # In this case only continue on the Page we started with if page != self.originPage: raise SaveError | b3a82878e843a78bea63f3e93be0d84fbebcb110 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/4404/b3a82878e843a78bea63f3e93be0d84fbebcb110/interwiki.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1453,
7100,
12,
2890,
16,
1363,
16,
394,
5716,
16,
2512,
4672,
3536,
2860,
1053,
309,
12392,
1703,
6873,
18,
3536,
309,
2552,
1401,
18,
3729,
3700,
30,
468,
657,
333,
648,
1338,
1324,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1453,
7100,
12,
2890,
16,
1363,
16,
394,
5716,
16,
2512,
4672,
3536,
2860,
1053,
309,
12392,
1703,
6873,
18,
3536,
309,
2552,
1401,
18,
3729,
3700,
30,
468,
657,
333,
648,
1338,
1324,
... |
print "* ",som1[0] print "* ",som1[1] | print "* ", som1[0] print "* ", som1[1] | def rebin_efficiency(obj1,obj2,**kwargs): """ This function takes two SOMs or two SOs and rebins the data for obj1 onto the axis provided by obj2. The units on the x-axes needs to be Angstroms, since this is what the efficiencies will be present as. Parameters: ---------- -> obj1 is a SOM or SO that will be rebinned -> obj2 is a SOM or SO that will provide the axis for rebinning -> kwargs is a list of key word arguments that the function accepts: units= a string containing the expected units for this function. The default for this function is Angstroms Returns: ------- <- A SOM or SO that has been rebinned Exceptions: ---------- <- TypeError is raised if the SOM-SO operation is attempted <- TypeError is raised if the SO-SOM operation is attempted <- TypeError is raised is obj1 not a SOM or SO <- TypeError is raised is obj2 not a SOM or SO <- IndexError is raised if the SOMs do not have the same number of SOs <- RuntimeError is raised if the SOM x-axis units are not Angstroms <- RuntimeError is raised if the x-axis units of the SOMs do not match """ # import the helper functions import hlr_utils # set up for working through data (result,res_descr)=hlr_utils.empty_result(obj1,obj2) (o1_descr,o2_descr)=hlr_utils.get_descr(obj1,obj2) # error checking for types if o1_descr == "SOM" and o2_descr == "SO": raise TypeError, "SOM-SO operation not supported" elif o1_descr == "SO" and o2_descr == "SOM": raise TypeError, "SO-SOM operation not supported" # Have the right object combination, go on else: pass # Setup keyword arguments try: units = kwargs["units"] except KeyError: units = "Angstroms" if o1_descr == "SOM" and o2_descr == "SOM": hlr_utils.hlr_math_compatible(obj1,o1_descr,obj2,o2_descr) # If both objects are not SOMs, do nothing else: pass result=hlr_utils.copy_som_attr(result,res_descr,obj2,o2_descr) if res_descr == "SOM": result = hlr_utils.hlr_force_units(result, "Angstroms") # Can't force units on anything other than a SOM else: pass # iterate through the values import common_lib for i in range(hlr_utils.get_length(obj1,obj2)): val1 = hlr_utils.get_value(obj1,i,o1_descr,"all") val2 = hlr_utils.get_value(obj2,i,o2_descr,"x") value=common_lib.rebin_axis_1D(val1, val2) hlr_utils.result_insert(result,res_descr,value,None,"all") return result | b71ce59d64b8722e53e1e93a78aa55e2f761ac0d /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/763/b71ce59d64b8722e53e1e93a78aa55e2f761ac0d/hlr_rebin_efficiency.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
283,
4757,
67,
73,
22217,
12,
2603,
21,
16,
2603,
22,
16,
636,
4333,
4672,
3536,
1220,
445,
5530,
2795,
348,
1872,
87,
578,
2795,
7460,
87,
471,
283,
11862,
326,
501,
364,
1081,
21,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
283,
4757,
67,
73,
22217,
12,
2603,
21,
16,
2603,
22,
16,
636,
4333,
4672,
3536,
1220,
445,
5530,
2795,
348,
1872,
87,
578,
2795,
7460,
87,
471,
283,
11862,
326,
501,
364,
1081,
21,
... |
eol = find(html, '\n', spos) | eol = html.find( '\n', spos) | def decapitate(html, RESPONSE=None): headers = [] spos = 0 eolen = 1 while 1: m = hdr_start(html, spos) if not m: if html[spos:spos+2] == '\r\n': eolen = 2 break if html[spos:spos+1] == '\n': eolen = 1 break return html header = list(m.groups()) headers.append(header) spos = m.end() + 1 while spos < len(html) and html[spos] in ' \t': eol = find(html, '\r\n', spos) if eol <> -1: eolen = 2 else: eol = find(html, '\n', spos) if eol < 0: return html eolen = 1 header.append(strip(html[spos:eol])) spos = eol + eolen if RESPONSE is not None: for header in headers: hkey = header.pop(0) RESPONSE.setHeader(hkey, ' '.join(header).strip()) return html[spos + eolen:] | 35accf50e26bdab753d9070e5dfd59572c939c1a /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/9658/35accf50e26bdab753d9070e5dfd59572c939c1a/DTMLMethod.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2109,
438,
305,
340,
12,
2620,
16,
20645,
33,
7036,
4672,
1607,
273,
5378,
272,
917,
225,
273,
374,
14775,
275,
273,
404,
1323,
404,
30,
312,
273,
7723,
67,
1937,
12,
2620,
16,
272,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2109,
438,
305,
340,
12,
2620,
16,
20645,
33,
7036,
4672,
1607,
273,
5378,
272,
917,
225,
273,
374,
14775,
275,
273,
404,
1323,
404,
30,
312,
273,
7723,
67,
1937,
12,
2620,
16,
272,
... |
'''Jig <j> was double clicked, so select, unselect or delete it based on the current modkey. | '''Jig <j> was double clicked, so select, unselect or delete its atoms based on the current modkey. | def jigLeftDouble(self): '''Jig <j> was double clicked, so select, unselect or delete it based on the current modkey. - If no modkey is pressed, pick the jig's atoms. - If Shift is pressed, pick the jig's atoms, adding them to the current selection. - If Ctrl is pressed, unpick the jig's atoms, removing them from the current selection. - If Shift+Control (Delete) is pressed, delete the jig's atoms. ''' if self.o.modkeys == 'Control': for a in self.obj_doubleclicked.atoms[:]: a.unpick() elif self.o.modkeys == 'Shift+Control': for a in self.atoms_of_last_deleted_jig[:]: a.kill() else: for a in self.obj_doubleclicked.atoms[:]: a.pick() | f00885ba22f9024d0d0cd8d1b0ee31146a42c403 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/11221/f00885ba22f9024d0d0cd8d1b0ee31146a42c403/selectMode.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
525,
360,
3910,
5265,
12,
2890,
4672,
9163,
46,
360,
411,
78,
34,
1703,
1645,
17688,
16,
1427,
2027,
16,
640,
4025,
578,
1430,
2097,
9006,
2511,
603,
326,
783,
681,
856,
18,
300,
971,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
525,
360,
3910,
5265,
12,
2890,
4672,
9163,
46,
360,
411,
78,
34,
1703,
1645,
17688,
16,
1427,
2027,
16,
640,
4025,
578,
1430,
2097,
9006,
2511,
603,
326,
783,
681,
856,
18,
300,
971,
... |
'/tmp', | def _setupInstance(chan): i, rchan = chan.receive() try: try: scpToEx(i.publicDNS, '/tmp/machine.conf', '/tmp', user=cluster.config('ssh.user'), options=cluster.config('ssh.options')) except: scpToEx(i.publicDNS, '/tmp/machine.conf', '/tmp', user=cluster.config('ssh.user'), options=cluster.config('ssh.options')) | f641ee2346dd5499a5b43527a4cb8a9c4e343ef1 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/5741/f641ee2346dd5499a5b43527a4cb8a9c4e343ef1/control.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
8401,
1442,
12,
7472,
4672,
277,
16,
436,
7472,
273,
3861,
18,
18149,
1435,
775,
30,
775,
30,
30361,
774,
424,
12,
77,
18,
482,
11602,
16,
1173,
5645,
19,
9149,
18,
3923,
2187,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
8401,
1442,
12,
7472,
4672,
277,
16,
436,
7472,
273,
3861,
18,
18149,
1435,
775,
30,
775,
30,
30361,
774,
424,
12,
77,
18,
482,
11602,
16,
1173,
5645,
19,
9149,
18,
3923,
2187,
... | |
for attr in ('origin', 'type'): setattr(metalinkobj3, attr, getattr(metalinkobj4, attr)) | setattr(metalinkobj3, 'origin', getattr(metalinkobj4, 'origin')) if getattr(metalinkobj4, 'dynamic').lower() == "true": setattr(metalinkobj3, 'type', 'dynamic') | def metalink4to3(metalinkobj4): metalinkobj3 = Metalink() for attr in ('origin', 'type'): setattr(metalinkobj3, attr, getattr(metalinkobj4, attr)) for fileobj4 in metalinkobj4.files: fileobj3 = MetalinkFile(fileobj4.filename) # copy common attributes for attr in ('filename', 'pieces', 'piecelength', 'piecetype', 'language', 'os', 'size'): setattr(fileobj3, attr, getattr(fileobj4, attr)) for attr in ('description', 'identity', 'license_url', 'license_name', 'publisher_url', 'publisher_name'): setattr(metalinkobj3, attr, getattr(fileobj4, attr)) # copy hashlist, change key names for key in fileobj4.hashlist.keys(): fileobj3.hashlist[key.replace("-", "")] = fileobj4.hashlist[key] for res4 in fileobj4.resources: if res4.priority != "": fileobj3.add_url(res4.url, "", res4.location, str(100-int(res4.priority))) else: fileobj3.add_url(res4.url, "", res4.location) metalinkobj3.files.append(fileobj3) return metalinkobj3 | 04ca8650414192536b163169ee5d4019276d08b9 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/6425/04ca8650414192536b163169ee5d4019276d08b9/xmlutils.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
5100,
16194,
24,
869,
23,
12,
10578,
16194,
2603,
24,
4672,
5100,
16194,
2603,
23,
273,
21604,
16194,
1435,
225,
9241,
12,
10578,
16194,
2603,
23,
16,
296,
10012,
2187,
3869,
12,
10578,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
5100,
16194,
24,
869,
23,
12,
10578,
16194,
2603,
24,
4672,
5100,
16194,
2603,
23,
273,
21604,
16194,
1435,
225,
9241,
12,
10578,
16194,
2603,
23,
16,
296,
10012,
2187,
3869,
12,
10578,
... |
ofp = open(out, 'wb') | ofp = io.open(out, 'wb') | def hexbin(inp, out): """(infilename, outfilename) - Decode binhexed file""" ifp = HexBin(inp) finfo = ifp.FInfo if not out: out = ifp.FName if os.name == 'mac': ofss = FSSpec(out) out = ofss.as_pathname() ofp = open(out, 'wb') # XXXX Do translation on non-mac systems while 1: d = ifp.read(128000) if not d: break ofp.write(d) ofp.close() ifp.close_data() d = ifp.read_rsrc(128000) if d: ofp = openrsrc(out, 'wb') ofp.write(d) while 1: d = ifp.read_rsrc(128000) if not d: break ofp.write(d) ofp.close() if os.name == 'mac': nfinfo = ofss.GetFInfo() nfinfo.Creator = finfo.Creator nfinfo.Type = finfo.Type nfinfo.Flags = finfo.Flags ofss.SetFInfo(nfinfo) ifp.close() | 34a042d301d6ab88645046a6dfa6c38265ca4b39 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/8546/34a042d301d6ab88645046a6dfa6c38265ca4b39/binhex.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
3827,
4757,
12,
31647,
16,
596,
4672,
3536,
12,
267,
3459,
16,
596,
3459,
13,
300,
6209,
4158,
7118,
329,
585,
8395,
309,
84,
273,
15734,
9913,
12,
31647,
13,
15190,
273,
309,
84,
18,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
3827,
4757,
12,
31647,
16,
596,
4672,
3536,
12,
267,
3459,
16,
596,
3459,
13,
300,
6209,
4158,
7118,
329,
585,
8395,
309,
84,
273,
15734,
9913,
12,
31647,
13,
15190,
273,
309,
84,
18,
... |
return 'http://img.youtube.com/vi/%s/default.jpg' % video_id | return 'http://img.youtube.com/vi/%s/hqdefault.jpg' % video_id | def get_thumbnail_url(url, shortmem=None): video_id = cgi.parse_qs(urlparse.urlsplit(url)[3])['v'][0] return 'http://img.youtube.com/vi/%s/default.jpg' % video_id | dfbd033fdd45a5b846eef47cefb003255810644e /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/12246/dfbd033fdd45a5b846eef47cefb003255810644e/youtube.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
67,
14904,
67,
718,
12,
718,
16,
3025,
3917,
33,
7036,
4672,
6191,
67,
350,
273,
276,
10052,
18,
2670,
67,
12926,
12,
718,
2670,
18,
718,
4939,
12,
718,
25146,
23,
5717,
3292,
9... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
67,
14904,
67,
718,
12,
718,
16,
3025,
3917,
33,
7036,
4672,
6191,
67,
350,
273,
276,
10052,
18,
2670,
67,
12926,
12,
718,
2670,
18,
718,
4939,
12,
718,
25146,
23,
5717,
3292,
9... |
comp_method = zlib.DEFLATED co = zlib.compressobj (zlib.Z_DEFAULT_COMPRESSION, comp_method, -15) zcfgdata = co.compress (cfgdata) + co.flush() | def create_exe (self, arcname, fullname): import struct, zlib | 9a4738fdcc09d216f84309e10e81edd081110eab /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8125/9a4738fdcc09d216f84309e10e81edd081110eab/bdist_wininst.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
752,
67,
14880,
261,
2890,
16,
8028,
529,
16,
13321,
4672,
1930,
1958,
16,
24220,
2,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
752,
67,
14880,
261,
2890,
16,
8028,
529,
16,
13321,
4672,
1930,
1958,
16,
24220,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... | |
if debug_pref("Extrude: don't merge selected chunks", Choice_boolean_False, prefs_key = True): | if debug_pref("Extrude: leave base-chunks separate", Choice_boolean_False, prefs_key = True): | def assy_merge_mols(assy, mollist): "merge multiple mols in assy into one mol in assy, and return it" mollist = list(mollist) # be safe in case it's identical to assy.selmols, # which we might modify as we run assert len(mollist) >= 1 ## mollist.sort() #k ok for mols? should be sorted by name, or by ## # position in model tree groups, I think... ## for now, don't sort, use selection order instead. res = mollist[0] from debug_prefs import debug_pref, Choice_boolean_False if debug_pref("Extrude: don't merge selected chunks", Choice_boolean_False, prefs_key = True): #bruce 070406; when it works, change default?? not sure. hook up to new dashboard checkbox, i guess. ###e res = fake_merged_mol(res) for mol in mollist[1:]: # ok if no mols in this loop if platform.atom_debug: print "fyi (atom_debug): extrude merging a mol" res.merge(mol) #041116 new feature # note: this will unpick mol (modifying assy.selmols) and kill it return res | 87507b5d72c4f9e44bf4b021301509d805c1bf11 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/11221/87507b5d72c4f9e44bf4b021301509d805c1bf11/extrudeMode.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1551,
93,
67,
2702,
67,
81,
3528,
12,
428,
93,
16,
12629,
1098,
4672,
315,
2702,
3229,
312,
3528,
316,
1551,
93,
1368,
1245,
12629,
316,
1551,
93,
16,
471,
327,
518,
6,
12629,
1098,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1551,
93,
67,
2702,
67,
81,
3528,
12,
428,
93,
16,
12629,
1098,
4672,
315,
2702,
3229,
312,
3528,
316,
1551,
93,
1368,
1245,
12629,
316,
1551,
93,
16,
471,
327,
518,
6,
12629,
1098,
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.