rem stringlengths 2 226k | add stringlengths 0 227k | context stringlengths 8 228k | meta stringlengths 156 215 | input_ids list | attention_mask list | labels list |
|---|---|---|---|---|---|---|
27 | 3^3 + O(3^5) | def uniformizer_pow(self, n): """ Returns p^n, as an element of self. | faa33523b3ad002e80eb21c4f0972ba282183142 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/9890/faa33523b3ad002e80eb21c4f0972ba282183142/padic_generic.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
10823,
1824,
67,
23509,
12,
2890,
16,
290,
4672,
3536,
2860,
293,
66,
82,
16,
487,
392,
930,
434,
365,
18,
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,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
10823,
1824,
67,
23509,
12,
2890,
16,
290,
4672,
3536,
2860,
293,
66,
82,
16,
487,
392,
930,
434,
365,
18,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
def __init__(self,server,port=5347,typ=None,debug=['always', 'nodebuilder'],domains=None,sasl=0,bind=0,route=0,xcp=0): | def __init__(self,transport,port=5347,typ=None,debug=['always', 'nodebuilder'],domains=None,sasl=0,bind=0,route=0,xcp=0): | def __init__(self,server,port=5347,typ=None,debug=['always', 'nodebuilder'],domains=None,sasl=0,bind=0,route=0,xcp=0): """ Init function for Components. As components use a different auth mechanism which includes the namespace of the component. Jabberd1.4 and Ejabberd use the default namespace then for all client messages. Jabberd2 uses jabber:client. 'server' argument is a server name that you are connecting to (f.e. "localhost"). 'port' can be specified if 'server' resolves to correct IP. If it is not then you'll need to specify IP and port while calling "connect()".""" CommonClient.__init__(self,server,port=port,debug=debug) self.typ=typ self.sasl=sasl self.bind=bind self.route=route self.xcp=xcp if domains: self.domains=domains else: self.domains=[server] | 6e3d3e98eebc327bfc4c002cd84375154cec8bcb /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/7194/6e3d3e98eebc327bfc4c002cd84375154cec8bcb/client.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
16,
13049,
16,
655,
33,
25,
5026,
27,
16,
12846,
33,
7036,
16,
4148,
33,
3292,
17737,
2187,
296,
2159,
9574,
17337,
14180,
33,
7036,
16,
29361,
80,
33,
20,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
13049,
16,
655,
33,
25,
5026,
27,
16,
12846,
33,
7036,
16,
4148,
33,
3292,
17737,
2187,
296,
2159,
9574,
17337,
14180,
33,
7036,
16,
29361,
80,
33,
20,
... |
finish_t = config.get("category_start", DEFAULT_FINISH) | finish_t = config.get("category_finish", DEFAULT_FINISH) | def genCategories(self): config = self._request.getConfiguration() root = config["datadir"] | 6531c0c1f1e8196bdf0f5f53b69611b6778a081a /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/11836/6531c0c1f1e8196bdf0f5f53b69611b6778a081a/pycategories.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
3157,
10487,
12,
2890,
4672,
642,
273,
365,
6315,
2293,
18,
588,
1750,
1435,
1365,
273,
642,
9614,
3404,
361,
481,
11929,
2,
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,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
3157,
10487,
12,
2890,
4672,
642,
273,
365,
6315,
2293,
18,
588,
1750,
1435,
1365,
273,
642,
9614,
3404,
361,
481,
11929,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
return '<br>\n'.join(res) | return Parser('<br/>\n'.join(res)) | def indent(self, text): """ Replace spaces at the begining of a line by Replace '\n' by <br>\n and URL by HTML links""" res = [] for line in text.splitlines(): sline = line.lstrip() indent = len(line) - len(sline) if indent: line = ' ' * indent + sline line = sub('http://(.\S*)', r'<a href="http://\1">\1</a>', line) res.append(line) return '<br>\n'.join(res) | b53a24c76dcecbfd3cc9de8db0e7ac34f9107bca /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/12681/b53a24c76dcecbfd3cc9de8db0e7ac34f9107bca/tracker.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
3504,
12,
2890,
16,
977,
4672,
3536,
6910,
7292,
622,
326,
2376,
310,
434,
279,
980,
635,
473,
10600,
31,
6910,
2337,
82,
11,
635,
411,
2848,
5333,
82,
471,
1976,
635,
3982,
4716,
8395... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3504,
12,
2890,
16,
977,
4672,
3536,
6910,
7292,
622,
326,
2376,
310,
434,
279,
980,
635,
473,
10600,
31,
6910,
2337,
82,
11,
635,
411,
2848,
5333,
82,
471,
1976,
635,
3982,
4716,
8395... |
\Format lyxhtml html "LyX HTML" "" "" "%%" "document" | \Format xhtml html "LyX HTML" "" "" "%%" "document" | def checkFormatEntries(dtl_tools): ''' Check all formats (\Format entries) ''' checkViewer('a Tgif viewer and editor', ['tgif'], rc_entry = [r'\Format tgif obj Tgif "" "%%" "%%" "vector"']) # checkViewer('a FIG viewer and editor', ['xfig', 'jfig3-itext.jar', 'jfig3.jar'], rc_entry = [r'\Format fig fig FIG "" "%%" "%%" "vector"']) # checkViewer('a Dia viewer and editor', ['dia'], rc_entry = [r'\Format dia dia DIA "" "%%" "%%" "vector"']) # checkViewer('a Grace viewer and editor', ['xmgrace'], rc_entry = [r'\Format agr agr Grace "" "%%" "%%" "vector"']) # checkViewer('a FEN viewer and editor', ['xboard -lpf $$i -mode EditPosition'], rc_entry = [r'\Format fen fen FEN "" "%%" "%%" ""']) # path, iv = checkViewer('a raster image viewer', ['xv', 'kview', 'gimp-remote', 'gimp']) path, ie = checkViewer('a raster image editor', ['gimp-remote', 'gimp']) addToRC(r'''\Format bmp bmp BMP "" "%s" "%s" "" | aa992dbbc2c3202e3f713b185b57735856a22ce2 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/7514/aa992dbbc2c3202e3f713b185b57735856a22ce2/configure.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
866,
1630,
5400,
12,
72,
6172,
67,
6642,
4672,
9163,
2073,
777,
6449,
17938,
1630,
3222,
13,
9163,
866,
18415,
2668,
69,
399,
13905,
14157,
471,
4858,
2187,
10228,
88,
13905,
17337,
4519,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
866,
1630,
5400,
12,
72,
6172,
67,
6642,
4672,
9163,
2073,
777,
6449,
17938,
1630,
3222,
13,
9163,
866,
18415,
2668,
69,
399,
13905,
14157,
471,
4858,
2187,
10228,
88,
13905,
17337,
4519,
... |
Sub(event_type, "user").text = self.username | if self.checkbuttonSysop.get_active(): Sub(event_type, "user").text = "sysop" else: Sub(event_type, "user").text = self.username | def dicts2XML(self): """ Returns information of all dictionaries as xml file """ xml = Element("event") Sub(Sub(xml, "event_id"), "value").text = self.dictEvent['xmlEventID'] event_type = Sub(xml, "event_type") Sub(event_type, "value").text = "manual" Sub(event_type, "user").text = self.username Sub(event_type, "public").text = "%s" % \ self.checkbuttonPublicEvent.get_active() # XXX standard values for unset keys!!!???!!!??? epidists = [] # go through all stream-dictionaries and look for picks for i, dict in enumerate(self.dicts): st = self.streams[i] | 08072571b11b984a33e9ee53ba52401ff881eaff /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/10346/08072571b11b984a33e9ee53ba52401ff881eaff/obspyck.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
15838,
22,
4201,
12,
2890,
4672,
3536,
2860,
1779,
434,
777,
16176,
487,
2025,
585,
3536,
2025,
273,
225,
3010,
2932,
2575,
7923,
2592,
12,
1676,
12,
2902,
16,
315,
2575,
67,
350,
6,
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,
15838,
22,
4201,
12,
2890,
4672,
3536,
2860,
1779,
434,
777,
16176,
487,
2025,
585,
3536,
2025,
273,
225,
3010,
2932,
2575,
7923,
2592,
12,
1676,
12,
2902,
16,
315,
2575,
67,
350,
6,
3... |
def _render_property_diff(self, req, ticket, field, old, new): | def _render_property_diff(self, req, ticket, field, old, new, resource_new=None): | def _render_property_diff(self, req, ticket, field, old, new): rendered = None # per type special rendering of diffs type_ = None for f in ticket.fields: if f['name'] == field: type_ = f['type'] break if type_ == 'checkbox': rendered = new == '1' and "set" or "unset" elif type_ == 'textarea': if 'preview' in req.args: rendered = _('modified') else: href = get_resource_url(self.env, ticket.resource, req.href, action='diff') rendered = tag('modified (', tag.a('diff', href=href), ')') | ca20db658ac4c6ec54da7e47ec7e97559928594b /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/2831/ca20db658ac4c6ec54da7e47ec7e97559928594b/web_ui.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
5902,
67,
4468,
67,
5413,
12,
2890,
16,
1111,
16,
9322,
16,
652,
16,
1592,
16,
394,
16,
1058,
67,
2704,
33,
7036,
4672,
7935,
273,
599,
468,
1534,
618,
4582,
9782,
434,
15250,
6... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
5902,
67,
4468,
67,
5413,
12,
2890,
16,
1111,
16,
9322,
16,
652,
16,
1592,
16,
394,
16,
1058,
67,
2704,
33,
7036,
4672,
7935,
273,
599,
468,
1534,
618,
4582,
9782,
434,
15250,
6... |
'date_open': fields.datetime('Opened', readonly=True), | def _compute_day(self, cr, uid, ids, fields, args, context=None): if context is None: context = {} """ @param cr: the current row, from the database cursor, @param uid: the current user’s ID for security checks, @param ids: List of Openday’s IDs @return: difference between current date and log date @param context: A standard dictionary for contextual values """ cal_obj = self.pool.get('resource.calendar') res_obj = self.pool.get('resource.resource') | 32392534dc1e2a3b947c919fb2706441a17ce1eb /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/7397/32392534dc1e2a3b947c919fb2706441a17ce1eb/project_issue.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
9200,
67,
2881,
12,
2890,
16,
4422,
16,
4555,
16,
3258,
16,
1466,
16,
833,
16,
819,
33,
7036,
4672,
309,
819,
353,
599,
30,
819,
273,
2618,
3536,
632,
891,
4422,
30,
326,
783,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
9200,
67,
2881,
12,
2890,
16,
4422,
16,
4555,
16,
3258,
16,
1466,
16,
833,
16,
819,
33,
7036,
4672,
309,
819,
353,
599,
30,
819,
273,
2618,
3536,
632,
891,
4422,
30,
326,
783,
... | |
def tearDown(self): GettextBaseTest.tearDown(self) | def tearDown(self): GettextBaseTest.tearDown(self) | fd9faa3ac7888182ec34b24c7543303b502dd440 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8125/fd9faa3ac7888182ec34b24c7543303b502dd440/test_gettext.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
268,
2091,
4164,
12,
2890,
4672,
968,
955,
2171,
4709,
18,
736,
297,
4164,
12,
2890,
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,
... | [
1,
1,
1,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
268,
2091,
4164,
12,
2890,
4672,
968,
955,
2171,
4709,
18,
736,
297,
4164,
12,
2890,
13,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... | |
self.setComponents(d) | self.setComponents(d.replace('%', '%%')) | def do(self, macros): for path in self.paths: path = path %macros dirs = util.braceExpand(path) for d in dirs: | 18777303521c30ba020574b0d3f0f043cb9d8a48 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8747/18777303521c30ba020574b0d3f0f043cb9d8a48/build.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
741,
12,
2890,
16,
24302,
4672,
364,
589,
316,
365,
18,
4481,
30,
589,
273,
589,
738,
5821,
6973,
7717,
273,
1709,
18,
70,
9963,
12271,
12,
803,
13,
364,
302,
316,
7717,
30,
2,
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,
1,
1,
1,
1,
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,
364,
589,
316,
365,
18,
4481,
30,
589,
273,
589,
738,
5821,
6973,
7717,
273,
1709,
18,
70,
9963,
12271,
12,
803,
13,
364,
302,
316,
7717,
30,
2,
-100,... |
for i, value in enumerate(s): | for value, i in s: print "inserting priority ", value, " ", i | def setPriorityList(self, s): """Remove all priorities, set them to `s`""" if self.hasTickets(): raise Exception("Will not modify database with existing tickets!") c = self.db().cursor() c.execute("""DELETE FROM enum WHERE type='priority'""") for i, value in enumerate(s): c.execute("""INSERT INTO enum (type, name, value) VALUES (%s, %s, %s)""", "priority", value, i) self.db().commit() | c5dcfdcbc56f3ce4c50bebf6511e29a385448c48 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/9317/c5dcfdcbc56f3ce4c50bebf6511e29a385448c48/bugzilla2trac.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
444,
8183,
682,
12,
2890,
16,
272,
4672,
3536,
3288,
777,
26783,
16,
444,
2182,
358,
1375,
87,
68,
8395,
309,
365,
18,
5332,
6264,
2413,
13332,
1002,
1185,
2932,
13670,
486,
5612,
2063,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
8183,
682,
12,
2890,
16,
272,
4672,
3536,
3288,
777,
26783,
16,
444,
2182,
358,
1375,
87,
68,
8395,
309,
365,
18,
5332,
6264,
2413,
13332,
1002,
1185,
2932,
13670,
486,
5612,
2063,
... |
self.pointerToMhist = lm3dsetup.pointerToMhist | def initialize(self, scanner, setup): | 82ea323f0844bfc481a0e846aaba046ff4a5b94c /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8645/82ea323f0844bfc481a0e846aaba046ff4a5b94c/Lithomop3d_run.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
4046,
12,
2890,
16,
7683,
16,
3875,
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,
... | [
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,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
4046,
12,
2890,
16,
7683,
16,
3875,
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,... | |
for attr, val in item_attrs.items(): setattr(item, attr, val) | def _AddControl(self, parent, # who the control is added to control_type, # type of control to add. events_class, events_init_args, # class/Init() args **item_attrs): # extra control attributes. # Outlook Toolbars suck :) # We have tried a number of options: temp/perm in the standard toolbar, # Always creating our own toolbar, etc. # This seems to be fairly common: # http://groups.google.com/groups?threadm=eKKmbvQvAHA.1808%40tkmsftngp02 # Now the strategy is just to use our own, permanent toolbar, with # permanent items, and ignore uninstall issues. # We search all commandbars for a control with our Tag. If found, we # use it (the user may have customized the bar and moved our buttons # elsewhere). If we can not find the child control, we then try and # locate our toolbar, creating if necessary. Our items get added to # that. assert item_attrs.has_key('Tag'), "Need a 'Tag' attribute!" tag = item_attrs["Tag"] item = self.CommandBars.FindControl( Type = control_type, Tag = tag) if item is None: if parent is None: # No parent specified - that means top-level - locate the # toolbar to use as the parent. if self.toolbar is None: # See if we can find our "SpamBayes" toolbar # Indexing via the name appears unreliable, so just loop # Pity we have no "Tag" on a toolbar - then we could even # handle being renamed by the user. bars = self.CommandBars for i in range(bars.Count): toolbar = bars.Item(i+1) if toolbar.Name == "SpamBayes": self.toolbar = toolbar print "Found SB toolbar - visible state is", toolbar.Visible break else: # for not broken - can't find toolbar. Create a new one. # Create it as a permanent one (which is default) if self.explorers_collection.have_created_toolbar: # Eeek - we have already created a toolbar, but # now we can't find it. It is likely this is the # first time we are being run, and outlook is # being started with multiple Windows open. # Hopefully things will get back to normal once # Outlook is restarted (which testing shows it does) return | 58998f1882be5586092d9f417003f50ab8631efa /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/9857/58998f1882be5586092d9f417003f50ab8631efa/addin.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
986,
3367,
12,
2890,
16,
982,
16,
468,
10354,
326,
3325,
353,
3096,
358,
3325,
67,
723,
16,
468,
618,
434,
3325,
358,
527,
18,
2641,
67,
1106,
16,
2641,
67,
2738,
67,
1968,
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,
389,
986,
3367,
12,
2890,
16,
982,
16,
468,
10354,
326,
3325,
353,
3096,
358,
3325,
67,
723,
16,
468,
618,
434,
3325,
358,
527,
18,
2641,
67,
1106,
16,
2641,
67,
2738,
67,
1968,
16,
... | |
if search_in_google: | if config.copyright_google: | def get_results(query, numresults = 10): url = list() query = re.sub("[()\"<>]", "", query) #wikipedia.output(query) if search_in_google: import google google.LICENSE_KEY = config.google_key print " google query..." search_request_retry = 6 while search_request_retry: #SOAP.faultType: <Fault SOAP-ENV:Server: Exception from service object: # Daily limit of 1000 queries exceeded for key xxx> try: data = google.doGoogleSearch('-Wikipedia "' + query + '"') search_request_retry = 0 for entry in data.results: url.append((entry.URL, 'google')) except Exception, err: print "Got an error ->", err search_request_retry -= 1 if search_in_yahoo: import yahoo.search.web print " yahoo query..." data = yahoo.search.web.WebSearch(config.yahoo_appid, query='"' + query.encode('utf_8') + '" -Wikipedia', results=numresults) search_request_retry = 6 while search_request_retry: try: for entry in data.parse_results(): if check_in_source_yahoo: if check_in_source(entry.Url): continue if not check_urllist(url, entry.Url): url.append((entry.Url, 'yahoo')) search_request_retry = 0 except Exception, err: print "Got an error ->", err search_request_retry -= 1 #if search_in_msn: # from __SOAPpy import WSDL # print " msn query..." # wsdl_url = 'http://soap.search.msn.com/webservices.asmx?wsdl' # server = WSDL.Proxy(wsdl_url) # params = {'AppID': config.msn_appid, 'Query': query, 'CultureInfo': 'en-US', 'SafeSearch': 'Off', 'Requests': { # 'SourceRequest':{'Source': 'Web', 'Offset': 0, 'Count': 10, 'ResultFields': 'All',}}} # server_results = server.Search(Request=params) # if server_results.Responses[0].Results: # results = server_results.Responses[0].Results[0] # for entry in results: # url.append((entry.Url, 'msn')) offset = 0 for i in range(len(url)): if check_list(url[i+offset][0], excl_list, debug=True): url.pop(i+offset) offset+=-1 return url | d445bcd2a4d71b17d4de9993e4f333dc7419cfb5 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/4404/d445bcd2a4d71b17d4de9993e4f333dc7419cfb5/copyright.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
67,
4717,
12,
2271,
16,
818,
4717,
273,
1728,
4672,
880,
273,
666,
1435,
843,
273,
283,
18,
1717,
2932,
63,
1435,
2412,
29667,
65,
3113,
23453,
843,
13,
468,
11999,
13744,
18,
284... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4717,
12,
2271,
16,
818,
4717,
273,
1728,
4672,
880,
273,
666,
1435,
843,
273,
283,
18,
1717,
2932,
63,
1435,
2412,
29667,
65,
3113,
23453,
843,
13,
468,
11999,
13744,
18,
284... |
elif item.description.startswith('Concession'): | elif item.description.find('Student') > -1: | def _registration_badge_data(self, registration, stamp = False): if registration: dinner_tickets = 0 speakers_tickets = 0 pdns_ticket = False ticket = '' for invoice in registration.person.invoices: if invoice.paid() and not invoice.is_void(): for item in invoice.items: if item.description.startswith('Penguin Dinner'): dinner_tickets += item.qty elif item.description.startswith('Speakers Dinner'): speakers_tickets += item.qty elif item.description.startswith('Concession'): ticket = 'Hobbyist' elif item.description.find('Hobbyist') > -1: ticket = 'Hobbyist' elif (item.description.find('Professional') > -1 or item.description.startswith('Korora')): ticket = 'Professional' pdns_ticket = True elif item.description.startswith('Press'): ticket = 'Press' pdns_ticket = True elif item.description.startswith('Organiser'): ticket = 'Organiser' pdns_ticket = True elif item.description.find('Miniconfs Only') > -1: ticket = 'Miniconfs Only' if registration.person.is_speaker(): ticket = 'Speaker' pdns_ticket = True elif registration.person.is_miniconf_org(): ticket = 'Miniconf Organiser' pdns_ticket = True elif registration.person.is_volunteer(): ticket = 'Volunteer' | 8d3c963f969767895e6438b83765cce64ced8d73 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/12856/8d3c963f969767895e6438b83765cce64ced8d73/registration.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
14170,
67,
21245,
67,
892,
12,
2890,
16,
7914,
16,
14429,
273,
1083,
4672,
309,
7914,
30,
302,
7872,
67,
6470,
2413,
273,
374,
272,
10244,
414,
67,
6470,
2413,
273,
374,
4863,
238... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
14170,
67,
21245,
67,
892,
12,
2890,
16,
7914,
16,
14429,
273,
1083,
4672,
309,
7914,
30,
302,
7872,
67,
6470,
2413,
273,
374,
272,
10244,
414,
67,
6470,
2413,
273,
374,
4863,
238... |
self.lines_per_frame = self.n * 3 / 6 if self.n % 6 != 0: self.lines_per_frame += 1 self.xyz = self.nextFrame() | self.lines_per_frame = self.n / 2 if self.n % 2 != 0: self.lines_per_frame += 1 self.xyz = self.__frame() | def getXyz( self ): """ Get coordinate array. @return: coordinates, N.array( N x 3, 'f') @rtype: array @raise ParseError: if can't interprete second line """ if not self.xyz: | 6561fff7ef3f1bdce874a4f2653fa69f6a6cb913 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/482/6561fff7ef3f1bdce874a4f2653fa69f6a6cb913/AmberRstParser.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
6538,
93,
94,
12,
365,
262,
30,
3536,
968,
7799,
526,
18,
225,
632,
2463,
30,
5513,
16,
423,
18,
1126,
12,
423,
619,
890,
16,
296,
74,
6134,
632,
86,
723,
30,
526,
225,
632,
11628,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
6538,
93,
94,
12,
365,
262,
30,
3536,
968,
7799,
526,
18,
225,
632,
2463,
30,
5513,
16,
423,
18,
1126,
12,
423,
619,
890,
16,
296,
74,
6134,
632,
86,
723,
30,
526,
225,
632,
11628,... |
def close(self, cursor, user, ids, context=None): self.write(cursor, user, ids, { 'state': 'close', }, context=context) return | def close(self, cursor, user, ids, context=None): self.write(cursor, user, ids, { 'state': 'close', }, context=context) return | 0babeaa116c12a16544a7d43bccd0a6aa0203f31 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/9290/0babeaa116c12a16544a7d43bccd0a6aa0203f31/journal.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1746,
12,
2890,
16,
3347,
16,
729,
16,
3258,
16,
819,
33,
7036,
4672,
365,
18,
2626,
12,
9216,
16,
729,
16,
3258,
16,
288,
296,
2019,
4278,
296,
4412,
2187,
19879,
819,
33,
2472,
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,
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,
1746,
12,
2890,
16,
3347,
16,
729,
16,
3258,
16,
819,
33,
7036,
4672,
365,
18,
2626,
12,
9216,
16,
729,
16,
3258,
16,
288,
296,
2019,
4278,
296,
4412,
2187,
19879,
819,
33,
2472,
13,... | |
alias = env.Command(env.File(target), stamp, []) | alias = env.Command(env.File(target), stamp, [ env.NopAction() ] ) | def BoostUnitTest(env, target=None, source=None, **kw): target = env.arg2nodes(target)[0] source = env.arg2nodes(source) binnode = target.dir.File('.' + target.name + '.bin') stampnode = target.dir.File('.' + target.name + '.stamp') bin = env.Program(binnode, source, LIBS = env['LIBS'] + [ '$TEST_EXTRA_LIBS' ], _LIBFLAGS = ' -Wl,-Bstatic -l$BOOSTTESTLIB -Wl,-Bdynamic ' + env['_LIBFLAGS'], **kw) stamp = env.Command(stampnode, bin, [ '$SOURCE $BOOSTTESTARGS', 'touch $TARGET' ], **kw) alias = env.Command(env.File(target), stamp, []) compileTests = [ src for src in source if src.suffix in SCons.Tool.cplusplus.CXXSuffixes \ and src.exists() \ and 'COMPILE_CHECK' in file(str(src)).read() ] if compileTests: env.Depends(alias, env.CompileCheck(source = compileTests)) _ALL_TESTS.append(alias) return alias | 9b3623af3e38de3d141a3bc8934ccf8b04f8a4b7 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/2548/9b3623af3e38de3d141a3bc8934ccf8b04f8a4b7/Boost.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
17980,
669,
2802,
4709,
12,
3074,
16,
1018,
33,
7036,
16,
1084,
33,
7036,
16,
225,
2826,
9987,
4672,
1018,
273,
1550,
18,
3175,
22,
4690,
12,
3299,
25146,
20,
65,
1084,
273,
1550,
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,
17980,
669,
2802,
4709,
12,
3074,
16,
1018,
33,
7036,
16,
1084,
33,
7036,
16,
225,
2826,
9987,
4672,
1018,
273,
1550,
18,
3175,
22,
4690,
12,
3299,
25146,
20,
65,
1084,
273,
1550,
18,
... |
J.Mx = [49, 193, 769, 3073, 12289] | J.Mx = [49, 98, 196, 392, 784] | def define_refinement_paths(KSPRTOL, SSARTOL): # Define all the supported refinement paths: tests = {} # A A = PISMVerificationTest() A.name = "A" A.test = "isothermal SIA with a marine margin" A.path = "(refine dx=53.33,40,26.67,20,13.33,km, dx=dy and Mx=My=31,41,61,81,121)" A.Mx = [31, 41, 61, 81, 121] A.My = A.Mx A.opts = "-y 25000.0" tests['A'] = A # B B = PISMVerificationTest() B.name = "B" B.test = "isothermal SIA with a moving margin" B.path = "(refine dx=80,60,40,30,20,km, dx=dy and Mx=My=31,41,61,81,121)" B.Mx = [31, 41, 61, 81, 121] B.My = B.Mx B.opts = "-ys 422.45 -y 25000.0" tests['B'] = B # C C = PISMVerificationTest() C.name = "C" C.test = "isothermal SIA w moving margin" C.path = "(refine dx=50,33.33,25,20,16,km, dx=dy and Mx=My=41,61,81,101,121)" C.Mx = [41, 61, 81, 101, 121] C.My = C.Mx C.opts = "-y 15208.0" tests['C'] = C # D D = PISMVerificationTest() D.name = "D" D.test = "isothermal SIA with variable accumulation" D.path = "(refine dx=50,33.33,25,20,16.67,km, dx=dy and Mx=My=41,61,81,101,121)" D.Mx = [41, 61, 81, 101, 121] D.My = D.Mx D.opts = "-y 25000.0" tests['D'] = D # E E = PISMVerificationTest() E.name = "E" E.test = "isothermal SIA with sliding" E.path = "(refine dx=53.33,40,26.67,20,13.33,km, dx=dy and Mx=My=31,41,61,81,121)" E.Mx = [31, 41, 61, 81, 121] E.My = E.Mx E.opts = "-y 25000.0" tests['E'] = E # F F = PISMVerificationTest() F.name = "F" F.test = "thermocoupled SIA" F.path = "(refine dx=30,20,15,10,7.5,km, dx=dy, dz=66.67,44.44,33.33,22.22,16.67 m\n and Mx=My=Mz=61,91,121,181,241)" F.Mx = [61, 91, 121, 181, 241] F.My = F.Mx F.Mz = F.Mx F.opts = "-y 25000.0" tests['F'] = F # G G = PISMVerificationTest() G.name = "G" G.test = "thermocoupled SIA with variable accumulation" G.path = "(refine dx=30,20,15,10,7.5,km, dx=dy, dz=66.67,44.44,33.33,22.22,16.67 m\n and Mx=My=Mz=61,91,121,181,241)" G.Mx = [61, 91, 121, 181, 241] G.My = G.Mx G.Mz = G.Mx G.opts = "-y 25000.0" tests['G'] = G # H H = PISMVerificationTest() H.name = "H" H.test = "isothermal SIA with a moving margin and isostatic bed deformation" H.path = "(refine dx=80,60,40,30,20,km, dx=dy and Mx=My=31,41,61,81,121)" H.Mx = [31, 41, 61, 81, 121] H.My = H.Mx H.opts = "-bed_def_iso -y 60000.0" tests['H'] = H # I I = PISMVerificationTest() I.name = "I" I.test = "plastic till ice stream" I.path = "(refine dy=5000,1250,312.5,78.13,19.53,m, My=49,193,769,3073,12289)" I.Mx = [5] * 5 I.My = [49, 193, 769, 3073, 12289] I.opts = "-ssa_rtol %1.e -ksp_rtol %1.e" % (SSARTOL, KSPRTOL) tests['I'] = I # J J = PISMVerificationTest() J.name = "J" J.test = "linearized periodic ice shelf" J.path = "(refine dy=5000,1250,312.5,78.13,19.53,m, Mx=49,193,769,3073,12289)" J.Mx = [49, 193, 769, 3073, 12289] J.My = J.Mx J.Mz = [11] * 5 J.opts = "-pc_type asm -sub_pc_type lu -ksp_rtol %1.e" % KSPRTOL tests['J'] = J # K K = PISMVerificationTest() K.name = "K" K.test = "pure conduction problem in ice and bedrock" K.path = "(refine dz=100,50,25,12.5,6.25,m, Mz=41,81,161,321,641)" K.Mx = [4] * 5 K.My = K.Mx K.Mz = array([41, 81, 161, 321, 641]) K.Mbz = (K.Mz - 1) / 4 + 1 K.opts = "-y 130000.0 -Lbz 1000" tests['K'] = K # L L = PISMVerificationTest() L.name = "L" L.test = "isothermal SIA with a non-flat bed" L.path = "(refine dx=60,30,20,15,10,km, dx=dy and Mx=My=31,61,91,121,181)" L.Mx = [31, 61, 91, 121, 181] L.My = L.Mx L.opts = "-y 25000.0" tests['L'] = L # M M = PISMVerificationTest() M.name = "M" M.test = "annular ice shelf with a calving front" M.path = "(refine dx=50,25,16.666,12.5,8.333 km; dx=dy and My=31,61,91,121,181)" M.Mx = [31, 61, 91, 121, 181] M.My = M.Mx M.Mz = [11] * 5 M.opts = "-ssa_rtol %1.e -ksp_rtol %1.e" % (SSARTOL, KSPRTOL) tests['M'] = M # test K (for a figure in the User's Manual) K = PISMVerificationTest() K.name = "K" K.test = "pure conduction problem in ice and bedrock" K.path = "(lots of levels)" K.Mz = array([21, 41, 61, 81, 101, 121, 141, 161, 181, 201, 221, 241, 261, 281, 301, 321]) K.Mbz = (K.Mz - 1) / 4 + 1 K.Mx = [4] * len(K.Mz) K.My = K.Mx tests['K_userman'] = K # test B (for a figure in the User's Manual) B = PISMVerificationTest() B.name = "B" B.test = "isothermal SIA with a moving margin" B.path = "(lots of levels)" B.Mx = [31, 41, 51, 61, 71, 81, 91, 101, 111, 121] B.My = B.Mx B.Mz = [31] * len(B.Mx) B.Mbz = [1] * len(B.Mx) B.opts = "-ys 422.45 -y 25000.0" tests['B_userman'] = B # test G (for a figure in the User's Manual) G = PISMVerificationTest() G.name = "G" G.test = "thermocoupled SIA with variable accumulation" G.path = "(lots of levels)" G.Mx = [61, 71, 81, 91, 101, 111, 121, 151, 181] G.My = G.Mx G.Mz = G.Mx tests['G_userman'] = G # test I (for a figure in the User's Manual) I = PISMVerificationTest() I.name = "I" I.test = "plastic till ice stream" I.path = "(lots of levels)" I.My = [51, 101, 151, 201, 401, 601, 801, 1001, 1501, 2001, 2501, 3073] I.Mx = [5] * len(I.My) tests['I_userman'] = I return tests | 07beffdd1820c2cc8f335a07abb760785e3c070c /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/7383/07beffdd1820c2cc8f335a07abb760785e3c070c/vfnow.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
4426,
67,
266,
926,
820,
67,
4481,
12,
47,
3118,
12185,
1741,
16,
12867,
4928,
1741,
4672,
468,
13184,
777,
326,
3260,
25994,
820,
2953,
30,
7434,
273,
2618,
468,
432,
432,
273,
453,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4426,
67,
266,
926,
820,
67,
4481,
12,
47,
3118,
12185,
1741,
16,
12867,
4928,
1741,
4672,
468,
13184,
777,
326,
3260,
25994,
820,
2953,
30,
7434,
273,
2618,
468,
432,
432,
273,
453,
5... |
self.log.debug("found no value") newbuf = "%s\n%s\n\n" % (buf, cf_full) self.change_config(cf_file, newbuf) self.log.info("Sending SIGHUP to postmaster") self.signal_postmaster(data_dir, signal.SIGHUP) def change_config(self, cf_file, buf): cf_old = cf_file + ".old" cf_new = cf_file + ".new" if self.not_really: cf_new = "/tmp/postgresql.conf.new" open(cf_new, "w").write(buf) self.log.info("Showing diff") os.system("diff -u %s %s" % (cf_file, cf_new)) self.log.info("Done diff") os.remove(cf_new) return if 0: open(cf_new, "w").write(buf) bak = open(cf_file, "r").read() open(cf_old, "w").write(bak) os.rename(cf_new, cf_file) else: open(cf_file, "w").write(buf) | self.log.debug("master_restart_cmd not specified, leaving archive_mode as is") cf_params = { "archive_command": "/bin/true" } self.log.debug("modifying configuration: %s" % cf_params) cf.modify(cf_params) cf.write() | def master_configure_archiving(self, cf_val): cf_file = self.cf.get("master_config") data_dir = self.cf.get("master_data") r_active = re.compile("^[ ]*archive_command[ ]*=[ ]*'(.*)'.*$", re.M) r_disabled = re.compile("^.*archive_command.*$", re.M) | cfca5d724afbf745f6a656e9eb302d44d3397ab9 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/14597/cfca5d724afbf745f6a656e9eb302d44d3397ab9/walmgr.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
4171,
67,
14895,
67,
991,
9288,
12,
2890,
16,
6080,
67,
1125,
4672,
6080,
67,
768,
273,
365,
18,
8522,
18,
588,
2932,
7525,
67,
1425,
7923,
501,
67,
1214,
273,
365,
18,
8522,
18,
588... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4171,
67,
14895,
67,
991,
9288,
12,
2890,
16,
6080,
67,
1125,
4672,
6080,
67,
768,
273,
365,
18,
8522,
18,
588,
2932,
7525,
67,
1425,
7923,
501,
67,
1214,
273,
365,
18,
8522,
18,
588... |
",\n ".join(["('%s', %s)" % (f[0], f[1]) for f in fields]), | "\n ".join(["('%s', %s)," % (f[0], f[1]) for f in fields]), | def handle(self, app=None, name="", model_list=None, initial=False, **options): # If model_list is None, then it's an empty list model_list = model_list or [] # make sure --model and --all aren't both specified if initial and model_list: print "You cannot use --initial and other options together" return # specify the default name 'initial' if a name wasn't specified and we're # doing a migration for an entire app if not name and initial: name = 'initial' # if not name, there's an error if not name: print "You must name this migration" return if not app: print "Please provide an app in which to create the migration." return # See if the app exists app_models_module = models.get_app(app) if not app_models_module: print "App '%s' doesn't seem to exist, isn't in INSTALLED_APPS, or has no models." % app return # Determine what models should be included in this migration. models_to_migrate = [] if initial: models_to_migrate = models.get_models(app_models_module) if not models_to_migrate: print "No models found in app '%s'" % (app) return else: for model_name in model_list: model = models.get_model(app, model_name) if not model: print "Couldn't find model '%s' in app '%s'" % (model_name, app) return models_to_migrate.append(model) # Make the migrations directory if it's not there app_module_path = app_models_module.__name__.split('.')[0:-1] try: app_module = __import__('.'.join(app_module_path), {}, {}, ['']) except ImportError: print "Couldn't find path to App '%s'." % app return migrations_dir = os.path.join( os.path.dirname(app_module.__file__), "migrations", ) if not os.path.isdir(migrations_dir): print "Creating migrations directory at '%s'..." % migrations_dir os.mkdir(migrations_dir) # Touch the init py file open(os.path.join(migrations_dir, "__init__.py"), "w").close() # See what filename is next in line. We assume they use numbers. migrations = migration.get_migration_names(migration.get_app(app)) highest_number = 0 for migration_name in migrations: try: number = int(migration_name.split("_")[0]) highest_number = max(highest_number, number) except ValueError: pass # Make the new filename new_filename = "%04i%s_%s.py" % ( highest_number + 1, "".join([random.choice(string.letters.lower()) for i in range(0)]), # Possible random stuff insertion name, ) # If there's a model, make the migration skeleton, else leave it bare forwards, backwards = '', '' if models_to_migrate: for model in models_to_migrate: table_name = model._meta.db_table mock_models = [] fields = [] for f in model._meta.local_fields: # look up the field definition to see how this was created field_definition = generate_field_definition(model, f) if field_definition: if isinstance(f, models.ForeignKey): mock_models.append(create_mock_model(f.rel.to)) field_definition = related_field_definition(f, field_definition) else: print "Warning: Could not generate field definition for %s.%s, manual editing of migration required." % \ (model._meta.object_name, f.name) field_definition = '<<< REPLACE THIS WITH FIELD DEFINITION FOR %s.%s >>>' % (model._meta.object_name, f.name) fields.append((f.name, field_definition)) if mock_models: forwards += ''' # Mock Models %s ''' % "\n ".join(mock_models) forwards += ''' # Model '%s' db.create_table('%s', ( %s ))''' % ( model._meta.object_name, table_name, ",\n ".join(["('%s', %s)" % (f[0], f[1]) for f in fields]), ) | 2fe30b259c1df54a0c7ee9289afbea9f041d34d7 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/13142/2fe30b259c1df54a0c7ee9289afbea9f041d34d7/startmigration.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1640,
12,
2890,
16,
595,
33,
7036,
16,
508,
1546,
3113,
938,
67,
1098,
33,
7036,
16,
2172,
33,
8381,
16,
2826,
2116,
4672,
225,
468,
971,
938,
67,
1098,
353,
599,
16,
1508,
518,
1807... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1640,
12,
2890,
16,
595,
33,
7036,
16,
508,
1546,
3113,
938,
67,
1098,
33,
7036,
16,
2172,
33,
8381,
16,
2826,
2116,
4672,
225,
468,
971,
938,
67,
1098,
353,
599,
16,
1508,
518,
1807... |
if self._docmap.has_key(v.uid().module())] del self._docmap[None] str = self._start_of('All Classes') public.write(str); private.write(str) self._write_toc_section(public, private, 'All Classes', classes) str = self._start_of('All Exceptions') public.write(str); private.write(str) self._write_toc_section(public, private, 'All Exceptions', excepts) str = self._start_of('All Functions') public.write(str); private.write(str) self._write_toc_section(public, private, 'All Functions', funcs) str = self._start_of('All Variables') public.write(str); private.write(str) self._write_toc_section(public, private, 'All Variables', vars) | if is_documented(v.uid().module())] self._write_toc_section(public, private, 'All Classes', classes) self._write_toc_section(public, private, 'All Exceptions', excepts) self._write_toc_section(public, private, 'All Functions', funcs) self._write_toc_section(public, private, 'All Variables', vars) | def _write_project_toc(self, public, private): """ @return: An HTML page containing the table of contents page for the whole project. This page lists the classes, exceptions, functions, and variables defined by any module or package in the project. @rtype: C{string} """ # Header and name. str = self._header('Everything') str += ('<center><font size="+1"><b>Everything</b>' + '</font></center>\n<hr>\n') public.write(str); private.write(str) | 21a6d8c30a29a133335836c07a6da6e2f0b95f2a /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/11420/21a6d8c30a29a133335836c07a6da6e2f0b95f2a/html.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
2626,
67,
4406,
67,
1391,
12,
2890,
16,
1071,
16,
3238,
4672,
3536,
632,
2463,
30,
1922,
3982,
1363,
4191,
326,
1014,
434,
2939,
1363,
364,
326,
7339,
1984,
18,
225,
1220,
1363,
6... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2626,
67,
4406,
67,
1391,
12,
2890,
16,
1071,
16,
3238,
4672,
3536,
632,
2463,
30,
1922,
3982,
1363,
4191,
326,
1014,
434,
2939,
1363,
364,
326,
7339,
1984,
18,
225,
1220,
1363,
6... |
return document.document_id in self.documents | return document.document_id in self.documents_ids | def isKnown(self, document): return document.document_id in self.documents | b191f5a63bc168b872ef798c89d452b0666f9c15 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/2259/b191f5a63bc168b872ef798c89d452b0666f9c15/p2pquerier.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
353,
11925,
12,
2890,
16,
1668,
4672,
327,
1668,
18,
5457,
67,
350,
316,
365,
18,
24795,
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,
... | [
1,
1,
1,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
353,
11925,
12,
2890,
16,
1668,
4672,
327,
1668,
18,
5457,
67,
350,
316,
365,
18,
24795,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100... |
self.push(LogException("ERROR: %s" % args[1]), "exception", "log") self.push(LogDebug(args[2]), "debug", "log") | log = self.env.log.channel self.push(LogException("ERROR: %s" % args[1]), "exception", log) self.push(LogDebug(args[2]), "debug", log) | def error(self, *args, **kwargs): if len(args) == 3 and issubclass(args[0], BaseException): type, value, traceback = args | c3dac4bb294b6ad544481379b92db15aa4f9cdb0 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/3020/c3dac4bb294b6ad544481379b92db15aa4f9cdb0/core.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
555,
12,
2890,
16,
380,
1968,
16,
2826,
4333,
4672,
309,
562,
12,
1968,
13,
422,
890,
471,
14664,
12,
1968,
63,
20,
6487,
26778,
4672,
618,
16,
460,
16,
10820,
273,
833,
2,
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,
1,
1,
1,
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,
555,
12,
2890,
16,
380,
1968,
16,
2826,
4333,
4672,
309,
562,
12,
1968,
13,
422,
890,
471,
14664,
12,
1968,
63,
20,
6487,
26778,
4672,
618,
16,
460,
16,
10820,
273,
833,
2,
-100,
-10... |
address are converted to an obvious bogus address (rather than just quietly dropping recipients). | address are converted to an obvious bogus address to help troubleshooting. | def emailAddressesFrom(self,subscribers): """ Convert a list of subscribers to a list of email addresses. | c20e5d4f9b2d176785211a3e81e97ead1ac50716 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/5225/c20e5d4f9b2d176785211a3e81e97ead1ac50716/Mail.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2699,
7148,
1265,
12,
2890,
16,
1717,
17769,
4672,
3536,
4037,
279,
666,
434,
16768,
358,
279,
666,
434,
2699,
6138,
18,
2,
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,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2699,
7148,
1265,
12,
2890,
16,
1717,
17769,
4672,
3536,
4037,
279,
666,
434,
16768,
358,
279,
666,
434,
2699,
6138,
18,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
item = form[key] if isinstance(item, list): l = [x.value for x in item] elif hasattr(item, "value"): l = [item.value] else: l = [item] return [ x.decode(charset) for x in l ] | return get_item_list(form[key]) def get_prefix_vals (form, prefix): """return a list of (key, value) pairs where ``prefix+key'' is a valid form field""" res = [] for key, item in form.items(): if key.startswith(prefix): res.append(key[len(prefix):], get_item_value(item)) return res | def getlist (form, key): """return a list of formfield values""" if not form.has_key(key): return [] item = form[key] if isinstance(item, list): l = [x.value for x in item] elif hasattr(item, "value"): l = [item.value] else: l = [item] return [ x.decode(charset) for x in l ] | ebb3f0f8f26d57ebcf5818dbfd680ba9192a5d5f /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/3948/ebb3f0f8f26d57ebcf5818dbfd680ba9192a5d5f/__init__.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
1098,
261,
687,
16,
498,
4672,
3536,
2463,
279,
666,
434,
646,
1518,
924,
8395,
309,
486,
646,
18,
5332,
67,
856,
12,
856,
4672,
327,
5378,
327,
336,
67,
1726,
67,
1098,
12,
687... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1098,
261,
687,
16,
498,
4672,
3536,
2463,
279,
666,
434,
646,
1518,
924,
8395,
309,
486,
646,
18,
5332,
67,
856,
12,
856,
4672,
327,
5378,
327,
336,
67,
1726,
67,
1098,
12,
687... |
error_info = error_info + "Student %s %s (%s)can not be assigned to this new group for %s,\ because he/she is already in group %s for %s.\n" \ | error_info = "Student %s %s (%s)can not be assigned to this new group for %s,\ because he/she is already in group %s for %s." \ | def validateIntegrity(request, isStudentCreatedGroup, groupForSemester, course, studentList, activityList): """ #If one student is in a group for an activity, he/she cannot be in another group for the same activity. """ integrityError = False error_info = "" for student in studentList: groupMembers = GroupMember.objects.filter(group__courseoffering = course, student = student) #check if the student is already in a group for all group activities of the semester for group in set(groupMember.group for groupMember in groupMembers): if groupForSemester == True and group.groupForSemester == True: integrityError = True #if this group is created by student if isStudentCreatedGroup: error_info = error_info + "You cannot create this group, \ because you are already in the group: %s for all activities of the semester" % (group.name) #if this group is created by instructor else: error_info = error_info + "Student %s %s (%s)can not be assigned to this new group,\ because he/she is already in group %s for all activities of the semester.\n" \ % (student.person.first_name, student.person.last_name, student.person.userid, group.name) if integrityError == True: continue #check if the student is in a group that already has one or more than one activities in the activityList for activity in activityList: for groupMember in groupMembers: if groupMember.activity == activity: integrityError = True #if this group is created by student if isStudentCreatedGroup: error_info = error_info + "You cannot create this group for %s, \ because you are already in the group: %s for %s.\n"\ % (activity.name, groupMember.group.name, activity.name) #if this group is created by instructor else: error_info = error_info + "Student %s %s (%s)can not be assigned to this new group for %s,\ because he/she is already in group %s for %s.\n" \ % (student.person.first_name, student.person.last_name, student.person.userid,\ activity.name, groupMember.group.name, activity.name) messages.add_message(request, messages.ERROR, error_info) return not integrityError | 1dbf358312499e9440cbf30849983e47ed802909 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/6634/1dbf358312499e9440cbf30849983e47ed802909/views.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1954,
30669,
12,
2293,
16,
353,
19943,
319,
6119,
1114,
16,
1041,
1290,
13185,
7654,
16,
4362,
16,
18110,
682,
16,
5728,
682,
4672,
3536,
468,
2047,
1245,
18110,
353,
316,
279,
1041,
364... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1954,
30669,
12,
2293,
16,
353,
19943,
319,
6119,
1114,
16,
1041,
1290,
13185,
7654,
16,
4362,
16,
18110,
682,
16,
5728,
682,
4672,
3536,
468,
2047,
1245,
18110,
353,
316,
279,
1041,
364... |
"ldd prog" lists the SONAMEs of the libraries it was linked against. | ldd lists the SONAMEs of the libraries a program was linked against. | def SharedLibrary3(env,target,sources,**kw): """ For a reference on Linux conventions for shared library names see http://tldp.org/HOWTO/Program-Library-HOWTO/shared-libraries.html The usual convention is that the full library name is something like: libxxx.so.3.4 The SONAME of the library is libxxx.so.3 And the basic library name is libxxx.so where 3 is the major number of the binary API and 4 is the minor number. Under linux, libxxx.so.3.4 is the actual library file, and libxxx.so.3 and libxxx.so are symbolic links. The idea is that two libraries with the same name, same major number, but differing minor number implement the same binary API, and that a library with a new minor number could replace the old without breaking executable programs that depend on the library. From the man page of ld, discussing the -soname option: -soname=name When creating an ELF shared object, set the internal DT_SONAME field to the specified name. When an executable is linked with a shared object which has a DT_SONAME field, then when the executable is run the dynamic linker will attempt to load the shared object specified by the DT_SONAME field rather than the using the file name given to the linker. If the SONAME of a library contains just the major number and not the minor number, and is a symbolic link to the real library, then the real library could be replaced with a library with a different minor number without re-linking executables. "ldd prog" lists the SONAMEs of the libraries it was linked against. The SONAME of a library can be seen with objdump -p | grep SONAME rpmbuild creates dependencies based on the SONAMEs. A library without major and minor number, libxxx.so, is only used at linking time, if the real library has a SONAME. That is why .so's without major and minor numbers are customarily found only in -devel RPMs. To create the above three libraries with this pseudo-builder, do: env['SHLIBMAJORVERSION'] = '3' env['SHLIBMINORVERSION'] = '4' libs = env.SharedLibrary3('xxx',objects) This builder will set the -soname of the real library, and the other two will be symbolic links. To install the library and the symbolic links to a destination: env.SharedLibrary3Install('/opt/local/mystuff',libs) The libraries will be installed to subdirectory 'lib' or 'lib64' of /opt/local/mystuff, depending on whether the current environment builds 64 or 32 bit objects. Note that the initial version of this tool is directed at Linux. Support for other architectures needs to be added as necessary. """ # add passed keywords to environment env = env.Clone(**kw) # target argument here is a simple string libname = env.subst('${SHLIBPREFIX}' + target + '$SHLIBSUFFIX') try: soname = libname + '.' + env['SHLIBMAJORVERSION'] except KeyError: print 'Cannot find SHLIBMAJORVERSION env variable' return None try: fullname = soname + '.' + env['SHLIBMINORVERSION'] except KeyError: print 'Cannot find SHLIBMINORVERSION env variable' return None nodes = [] # build the shared library with full .so.MAJOR.MINOR suffix # and a -soname linker option pointing to .so.MAJOR # kw['SHLINKFLAGS'] = env['SHLINKFLAGS'] + ['-Wl,-soname=' + soname] # kw['SHLIBSUFFIX'] = env['SHLIBSUFFIX'] + '.' + env['SHLIBMAJORVERSION'] + '.' + env['SHLIBMINORVERSION'] # nodes.extend(env.SharedLibrary(target,sources,**kw)) nodes.extend(env.SharedLibrary(target,sources, SHLINKFLAGS = env['SHLINKFLAGS'] + ['-Wl,-soname=' + soname], SHLIBSUFFIX = env['SHLIBSUFFIX'] + '.' + env['SHLIBMAJORVERSION'] + '.' + env['SHLIBMINORVERSION'])) # print 'nodes[0]=' + str(nodes[0]) # symbolic links nodes.extend(env.Command(libname,fullname,'cd $TARGET.dir; ln -sf $SOURCE.file $TARGET.file')) nodes.extend(env.Command(soname,fullname,'cd $TARGET.dir; ln -sf $SOURCE.file $TARGET.file')) return nodes | c70b9529a62f48e8453d823fb76495538f9931b6 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/1466/c70b9529a62f48e8453d823fb76495538f9931b6/sharedlibrary.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
10314,
9313,
23,
12,
3074,
16,
3299,
16,
10141,
16,
636,
9987,
4672,
225,
3536,
2457,
279,
2114,
603,
13318,
356,
24862,
364,
5116,
5313,
1257,
2621,
1062,
2207,
88,
18503,
18,
3341,
19,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
10314,
9313,
23,
12,
3074,
16,
3299,
16,
10141,
16,
636,
9987,
4672,
225,
3536,
2457,
279,
2114,
603,
13318,
356,
24862,
364,
5116,
5313,
1257,
2621,
1062,
2207,
88,
18503,
18,
3341,
19,... |
log.info('remove socket from dead server') | log.debug('remove socket from dead server') | def __init__(self, address, auth_secret = ''): | 842d345982b9d6198e33a7209cc9906dc2aa2fbd /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/11722/842d345982b9d6198e33a7209cc9906dc2aa2fbd/rpc.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
16,
1758,
16,
1357,
67,
5875,
273,
875,
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... | [
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,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
16,
1758,
16,
1357,
67,
5875,
273,
875,
4672,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
def typecode(typename): | def typecode(typename, namespace=None): | def typecode(typename): """create a typecode (eg. GTK_TYPE_WIDGET) from a typename""" return string.replace(to_upper_str(typename), '_', '_TYPE_', 1) | 2311187824d1b48a996ee2620fd3c9a63e3edd66 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/8659/2311187824d1b48a996ee2620fd3c9a63e3edd66/h2def.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
618,
710,
12,
12846,
1069,
16,
1981,
33,
7036,
4672,
3536,
2640,
279,
618,
710,
261,
1332,
18,
19688,
47,
67,
2399,
67,
59,
734,
3264,
13,
628,
279,
26735,
8395,
327,
533,
18,
2079,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
618,
710,
12,
12846,
1069,
16,
1981,
33,
7036,
4672,
3536,
2640,
279,
618,
710,
261,
1332,
18,
19688,
47,
67,
2399,
67,
59,
734,
3264,
13,
628,
279,
26735,
8395,
327,
533,
18,
2079,
... |
parser = config.IncludingConfigParser() | parser = IncludingConfigParser() | def _getpluginconf(self, modname): '''Parse the plugin specific configuration file and return a IncludingConfigParser instance representing it. Returns None if there was an error reading or parsing the configuration file. ''' for dir in self.pluginconfpath: conffilename = os.path.join(dir, modname + ".conf") if os.access(conffilename, os.R_OK): # Found configuration file break self.verbose_logger.log(logginglevels.INFO_2, "Configuration file %s not found" % conffilename) else: # for # Configuration files for the plugin not found self.verbose_logger.log(logginglevels.INFO_2, "Unable to find configuration file for plugin %s" % modname) return None | 3481a879a6b1eb969a845a598ca5667cbcd465f4 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/5445/3481a879a6b1eb969a845a598ca5667cbcd465f4/plugins.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
588,
4094,
3923,
12,
2890,
16,
16037,
4672,
9163,
3201,
326,
1909,
2923,
1664,
585,
471,
327,
279,
657,
18596,
809,
2678,
791,
5123,
518,
18,
2860,
599,
309,
1915,
1703,
392,
555,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
588,
4094,
3923,
12,
2890,
16,
16037,
4672,
9163,
3201,
326,
1909,
2923,
1664,
585,
471,
327,
279,
657,
18596,
809,
2678,
791,
5123,
518,
18,
2860,
599,
309,
1915,
1703,
392,
555,
... |
dups = [] | def _readRecordPoly(self, fp): """ Type: PolyLine (3), Polygon (5), PolyLineZ (13), PolygonZ (15), PolyLineM (23), or PolygonM (25) | 21d08cb05ff682765ee80c7919f1985ba6ea48ed /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/1821/21d08cb05ff682765ee80c7919f1985ba6ea48ed/shapefile.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
896,
2115,
12487,
12,
2890,
16,
4253,
4672,
3536,
1412,
30,
18394,
1670,
261,
23,
3631,
12681,
261,
25,
3631,
18394,
1670,
62,
261,
3437,
3631,
12681,
62,
261,
3600,
3631,
18394,
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,
0,
0,
0,
0,
0,
0,
0,
0,
0,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
896,
2115,
12487,
12,
2890,
16,
4253,
4672,
3536,
1412,
30,
18394,
1670,
261,
23,
3631,
12681,
261,
25,
3631,
18394,
1670,
62,
261,
3437,
3631,
12681,
62,
261,
3600,
3631,
18394,
16... | |
elif self.config['quality'] == "hq": | elif self.config['quality'] == "hd" and self.hd_available: quality = "&fmt=22" else: | def get_file_url(self): """ returns the absolute downloadable filepath """ if self.html == None: self.download_html() | a02a3ecd5b23b5380cf41e161f02a044d1db00af /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/9838/a02a3ecd5b23b5380cf41e161f02a044d1db00af/YoutubeCom.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
67,
768,
67,
718,
12,
2890,
4672,
3536,
1135,
326,
4967,
4224,
429,
3608,
3536,
309,
365,
18,
2620,
422,
599,
30,
365,
18,
7813,
67,
2620,
1435,
2,
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,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
67,
768,
67,
718,
12,
2890,
4672,
3536,
1135,
326,
4967,
4224,
429,
3608,
3536,
309,
365,
18,
2620,
422,
599,
30,
365,
18,
7813,
67,
2620,
1435,
2,
-100,
-100,
-100,
-100,
-100,
... |
fhandle = open(conffile) limits = fhandle.readline() | if isfile(conffile): fhandle = open(conffile) limits = fhandle.readline() limits = re.compile('(\d+)').findall(limits) lims = map(int, limits) else: lims = [ 86400, 86400, 86400, 86400, 86400, 86400, 86400 ] | def readusersettings(user, conffile): #Returns limits and from/to allowed hours fhandle = open(conffile) limits = fhandle.readline() #Read 1st line bfromandto = getuserlimits(user) bfromtemp = bfromandto[0] #Using map instead of for i in ... bfrom = map(int, bfromtemp) btotemp = bfromandto[1] bto = map(int, btotemp) limits = re.compile('(\d+)').findall(limits) lims = map(int, limits) return lims, bfrom, bto | 55861be7998f68e7810a52194d76a56a2c80be43 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/1574/55861be7998f68e7810a52194d76a56a2c80be43/timekpr.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
855,
5577,
278,
1256,
12,
1355,
16,
2195,
768,
4672,
468,
1356,
8181,
471,
628,
19,
869,
2935,
7507,
284,
4110,
273,
1696,
12,
3923,
768,
13,
8181,
273,
284,
4110,
18,
896,
1369,
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,
855,
5577,
278,
1256,
12,
1355,
16,
2195,
768,
4672,
468,
1356,
8181,
471,
628,
19,
869,
2935,
7507,
284,
4110,
273,
1696,
12,
3923,
768,
13,
8181,
273,
284,
4110,
18,
896,
1369,
1435,... |
return False if catname not in currule.ratings: currule.ratings[catname] = value info['rulecategory'] = True elif currule.ratings[catname] != value: currule.ratings[catname] = value info['rulecategory'] = True elif catname in currule.ratings: | return if currule.ratings[catname] != value: currule.ratings[catname] = value currule.compile_values() | def _form_apply_rating (form): # rating categories for catname, value in _get_prefix_vals(form, 'category_'): category = _get_category(catname) if category is None: # unknown category error['categoryvalue'] = True return False if category.iterable: realvalue = value else: realvalue = _intrange_from_string(value) if not category.valid_value(realvalue): error['categoryvalue'] = True return False if catname not in currule.ratings: currule.ratings[catname] = value info['rulecategory'] = True elif currule.ratings[catname] != value: currule.ratings[catname] = value info['rulecategory'] = True elif catname in currule.ratings: info['rulecategory'] = True del currule.ratings[catname] | 5fd5c49de60a4a0ba16f79b3b8178709baff598d /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/3948/5fd5c49de60a4a0ba16f79b3b8178709baff598d/filterconfig_html.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
687,
67,
9010,
67,
17326,
261,
687,
4672,
468,
13953,
6477,
364,
6573,
529,
16,
460,
316,
389,
588,
67,
3239,
67,
4524,
12,
687,
16,
296,
4743,
4623,
4672,
3150,
273,
389,
588,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
687,
67,
9010,
67,
17326,
261,
687,
4672,
468,
13953,
6477,
364,
6573,
529,
16,
460,
316,
389,
588,
67,
3239,
67,
4524,
12,
687,
16,
296,
4743,
4623,
4672,
3150,
273,
389,
588,
... |
two, which is tricky on DOS/Windows and Mac OS.""" if not abspath (pathname): return os.path.join (new_root, pathname) elif os.name == 'posix': return os.path.join (new_root, pathname[1:]) | two, which is tricky on DOS/Windows and Mac OS. """ if os.name == 'posix': if not os.path.isabs (pathname): return os.path.join (new_root, pathname) else: return os.path.join (new_root, pathname[1:]) | def change_root (new_root, pathname): """Return 'pathname' with 'new_root' prepended. If 'pathname' is relative, this is equivalent to "os.path.join(new_root,pathname)". Otherwise, it requires making 'pathname' relative and then joining the two, which is tricky on DOS/Windows and Mac OS.""" if not abspath (pathname): return os.path.join (new_root, pathname) elif os.name == 'posix': return os.path.join (new_root, pathname[1:]) elif os.name == 'nt': (root_drive, root_path) = os.path.splitdrive (new_root) (drive, path) = os.path.splitdrive (pathname) raise RuntimeError, "I give up -- not sure how to do this on Windows" elif os.name == 'mac': raise RuntimeError, "no clue how to do this on Mac OS" else: raise DistutilsPlatformError, \ "nothing known about platform '%s'" % os.name | 7c3f7a4a3d61490de1c6e92609311b7216e3dfb9 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12029/7c3f7a4a3d61490de1c6e92609311b7216e3dfb9/util.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2549,
67,
3085,
261,
2704,
67,
3085,
16,
9806,
4672,
225,
3536,
990,
296,
28336,
11,
598,
296,
2704,
67,
3085,
11,
26989,
18,
225,
971,
296,
28336,
11,
353,
3632,
16,
333,
353,
7680,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2549,
67,
3085,
261,
2704,
67,
3085,
16,
9806,
4672,
225,
3536,
990,
296,
28336,
11,
598,
296,
2704,
67,
3085,
11,
26989,
18,
225,
971,
296,
28336,
11,
353,
3632,
16,
333,
353,
7680,
... |
print | print '%s\n' % self._varOrBlank(self.description) | def generateReportTemplate(self): oldstdout = sys.stdout sys.stdout = cStringIO.StringIO() | 35d1d8320f58c95ee543050d5dbfc71f3e2fd29f /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/3557/35d1d8320f58c95ee543050d5dbfc71f3e2fd29f/bug.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2103,
4820,
2283,
12,
2890,
4672,
1592,
10283,
273,
2589,
18,
10283,
2589,
18,
10283,
273,
276,
780,
4294,
18,
780,
4294,
1435,
2,
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,
2103,
4820,
2283,
12,
2890,
4672,
1592,
10283,
273,
2589,
18,
10283,
2589,
18,
10283,
273,
276,
780,
4294,
18,
780,
4294,
1435,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
os.path.join(portable_dir, 'libtorrent', 'include'), os.path.join(portable_dir, 'libtorrent', 'include', 'libtorrent'), BOOST_INCLUDE_PATH, ZLIB_INCLUDE_PATH, OPENSSL_INCLUDE_PATH, | os.path.join(portable_dir, 'libtorrent'), os.path.join(portable_dir, 'libtorrent', 'include'), os.path.join(portable_dir, 'libtorrent', 'include', 'libtorrent'), BOOST_INCLUDE_PATH, ZLIB_INCLUDE_PATH, OPENSSL_INCLUDE_PATH, | def fetch_sources(): for root, dirs, files in os.walk(os.path.join(portable_dir, 'libtorrent')): if '.svn' in dirs: dirs.remove('.svn') if '_svn' in dirs: dirs.remove('_svn') for file in files: if file.endswith('.cpp') or file.endswith('.c'): yield os.path.join(root, file) | df09c6f3eb6f6abb6e6bf57d230dad75d0b75ccb /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/12354/df09c6f3eb6f6abb6e6bf57d230dad75d0b75ccb/setup.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2158,
67,
10141,
13332,
364,
1365,
16,
7717,
16,
1390,
316,
1140,
18,
11348,
12,
538,
18,
803,
18,
5701,
12,
655,
429,
67,
1214,
16,
296,
2941,
13039,
547,
26112,
30,
309,
2418,
31505,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2158,
67,
10141,
13332,
364,
1365,
16,
7717,
16,
1390,
316,
1140,
18,
11348,
12,
538,
18,
803,
18,
5701,
12,
655,
429,
67,
1214,
16,
296,
2941,
13039,
547,
26112,
30,
309,
2418,
31505,... |
except AttributeError: self.__gens = {} self.__regulator = {} | def regulator(self, use_database=True, verbose=None, proof=None): """ Returns the regulator of this curve, which must be defined over Q. | 191c8e1d61e26b049ead6a7ffe9599d513e93fe4 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/9890/191c8e1d61e26b049ead6a7ffe9599d513e93fe4/ell_rational_field.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
960,
11775,
12,
2890,
16,
999,
67,
6231,
33,
5510,
16,
3988,
33,
7036,
16,
14601,
33,
7036,
4672,
3536,
2860,
326,
960,
11775,
434,
333,
8882,
16,
1492,
1297,
506,
2553,
1879,
2238,
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,
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,
960,
11775,
12,
2890,
16,
999,
67,
6231,
33,
5510,
16,
3988,
33,
7036,
16,
14601,
33,
7036,
4672,
3536,
2860,
326,
960,
11775,
434,
333,
8882,
16,
1492,
1297,
506,
2553,
1879,
2238,
18... | |
for item in tmsg.splitlines(): item = item.strip() | for b_item in tmsg.split(os.linesep): item = str(b_item).strip() | def _parse(self, fp): """Override this method to support alternative .mo formats.""" unpack = struct.unpack filename = getattr(fp, 'name', '') # Parse the .mo file header, which consists of 5 little endian 32 # bit words. self._catalog = catalog = {} self.plural = lambda n: int(n != 1) # germanic plural by default buf = fp.read() buflen = len(buf) # Are we big endian or little endian? magic = unpack('<I', buf[:4])[0] if magic == self.LE_MAGIC: version, msgcount, masteridx, transidx = unpack('<4I', buf[4:20]) ii = '<II' elif magic == self.BE_MAGIC: version, msgcount, masteridx, transidx = unpack('>4I', buf[4:20]) ii = '>II' else: raise IOError(0, 'Bad magic number', filename) # Now put all messages from the .mo file buffer into the catalog # dictionary. for i in range(0, msgcount): mlen, moff = unpack(ii, buf[masteridx:masteridx+8]) mend = moff + mlen tlen, toff = unpack(ii, buf[transidx:transidx+8]) tend = toff + tlen if mend < buflen and tend < buflen: msg = buf[moff:mend] tmsg = buf[toff:tend] else: raise IOError(0, 'File is corrupt', filename) # See if we're looking at GNU .mo conventions for metadata if mlen == 0: # Catalog description lastk = k = None for item in tmsg.splitlines(): item = item.strip() if not item: continue if ':' in item: k, v = item.split(':', 1) k = k.strip().lower() v = v.strip() self._info[k] = v lastk = k elif lastk: self._info[lastk] += '\n' + item if k == 'content-type': self._charset = v.split('charset=')[1] elif k == 'plural-forms': v = v.split(';') plural = v[1].split('plural=')[1] self.plural = c2py(plural) # Note: we unconditionally convert both msgids and msgstrs to # Unicode using the character encoding specified in the charset # parameter of the Content-Type header. The gettext documentation # strongly encourages msgids to be us-ascii, but some appliations # require alternative encodings (e.g. Zope's ZCML and ZPT). For # traditional gettext applications, the msgid conversion will # cause no problems since us-ascii should always be a subset of # the charset encoding. We may want to fall back to 8-bit msgids # if the Unicode conversion fails. if '\x00' in msg: # Plural forms msgid1, msgid2 = msg.split('\x00') tmsg = tmsg.split('\x00') if self._charset: msgid1 = str(msgid1, self._charset) tmsg = [str(x, self._charset) for x in tmsg] for i in range(len(tmsg)): catalog[(msgid1, i)] = tmsg[i] else: if self._charset: msg = str(msg, self._charset) tmsg = str(tmsg, self._charset) catalog[msg] = tmsg # advance to next entry in the seek tables masteridx += 8 transidx += 8 | 1c1fac05322c471aaf723819655b215cfa671210 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/3187/1c1fac05322c471aaf723819655b215cfa671210/gettext.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
2670,
12,
2890,
16,
4253,
4672,
3536,
6618,
333,
707,
358,
2865,
10355,
263,
8683,
6449,
12123,
6167,
273,
1958,
18,
17309,
1544,
273,
3869,
12,
7944,
16,
296,
529,
2187,
28707,
468... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2670,
12,
2890,
16,
4253,
4672,
3536,
6618,
333,
707,
358,
2865,
10355,
263,
8683,
6449,
12123,
6167,
273,
1958,
18,
17309,
1544,
273,
3869,
12,
7944,
16,
296,
529,
2187,
28707,
468... |
return {'results': topics, 'paged_qs': topics, } | return {'paged_qs': topics} | def search(request): # TODO: move to form if 'action' in request.GET: action = request.GET['action'] if action == 'show_24h': date = datetime.datetime.today() - datetime.timedelta(1) topics = Topic.objects.filter(created__gte=date).order_by('created') elif action == 'show_new': #TODO: FIXME topics = Topic.objects.all().order_by('created') topics = [topic for topic in topics if forum_extras.has_unreads(topic, request.user)] elif action == 'show_unanswered': topics = Topic.objects.filter(post_count=1) elif action == 'show_subscriptions': topics = Topic.objects.filter(subscribers=request.user) elif action == 'show_user': user_id = request.GET['user_id'] posts = Post.objects.filter(user__id=user_id) topics = [post.topic for post in posts] elif action == 'search': keywords = request.GET.get('keywords') author = request.GET.get('author') forum = request.GET.get('forum') search_in = request.GET.get('search_in') sort_by = request.GET.get('sort_by') sort_dir = request.GET.get('sort_dir') if keywords and author: if search_in == 'all': if forum == '0': query = 'user:%s AND (topic:%s OR body:%s)' % (author, keywords, keywords) else: query = 'user:%s AND forum:%s AND (topic:%s OR body:%s)' % (author, forum, keywords, keywords) elif search_in == 'message': if forum == '0': query = 'user:%s AND body:%s' % (author, keywords) else: query = 'user:%s AND forum:%s AND body:%s' % (author, forum, keywords) elif search_in == 'topic': if forum == '0': query = 'user:%s AND topic:%s' % (author, keywords) else: query = 'user:%s AND forum:%s AND topic:%s' % (author, forum, keywords) elif keywords: if search_in == 'all': if forum == '0': query = 'topic:%s OR body:%s' % (keywords, keywords) else: query = 'forum:%s AND (topic:%s OR body:%s)' % (forum, keywords, keywords) elif search_in == 'message': if forum == '0': query = 'body:%s' % (keywords) else: query = 'forum:%s AND body:%s' % (forum, keywords) elif search_in == 'topic': if forum == '0': query = 'topic:%s' % (keywords) else: query = 'forum:%s AND topic:%s' % (forum, keywords) elif author: if forum == '0': query = 'user:%s' % (author) else: query = 'forum:%s AND user:%s' % (forum, author) else: return HttpResponseRedirect(reverse('search')) order = {'0': 'created', '1': 'user', '2': 'topic', '3': 'forum'}.get(sort_by, 'created') if sort_dir == 'DESC': order = '-' + order posts = post_indexer.search(query).order_by(order) if 'topics' in request.GET['show_as']: topics = [] for post in posts: if post.instance.topic not in topics: topics.append(post.instance.topic) return {'results': topics, 'paged_qs': topics, } elif 'posts' in request.GET['show_as']: return {'results': posts, 'paged_qs': posts, 'TEMPLATE': 'forum/search_posts.html' } return {'results': topics, 'paged_qs': topics, } else: form = PostSearchForm() return {'categories': Category.objects.all(), 'form': form, 'TEMPLATE': 'forum/search_form.html' } | ba4c7d664c5fdb0de1cf4045b77c042a04a6a932 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/13701/ba4c7d664c5fdb0de1cf4045b77c042a04a6a932/views.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1623,
12,
2293,
4672,
468,
2660,
30,
3635,
358,
646,
309,
296,
1128,
11,
316,
590,
18,
3264,
30,
1301,
273,
590,
18,
3264,
3292,
1128,
3546,
309,
1301,
422,
296,
4500,
67,
3247,
76,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1623,
12,
2293,
4672,
468,
2660,
30,
3635,
358,
646,
309,
296,
1128,
11,
316,
590,
18,
3264,
30,
1301,
273,
590,
18,
3264,
3292,
1128,
3546,
309,
1301,
422,
296,
4500,
67,
3247,
76,
... |
if [abs(a), abs(b)]<[ediff, ediff]: | if [abs(a), abs(b)] < [ediff, ediff]: | def read_convergence(self): """Method that checks whether a calculation has converged.""" converged = None for line in open('OUTCAR', 'r'): if line.rfind('EDIFF ')>-1: ediff = float(line.split()[2]) if line.rfind('total energy-change')>-1: split = line.split(':') a = float(split[1].split('(')[0]) b = float(split[1].split('(')[1][0:-2]) if [abs(a), abs(b)]<[ediff, ediff]: converged = True else: converged = None return converged | f4423f58cc5570456d20942075770a4ede73c36c /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/5572/f4423f58cc5570456d20942075770a4ede73c36c/vasp.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
855,
67,
591,
502,
15570,
12,
2890,
4672,
3536,
1305,
716,
4271,
2856,
279,
11096,
711,
14581,
2423,
12123,
14581,
2423,
273,
599,
364,
980,
316,
1696,
2668,
5069,
39,
985,
2187,
296,
86... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
855,
67,
591,
502,
15570,
12,
2890,
4672,
3536,
1305,
716,
4271,
2856,
279,
11096,
711,
14581,
2423,
12123,
14581,
2423,
273,
599,
364,
980,
316,
1696,
2668,
5069,
39,
985,
2187,
296,
86... |
class FlexGridSizerDTC(GridSizerDTC): | class FlexGridSizerDTC(GridSizerDTC): | def updateGUI(self): self.control.Layout() wxCallAfter(self.designer.controllerView.Refresh) | 6855cdd6e993138a31fabc262e2e332cdd94b9fc /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/4325/6855cdd6e993138a31fabc262e2e332cdd94b9fc/SizerCompanions.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1089,
43,
5370,
12,
2890,
4672,
365,
18,
7098,
18,
3744,
1435,
7075,
1477,
4436,
12,
2890,
18,
16934,
264,
18,
5723,
1767,
18,
8323,
13,
225,
2,
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,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1089,
43,
5370,
12,
2890,
4672,
365,
18,
7098,
18,
3744,
1435,
7075,
1477,
4436,
12,
2890,
18,
16934,
264,
18,
5723,
1767,
18,
8323,
13,
225,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
except: continue else: try: sc_veclist += kin_vec(key_hash[bond[0]], | except: continue else: try: sc_veclist += kin_vec(key_hash[bond[0]], | def get_kin_lots(chain, pdbID=None, index=0, show_hydrogen=True): mc_atoms = ["N", "CA", "C", "O", "OXT", "P", "OP1", "OP2", "O5'", "C5'", "C4'", "O4'", "C1'", "C3'", "O3'", "C2'", "O2'"] mc_veclist = "" sc_veclist = "" mc_h_veclist = "" sc_h_veclist = "" ca_trace = "" virtual_bb = "" water_list = "" kin_out = "" color = get_chain_color(index) mc_veclist = "@vectorlist {mc} color= %s master= {mainchain}\n" % color sc_veclist = "@vectorlist {sc} color= cyan master= {sidechain}\n" ca_trace = "@vectorlist {Calphas} color= %s master= {Calphas}\n" % color virtual_bb = "@vectorlist {Virtual BB} color= %s off master= {Virtual BB}\n" % color water_list = "@balllist {water O} color= peachtint radius= 0.15 master= {water}\n" hets = "@vectorlist {het} color= pink master= {hets}\n" het_h = "@vectorlist {ht H} color= gray nobutton master= {hets} master= {H's}\n" if show_hydrogen: mc_h_veclist = \ "@vectorlist {mc H} color= gray nobutton master= {mainchain} master= {H's}\n" sc_h_veclist = \ "@vectorlist {sc H} color= gray nobutton master= {sidechain} master= {H's}\n" prev_resid = None prev_C_xyz = None prev_C_key = None prev_CA_xyz = None prev_CA_key = None cur_resid = None cur_C_xyz = None cur_C_key = None cur_CA_xyz = None cur_CA_key = None prev_O3_xyz = None prev_O3_key = None cur_O3_xyz = None cur_O3_key = None p_hash_key = {} p_hash_xyz = {} c1_hash_key = {} c1_hash_xyz = {} c4_hash_key = {} c4_hash_xyz = {} for residue_group in chain.residue_groups(): cur_resid = residue_group.resseq #print dir(residue_group) #sys.exit() for atom_group in residue_group.atom_groups(): #print dir(atom_group) #sys.exit() key_hash = {} xyz_hash = {} het_hash = {} for atom in atom_group.atoms(): #print dir(atom) #sys.exit() key = "%s %s %s%s B%.2f %s" % ( atom.name.lower(), atom_group.resname.lower(), chain.id, residue_group.resseq, atom.b, pdbID) key_hash[atom.name.strip()] = key xyz_hash[atom.name.strip()] = atom.xyz if(common_residue_names_get_class(atom_group.resname) == "common_amino_acid"): if atom.name == ' C ': cur_C_xyz = atom.xyz cur_C_key = key if atom.name == ' CA ': cur_CA_key = key cur_CA_xyz = atom.xyz if prev_CA_key != None and prev_CA_xyz != None: if int(residue_group.resid()) - int(prev_resid) == 1: try: ca_trace += kin_vec(prev_CA_key, prev_CA_xyz, key, atom.xyz) except: continue if atom.name == ' N ': if prev_C_key != None and prev_C_xyz != None: if int(residue_group.resid()) - int(prev_resid) == 1: try: mc_veclist += kin_vec(prev_C_key, prev_C_xyz, key, atom.xyz) except: continue elif(common_residue_names_get_class(atom_group.resname) == "common_rna_dna"): if atom.name == " O3'": cur_O3_xyz = atom.xyz cur_O3_key = key elif atom.name == ' P ': if prev_O3_key != None and prev_O3_xyz != None: if int(residue_group.resid()) - int(prev_resid) == 1: try: mc_veclist += kin_vec(prev_O3_key, prev_O3_xyz, key, atom.xyz) except: continue p_hash_key[int(residue_group.resseq)] = key p_hash_xyz[int(residue_group.resseq)] = atom.xyz elif atom.name == " C1'": c1_hash_key[int(residue_group.resseq)] = key c1_hash_xyz[int(residue_group.resseq)] = atom.xyz elif atom.name == " C4'": c4_hash_key[int(residue_group.resseq)] = key c4_hash_xyz[int(residue_group.resseq)] = atom.xyz elif atom_group.resname.lower() == 'hoh': if atom.name == ' O ': water_list += "{%s} P %.3f %.3f %.3f\n" % ( key, atom.xyz[0], atom.xyz[1], atom.xyz[2]) elif atom.hetero == True: het_hash[atom.name.strip()] = [key, atom.xyz] # print common_residue_names_get_class(atom_group.resname) if(common_residue_names_get_class(atom_group.resname) == "common_rna_dna"): try: virtual_bb += "{%s} P %.3f %.3f %.3f {%s} L %.3f %.3f %.3f\n" % ( c4_hash_key[int(residue_group.resseq)-1], c4_hash_xyz[int(residue_group.resseq)-1][0], c4_hash_xyz[int(residue_group.resseq)-1][1], c4_hash_xyz[int(residue_group.resseq)-1][2], p_hash_key[int(residue_group.resseq)], p_hash_xyz[int(residue_group.resseq)][0], p_hash_xyz[int(residue_group.resseq)][1], p_hash_xyz[int(residue_group.resseq)][2]) except: continue try: virtual_bb += "{%s} P %.3f %.3f %.3f {%s} L %.3f %.3f %.3f\n" % ( p_hash_key[int(residue_group.resseq)], p_hash_xyz[int(residue_group.resseq)][0], p_hash_xyz[int(residue_group.resseq)][1], p_hash_xyz[int(residue_group.resseq)][2], c4_hash_key[int(residue_group.resseq)], c4_hash_xyz[int(residue_group.resseq)][0], c4_hash_xyz[int(residue_group.resseq)][1], c4_hash_xyz[int(residue_group.resseq)][2]) except: continue try: virtual_bb += "{%s} P %.3f %.3f %.3f {%s} L %.3f %.3f %.3f\n" % ( c4_hash_key[int(residue_group.resseq)], c4_hash_xyz[int(residue_group.resseq)][0], c4_hash_xyz[int(residue_group.resseq)][1], c4_hash_xyz[int(residue_group.resseq)][2], c1_hash_key[int(residue_group.resseq)], c1_hash_xyz[int(residue_group.resseq)][0], c1_hash_xyz[int(residue_group.resseq)][1], c1_hash_xyz[int(residue_group.resseq)][2]) except: continue bonds = get_bond_pairs(code=atom_group.resname) prev_CA_xyz = cur_CA_xyz prev_CA_key = cur_CA_key prev_C_xyz = cur_C_xyz prev_C_key = cur_C_key prev_resid = cur_resid prev_O3_key = cur_O3_key prev_O3_xyz = cur_O3_xyz if (common_residue_names_get_class(atom_group.resname) == 'other'): for bond in bonds: if (bond[0].startswith('H') or bond[1].startswith('H')): if show_hydrogen: try: het_h += kin_vec(het_hash[bond[0]][0], het_hash[bond[0]][1], het_hash[bond[1]][0], het_hash[bond[1]][1]) except: continue else: try: hets += "{%s} P %.3f %.3f %.3f {%s} L %.3f %.3f %.3f\n" % ( het_hash[bond[0]][0], het_hash[bond[0]][1][0], het_hash[bond[0]][1][1], het_hash[bond[0]][1][2], het_hash[bond[1]][0], het_hash[bond[1]][1][0], het_hash[bond[1]][1][1], het_hash[bond[1]][1][2]) except: continue for bond in bonds: if bond[0] in mc_atoms and bond[1] in mc_atoms: try: mc_veclist += kin_vec(key_hash[bond[0]], xyz_hash[bond[0]], key_hash[bond[1]], xyz_hash[bond[1]]) except: continue elif (bond[0].startswith('H') or bond[1].startswith('H')): if show_hydrogen: if (bond[0] in mc_atoms or bond[1] in mc_atoms): try: mc_h_veclist += kin_vec(key_hash[bond[0]], xyz_hash[bond[0]], key_hash[bond[1]], xyz_hash[bond[1]]) except: continue else: try: sc_h_veclist += kin_vec(key_hash[bond[0]], xyz_hash[bond[0]], key_hash[bond[1]], xyz_hash[bond[1]]) except: continue else: try: sc_veclist += kin_vec(key_hash[bond[0]], xyz_hash[bond[0]], key_hash[bond[1]], xyz_hash[bond[1]]) except: continue #clean up empty lists: if len(mc_veclist.splitlines()) > 1: kin_out += mc_veclist if len(mc_h_veclist.splitlines()) > 1: kin_out += mc_h_veclist if len(ca_trace.splitlines()) > 1: kin_out += ca_trace if len(sc_veclist.splitlines()) > 1: kin_out += sc_veclist if len(sc_h_veclist.splitlines()) > 1: kin_out += sc_h_veclist if len(water_list.splitlines()) > 1: kin_out += water_list if len(virtual_bb.splitlines()) > 1: kin_out += virtual_bb if len(hets.splitlines()) > 1: kin_out += hets if len(het_h.splitlines()) > 1: kin_out += het_h return kin_out | cf23624f960f6654c1080d039c5b085f6133a56c /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/696/cf23624f960f6654c1080d039c5b085f6133a56c/validation.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
67,
15984,
67,
80,
6968,
12,
5639,
16,
10892,
734,
33,
7036,
16,
770,
33,
20,
16,
2405,
67,
18112,
24096,
33,
5510,
4672,
6108,
67,
14937,
273,
8247,
50,
3113,
315,
3587,
3113,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
15984,
67,
80,
6968,
12,
5639,
16,
10892,
734,
33,
7036,
16,
770,
33,
20,
16,
2405,
67,
18112,
24096,
33,
5510,
4672,
6108,
67,
14937,
273,
8247,
50,
3113,
315,
3587,
3113,
... |
self.assert_(mailbox.MHMessage(msg_maildir).get_sequences() == \ result) | self.assertEqual(mailbox.MHMessage(msg_maildir).get_sequences(), result) | def test_maildir_to_mh(self): # Convert MaildirMessage to MHMessage msg_maildir = mailbox.MaildirMessage(_sample_message) pairs = (('D', ['unseen']), ('F', ['unseen', 'flagged']), ('P', ['unseen']), ('R', ['unseen', 'replied']), ('S', []), ('T', ['unseen']), ('DFPRST', ['replied', 'flagged'])) for setting, result in pairs: msg_maildir.set_flags(setting) self.assert_(mailbox.MHMessage(msg_maildir).get_sequences() == \ result) | ea8344797e1a0ebd0b419ce14e16ab25af771fcc /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/8546/ea8344797e1a0ebd0b419ce14e16ab25af771fcc/test_mailbox.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1842,
67,
2540,
545,
481,
67,
869,
67,
81,
76,
12,
2890,
4672,
468,
4037,
490,
69,
545,
481,
1079,
358,
490,
44,
1079,
1234,
67,
2540,
545,
481,
273,
14187,
18,
49,
69,
545,
481,
1... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2540,
545,
481,
67,
869,
67,
81,
76,
12,
2890,
4672,
468,
4037,
490,
69,
545,
481,
1079,
358,
490,
44,
1079,
1234,
67,
2540,
545,
481,
273,
14187,
18,
49,
69,
545,
481,
1... |
D += O.trait_names() except (AttributeError, TypeError): pass if method == '': v = [obj + '.'+x for x in D if x and x[0] != '_'] else: v = [obj + '.'+x for x in D if x[:n] == method] except Exception, msg: print msg v = [] v = list(set(v)) v.sort() | O = eval(obj, globs) D = dir(O) try: D += O.trait_names() except (AttributeError, TypeError): pass if method == '': v = [obj + '.'+x for x in D if x and x[0] != '_'] else: v = [obj + '.'+x for x in D if x[:n] == method] except Exception, msg: print msg v = [] v = list(set(v)) v.sort() except Exception, msg: print msg v = [] | def completions(s, globs, format=False, width=90): """ Return a list of completions in the context of globs. """ n = len(s) if n == 0: return '(empty string)' if not '.' in s and not '(' in s: v = [x for x in globs.keys() if x[:n] == s] else: if not ')' in s: i = s.rfind('.') method = s[i+1:] obj = s[:i] n = len(method) else: obj = preparse(s) method = '' try: O = eval(obj, globs) D = dir(O) try: D += O.trait_names() except (AttributeError, TypeError): pass if method == '': v = [obj + '.'+x for x in D if x and x[0] != '_'] else: v = [obj + '.'+x for x in D if x[:n] == method] except Exception, msg: print msg v = [] v = list(set(v)) # make uniq v.sort() if format: if len(v) == 0: return "no completions of %s"%s else: return tabulate(v, width) return v | 2cc37d146f4c9b07e55bd1c19f1d2543f3ac19cd /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/9890/2cc37d146f4c9b07e55bd1c19f1d2543f3ac19cd/support.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
23738,
12,
87,
16,
4715,
87,
16,
740,
33,
8381,
16,
1835,
33,
9349,
4672,
3536,
2000,
279,
666,
434,
23738,
316,
326,
819,
434,
4715,
87,
18,
3536,
290,
273,
562,
12,
87,
13,
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,
23738,
12,
87,
16,
4715,
87,
16,
740,
33,
8381,
16,
1835,
33,
9349,
4672,
3536,
2000,
279,
666,
434,
23738,
316,
326,
819,
434,
4715,
87,
18,
3536,
290,
273,
562,
12,
87,
13,
309,
... |
for k, v in os.environ.iteritems(): | for k in os.environ.keys(): | def setUp(self): # Records changes to env vars self.env = test_support.EnvironmentVarGuard() # Delete all proxy related env vars for k, v in os.environ.iteritems(): if 'proxy' in k.lower(): self.env.unset(k) | 718c2fce66ddbb03c242d5c02881a100a27cb8b7 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/3187/718c2fce66ddbb03c242d5c02881a100a27cb8b7/test_urllib.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
24292,
12,
2890,
4672,
468,
27390,
3478,
358,
1550,
4153,
365,
18,
3074,
273,
1842,
67,
13261,
18,
5494,
1537,
16709,
1435,
468,
2504,
777,
2889,
3746,
1550,
4153,
364,
417,
316,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
24292,
12,
2890,
4672,
468,
27390,
3478,
358,
1550,
4153,
365,
18,
3074,
273,
1842,
67,
13261,
18,
5494,
1537,
16709,
1435,
468,
2504,
777,
2889,
3746,
1550,
4153,
364,
417,
316,
1140,
1... |
while True: | while 1: | def vonmisesvariate(self, mu, kappa): """Circular data distribution. | 42406e6f27e9a42e91db8706d897e0b478b13a4d /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8546/42406e6f27e9a42e91db8706d897e0b478b13a4d/random.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
331,
265,
81,
6141,
1401,
3840,
12,
2890,
16,
4129,
16,
23125,
4672,
3536,
25858,
501,
7006,
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,
... | [
1,
1,
1,
1,
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,
331,
265,
81,
6141,
1401,
3840,
12,
2890,
16,
4129,
16,
23125,
4672,
3536,
25858,
501,
7006,
18,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-1... |
request.connection.write('ThisWillCauseHandshakeError') | request.connection.write('ThisWillCauseHandshakeError\r\n') | def web_socket_do_extra_handshake(request): request.connection.write('ThisWillCauseHandshakeError') | d366546542742dfde546317f1a952bfaa8536a3a /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/9392/d366546542742dfde546317f1a952bfaa8536a3a/handshake-error_wsh.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
3311,
67,
7814,
67,
2896,
67,
7763,
67,
2349,
7478,
12,
2293,
4672,
590,
18,
4071,
18,
2626,
2668,
2503,
13670,
10683,
14545,
668,
64,
86,
64,
82,
6134,
282,
2,
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,
3311,
67,
7814,
67,
2896,
67,
7763,
67,
2349,
7478,
12,
2293,
4672,
590,
18,
4071,
18,
2626,
2668,
2503,
13670,
10683,
14545,
668,
64,
86,
64,
82,
6134,
282,
2,
-100,
-100,
-100,
-100,... |
return [self.object_name, self.should_save_image, self.image_name] | result = [] for object in self.objects: result += [object.object_name, object.should_save_image,object.image_name] return result | def settings(self): """The settings as saved in the pipeline file """ return [self.object_name, self.should_save_image, self.image_name] | a0bb548da9fde1e6fd3c949608fd007fd37a3ee9 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/2870/a0bb548da9fde1e6fd3c949608fd007fd37a3ee9/measureimageareaoccupied.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1947,
12,
2890,
4672,
3536,
1986,
1947,
487,
5198,
316,
326,
5873,
585,
225,
3536,
327,
306,
2890,
18,
1612,
67,
529,
16,
365,
18,
13139,
67,
5688,
67,
2730,
16,
365,
18,
2730,
67,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1947,
12,
2890,
4672,
3536,
1986,
1947,
487,
5198,
316,
326,
5873,
585,
225,
3536,
327,
306,
2890,
18,
1612,
67,
529,
16,
365,
18,
13139,
67,
5688,
67,
2730,
16,
365,
18,
2730,
67,
5... |
raise RuntimeError, "Failed to converge after %d iterations, value is %s" % (maxiter,p) | msg = "Failed to converge after %d iterations, value is %s" % (maxiter, p) raise RuntimeError(msg) | def newton(func, x0, fprime=None, args=(), tol=1.48e-8, maxiter=50): """Find a zero using the Newton-Raphson or secant method. Find a zero of the function `func` given a nearby starting point `x0`. The Newton-Rapheson method is used if the derivative `fprime` of `func` is provided, otherwise the secant method is used. Parameters ---------- func : function The function whose zero is wanted. It must be a function of a single variable of the form f(x,a,b,c...), where a,b,c... are extra arguments that can be passed in the `args` parameter. x0 : float An initial estimate of the zero that should be somewhere near the actual zero. fprime : {None, function}, optional The derivative of the function when available and convenient. If it is None, then the secant method is used. The default is None. args : tuple, optional Extra arguments to be used in the function call. tol : float, optional The allowable error of the zero value. maxiter : int, optional Maximum number of iterations. Returns ------- zero : float Estimated location where function is zero. See Also -------- brentq, brenth, ridder, bisect -- find zeroes in one dimension. fsolve -- find zeroes in n dimensions. Notes ----- The convergence rate of the Newton-Rapheson method is quadratic while that of the secant method is somewhat less. This means that if the function is well behaved the actual error in the estimated zero is approximatly the square of the requested tolerance up to roundoff error. However, the stopping criterion used here is the step size and there is no quarantee that a zero has been found. Consequently the result should be verified. Safer algorithms are brentq, brenth, ridder, and bisect, but they all require that the root first be bracketed in an interval where the function changes sign. The brentq algorithm is recommended for general use in one dimemsional problems when such an interval has been found. """ if fprime is not None: # Newton-Rapheson method p0 = x0 for iter in range(maxiter): myargs = (p0,) + args fval = func(*myargs) fder = fprime(*myargs) if fder == 0: print "Warning: zero-derivative encountered." return p0 p = p0 - func(*myargs)/fprime(*myargs) if abs(p - p0) < tol: return p p0 = p else: # Secant method p0 = x0 p1 = x0*(1 + 1e-4) q0 = func(*((p0,) + args)) q1 = func(*((p1,) + args)) for iter in range(maxiter): if q1 == q0: if p1 != p0: print "Tolerance of %s reached" % (p1-p0) return (p1 + p0)/2.0 else: p = p1 - q1*(p1 - p0)/(q1 - q0) if abs(p - p1) < tol: return p p0 = p1 q0 = q1 p1 = p q1 = func(*((p1,) + args)) raise RuntimeError, "Failed to converge after %d iterations, value is %s" % (maxiter,p) | 510547f61f981abe1ea89b12aa0442c154378da2 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/12971/510547f61f981abe1ea89b12aa0442c154378da2/minpack.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
394,
1917,
12,
644,
16,
619,
20,
16,
284,
16382,
33,
7036,
16,
833,
33,
9334,
6085,
33,
21,
18,
8875,
73,
17,
28,
16,
25743,
33,
3361,
4672,
3536,
3125,
279,
3634,
1450,
326,
1166,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
394,
1917,
12,
644,
16,
619,
20,
16,
284,
16382,
33,
7036,
16,
833,
33,
9334,
6085,
33,
21,
18,
8875,
73,
17,
28,
16,
25743,
33,
3361,
4672,
3536,
3125,
279,
3634,
1450,
326,
1166,
... |
if self.writeoperation(convop, self.llreprs[v1], self.llreprs[v2]): self.mark_release(v2) | self.writeoperation(convop, self.llreprs[v1], self.llreprs[v2]) | def convert_variable(self, v1, v2): self.makevar(v1) self.makevar(v2) convop = self.getconversion(self.hltypes[v1], self.hltypes[v2]) if self.writeoperation(convop, self.llreprs[v1], self.llreprs[v2]): self.mark_release(v2) | 842d71aa77f5a1dec4c16a6ec8790eb83ff69fa4 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/6934/842d71aa77f5a1dec4c16a6ec8790eb83ff69fa4/typer.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1765,
67,
6105,
12,
2890,
16,
331,
21,
16,
331,
22,
4672,
365,
18,
6540,
1401,
12,
90,
21,
13,
365,
18,
6540,
1401,
12,
90,
22,
13,
6292,
556,
273,
365,
18,
588,
20990,
12,
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,
1765,
67,
6105,
12,
2890,
16,
331,
21,
16,
331,
22,
4672,
365,
18,
6540,
1401,
12,
90,
21,
13,
365,
18,
6540,
1401,
12,
90,
22,
13,
6292,
556,
273,
365,
18,
588,
20990,
12,
2890,
... |
sage: hash(repr(SR(3/1))) | sage: hash(repr(SR(3/1))) | def __hash__(self): """ Returns the hash of this symbolic expression. | 2b6ad56bcf2516ea032c64349bb279c9ac313cda /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/9890/2b6ad56bcf2516ea032c64349bb279c9ac313cda/calculus.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2816,
972,
12,
2890,
4672,
3536,
2860,
326,
1651,
434,
333,
16754,
2652,
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,
... | [
1,
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,
1001,
2816,
972,
12,
2890,
4672,
3536,
2860,
326,
1651,
434,
333,
16754,
2652,
18,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
query = 'self.getCatalogedObjects(meta_type=%s, approved=1' % meta | query = 'self.getCatalogedObjects(meta_type=[METATYPE_NYSMAPEXPERT], approved=1' | def searchExperts(self, priority_area='', focus=[], country='', free_text='', skey='', rkey=0, perform_search='', meta='', REQUEST=None): """ """ res_per_page = 10 query = '' res = [] results = [] lang = self.gl_get_selected_language() if meta == 'prj': meta = '[METATYPE_NYSMAPPROJECT]' area_indexname = 'resource_area' focus_indexname = 'resource_focus' elif meta == 'exp': meta = '[METATYPE_NYSMAPEXPERT]' area_indexname = 'resource_area_exp' focus_indexname = 'resource_focus_exp' else: meta = '[]' | a556620cf6e2843951329931a6288ce7153c66bc /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/3287/a556620cf6e2843951329931a6288ce7153c66bc/SMAPSite.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1623,
424,
672,
87,
12,
2890,
16,
4394,
67,
5036,
2218,
2187,
7155,
22850,
6487,
5251,
2218,
2187,
4843,
67,
955,
2218,
2187,
272,
856,
2218,
2187,
436,
856,
33,
20,
16,
3073,
67,
3072... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1623,
424,
672,
87,
12,
2890,
16,
4394,
67,
5036,
2218,
2187,
7155,
22850,
6487,
5251,
2218,
2187,
4843,
67,
955,
2218,
2187,
272,
856,
2218,
2187,
436,
856,
33,
20,
16,
3073,
67,
3072... |
z.mem_fun(lambda x: x.name==t and 'CvMat' in x.decl_string)._transformer_kwds['alias'] = t | for t2 in z.mem_funs(t): t2._transformer_kwds['alias'] = t | def _KLASS__repr__(self): return "KLASS(min_val=" + repr(self.min_val) + ", max_val=" + repr(self.max_val) \ + ", step=" + repr(self.step) + ")" | ae9b17d7557fc6b2b10eac03a2d3d28f6f784b42 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/4310/ae9b17d7557fc6b2b10eac03a2d3d28f6f784b42/ml_h.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
47,
3979,
972,
12715,
972,
12,
2890,
4672,
327,
315,
47,
3979,
12,
1154,
67,
1125,
1546,
397,
8480,
12,
2890,
18,
1154,
67,
1125,
13,
397,
3104,
943,
67,
1125,
1546,
397,
8480,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
47,
3979,
972,
12715,
972,
12,
2890,
4672,
327,
315,
47,
3979,
12,
1154,
67,
1125,
1546,
397,
8480,
12,
2890,
18,
1154,
67,
1125,
13,
397,
3104,
943,
67,
1125,
1546,
397,
8480,
... |
self.file, self.line, self.column = File(f), l, c | f = File(f) if f else None self.file, self.line, self.column = f, int(l.value), int(c.value) | def init(self): """ Initialize the source location, setting its file, line and column. """ f, l, c = c_void_p(), c_uint(), c_uint() SourceLocation_loc(self, byref(f), byref(l), byref(c)) self.file, self.line, self.column = File(f), l, c return self | ee81737e7facd5c47077ebba89c462bc1ecd3835 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/11986/ee81737e7facd5c47077ebba89c462bc1ecd3835/cindex.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1208,
12,
2890,
4672,
3536,
9190,
326,
1084,
2117,
16,
3637,
2097,
585,
16,
980,
471,
1057,
18,
3536,
284,
16,
328,
16,
276,
273,
276,
67,
6459,
67,
84,
9334,
276,
67,
11890,
9334,
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,
1208,
12,
2890,
4672,
3536,
9190,
326,
1084,
2117,
16,
3637,
2097,
585,
16,
980,
471,
1057,
18,
3536,
284,
16,
328,
16,
276,
273,
276,
67,
6459,
67,
84,
9334,
276,
67,
11890,
9334,
2... |
defaultFile = "", wildcard = "Moho switch files (*.dat)|*.dat", style = wx.SAVE | wx.CHANGE_DIR | wx.OVERWRITE_PROMPT) | defaultFile = "%s" % self.doc.soundPath.rsplit('.', 1)[0]+".dat", wildcard = "Moho switch files (*.dat)|*.dat", style = wx.SAVE | wx.CHANGE_DIR | wx.OVERWRITE_PROMPT) | def OnVoiceExport(self, event): language = self.languageChoice.GetStringSelection() if (self.doc is not None) and (self.doc.currentVoice is not None): exporter = self.exportChoice.GetStringSelection() if exporter == "MOHO": dlg = wx.FileDialog( self, message = "Export Lipsync Data (MOHO)", defaultDir = self.config.Read("WorkingDir", get_main_dir()), defaultFile = "", wildcard = "Moho switch files (*.dat)|*.dat", style = wx.SAVE | wx.CHANGE_DIR | wx.OVERWRITE_PROMPT) if dlg.ShowModal() == wx.ID_OK: self.config.Write("WorkingDir", dlg.GetDirectory()) self.doc.currentVoice.Export(dlg.GetPaths()[0]) dlg.Destroy() elif exporter == "ALELO": fps = int(self.fpsCtrl.GetValue()) if fps != 100: dlg = wx.MessageDialog(self, 'FPS is NOT 100 continue? (You will have issues downstream.)', appTitle, wx.YES_NO | wx.CANCEL | wx.YES_DEFAULT | wx.ICON_WARNING) result = dlg.ShowModal() dlg.Destroy() else: result = wx.ID_YES if result == wx.ID_YES: dlg = wx.FileDialog( self, message = "Export Lipsync Data (ALELO)", defaultDir = self.config.Read("WorkingDir", get_main_dir()), defaultFile = "", wildcard = "Alelo timing files (*.timing)|*.timing", style = wx.SAVE | wx.CHANGE_DIR | wx.OVERWRITE_PROMPT) if dlg.ShowModal() == wx.ID_OK: self.config.Write("WorkingDir", dlg.GetDirectory()) self.doc.currentVoice.ExportAlelo(dlg.GetPaths()[0], language, self.langman) dlg.Destroy() | d584fcc14e928cd6d2fe571769dc0e1a0be3fb8c /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/9693/d584fcc14e928cd6d2fe571769dc0e1a0be3fb8c/LipsyncFrame.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2755,
14572,
6144,
12,
2890,
16,
871,
4672,
2653,
273,
365,
18,
4923,
10538,
18,
967,
780,
6233,
1435,
309,
261,
2890,
18,
2434,
353,
486,
599,
13,
471,
261,
2890,
18,
2434,
18,
2972,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
2755,
14572,
6144,
12,
2890,
16,
871,
4672,
2653,
273,
365,
18,
4923,
10538,
18,
967,
780,
6233,
1435,
309,
261,
2890,
18,
2434,
353,
486,
599,
13,
471,
261,
2890,
18,
2434,
18,
2972,
... |
""" | """ | def flimage_add_marker_struct(p1, p2): """ flimage_add_marker_struct(p1, p2) -> num. """ retval = _flimage_add_marker_struct(p1, p2) return retval | 9942dac8ce2b35a1e43615a26fd8e7054ef805d3 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/2429/9942dac8ce2b35a1e43615a26fd8e7054ef805d3/xformslib.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1183,
2730,
67,
1289,
67,
11145,
67,
1697,
12,
84,
21,
16,
293,
22,
4672,
3536,
1183,
2730,
67,
1289,
67,
11145,
67,
1697,
12,
84,
21,
16,
293,
22,
13,
317,
818,
18,
3536,
225,
522... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1183,
2730,
67,
1289,
67,
11145,
67,
1697,
12,
84,
21,
16,
293,
22,
4672,
3536,
1183,
2730,
67,
1289,
67,
11145,
67,
1697,
12,
84,
21,
16,
293,
22,
13,
317,
818,
18,
3536,
225,
522... |
reloadlist = glob.glob(os.path.join(profileBase, '*.dump.tgz')) | reloadlist = glob.glob(os.path.join(profileBase, 'Chandler*.dump')) | def run(cls, exception=None): dialog = UpgradeDialog(exception) | 73ff69a8aff085cf06275a77da5bfcc7d80e47b6 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/9228/73ff69a8aff085cf06275a77da5bfcc7d80e47b6/UpgradeDialog.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1086,
12,
6429,
16,
1520,
33,
7036,
4672,
6176,
273,
17699,
6353,
12,
4064,
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,... | [
1,
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,
1086,
12,
6429,
16,
1520,
33,
7036,
4672,
6176,
273,
17699,
6353,
12,
4064,
13,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-... |
if self.manualUpload or self.get_upload_ratio() < 1.5: | if ((self.manualUpload or (config.get(prefs.LIMIT_UPLOAD_RATIO) and self.get_upload_ratio() < config.get(prefs.UPLOAD_RATIO)))): | def restart_on_startup_if_needed(self): if _downloads.has_key(self.dlid): # something has caused us to restart already, (for # example, the user selects "resume seeding"). squelch # any automatic behaviour (#12462) return if self.get_state() in (u'downloading', u'offline'): self.restart() if self.get_state() in (u'uploading'): if self.manualUpload or self.get_upload_ratio() < 1.5: self.restart() else: self.stop_upload() | ab0784d4ca1dda43165e680f3637a973bcddbf4a /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/12354/ab0784d4ca1dda43165e680f3637a973bcddbf4a/downloader.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
7870,
67,
265,
67,
23939,
67,
430,
67,
17471,
12,
2890,
4672,
309,
389,
7813,
87,
18,
5332,
67,
856,
12,
2890,
18,
5761,
350,
4672,
468,
5943,
711,
15848,
584,
358,
7870,
1818,
16,
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,
7870,
67,
265,
67,
23939,
67,
430,
67,
17471,
12,
2890,
4672,
309,
389,
7813,
87,
18,
5332,
67,
856,
12,
2890,
18,
5761,
350,
4672,
468,
5943,
711,
15848,
584,
358,
7870,
1818,
16,
2... |
if t: geo.texcoords = t if i: geo.indices = i | if t: if type(t) is not list: t = [t] geo.texcoords[:] = t | def buildGeometry(type, v=None, c=None, n=None, t=None, i=None): geo = Geometry(type) if v: geo.vertices = v if c: geo.colors = c if n: geo.normals = n if t: geo.texcoords = t if i: geo.indices = i return geo | 9e3b1be1196ee74237421170dd27e384a9e31ad5 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/2798/9e3b1be1196ee74237421170dd27e384a9e31ad5/glscry.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1361,
9823,
12,
723,
16,
331,
33,
7036,
16,
276,
33,
7036,
16,
290,
33,
7036,
16,
268,
33,
7036,
16,
277,
33,
7036,
4672,
7856,
273,
8344,
12,
723,
13,
309,
331,
30,
7856,
18,
1747... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
9823,
12,
723,
16,
331,
33,
7036,
16,
276,
33,
7036,
16,
290,
33,
7036,
16,
268,
33,
7036,
16,
277,
33,
7036,
4672,
7856,
273,
8344,
12,
723,
13,
309,
331,
30,
7856,
18,
1747... |
ed = DateFromMx(end_date) | def get_graph(self, end_date, report_days, host=None, user=None, email=None): if email or host or user: return None | 0664df1f0b17740be9637ecca86984eaa336f0dd /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/87/0664df1f0b17740be9637ecca86984eaa336f0dd/untangle_server.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
67,
4660,
12,
2890,
16,
679,
67,
712,
16,
2605,
67,
9810,
16,
1479,
33,
7036,
16,
729,
33,
7036,
16,
2699,
33,
7036,
4672,
309,
2699,
578,
1479,
578,
729,
30,
327,
599,
2,
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,
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,
336,
67,
4660,
12,
2890,
16,
679,
67,
712,
16,
2605,
67,
9810,
16,
1479,
33,
7036,
16,
729,
33,
7036,
16,
2699,
33,
7036,
4672,
309,
2699,
578,
1479,
578,
729,
30,
327,
599,
2,
-10... | |
def __init__(data = None) | def __init__(data = None): | def __init__(data = None) if data == None: quickfix.StringField.__init__(self, 716) else quickfix.StringField.__init__(self, 716, 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,
780,
974,
16186,
2738,
972,
12,
2890,
16,
2371,
2313,
13,
469,
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,
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,
780,
974,
16186,
2738,
972,
12,
2890,
16,
2371,
2313,
13,
469,
9549,
904,
18,
780,
974,
16186,
2738,
... |
"""main function for the curses convenience wrapper Initialise the two main objects: the interpreter and the repl. The repl does what a repl does and lots of other cool stuff like syntax highlighting and stuff. I've tried to keep it well factored but it needs some tidying up, especially in separating the curses stuff from the rest of the repl. """ global stdscr global DO_RESIZE DO_RESIZE = False signal.signal( signal.SIGWINCH, lambda x,y: sigwinch(scr) ) loadrc() stdscr = scr curses.start_color() curses.use_default_colors() cols = make_colours() scr.timeout( 300 ) main_win, statusbar = init_wins( scr, cols ) interpreter = Interpreter() repl = Repl( main_win, interpreter, statusbar, idle ) repl._C = cols sys.stdout = repl sys.stderr = repl repl.repl() return repl.getstdout() o = curses.wrapper( main ) | """main function for the curses convenience wrapper Initialise the two main objects: the interpreter and the repl. The repl does what a repl does and lots of other cool stuff like syntax highlighting and stuff. I've tried to keep it well factored but it needs some tidying up, especially in separating the curses stuff from the rest of the repl. """ global stdscr global DO_RESIZE DO_RESIZE = False signal.signal( signal.SIGWINCH, lambda x,y: sigwinch(scr) ) loadrc() stdscr = scr curses.start_color() curses.use_default_colors() cols = make_colours() scr.timeout( 300 ) main_win, statusbar = init_wins( scr, cols ) interpreter = Interpreter() repl = Repl( main_win, interpreter, statusbar, idle ) repl._C = cols sys.stdout = repl sys.stderr = repl repl.repl() return repl.getstdout() tb = None try: o = curses.wrapper( main ) except: tb = traceback.format_exc() finally: stdscr.keypad(0) curses.echo() curses.nocbreak() curses.endwin() | def main( scr ): """main function for the curses convenience wrapper Initialise the two main objects: the interpreter and the repl. The repl does what a repl does and lots of other cool stuff like syntax highlighting and stuff. I've tried to keep it well factored but it needs some tidying up, especially in separating the curses stuff from the rest of the repl. """ global stdscr global DO_RESIZE DO_RESIZE = False signal.signal( signal.SIGWINCH, lambda x,y: sigwinch(scr) ) loadrc() stdscr = scr curses.start_color() curses.use_default_colors() cols = make_colours() scr.timeout( 300 ) main_win, statusbar = init_wins( scr, cols ) interpreter = Interpreter() repl = Repl( main_win, interpreter, statusbar, idle ) repl._C = cols sys.stdout = repl sys.stderr = repl repl.repl() return repl.getstdout() | c6361de06b71b20ac271f61d115e6c3b39ce82c6 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/6932/c6361de06b71b20ac271f61d115e6c3b39ce82c6/bpython.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2774,
12,
11991,
262,
30,
3536,
5254,
445,
364,
326,
30436,
13553,
4053,
225,
31739,
326,
2795,
2774,
2184,
30,
326,
16048,
471,
326,
6831,
18,
1021,
6831,
1552,
4121,
279,
6831,
1552,
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,
2774,
12,
11991,
262,
30,
3536,
5254,
445,
364,
326,
30436,
13553,
4053,
225,
31739,
326,
2795,
2774,
2184,
30,
326,
16048,
471,
326,
6831,
18,
1021,
6831,
1552,
4121,
279,
6831,
1552,
4... |
>>> msg1.locations | >>> msg2.locations | def update(self, template, fuzzy_matching=True): """Update the catalog based on the given template catalog. >>> from babel.messages import Catalog >>> template = Catalog() >>> template.add('blue', locations=[('main.py', 100)]) >>> template.add(('salad', 'salads'), locations=[('util.py', 42)]) >>> catalog = Catalog(locale='de_DE') >>> catalog.add('blue', u'blau', locations=[('main.py', 98)]) >>> catalog.add('head', u'Kopf', locations=[('util.py', 33)]) >>> catalog.add(('salad', 'salads'), (u'Salat', u'Salate'), ... locations=[('util.py', 38)]) >>> catalog.update(template) >>> len(catalog) 2 >>> msg1 = catalog['blue'] >>> msg1.string u'blau' >>> msg1.locations [('main.py', 100)] >>> msg2 = catalog['salad'] >>> msg2.string (u'Salat', u'Salate') >>> msg2.locations [('util.py', 42)] Messages that are in the catalog but not in the template are removed from the main collection, but can still be accessed via the `obsolete` member: >>> 'head' in catalog False >>> catalog.obsolete.values() [<Message 'head' (Flags: '')>] :param template: the reference catalog, usually read from a POT file :param fuzzy_matching: whether to use fuzzy matching of message IDs """ messages = self._messages self._messages = odict() | 4e62a83cc1f93e9fd80af0b02628bce30c068783 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/8909/4e62a83cc1f93e9fd80af0b02628bce30c068783/catalog.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1089,
12,
2890,
16,
1542,
16,
21315,
67,
16271,
33,
5510,
4672,
3536,
1891,
326,
6222,
2511,
603,
326,
864,
1542,
6222,
18,
225,
4080,
628,
26592,
18,
6833,
1930,
14953,
4080,
1542,
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,
1089,
12,
2890,
16,
1542,
16,
21315,
67,
16271,
33,
5510,
4672,
3536,
1891,
326,
6222,
2511,
603,
326,
864,
1542,
6222,
18,
225,
4080,
628,
26592,
18,
6833,
1930,
14953,
4080,
1542,
273,... |
invoice_domain.append(('id', '=', created_inv)) | invoice_domain.append(('id', 'in', created_inv)) | def compute_refund(self, cr, uid, ids, mode='refund', context=None): """ @param cr: the current row, from the database cursor, @param uid: the current user’s ID for security checks, @param ids: the account invoice refund’s ID or list of IDs | 6bc2e55c1f70f27f7f02ea2bb7eff4684ffc2780 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/7397/6bc2e55c1f70f27f7f02ea2bb7eff4684ffc2780/account_invoice_refund.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
3671,
67,
1734,
1074,
12,
2890,
16,
4422,
16,
4555,
16,
3258,
16,
1965,
2218,
1734,
1074,
2187,
819,
33,
7036,
4672,
3536,
632,
891,
4422,
30,
326,
783,
1027,
16,
628,
326,
2063,
3347,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3671,
67,
1734,
1074,
12,
2890,
16,
4422,
16,
4555,
16,
3258,
16,
1965,
2218,
1734,
1074,
2187,
819,
33,
7036,
4672,
3536,
632,
891,
4422,
30,
326,
783,
1027,
16,
628,
326,
2063,
3347,... |
ui.write("%s\n" % t) | ui.write("%s\n" % tag) | def branches(ui, repo, active=False): """list repository named branches List the repository's named branches, indicating which ones are inactive. If active is specified, only show active branches. A branch is considered active if it contains unmerged heads. Use the command 'hg update' to switch to an existing branch. """ b = repo.branchtags() heads = dict.fromkeys(repo.heads(), 1) l = [((n in heads), repo.changelog.rev(n), n, t) for t, n in b.items()] l.sort() l.reverse() for ishead, r, n, t in l: if active and not ishead: # If we're only displaying active branches, abort the loop on # encountering the first inactive head break else: hexfunc = ui.debugflag and hex or short if ui.quiet: ui.write("%s\n" % t) else: spaces = " " * (30 - util.locallen(t)) # The code only gets here if inactive branches are being # displayed or the branch is active. isinactive = ((not ishead) and " (inactive)") or '' ui.write("%s%s %s:%s%s\n" % (t, spaces, r, hexfunc(n), isinactive)) | 8e8d29fe6aed94e83d5d9dfabf0e0f42fbc9c3fc /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/11312/8e8d29fe6aed94e83d5d9dfabf0e0f42fbc9c3fc/commands.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
11483,
12,
4881,
16,
3538,
16,
2695,
33,
8381,
4672,
3536,
1098,
3352,
4141,
11483,
225,
987,
326,
3352,
1807,
4141,
11483,
16,
11193,
1492,
5945,
854,
16838,
18,
225,
971,
2695,
353,
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,
11483,
12,
4881,
16,
3538,
16,
2695,
33,
8381,
4672,
3536,
1098,
3352,
4141,
11483,
225,
987,
326,
3352,
1807,
4141,
11483,
16,
11193,
1492,
5945,
854,
16838,
18,
225,
971,
2695,
353,
12... |
J -- a quaternion ideal. OUTPUT: - a quaternionic fractional ideal. | - ``J`` -- a quaternion ideal. OUTPUT: a quaternionic fractional ideal. | def multiply_by_conjugate(self, J): """ Return product of self and the conjugate Jbar of J. | b7a16ed05ab1759a61c3840607275d6cd5b220a1 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9890/b7a16ed05ab1759a61c3840607275d6cd5b220a1/quaternion_algebra.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
10194,
67,
1637,
67,
591,
78,
31529,
12,
2890,
16,
804,
4672,
3536,
2000,
3017,
434,
365,
471,
326,
10550,
31529,
804,
3215,
434,
804,
18,
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,
10194,
67,
1637,
67,
591,
78,
31529,
12,
2890,
16,
804,
4672,
3536,
2000,
3017,
434,
365,
471,
326,
10550,
31529,
804,
3215,
434,
804,
18,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
[(3, [(0, 0, 1, -6/7)], 1), (2, [(0, 1, 0, 17/7)], 2)] | [(3, [ (0, 0, 1, -6/7) ], 1), (2, [ (0, 1, 0, 17/7) ], 2)] | def eigenvectors(self,extend=True): """ Computes the subspace of eigenvectors of a given eigenvalue. | 008040e2ed037beda080180d1d6162300fff207d /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/9417/008040e2ed037beda080180d1d6162300fff207d/free_module_morphism.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
11043,
29098,
12,
2890,
16,
14313,
33,
5510,
4672,
3536,
14169,
281,
326,
720,
2981,
434,
11043,
29098,
434,
279,
864,
16719,
1132,
18,
2,
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,
11043,
29098,
12,
2890,
16,
14313,
33,
5510,
4672,
3536,
14169,
281,
326,
720,
2981,
434,
11043,
29098,
434,
279,
864,
16719,
1132,
18,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
self._dragging = True | def on_mouse_release(self, x, y, button, modifiers): self._dragging = False self._drag_start = None lx, ly = self.position | c6e6cbe08305873a75f65c8572d395a52598b4f8 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/7473/c6e6cbe08305873a75f65c8572d395a52598b4f8/editor.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
603,
67,
11697,
67,
9340,
12,
2890,
16,
619,
16,
677,
16,
3568,
16,
10429,
4672,
365,
6315,
15997,
1998,
273,
1083,
365,
6315,
15997,
67,
1937,
273,
599,
15855,
16,
18519,
273,
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,
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,
603,
67,
11697,
67,
9340,
12,
2890,
16,
619,
16,
677,
16,
3568,
16,
10429,
4672,
365,
6315,
15997,
1998,
273,
1083,
365,
6315,
15997,
67,
1937,
273,
599,
15855,
16,
18519,
273,
365,
18... | |
>>> if old is not None: ... sys.modules['zope.app.layers'] = old | >>> sys.modules['zope.app.layers'] = old | ... def resolve(self, path): | 0437228b54d73af25b4a383d5609ee2c3d4b1fad /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/9537/0437228b54d73af25b4a383d5609ee2c3d4b1fad/back35.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1372,
377,
1652,
2245,
12,
2890,
16,
589,
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,
... | [
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,
0... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1372,
377,
1652,
2245,
12,
2890,
16,
589,
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,... |
res = self.ReplicaManager.getCatalogFileMetadata(checksumToObtain) if not res['OK']: gLogger.error("[%s] __validateChecksums: Failed to obtain file checksums" % se) | res = self.ReplicaManager.getCatalogFileMetadata( checksumToObtain ) if not res['OK']: gLogger.error( "[%s] __validateChecksums: Failed to obtain file checksums" % se ) | def __validateChecksums(self,se, migratedFileIDs,migratingFiles): """ Obtain the checksums in the catalog if not present and check against the checksum from the storage """ lfnFileID = {} checksumToObtain = [] for fileID in migratedFileIDs.keys(): if not migratingFiles[fileID]['Checksum']: lfn = migratingFiles[fileID]['LFN'] checksumToObtain.append(lfn) lfnFileID[lfn] = fileID if checksumToObtain: res = self.ReplicaManager.getCatalogFileMetadata(checksumToObtain) if not res['OK']: gLogger.error("[%s] __validateChecksums: Failed to obtain file checksums" % se) return res for lfn,error in res['Value']['Failed'].items(): gLogger.error("[%s] __validateChecksums: Failed to get file checksum" % se,"%s %s" % (lfn,error)) for lfn,metadata in res['Value']['Successful'].items(): migratingFiles[lfnFileID[lfn]]['Checksum'] = metadata['CheckSumValue'] mismatchFiles = [] matchFiles = [] checksumMismatches = [] fileRecords = [] for fileID,seChecksum in migratedFileIDs.items(): lfn = migratingFiles[fileID]['LFN'] catalogChecksum = migratingFiles[fileID]['Checksum'] if not seChecksum: gLogger.error("[%s] __validateChecksums: Storage checksum not available" % se, migratingFiles[fileID]['PFN']) elif not compareAdler(seChecksum,catalogChecksum): gLogger.error("[%s] __validateChecksums: Storage and catalog checksum mismatch" % se,"%s '%s' '%s'" % (migratingFiles[fileID]['PFN'],seChecksum,catalogChecksum)) mismatchFiles.append(fileID) pfn = migratingFiles[fileID]['PFN'] se = migratingFiles[fileID]['SE'] checksumMismatches.append((lfn,pfn,se,'CatalogPFNChecksumMismatch')) fileRecords.append((lfn,'Checksum match','%s@%s' % (seChecksum,se),'','MigrationMonitoringAgent')) else: fileRecords.append((lfn,'Checksum mismatch','%s@%s' % (seChecksum,se),'','MigrationMonitoringAgent')) matchFiles.append(fileID) # Add the data logging records self.DataLog.addFileRecords(fileRecords) if checksumMismatches: # Update the (mis)matching checksums (in the integrityDB and) in the migration monitoring db self.__reportProblematicReplicas(checksumMismatches) res = self.MigrationMonitoringDB.setMigratingReplicaStatus(mismatchFiles,'ChecksumFail') if not res['OK']: gLogger.error("[%s] __validateChecksums: Failed to update checksum mismatching files." % se, res['Message']) if matchFiles: res = self.MigrationMonitoringDB.setMigratingReplicaStatus(matchFiles,'ChecksumMatch') if not res['OK']: gLogger.error("[%s] __validateChecksums: Failed to update checksum mismatching files." % se, res['Message']) resDict = {'MatchingFiles':matchFiles,'MismatchFiles':mismatchFiles} return S_OK(resDict) | d0365a9152f6e7105162edd475d5401448bfdaed /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12864/d0365a9152f6e7105162edd475d5401448bfdaed/MigrationMonitoringAgent.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
5662,
10723,
87,
12,
2890,
16,
307,
16,
24741,
812,
5103,
16,
81,
2757,
1776,
2697,
4672,
3536,
24850,
326,
26829,
316,
326,
6222,
309,
486,
3430,
471,
866,
5314,
326,
6697,
628,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
5662,
10723,
87,
12,
2890,
16,
307,
16,
24741,
812,
5103,
16,
81,
2757,
1776,
2697,
4672,
3536,
24850,
326,
26829,
316,
326,
6222,
309,
486,
3430,
471,
866,
5314,
326,
6697,
628,
... |
The iterator changes state of interenal variables and objects. | The iterator changes state of internal variables and objects. | def iterator(self, name): ''' An iterator over the values of a certain name. The iterator changes state of interenal variables and objects. When calling get_value in a loop, this will result each time in a different value. ''' if name == 'record': for self.recID in self.recIDs: self.record = get_record(self.recID) if self.preprocess: self.preprocess(self.record) yield str(self.recID) else: full_object = self.build_object(name) level = self.determine_level(name) for new_object in record_parts(full_object, level): self.memory[name]['object'] = new_object #parent has changed state; also set childs state to None; for children_name in self.memory[name]['children']: self.memory[children_name]['object'] = None yield new_object #the result for a call of the same name after an iterator should be the same as if there was no iterator called before self.memory[name]['object'] = None | 932a351453bac35d2c0cc1754d586e0f9f7026dd /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/2763/932a351453bac35d2c0cc1754d586e0f9f7026dd/bibformat_bfx_engine.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2775,
12,
2890,
16,
508,
4672,
9163,
1922,
2775,
1879,
326,
924,
434,
279,
8626,
508,
18,
1021,
2775,
3478,
919,
434,
2713,
3152,
471,
2184,
18,
5203,
4440,
336,
67,
1132,
316,
279,
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,
2775,
12,
2890,
16,
508,
4672,
9163,
1922,
2775,
1879,
326,
924,
434,
279,
8626,
508,
18,
1021,
2775,
3478,
919,
434,
2713,
3152,
471,
2184,
18,
5203,
4440,
336,
67,
1132,
316,
279,
27... |
op.add_option('--args', dest='shell_args', | op.add_option('--args', dest='shell_args', default='', | def run_tests(tests, results): """Run the given tests, sending raw results to the given results accumulator.""" pb = None if not OPTIONS.hide_progress: try: from progressbar import ProgressBar pb = ProgressBar('', len(tests), 16) except ImportError: pass results.pb = pb test_list = [ TestTask(test) for test in tests ] pipeline = Source(test_list, results, False) results.finished = pipeline.start(OPTIONS.worker_count) if pb: pb.finish() if not OPTIONS.tinderbox: results.list() | d0ce6eff2c244f3101eb287025d8750da846cbbc /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/11102/d0ce6eff2c244f3101eb287025d8750da846cbbc/jstests.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1086,
67,
16341,
12,
16341,
16,
1686,
4672,
3536,
1997,
326,
864,
7434,
16,
5431,
1831,
1686,
358,
326,
864,
1686,
13514,
12123,
6386,
273,
599,
309,
486,
16726,
18,
11248,
67,
8298,
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,
1086,
67,
16341,
12,
16341,
16,
1686,
4672,
3536,
1997,
326,
864,
7434,
16,
5431,
1831,
1686,
358,
326,
864,
1686,
13514,
12123,
6386,
273,
599,
309,
486,
16726,
18,
11248,
67,
8298,
30,... |
down_vector[down_max + 1] = -1 | down_vector[self.downoff + down_max + 1] = -1 | def _findSMS(self, a_lower, a_upper, b_lower, b_upper, find_minimal): """ Finds the Shortest Middle Snake. """ down_vector = self.fdiag # The vector for the (0, 0) to (x, y) search up_vector = self.bdiag # The vector for the (u, v) to (N, M) search | 97543e17e72ffa73040dbf9d8592f08aa6cf12c3 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/1600/97543e17e72ffa73040dbf9d8592f08aa6cf12c3/myersdiff.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
4720,
29533,
12,
2890,
16,
279,
67,
8167,
16,
279,
67,
5797,
16,
324,
67,
8167,
16,
324,
67,
5797,
16,
1104,
67,
1154,
2840,
4672,
3536,
4163,
87,
326,
7925,
395,
490,
3132,
189... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4720,
29533,
12,
2890,
16,
279,
67,
8167,
16,
279,
67,
5797,
16,
324,
67,
8167,
16,
324,
67,
5797,
16,
1104,
67,
1154,
2840,
4672,
3536,
4163,
87,
326,
7925,
395,
490,
3132,
189... |
ids = [ids] | ids = [ids] | def write(self, cr, uid, ids, vals, context={}): | 5bd1f2197b1e0f8a0d5ad71259e8b33593c011a5 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/7397/5bd1f2197b1e0f8a0d5ad71259e8b33593c011a5/ir_ui_view.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1045,
12,
2890,
16,
4422,
16,
4555,
16,
3258,
16,
5773,
16,
819,
12938,
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,
... | [
1,
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,
1045,
12,
2890,
16,
4422,
16,
4555,
16,
3258,
16,
5773,
16,
819,
12938,
4672,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-10... |
name_len = config.get('stgit.namelength') | name_len = config.getint('stgit.namelength') | def patch_name_from_msg(msg): """Return a string to be used as a patch name. This is generated from the top line of the string passed as argument.""" if not msg: return None name_len = config.get('stgit.namelength') if not name_len: name_len = 30 subject_line = msg.split('\n', 1)[0].lstrip().lower() return re.sub('[\W]+', '-', subject_line).strip('-')[:name_len] | 7e20ab3a7194a445408261f7c1949f655f355acf /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/12366/7e20ab3a7194a445408261f7c1949f655f355acf/utils.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
4729,
67,
529,
67,
2080,
67,
3576,
12,
3576,
4672,
3536,
990,
279,
533,
358,
506,
1399,
487,
279,
4729,
508,
18,
1220,
353,
4374,
628,
326,
1760,
980,
434,
326,
533,
2275,
487,
1237,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4729,
67,
529,
67,
2080,
67,
3576,
12,
3576,
4672,
3536,
990,
279,
533,
358,
506,
1399,
487,
279,
4729,
508,
18,
1220,
353,
4374,
628,
326,
1760,
980,
434,
326,
533,
2275,
487,
1237,
... |
inspector_html_name = argv[1] devtools_html_name = argv[2] | inspector_html_name = argv[2] devtools_html_name = argv[3] | def main(argv): if len(argv) < 4: print 'usage: %s inspector_html devtools_html css_and_js_files_list' % argv[0] return 1 inspector_html_name = argv[1] devtools_html_name = argv[2] inspector_html = open(inspector_html_name, 'r') devtools_html = open(devtools_html_name, 'w') for line in inspector_html: if '</head>' in line: devtools_html.write('\n <!-- The following lines are added to include DevTools resources -->\n') for resource in argv[3:]: devtools_html.write(GenerateIncludeTag(resource)) devtools_html.write(' <!-- End of auto-added files list -->\n') devtools_html.write(line) devtools_html.close() inspector_html.close() # Touch output file directory to make sure that Xcode will copy # modified resource files. if sys.platform == 'darwin': output_dir_name = os.path.dirname(devtools_html_name) os.utime(output_dir_name, None) | f54d1fe210e3b03b65b61bff6cdce08b8fbc10e5 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/5060/f54d1fe210e3b03b65b61bff6cdce08b8fbc10e5/generate_devtools_html.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2774,
12,
19485,
4672,
225,
309,
562,
12,
19485,
13,
411,
1059,
30,
1172,
296,
9167,
30,
738,
87,
22700,
67,
2620,
4461,
6642,
67,
2620,
3747,
67,
464,
67,
2924,
67,
2354,
67,
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,
2774,
12,
19485,
4672,
225,
309,
562,
12,
19485,
13,
411,
1059,
30,
1172,
296,
9167,
30,
738,
87,
22700,
67,
2620,
4461,
6642,
67,
2620,
3747,
67,
464,
67,
2924,
67,
2354,
67,
1098,
... |
vbox.pack_start(checkbutton) | vbox.pack_start(checkbutton, expand=False, fill=False) | def create_ui(self): vbox = gtk.VBox(spacing=5) vbox.set_border_width(5) self.vbox.add(vbox) | f0fe4bbf25557633d73b2b6baaa91816f3fd690f /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/4596/f0fe4bbf25557633d73b2b6baaa91816f3fd690f/gtkui.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
752,
67,
4881,
12,
2890,
4672,
331,
2147,
273,
22718,
18,
58,
3514,
12,
14080,
33,
25,
13,
331,
2147,
18,
542,
67,
8815,
67,
2819,
12,
25,
13,
365,
18,
90,
2147,
18,
1289,
12,
90,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
752,
67,
4881,
12,
2890,
4672,
331,
2147,
273,
22718,
18,
58,
3514,
12,
14080,
33,
25,
13,
331,
2147,
18,
542,
67,
8815,
67,
2819,
12,
25,
13,
365,
18,
90,
2147,
18,
1289,
12,
90,
... |
desBegIJ = numpy.around(numpy.subtract(desCtrIJ, numpy.divide(sizeIJ, 2.0))).astype(numpy.Long) | desBegIJ = numpy.around(numpy.subtract(desCtrIJ, numpy.divide(sizeIJ, 2.0))).astype(numpy.int) | def _updImBounds(self, desCtrIJ=None, updZoom=True): """Update self.begIJ, self.endIJ and (if desired) self.zoomFac based on self.zoomFac and self.frameShape. Inputs: - updZoom: if True, zoom is increased if necessary so that the image fills x or y """ #print "self._updImBounds(desCtrIJ=%s, updZoom=%s)" % (desCtrIJ, updZoom) if self.dataArr == None: return if not updZoom: if desCtrIJ == None: desCtrIJ = numpy.divide(numpy.add(self.endIJ, self.begIJ), 2.0) desSizeIJ = numpy.around(numpy.divide(self.frameShape[::-1], float(self.zoomFac))).astype(numpy.Long) sizeIJ = numpy.minimum(self.dataArr.shape, desSizeIJ) desBegIJ = numpy.around(numpy.subtract(desCtrIJ, numpy.divide(sizeIJ, 2.0))).astype(numpy.Long) self.begIJ = numpy.minimum(numpy.maximum(desBegIJ, (0,0)), numpy.subtract(self.dataArr.shape, sizeIJ)) self.endIJ = self.begIJ + sizeIJ | 97a5bfc91d51810d69ef9055899872a03ff0995a /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/6353/97a5bfc91d51810d69ef9055899872a03ff0995a/GrayImageDispWdg.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
5533,
1170,
5694,
12,
2890,
16,
2832,
39,
313,
45,
46,
33,
7036,
16,
2166,
11497,
33,
5510,
4672,
3536,
1891,
365,
18,
70,
1332,
45,
46,
16,
365,
18,
409,
45,
46,
471,
261,
43... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
5533,
1170,
5694,
12,
2890,
16,
2832,
39,
313,
45,
46,
33,
7036,
16,
2166,
11497,
33,
5510,
4672,
3536,
1891,
365,
18,
70,
1332,
45,
46,
16,
365,
18,
409,
45,
46,
471,
261,
43... |
reactor.connectSSL(host, port, bf, timeout) | from twisted.internet import ssl reactor.connectSSL(host, port, bf, ssl.ClientContextFactory(), timeout) | def getObjectAtSSL(host, port, timeout=None): """Establishes a PB connection over SSL and returns with a RemoteReference. @param host: the host to connect to @param port: the port number to connect to @param timeout: a value in milliseconds to wait before failing by default. (OPTIONAL) @returns: A Deferred which will be passed a remote reference to the root object of a PB server.x """ bf, d = getObjectRetriever() reactor.connectSSL(host, port, bf, timeout) return d | 139f1cfcc420d59daac07ab253996d981ad21a53 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12595/139f1cfcc420d59daac07ab253996d981ad21a53/pb.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
6455,
861,
6745,
12,
2564,
16,
1756,
16,
225,
2021,
33,
7036,
4672,
3536,
9122,
23385,
281,
279,
20819,
1459,
1879,
7419,
471,
1135,
598,
279,
6304,
2404,
18,
225,
632,
891,
1479,
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,
6455,
861,
6745,
12,
2564,
16,
1756,
16,
225,
2021,
33,
7036,
4672,
3536,
9122,
23385,
281,
279,
20819,
1459,
1879,
7419,
471,
1135,
598,
279,
6304,
2404,
18,
225,
632,
891,
1479,
30,
... |
str = self._table_header(heading) | str = self._table_header(heading, 'summary') | def _var_summary(self, variables, heading='Variable Summary'): 'Return a summary of the variables in a class or module' variables = self._sort(variables) if len(variables) == 0: return '' str = self._table_header(heading) | 07991a6224980123acb6be68dd2d39634e5ac591 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/3512/07991a6224980123acb6be68dd2d39634e5ac591/html.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
1401,
67,
7687,
12,
2890,
16,
3152,
16,
11053,
2218,
3092,
17967,
11,
4672,
296,
990,
279,
4916,
434,
326,
3152,
316,
279,
667,
578,
1605,
11,
3152,
273,
365,
6315,
3804,
12,
7528... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1401,
67,
7687,
12,
2890,
16,
3152,
16,
11053,
2218,
3092,
17967,
11,
4672,
296,
990,
279,
4916,
434,
326,
3152,
316,
279,
667,
578,
1605,
11,
3152,
273,
365,
6315,
3804,
12,
7528... |
sel = Numeric.compress(a, arr[i]).tolist() | sel = Numeric.compress(a, arr[i]) sel = Numeric.compress(Numeric.where(sel != 1e20, 1, 0), sel).tolist() | def __call__(self, attr, data): # if the data changed clear the attribute values if data != self.data: self.attrInfo = {} self.data = data | 741aff74ddc579ee2c89c421ff0b119d80c313f0 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/6366/741aff74ddc579ee2c89c421ff0b119d80c313f0/OWVisAttrSelection.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
1991,
972,
12,
2890,
16,
1604,
16,
501,
4672,
468,
309,
326,
501,
3550,
2424,
326,
1566,
924,
309,
501,
480,
365,
18,
892,
30,
365,
18,
1747,
966,
273,
2618,
365,
18,
892,
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,
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,
1991,
972,
12,
2890,
16,
1604,
16,
501,
4672,
468,
309,
326,
501,
3550,
2424,
326,
1566,
924,
309,
501,
480,
365,
18,
892,
30,
365,
18,
1747,
966,
273,
2618,
365,
18,
892,
273,... |
except Exception, e: print e | except Exception: traceback.print_exc() | def run_test(get_atoms, get_calculator, name, fmax=0.05, steps=100, plot=True): plotter = Plotter(name, fmax) csvwriter = CSVWriter(name) for optimizer in optimizers: note = '' logname = name + '-' + optimizer atoms = get_atoms() atoms.set_calculator(get_calculator()) opt = get_optimizer(optimizer) relax = opt(atoms, logfile=None) #logfile = logname + '.log', #trajectory = logname + '.traj') obs = DataObserver(atoms) relax.attach(obs) try: relax.run(fmax = fmax, steps = steps) E = atoms.get_potential_energy() if relax.get_number_of_steps() == steps: note = 'Not converged in %i steps' % steps except Exception, e: print e note = 'An exception occurred' E = np.nan nsteps = relax.get_number_of_steps() if hasattr(relax, 'force_calls'): fc = relax.force_calls if rank == 0: print '%-15s %-15s %3i %8.3f (%3i) %s' % (name, optimizer, nsteps, E, fc, note) else: fc = nsteps if rank == 0: print '%-15s %-15s %3i %8.3f %s' % (name, optimizer, nsteps, E, note) plotter.plot(optimizer, obs.get_E(), obs.get_fmax()) csvwriter.write(optimizer, nsteps, E, fc, note) plotter.save() csvwriter.finalize() | b7be3390fbf8e9486a1e1c22421aba234dffb1ea /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/5735/b7be3390fbf8e9486a1e1c22421aba234dffb1ea/__init__.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1086,
67,
3813,
12,
588,
67,
14937,
16,
336,
67,
12780,
639,
16,
508,
16,
284,
1896,
33,
20,
18,
6260,
16,
6075,
33,
6625,
16,
3207,
33,
5510,
4672,
225,
3207,
387,
273,
15211,
387,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
3813,
12,
588,
67,
14937,
16,
336,
67,
12780,
639,
16,
508,
16,
284,
1896,
33,
20,
18,
6260,
16,
6075,
33,
6625,
16,
3207,
33,
5510,
4672,
225,
3207,
387,
273,
15211,
387,
... |
elif self.config['quality'] == "hd": quality = "&fmt=22" | def get_file_url(self): """ returns the absolute downloadable filepath """ if self.html == None: self.download_html() | a02a3ecd5b23b5380cf41e161f02a044d1db00af /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/9838/a02a3ecd5b23b5380cf41e161f02a044d1db00af/YoutubeCom.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
67,
768,
67,
718,
12,
2890,
4672,
3536,
1135,
326,
4967,
4224,
429,
3608,
3536,
309,
365,
18,
2620,
422,
599,
30,
365,
18,
7813,
67,
2620,
1435,
2,
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,
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... | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
67,
768,
67,
718,
12,
2890,
4672,
3536,
1135,
326,
4967,
4224,
429,
3608,
3536,
309,
365,
18,
2620,
422,
599,
30,
365,
18,
7813,
67,
2620,
1435,
2,
-100,
-100,
-100,
-100,
-100,
... | |
flags = [re.IGNORECASE] | flags = re.IGNORECASE | sage: 'divisors' in _search_src_or_doc('src', '^ *def prime', interact=False) | 2d8dd972b7654687a2e8843501b1e511c530c8b7 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/9890/2d8dd972b7654687a2e8843501b1e511c530c8b7/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... |
while (ppow <= prec): | while (ppow < prec): | def eisenstein_series_qexp(k, prec=10, K=QQ): r""" Return the $q$-expansion of the weight $k$ Eisenstein series to precision prec in the field $K$. Here's a rough description of how the algorithm works: we know $E_k = const + \sum_n sigma(n,k-1) q^n$. Now, we basically just compute all the $\sigma(n,k-1)$ simultaneously, as $\sigma$ is multiplicative. INPUT: k -- even positive integer prec -- nonnegative integer K -- a ring in which B_k/(2*k) is invertible EXAMPLES: sage: eisenstein_series_qexp(2,5) -1/24 + q + 3*q^2 + 4*q^3 + 7*q^4 + O(q^5) sage: eisenstein_series_qexp(2,0) O(q^0) AUTHORS: -- William Stein: original implementation -- Craig Citro (2007-06-01): rewrote for massive speedup """ k = Integer(k) if k%2 or k < 2: raise ValueError, "k (=%s) must be an even positive integer"%k precision = Integer(prec) if precision < 0: raise ValueError, "prec (=%s) must an even nonnegative integer"%prec R = K[['q']] one = Integer(1) val = [one] * (prec + 1) pow = 0 ind = 0 term = 0 expt = k - one for p in prime_range(1,prec+1): int_p = int(p) ppow = int_p mult = p**expt term = mult*mult last = mult while (ppow <= prec): ind = ppow while (ind <= prec): val[ind] = val[ind] * (term - one) // (last - one) ind += ppow ppow *= int_p last = term term *= mult val[0] = [-bernoulli(k) / (2*k)] return R(val, precision) | fb14894ed883dbcefa08f66508ec84fba4e217b4 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/9890/fb14894ed883dbcefa08f66508ec84fba4e217b4/eis_series.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
425,
291,
275,
334,
13685,
67,
10222,
67,
85,
2749,
12,
79,
16,
13382,
33,
2163,
16,
1475,
33,
53,
53,
4672,
436,
8395,
2000,
326,
271,
85,
8,
17,
2749,
12162,
434,
326,
3119,
271,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
425,
291,
275,
334,
13685,
67,
10222,
67,
85,
2749,
12,
79,
16,
13382,
33,
2163,
16,
1475,
33,
53,
53,
4672,
436,
8395,
2000,
326,
271,
85,
8,
17,
2749,
12162,
434,
326,
3119,
271,
... |
self._name = 'PY_VAR' + repr(_varnum) _varnum = _varnum + 1 self.set(self._default) | if name: self._name = name else: self._name = 'PY_VAR' + `_varnum` _varnum += 1 if value != None: self.set(value) elif not self._tk.call("info", "exists", self._name): self.set(self._default) | def __init__(self, master=None): """Construct a variable with an optional MASTER as master widget. The variable is named PY_VAR_number in Tcl. """ global _varnum if not master: master = _default_root self._master = master self._tk = master.tk self._name = 'PY_VAR' + repr(_varnum) _varnum = _varnum + 1 self.set(self._default) | 72daca43c49dee94d35b25084bba9045bd6d0f49 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/3187/72daca43c49dee94d35b25084bba9045bd6d0f49/Tkinter.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
16,
4171,
33,
7036,
4672,
3536,
7249,
279,
2190,
598,
392,
3129,
27312,
487,
4171,
3604,
18,
1021,
2190,
353,
4141,
12191,
67,
7716,
67,
2696,
316,
399,
830,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
4171,
33,
7036,
4672,
3536,
7249,
279,
2190,
598,
392,
3129,
27312,
487,
4171,
3604,
18,
1021,
2190,
353,
4141,
12191,
67,
7716,
67,
2696,
316,
399,
830,
... |
wrap_encoder.unwrap_spec = [ObjSpace, unicode, str] | wrap_encoder.unwrap_spec = [ObjSpace, unicode, 'str_or_None'] | def wrap_encoder(space, uni, errors="strict"): state = space.fromcache(CodecState) func = getattr(runicode, rname) result = func(uni, len(uni), errors, state.encode_error_handler) return space.newtuple([space.wrap(result), space.wrap(len(uni))]) | 9866a202f3fc5ddc35c962319d0bd6ccdc40347e /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/6934/9866a202f3fc5ddc35c962319d0bd6ccdc40347e/interp_codecs.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
2193,
67,
16480,
12,
2981,
16,
7738,
16,
1334,
1546,
13948,
6,
4672,
919,
273,
3476,
18,
2080,
2493,
12,
11008,
1119,
13,
1326,
273,
3869,
12,
2681,
3487,
16,
436,
529,
13,
563,
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,
2193,
67,
16480,
12,
2981,
16,
7738,
16,
1334,
1546,
13948,
6,
4672,
919,
273,
3476,
18,
2080,
2493,
12,
11008,
1119,
13,
1326,
273,
3869,
12,
2681,
3487,
16,
436,
529,
13,
563,
273,
... |
def refill_slots(self, pushed_color): | def refill_slots(self, *junk): | def refill_slots(self, pushed_color): for hsv,slot in zip(self.app.ch.colors, reversed(self.slots)): slot.set_color(hsv) | 7325221e684934ffa9b96e815915fc7c97119d69 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/7129/7325221e684934ffa9b96e815915fc7c97119d69/colorsamplerwindow.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1278,
737,
67,
18875,
12,
2890,
16,
380,
78,
1683,
4672,
364,
30785,
16,
14194,
316,
3144,
12,
2890,
18,
2910,
18,
343,
18,
9724,
16,
9553,
12,
2890,
18,
18875,
3719,
30,
4694,
18,
5... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1278,
737,
67,
18875,
12,
2890,
16,
380,
78,
1683,
4672,
364,
30785,
16,
14194,
316,
3144,
12,
2890,
18,
2910,
18,
343,
18,
9724,
16,
9553,
12,
2890,
18,
18875,
3719,
30,
4694,
18,
5... |
lib_link=None): | lib_link=None, broken_bond_i_seq_pairs=None): | def __init__(self, counters, m_i, m_j, chir_list, chirality_proxy_registry, special_position_indices, chir_volume_esd, lib_link=None): self.counters = counters self.counters.unsupported_volume_sign = dicts.with_default_value(0) if (m_j is None): m_c,m_1,m_2,m_3 = m_i,m_i,m_i,m_i else: assert m_i.i_conformer == m_j.i_conformer stage_1 = m_i.pdb_residue.chain.conformer.model.stage_1 for chir in chir_list: if (m_j is not None): m_c,m_1,m_2,m_3 = [(m_i, m_j)[comp_id-1] for comp_id in ( chir.atom_centre_comp_id, chir.atom_1_comp_id, chir.atom_2_comp_id, chir.atom_3_comp_id)] volume_sign = chir.volume_sign if (volume_sign is not None): volume_sign = volume_sign[:4].lower() if (volume_sign not in ["posi", "nega", "both"]): counters.unsupported_volume_sign[volume_sign] += 1 continue if ( not m_c.monomer_atom_dict.has_key(chir.atom_id_centre) or not m_1.monomer_atom_dict.has_key(chir.atom_id_1) or not m_2.monomer_atom_dict.has_key(chir.atom_id_2) or not m_3.monomer_atom_dict.has_key(chir.atom_id_3)): counters.corrupt_monomer_library_definitions += 1 continue i_seqs = (m_c.expected_atom_i_seqs.get(chir.atom_id_centre, None), m_1.expected_atom_i_seqs.get(chir.atom_id_1, None), m_2.expected_atom_i_seqs.get(chir.atom_id_2, None), m_3.expected_atom_i_seqs.get(chir.atom_id_3, None)) if (None in i_seqs): if ( m_c.monomer_atom_dict[chir.atom_id_centre].type_symbol == "H" or m_1.monomer_atom_dict[chir.atom_id_1].type_symbol == "H" or m_2.monomer_atom_dict[chir.atom_id_2].type_symbol == "H" or m_3.monomer_atom_dict[chir.atom_id_3].type_symbol == "H"): counters.unresolved_hydrogen += 1 else: counters.unresolved_non_hydrogen += 1 elif ( volume_sign is None or chir_volume_esd in [None, 0]): counters.undefined += 1 else: if (m_j is None): volume_ideal = m_i.monomer.get_chir_volume_ideal(chir) else: volume_ideal = lib_link.get_chir_volume_ideal( m_i.monomer, m_j.monomer, chir) if (volume_ideal is None): counters.undefined += 1 else: counters.resolved += 1 if (involves_special_positions(special_position_indices, i_seqs)): counters.discarded_because_of_special_positions += 1 else: registry_process_result = chirality_proxy_registry.process( source_info=source_info_server(m_i=m_i, m_j=m_j), proxy=geometry_restraints.chirality_proxy( i_seqs=i_seqs, volume_ideal=volume_ideal, both_signs=(volume_sign == "both"), weight=1/chir_volume_esd**2)) evaluate_registry_process_result( proxy_label="chirality", m_i=m_i, m_j=m_j, i_seqs=i_seqs, registry_process_result=registry_process_result) | b658df9726b7aae32f2fe28cdcb3e4e5459f257c /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/696/b658df9726b7aae32f2fe28cdcb3e4e5459f257c/pdb_interpretation.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
16,
13199,
16,
312,
67,
77,
16,
312,
67,
78,
16,
462,
481,
67,
1098,
16,
462,
481,
7919,
67,
5656,
67,
9893,
16,
4582,
67,
3276,
67,
6836,
16,
462,
481,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
13199,
16,
312,
67,
77,
16,
312,
67,
78,
16,
462,
481,
67,
1098,
16,
462,
481,
7919,
67,
5656,
67,
9893,
16,
4582,
67,
3276,
67,
6836,
16,
462,
481,
... |
def adjust_positions(self, old, new): | def adjust_positions(self, old, new): | def adjust_positions(self, old, new): p1, p2 = old[self.indices] d = p2 - p1 p = sqrt(npy.dot(d, d)) q1, q2 = new[self.indices] d = q2 - q1 q = sqrt(npy.dot(d, d)) d *= 0.5 * (p - q) / q new[self.indices] = (q1 - d, q2 + d) | 5bac38bedcb66411fb5aa63e0ddfa49f73f07202 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/5735/5bac38bedcb66411fb5aa63e0ddfa49f73f07202/constraints.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
5765,
67,
12388,
12,
2890,
16,
1592,
16,
394,
4672,
293,
21,
16,
293,
22,
273,
1592,
63,
2890,
18,
6836,
65,
302,
273,
293,
22,
300,
293,
21,
293,
273,
5700,
12,
82,
2074,
18,
9811... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
5765,
67,
12388,
12,
2890,
16,
1592,
16,
394,
4672,
293,
21,
16,
293,
22,
273,
1592,
63,
2890,
18,
6836,
65,
302,
273,
293,
22,
300,
293,
21,
293,
273,
5700,
12,
82,
2074,
18,
9811... |
'leading_path' : None, | 'leading_path' : '', | def fileInfo(filepath, product): """Extract information about a release file. Returns a dictionary with the following keys set: 'product', 'version', 'locale', 'platform', 'contents', 'format', 'pathstyle' 'contents' is one of 'complete', 'installer' 'format' is one of 'mar' or 'exe' 'pathstyle' is either 'short' or 'long', and refers to if files are all in one directory, with the locale as part of the filename ('short' paths, firefox 3.0 style filenames), or if the locale names are part of the directory structure, but not the file name itself ('long' paths, firefox 3.5+ style filenames) """ try: # Mozilla 1.9.0 style (aka 'short') paths # e.g. firefox-3.0.12.en-US.win32.complete.mar filename = os.path.basename(filepath) m = re.match("^(%s)-([0-9.]+)\.([-a-zA-Z]+)\.(win32)\.(complete|installer)\.(mar|exe)$" % product, filename) if not m: raise ValueError("Could not parse: %s" % filename) return {'product': m.group(1), 'version': m.group(2), 'locale': m.group(3), 'platform': m.group(4), 'contents': m.group(5), 'format': m.group(6), 'pathstyle': 'short', 'leading_path' : None, } except: # Mozilla 1.9.1 and on style (aka 'long') paths # e.g. update/win32/en-US/firefox-3.5.1.complete.mar # win32/en-US/Firefox Setup 3.5.1.exe ret = {'pathstyle': 'long'} if filepath.endswith('.mar'): ret['format'] = 'mar' m = re.search("update/(win32|linux-i686|linux-x86_64|mac|mac64)/([-a-zA-Z]+)/(%s)-(\d+\.\d+(?:\.\d+)?(?:\w+\d+)?)\.(complete)\.mar" % product, filepath) if not m: raise ValueError("Could not parse: %s" % filepath) ret['platform'] = m.group(1) ret['locale'] = m.group(2) ret['product'] = m.group(3) ret['version'] = m.group(4) ret['contents'] = m.group(5) ret['leading_path'] = None elif filepath.endswith('.exe'): ret['format'] = 'exe' m = re.search("(partner-repacks/\w+/|)(win32|mac|linux-i686)/([-a-zA-Z]+)/((?i)%s) Setup (\d+\.\d+(?:\.\d+)?(?:\w+\d+)?(?:\ \w+\ \d+)?)\.exe" % product, filepath) if not m: raise ValueError("Could not parse: %s" % filepath) ret['leading_path'] = m.group(1) ret['platform'] = m.group(2) ret['locale'] = m.group(3) ret['product'] = m.group(4).lower() ret['version'] = m.group(5) ret['contents'] = 'installer' else: raise ValueError("Unknown filetype for %s" % filepath) return ret | c3782d3dfb0b3af70866c985aa93d0a1c332b082 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/6206/c3782d3dfb0b3af70866c985aa93d0a1c332b082/signing.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
12538,
12,
10561,
16,
3017,
4672,
3536,
4976,
1779,
2973,
279,
3992,
585,
18,
225,
2860,
279,
3880,
598,
326,
3751,
1311,
444,
30,
296,
5896,
2187,
296,
1589,
2187,
296,
6339,
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,
12538,
12,
10561,
16,
3017,
4672,
3536,
4976,
1779,
2973,
279,
3992,
585,
18,
225,
2860,
279,
3880,
598,
326,
3751,
1311,
444,
30,
296,
5896,
2187,
296,
1589,
2187,
296,
6339,
2187,
296,... |
if nim2 == (nim1 - 1): self.linkInternally(nim1) | def linkNIMs(self, sec, nim1, nim2): print "link tuner", nim1, "to tuner", nim2 if nim2 == (nim1 - 1): self.linkInternally(nim1) sec.setTunerLinked(nim1, nim2) | 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,
1692,
50,
3445,
87,
12,
2890,
16,
1428,
16,
290,
381,
21,
16,
290,
381,
22,
4672,
1172,
315,
1232,
268,
29640,
3113,
290,
381,
21,
16,
315,
869,
268,
29640,
3113,
290,
381,
22,
1428,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1692,
50,
3445,
87,
12,
2890,
16,
1428,
16,
290,
381,
21,
16,
290,
381,
22,
4672,
1172,
315,
1232,
268,
29640,
3113,
290,
381,
21,
16,
315,
869,
268,
29640,
3113,
290,
381,
22,
1428,... | |
""" | """ | def __init__(self): """ Created: 13.04.2006, KP Description: Initialization """ ProcessingFilter.ProcessingFilter.__init__(self, (1, 1)) self.vtkfilter = vtk.vtkImageThreshold() self.origCtf = None self.ignoreObjects = 1 self.descs = {"ReplaceInValue": "Value for voxels inside thresholds", "ReplaceOutValue": "Value for voxels outside thresholds", "ReplaceIn": "Inside thresholds", "ReplaceOut": "Outside thresholds", "LowerThreshold": "Lower Threshold", "UpperThreshold": "Upper threshold", "Demonstrate": "Use lookup table to demonstrate effect"} | 6d7b572696d4ecdce2049b45a6e109836f3272c9 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/2877/6d7b572696d4ecdce2049b45a6e109836f3272c9/SegmentationFilters.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1001,
2738,
972,
12,
2890,
4672,
3536,
12953,
30,
5958,
18,
3028,
18,
6976,
26,
16,
1475,
52,
6507,
30,
26586,
3536,
19652,
1586,
18,
7798,
1586,
16186,
2738,
972,
12,
2890,
16,
261,
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,
972,
12,
2890,
4672,
3536,
12953,
30,
5958,
18,
3028,
18,
6976,
26,
16,
1475,
52,
6507,
30,
26586,
3536,
19652,
1586,
18,
7798,
1586,
16186,
2738,
972,
12,
2890,
16,
261,
2... |
[--resolution=seconds] | [--writestats=filename | --readstats=filename] [--urlfocus=url] [--urlfocustime=seconds] | def usage(basic=1): usage = ( """ | 76070c7cdc68bf22cdf41234ce64835eb149b1ae /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/9658/76070c7cdc68bf22cdf41234ce64835eb149b1ae/requestprofiler.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
4084,
12,
13240,
33,
21,
4672,
4084,
273,
261,
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,
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,
4084,
12,
13240,
33,
21,
4672,
4084,
273,
261,
3536,
2,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
-100,
... |
return str.decode('utf-8') | return string.decode('utf-8') | def as_unicode(string): if isinstance(string, unicode): return string elif isinstance(string, str): return str.decode('utf-8') else: raise Exception('You must pass a string type') | 8ba3e68cd14603977dce91bb4e025e1e40a4b808 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/11388/8ba3e68cd14603977dce91bb4e025e1e40a4b808/import_old_prefs.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
487,
67,
9124,
12,
1080,
4672,
309,
1549,
12,
1080,
16,
5252,
4672,
327,
533,
1327,
1549,
12,
1080,
16,
609,
4672,
327,
533,
18,
3922,
2668,
3158,
17,
28,
6134,
469,
30,
1002,
1185,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
487,
67,
9124,
12,
1080,
4672,
309,
1549,
12,
1080,
16,
5252,
4672,
327,
533,
1327,
1549,
12,
1080,
16,
609,
4672,
327,
533,
18,
3922,
2668,
3158,
17,
28,
6134,
469,
30,
1002,
1185,
... |
print "write", txt, "*" | if DEBUG: print "write", txt, "*" | def handle_data(self, txt): if self.td is not None: # drawing a table? if 'width' not in self.td and 'colspan' not in self.td: l = [self.table_col_width[self.table_col_index]] elif 'colspan' in self.td: i = self.table_col_index colspan = int(self.td['colspan']) l = self.table_col_width[i:i+colspan] else: l = [self.td.get('width','240')] w = sum([self.width2mm(lenght) for lenght in l]) h = int(self.td.get('height', 0)) / 4 or self.h*1.30 self.table_h = h border = int(self.table.get('border', 0)) if not self.th: align = self.td.get('align', 'L')[0].upper() border = border and 'LR' else: self.set_style('B',True) border = border or 'B' align = 'C' bgcolor = hex2dec(self.td.get('bgcolor', self.tr.get('bgcolor', ''))) # parsing table header/footer (drawn later): if self.thead is not None: self.theader.append(((w,h,txt,border,0,align), bgcolor)) if self.tfoot is not None: self.tfooter.append(((w,h,txt,border,0,align), bgcolor)) # check if reached end of page, add table footer and header: height = h + (self.tfooter and self.tfooter[0][0][1] or 0) if self.pdf.y+height>self.pdf.page_break_trigger and not self.th: self.output_table_footer() self.pdf.add_page() self.theader_out = self.tfooter_out = False if self.tfoot is None and self.thead is None: if not self.theader_out: self.output_table_header() self.box_shadow(w, h, bgcolor) print "td cell", self.pdf.x, w, txt, "*" self.pdf.cell(w,h,txt,border,0,align) elif self.table is not None: # ignore anything else than td inside a table pass elif self.align: print "cell", txt, "*" self.pdf.cell(0,self.h,txt,0,1,self.align[0].upper(), self.href) else: txt = txt.replace("\n"," ") if self.href: self.put_link(self.href,txt) else: print "write", txt, "*" self.pdf.write(self.h,txt) | 996f6e35601b75cac6b1dc86d1139ccdc5003c81 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/8794/996f6e35601b75cac6b1dc86d1139ccdc5003c81/html.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
1640,
67,
892,
12,
2890,
16,
6463,
4672,
309,
365,
18,
4465,
353,
486,
599,
30,
468,
16327,
279,
1014,
35,
309,
296,
2819,
11,
486,
316,
365,
18,
4465,
471,
296,
1293,
3969,
11,
486,... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
1640,
67,
892,
12,
2890,
16,
6463,
4672,
309,
365,
18,
4465,
353,
486,
599,
30,
468,
16327,
279,
1014,
35,
309,
296,
2819,
11,
486,
316,
365,
18,
4465,
471,
296,
1293,
3969,
11,
486,... |
expr = 'const platform="%s"; const libdir="%s";'%(sys.platform, libdir_var) cmd = '%s -j -e \'%s\' -f %s -f %s'%( JS, expr, os.path.join(lib_dir, 'prolog.js'), path) return cmd | expr = "const platform=%r; const libdir=%r;"%(sys.platform, libdir_var) return [ JS, '-j', '-e', expr, '-f', os.path.join(lib_dir, 'prolog.js'), '-f', path ] | def get_test_cmd(path, lib_dir): libdir_var = lib_dir if not libdir_var.endswith('/'): libdir_var += '/' expr = 'const platform="%s"; const libdir="%s";'%(sys.platform, libdir_var) cmd = '%s -j -e \'%s\' -f %s -f %s'%( JS, expr, os.path.join(lib_dir, 'prolog.js'), path) return cmd | 2cf9fb6635193d6bd8c9dcac3437def11f9551ce /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/11102/2cf9fb6635193d6bd8c9dcac3437def11f9551ce/trace-test.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
336,
67,
3813,
67,
4172,
12,
803,
16,
2561,
67,
1214,
4672,
2561,
1214,
67,
1401,
273,
2561,
67,
1214,
309,
486,
2561,
1214,
67,
1401,
18,
5839,
1918,
2668,
2473,
4672,
2561,
1214,
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,
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,
3813,
67,
4172,
12,
803,
16,
2561,
67,
1214,
4672,
2561,
1214,
67,
1401,
273,
2561,
67,
1214,
309,
486,
2561,
1214,
67,
1401,
18,
5839,
1918,
2668,
2473,
4672,
2561,
1214,
67,... |
sys.stdout = SCons.Util.Unbuffered(sys.stdout) | if not sys.stdout.isatty(): sys.stdout = SCons.Util.Unbuffered(sys.stdout) | def _main(parser): global exit_status options = parser.values # Here's where everything really happens. # First order of business: set up default warnings and then # handle the user's warning options, so that we can issue (or # suppress) appropriate warnings about anything that might happen, # as configured by the user. default_warnings = [ SCons.Warnings.CorruptSConsignWarning, SCons.Warnings.DeprecatedWarning, SCons.Warnings.DuplicateEnvironmentWarning, SCons.Warnings.MissingSConscriptWarning, SCons.Warnings.NoMD5ModuleWarning, SCons.Warnings.NoMetaclassSupportWarning, SCons.Warnings.NoObjectCountWarning, SCons.Warnings.NoParallelSupportWarning, SCons.Warnings.MisleadingKeywordsWarning, SCons.Warnings.StackSizeWarning, ] for warning in default_warnings: SCons.Warnings.enableWarningClass(warning) SCons.Warnings._warningOut = _scons_internal_warning if options.warn: _setup_warn(options.warn) # Now that we have the warnings configuration set up, we can actually # issue (or suppress) any warnings about warning-worthy things that # occurred while the command-line options were getting parsed. try: dw = options.delayed_warnings except AttributeError: pass else: delayed_warnings.extend(dw) for warning_type, message in delayed_warnings: SCons.Warnings.warn(warning_type, message) if options.diskcheck: SCons.Node.FS.set_diskcheck(options.diskcheck) # Next, we want to create the FS object that represents the outside # world's file system, as that's central to a lot of initialization. # To do this, however, we need to be in the directory from which we # want to start everything, which means first handling any relevant # options that might cause us to chdir somewhere (-C, -D, -U, -u). if options.directory: cdir = _create_path(options.directory) try: os.chdir(cdir) except OSError: sys.stderr.write("Could not change directory to %s\n" % cdir) target_top = None if options.climb_up: target_top = '.' # directory to prepend to targets script_dir = os.getcwd() # location of script while script_dir and not _SConstruct_exists(script_dir, options.repository): script_dir, last_part = os.path.split(script_dir) if last_part: target_top = os.path.join(last_part, target_top) else: script_dir = '' if script_dir: display("scons: Entering directory `%s'" % script_dir) os.chdir(script_dir) # Now that we're in the top-level SConstruct directory, go ahead # and initialize the FS object that represents the file system, # and make it the build engine default. fs = SCons.Node.FS.get_default_fs() for rep in options.repository: fs.Repository(rep) # Now that we have the FS object, the next order of business is to # check for an SConstruct file (or other specified config file). # If there isn't one, we can bail before doing any more work. scripts = [] if options.file: scripts.extend(options.file) if not scripts: sfile = _SConstruct_exists(repositories=options.repository) if sfile: scripts.append(sfile) if not scripts: if options.help: # There's no SConstruct, but they specified -h. # Give them the options usage now, before we fail # trying to read a non-existent SConstruct file. raise SConsPrintHelpException raise SCons.Errors.UserError, "No SConstruct file found." if scripts[0] == "-": d = fs.getcwd() else: d = fs.File(scripts[0]).dir fs.set_SConstruct_dir(d) _set_debug_values(options) SCons.Node.implicit_cache = options.implicit_cache SCons.Node.implicit_deps_changed = options.implicit_deps_changed SCons.Node.implicit_deps_unchanged = options.implicit_deps_unchanged if options.no_exec: SCons.SConf.dryrun = 1 SCons.Action.execute_actions = None if options.question: SCons.SConf.dryrun = 1 if options.clean: SCons.SConf.SetBuildType('clean') if options.help: SCons.SConf.SetBuildType('help') SCons.SConf.SetCacheMode(options.config) SCons.SConf.SetProgressDisplay(progress_display) if options.no_progress or options.silent: progress_display.set_mode(0) if options.site_dir: _load_site_scons_dir(d, options.site_dir) elif not options.no_site_dir: _load_site_scons_dir(d) if options.include_dir: sys.path = options.include_dir + sys.path # That should cover (most of) the options. Next, set up the variables # that hold command-line arguments, so the SConscript files that we # read and execute have access to them. targets = [] xmit_args = [] for a in parser.largs: if a[0] == '-': continue if '=' in a: xmit_args.append(a) else: targets.append(a) SCons.Script._Add_Targets(targets + parser.rargs) SCons.Script._Add_Arguments(xmit_args) sys.stdout = SCons.Util.Unbuffered(sys.stdout) memory_stats.append('before reading SConscript files:') count_stats.append(('pre-', 'read')) # And here's where we (finally) read the SConscript files. progress_display("scons: Reading SConscript files ...") start_time = time.time() try: for script in scripts: SCons.Script._SConscript._SConscript(fs, script) except SCons.Errors.StopError, e: # We had problems reading an SConscript file, such as it # couldn't be copied in to the BuildDir. Since we're just # reading SConscript files and haven't started building # things yet, stop regardless of whether they used -i or -k # or anything else. sys.stderr.write("scons: *** %s Stop.\n" % e) exit_status = 2 sys.exit(exit_status) global sconscript_time sconscript_time = time.time() - start_time progress_display("scons: done reading SConscript files.") memory_stats.append('after reading SConscript files:') count_stats.append(('post-', 'read')) if not options.help: SCons.SConf.CreateConfigHBuilder(SCons.Defaults.DefaultEnvironment()) # Now re-parse the command-line options (any to the left of a '--' # argument, that is) with any user-defined command-line options that # the SConscript files may have added to the parser object. This will # emit the appropriate error message and exit if any unknown option # was specified on the command line. parser.preserve_unknown_options = False parser.parse_args(parser.largs, options) if options.help: help_text = SCons.Script.help_text if help_text is None: # They specified -h, but there was no Help() inside the # SConscript files. Give them the options usage. raise SConsPrintHelpException else: print help_text print "Use scons -H for help about command-line options." exit_status = 0 return # Change directory to the top-level SConstruct directory, then tell # the Node.FS subsystem that we're all done reading the SConscript # files and calling Repository() and BuildDir() and changing # directories and the like, so it can go ahead and start memoizing # the string values of file system nodes. fs.chdir(fs.Top) SCons.Node.FS.save_strings(1) # Now that we've read the SConscripts we can set the options # that are SConscript settable: SCons.Node.implicit_cache = options.implicit_cache SCons.Node.FS.set_duplicate(options.duplicate) fs.set_max_drift(options.max_drift) if not options.stack_size is None: SCons.Job.stack_size = options.stack_size platform = SCons.Platform.platform_module() if options.interactive: SCons.Script.Interactive.interact(fs, OptionsParser, options, targets, target_top) else: # Build the targets nodes = _build_targets(fs, options, targets, target_top) | 7eaf742e9ec94435c3387a023f7accd45d32d8cc /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/12817/7eaf742e9ec94435c3387a023f7accd45d32d8cc/Main.py | [
1,
8585,
326,
22398,
316,
326,
981,
30,
1652,
389,
5254,
12,
4288,
4672,
2552,
2427,
67,
2327,
225,
702,
273,
2082,
18,
2372,
225,
468,
13743,
1807,
1625,
7756,
8654,
10555,
18,
225,
468,
5783,
1353,
434,
13160,
30,
225,
444,
731,
... | [
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
1,
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,
5254,
12,
4288,
4672,
2552,
2427,
67,
2327,
225,
702,
273,
2082,
18,
2372,
225,
468,
13743,
1807,
1625,
7756,
8654,
10555,
18,
225,
468,
5783,
1353,
434,
13160,
30,
225,
444,
731,
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.