rem
stringlengths
2
226k
add
stringlengths
0
227k
context
stringlengths
8
228k
meta
stringlengths
156
215
input_ids
list
attention_mask
list
labels
list
if not inv:
if not locs:
def do_merge(self, cr, uid, data, context): invent_obj = pooler.get_pool(cr.dbname).get('stock.inventory') invent_line_obj = pooler.get_pool(cr.dbname).get('stock.inventory.line') prod_obj = pooler.get_pool(cr.dbname).get('product.product') if len(data['ids']) <> 1: raise wizard.except_wizard("Warning", "Please select one and only one inventory !") cr.execute('select distinct location_id from stock_inventory_line where inventory_id=%s', (data['ids'][0],)) loc_ids = map(lambda x: x[0], cr.fetchall()) locs = ','.join(map(lambda x: str(x), loc_ids)) cr.execute('select distinct location_id,product_id from stock_inventory_line where inventory_id=%s', (data['ids'][0],)) inv = cr.fetchall() if not inv: raise wizard.except_wizard("Warning", "Please select at least one inventory location !") else: cr.execute('select distinct product_id from stock_move where (location_dest_id in ('+locs+')) or (location_id in ('+locs+'))') stock = cr.fetchall() for s in stock: for loc in loc_ids: if (loc,s[0]) not in inv: p = prod_obj.browse(cr, uid, s[0]) invent_line_obj.create(cr, uid, { 'inventory_id': data['ids'][0], 'location_id': loc, 'product_id': s[0], 'product_uom': p.uom_id.id, 'product_qty': 0.0, }) return {}
f6fd0320dcd1c4388d63b13abe4a6c58414be46e /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/7397/f6fd0320dcd1c4388d63b13abe4a6c58414be46e/inventory_merge_zero.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 741, 67, 2702, 12, 2890, 16, 4422, 16, 4555, 16, 501, 16, 819, 4672, 316, 616, 67, 2603, 273, 2845, 264, 18, 588, 67, 6011, 12, 3353, 18, 20979, 2934, 588, 2668, 15381, 18, 26024, 61...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 741, 67, 2702, 12, 2890, 16, 4422, 16, 4555, 16, 501, 16, 819, 4672, 316, 616, 67, 2603, 273, 2845, 264, 18, 588, 67, 6011, 12, 3353, 18, 20979, 2934, 588, 2668, 15381, 18, 26024, 61...
return min([s for s in self.snapshots])
return min([s.size for s in self.snapshots])
def minimum(self): return min([s for s in self.snapshots])
3d54987f1360df6463bc224cf3f1d51468c25d69 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12624/3d54987f1360df6463bc224cf3f1d51468c25d69/diskspace-report.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 5224, 12, 2890, 4672, 327, 1131, 3816, 87, 364, 272, 316, 365, 18, 26918, 5717, 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, 5224, 12, 2890, 4672, 327, 1131, 3816, 87, 364, 272, 316, 365, 18, 26918, 5717, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -...
c.repos_list = sorted(cached_repo_list, key=itemgetter('name'))
c.repos_list = sorted(cached_repo_list, key=itemgetter('name_sort'))
def index(self, format='html'): """GET /repos: All items in the collection""" # url('repos') cached_repo_list = HgModel().get_repos() c.repos_list = sorted(cached_repo_list, key=itemgetter('name')) return render('admin/repos/repos.html')
97a436cae19dc7c3c2d5f247b860cf7c16010f1c /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/4230/97a436cae19dc7c3c2d5f247b860cf7c16010f1c/repos.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 770, 12, 2890, 16, 740, 2218, 2620, 11, 4672, 3536, 3264, 342, 15564, 30, 4826, 1516, 316, 326, 1849, 8395, 468, 880, 2668, 15564, 6134, 3472, 67, 7422, 67, 1098, 273, 670, 75, 1488, 7...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 770, 12, 2890, 16, 740, 2218, 2620, 11, 4672, 3536, 3264, 342, 15564, 30, 4826, 1516, 316, 326, 1849, 8395, 468, 880, 2668, 15564, 6134, 3472, 67, 7422, 67, 1098, 273, 670, 75, 1488, 7...
sage: P5.homology()
The following computation can take a long time -- over half an hour -- with Sage's default computation of homology groups, but if you have CHomP installed, Sage will use that and the computation should only take a second or two. (You can download CHomP from http://chomp.rutgers.edu/, or you can install it as a Sage package using "sage -i chomp"). :: sage: P5.homology()
def RealProjectiveSpace(self, n): r""" A triangulation of `\Bold{R}P^n` for any `n \geq 0`.
5d95ced8f0044b3d060e0809a34beccba8fa7a04 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/9417/5d95ced8f0044b3d060e0809a34beccba8fa7a04/examples.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 15987, 4109, 688, 3819, 12, 2890, 16, 290, 4672, 436, 8395, 432, 6882, 539, 6234, 434, 1375, 64, 38, 1673, 95, 54, 97, 52, 66, 82, 68, 364, 1281, 1375, 82, 521, 908, 85, 374, 8338, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 15987, 4109, 688, 3819, 12, 2890, 16, 290, 4672, 436, 8395, 432, 6882, 539, 6234, 434, 1375, 64, 38, 1673, 95, 54, 97, 52, 66, 82, 68, 364, 1281, 1375, 82, 521, 908, 85, 374, 8338, ...
'''
"""
def field(self): ''' Render a form edit field for the property
16a3ebf380b95607b344181655488d818a27791f /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/1906/16a3ebf380b95607b344181655488d818a27791f/templating.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 652, 12, 2890, 4672, 3536, 6987, 279, 646, 3874, 652, 364, 326, 1272, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 652, 12, 2890, 4672, 3536, 6987, 279, 646, 3874, 652, 364, 326, 1272, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, ...
print "***_getObjectDefinedHighlightColor = ", method
def _getObjectDefinedHighlightColor(self, selobj): """
303485461d2eb26da89a2109a764eda22758493a /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/11221/303485461d2eb26da89a2109a764eda22758493a/Select_GraphicsMode.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 588, 921, 8116, 16205, 2957, 12, 2890, 16, 357, 2603, 4672, 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, ...
[ 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, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 588, 921, 8116, 16205, 2957, 12, 2890, 16, 357, 2603, 4672, 3536, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, ...
if not done: if coerce: xdata = [] ydata = [] for z in points: if len(z) == 3: return self._graphic3d()(points, coerce=coerce, **kwds) xdata.append(float(z[0])) ydata.append(float(z[1])) else: for z in points: if len(z) == 3: return self._graphic3d()(points, coerce=coerce, **kwds) xdata.append(z[0]) ydata.append(z[1])
xdata = [] ydata = [] if coerce: for z in points: if len(z) == 3: return self._graphic3d()(points, coerce=coerce, **kwds) xdata.append(float(z[0])) ydata.append(float(z[1])) else: for z in points: if len(z) == 3: return self._graphic3d()(points, coerce=coerce, **kwds) xdata.append(z[0]) ydata.append(z[1])
def __call__(self, points, coerce=True, **kwds): try: return points.plot(**kwds) except AttributeError: pass options = dict(self.options) for k, v in kwds.iteritems(): options[k] = v
6c2deef5173e30690e3a032c3043b4f268ae2496 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/9417/6c2deef5173e30690e3a032c3043b4f268ae2496/plot.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 1991, 972, 12, 2890, 16, 3143, 16, 12270, 33, 5510, 16, 2826, 25577, 4672, 775, 30, 327, 3143, 18, 4032, 12, 636, 25577, 13, 1335, 6394, 30, 1342, 702, 273, 2065, 12, 2890, 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, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 1991, 972, 12, 2890, 16, 3143, 16, 12270, 33, 5510, 16, 2826, 25577, 4672, 775, 30, 327, 3143, 18, 4032, 12, 636, 25577, 13, 1335, 6394, 30, 1342, 702, 273, 2065, 12, 2890, 18, ...
try: return descriptor.recv(buflen) except socket.error, e: if e[0] == errno.EWOULDBLOCK: return None if e[0] in SOCKET_CLOSED: return '' raise except util.SSL.WantReadError:
return descriptor.recv(buflen) except socket.error, e: if e[0] == errno.EWOULDBLOCK:
def socket_recv(descriptor, buflen): timeout = descriptor.gettimeout() if timeout: cancel = exc_after(timeout, TimeoutError) else: cancel = None try: try: return descriptor.recv(buflen) except socket.error, e: if e[0] == errno.EWOULDBLOCK: return None if e[0] in SOCKET_CLOSED: return '' raise except util.SSL.WantReadError: return None except util.SSL.ZeroReturnError: return '' except util.SSL.SysCallError, e: if e[0] == -1 or e[0] > 0: return '' raise finally: if cancel: cancel.cancel()
33ccd249ce6338c6350d1a12be9b41ce6591de83 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/10078/33ccd249ce6338c6350d1a12be9b41ce6591de83/greenio.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2987, 67, 18334, 12, 12628, 16, 1681, 1897, 4672, 2021, 273, 4950, 18, 588, 4538, 1435, 309, 2021, 30, 3755, 273, 3533, 67, 5205, 12, 4538, 16, 28758, 13, 469, 30, 3755, 273, 599, 775,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2987, 67, 18334, 12, 12628, 16, 1681, 1897, 4672, 2021, 273, 4950, 18, 588, 4538, 1435, 309, 2021, 30, 3755, 273, 3533, 67, 5205, 12, 4538, 16, 28758, 13, 469, 30, 3755, 273, 599, 775,...
self.assertEqual(1, len(os), "data object not in database")
self.failIfEqual(0, len(os), "data object %r not in database" % (self.model,)) self.assertEqual(1, len(os), "more than one object in database (currently %r)" % (os,))
def create(self): #"""Test create action on controller"""
13e42d8dd7ccf85183db28ef9b65892c19d3d7f7 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12856/13e42d8dd7ccf85183db28ef9b65892c19d3d7f7/__init__.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 752, 12, 2890, 4672, 468, 8395, 4709, 752, 1301, 603, 2596, 8395, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 752, 12, 2890, 4672, 468, 8395, 4709, 752, 1301, 603, 2596, 8395, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100,...
[ -1/2 sqrt(3)/2] [sqrt(3)/2 1/2]
[ -1/2 1/2*sqrt(3)] [1/2*sqrt(3) 1/2]
def _representation_matrix_uncached(self, permutation): r""" Return the matrix representing ``permutation``.
2fdeb747e9bb057796e7378938cfcf0380030b8b /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9417/2fdeb747e9bb057796e7378938cfcf0380030b8b/symmetric_group_representations.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 28957, 67, 5667, 67, 551, 2004, 12, 2890, 16, 17440, 4672, 436, 8395, 2000, 326, 3148, 5123, 12176, 12160, 9245, 68, 8338, 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, 389, 28957, 67, 5667, 67, 551, 2004, 12, 2890, 16, 17440, 4672, 436, 8395, 2000, 326, 3148, 5123, 12176, 12160, 9245, 68, 8338, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -...
def __init__(self,name = "",type = "metatag"): self.name = name self.type = type
def __init__(self,name = ""): self.name = name self.type = "metatag"
def __init__(self,name = "",type = "metatag"): self.name = name self.type = type
b53942f263a55f85a77d04b9126525cca8cd1697 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/886/b53942f263a55f85a77d04b9126525cca8cd1697/asModel.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 16, 529, 273, 23453, 723, 273, 315, 10578, 270, 346, 6, 4672, 365, 18, 529, 273, 508, 365, 18, 723, 273, 618, 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, 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, 1001, 2738, 972, 12, 2890, 16, 529, 273, 23453, 723, 273, 315, 10578, 270, 346, 6, 4672, 365, 18, 529, 273, 508, 365, 18, 723, 273, 618, 2, -100, -100, -100, -100, -100, -100, -100, ...
return self.singleApiJdl ( obj, requirements )
return self.singleApiJdl ( obj, requirements )
def decode ( self, obj, requirements='' ) : """ prepare file for submission """ if type(obj) == RunningJob or type(obj) == Job : return self.singleApiJdl ( obj, requirements ) elif type(obj) == Task : return self.collectionApiJdl ( obj, requirements )
eb0192bf3b8b1626bda0daa62b8bc557cf397c07 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/8886/eb0192bf3b8b1626bda0daa62b8bc557cf397c07/SchedulerGLiteAPI.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2495, 225, 261, 365, 16, 1081, 16, 8433, 2218, 11, 262, 294, 3536, 2911, 585, 364, 8515, 3536, 309, 618, 12, 2603, 13, 422, 20480, 2278, 578, 618, 12, 2603, 13, 422, 3956, 294, 327, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2495, 225, 261, 365, 16, 1081, 16, 8433, 2218, 11, 262, 294, 3536, 2911, 585, 364, 8515, 3536, 309, 618, 12, 2603, 13, 422, 20480, 2278, 578, 618, 12, 2603, 13, 422, 3956, 294, 327, ...
if i==0: t="%4d" % (bandmap2[i][0],) + " " + bandmap2[i][1] nage=int((nseq - bandmap[i][2])/15) if nage==0: attr='age0' if nage==1: attr='age1' if nage==2: attr='age2' if nage>=3: attr='age3' text1.insert(END,t+"\n",attr) else: if bandmap2[i][1]!=call0: t="%4d" % (bandmap2[i][0],) + " " + bandmap2[i][1] nage=int((nseq - bandmap[i][2])/15) if nage==0: attr='age0' if nage==1: attr='age1' if nage==2: attr='age2' if nage>=3: attr='age3' text1.insert(END,t+"\n",attr) call0=bandmap2[i][1]
t="%4d" % (bandmap[i][0],) + " " + bandmap[i][1] nage=int((nseq - bandmap[i][2])/15) attr='age0' if nage==1: attr='age1' if nage==2: attr='age2' if nage>=3: attr='age3' text1.insert(END,t+"\n",attr)
def get_decoded(): global bandmap,bandmap2,newdat,loopall
0b7e0fdc65acf8ff147a55031e80fefa8f26260c /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/2394/0b7e0fdc65acf8ff147a55031e80fefa8f26260c/wspr.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 67, 26646, 13332, 2552, 8937, 1458, 16, 12752, 1458, 22, 16, 2704, 3404, 16, 6498, 454, 225, 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, 336, 67, 26646, 13332, 2552, 8937, 1458, 16, 12752, 1458, 22, 16, 2704, 3404, 16, 6498, 454, 225, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -...
transports.TLS().PlugIn(self,now=1) self.connected='ssl'
try: transports.TLS().PlugIn(self,now=1) self.connected='ssl' except socket.sslerror: return
def connect(self,server=None,proxy=None,ssl=None): """ Make a tcp/ip connection, protect it with tls/ssl if possible and start XMPP stream. Returns None or 'tcp' or 'tls', depending on the result.""" if not server: server=(self.Server,self.Port) if proxy: connected=transports.HTTPPROXYsocket(proxy,server).PlugIn(self) else: connected=transports.TCPsocket(server).PlugIn(self) if not connected: return self._Server,self._Proxy=server,proxy self.connected='tcp'
b9f9e067ab0d471b30a1ca7a5b9ece36c20c19a0 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/7194/b9f9e067ab0d471b30a1ca7a5b9ece36c20c19a0/client.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3077, 12, 2890, 16, 3567, 33, 7036, 16, 5656, 33, 7036, 16, 8157, 33, 7036, 4672, 3536, 4344, 279, 9658, 19, 625, 1459, 16, 17151, 518, 598, 6871, 19, 8157, 309, 3323, 471, 787, 23216,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 3077, 12, 2890, 16, 3567, 33, 7036, 16, 5656, 33, 7036, 16, 8157, 33, 7036, 4672, 3536, 4344, 279, 9658, 19, 625, 1459, 16, 17151, 518, 598, 6871, 19, 8157, 309, 3323, 471, 787, 23216,...
raise error, 'don\'t know what to do with indexsubitem ' + `idxsi`
command = 'defcv' cat_class = 'exception'
def do_excdesc(length, buf, pp, i): startpoint = i-1 ch = pp[startpoint] wh = ch.where length, newi = getnextarg(length, buf, pp, i) excname = chunk(GROUP, wh, pp[i:newi]) del pp[i:newi] length = length - (newi-i) idxsi = hist.indexsubitem # words command = '' cat_class = '' class_class = '' if len(idxsi) == 2 and idxsi[1] == 'exception': command = 'defvr' cat_class = string.join(idxsi) elif len(idxsi) == 3 and idxsi[:2] == ['in', 'module']: command = 'defcv' cat_class = 'exception' class_class = string.join(idxsi[1:]) elif len(idxsi) == 4 and idxsi[:3] == ['exception', 'in', 'module']: command = 'defcv' cat_class = 'exception' class_class = string.join(idxsi[2:]) elif idxsi == ['built-in', 'exception', 'base', 'class']: command = 'defvr' cat_class = 'exception base class' else: raise error, 'don\'t know what to do with indexsubitem ' + `idxsi` ch.chtype = chunk_type[CSLINE] ch.data = command cslinearg = [chunk(GROUP, wh, [chunk(PLAIN, wh, cat_class)])] cslinearg.append(chunk(PLAIN, wh, ' ')) if class_class: cslinearg.append(chunk(GROUP, wh, [chunk(PLAIN, wh, class_class)])) cslinearg.append(chunk(PLAIN, wh, ' ')) cslinearg.append(excname) pp.insert(i, chunk(GROUP, wh, cslinearg)) i, length = i+1, length+1 hist.command = command return length, i
a302c9555984072394cd72609bc8973adecd6fe3 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/3187/a302c9555984072394cd72609bc8973adecd6fe3/partparse.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 741, 67, 338, 4315, 742, 12, 2469, 16, 1681, 16, 8228, 16, 277, 4672, 787, 1153, 273, 277, 17, 21, 462, 273, 8228, 63, 1937, 1153, 65, 600, 273, 462, 18, 6051, 769, 16, 394, 77, 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, 741, 67, 338, 4315, 742, 12, 2469, 16, 1681, 16, 8228, 16, 277, 4672, 787, 1153, 273, 277, 17, 21, 462, 273, 8228, 63, 1937, 1153, 65, 600, 273, 462, 18, 6051, 769, 16, 394, 77, 27...
self.daily_double_overlay(self.get_width(), self.get_height())
self.daily_double_overlay.set_size(self.get_width(), self.get_height())
def on_allocation_changed(self, stage, box, flags): """ """ logging.debug("self size %d x %d and stage size %d x %d" % (self.get_width(), self.get_height(), stage.get_width(), stage.get_height())) self.clue_overlay.set_size(self.get_width(), self.get_height()) self.daily_double_overlay(self.get_width(), self.get_height()) self.game_board.set_size(self.get_width() * 0.9, self.get_height()) self.board_box.set_size(self.get_width(), self.get_height()) self.category_overlay.set_size(self.get_width(), self.get_height()) self.player_buzz_overlay.set_size(self.get_width(), self.get_height())
11acc3996060bc89c9bdef60ec7b237905d295a6 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/10391/11acc3996060bc89c9bdef60ec7b237905d295a6/gui.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 603, 67, 29299, 67, 6703, 12, 2890, 16, 6009, 16, 3919, 16, 2943, 4672, 3536, 3536, 2907, 18, 4148, 2932, 2890, 963, 738, 72, 619, 738, 72, 225, 471, 6009, 963, 738, 72, 619, 738, 72...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 603, 67, 29299, 67, 6703, 12, 2890, 16, 6009, 16, 3919, 16, 2943, 4672, 3536, 3536, 2907, 18, 4148, 2932, 2890, 963, 738, 72, 619, 738, 72, 225, 471, 6009, 963, 738, 72, 619, 738, 72...
def checksum(pkt): if len(pkt) % 2 == 1: pkt += "\0" s = sum(array.array("H", pkt)) s = (s >> 16) + (s & 0xffff) s += s >> 16 s = ~s return (((s>>8)&0xff)|s<<8) & 0xffff
if BIG_ENDIAN: def checksum(pkt): if len(pkt) % 2 == 1: pkt += "\0" s = sum(array.array("H", pkt)) s = (s >> 16) + (s & 0xffff) s += s >> 16 s = ~s return s & 0xffff else: def checksum(pkt): if len(pkt) % 2 == 1: pkt += "\0" s = sum(array.array("H", pkt)) s = (s >> 16) + (s & 0xffff) s += s >> 16 s = ~s return (((s>>8)&0xff)|s<<8) & 0xffff
def checksum(pkt): if len(pkt) % 2 == 1: pkt += "\0" s = sum(array.array("H", pkt)) s = (s >> 16) + (s & 0xffff) s += s >> 16 s = ~s return (((s>>8)&0xff)|s<<8) & 0xffff
01f4fa196b6f5e6eef7ce0caf807b0cc637dd64d /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/7311/01f4fa196b6f5e6eef7ce0caf807b0cc637dd64d/scapy.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 309, 18855, 67, 30597, 30, 1652, 6697, 12, 5465, 88, 4672, 309, 562, 12, 5465, 88, 13, 738, 576, 422, 404, 30, 11536, 1011, 1548, 20, 6, 272, 273, 2142, 12, 1126, 18, 1126, 2932, 44, 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, 309, 18855, 67, 30597, 30, 1652, 6697, 12, 5465, 88, 4672, 309, 562, 12, 5465, 88, 13, 738, 576, 422, 404, 30, 11536, 1011, 1548, 20, 6, 272, 273, 2142, 12, 1126, 18, 1126, 2932, 44, 3113,...
if len(values['body']) > 128:
if values['body'] and (len(values['body']) > 128):
def request_send(self, cr, uid, ids, *args): for id in ids: cr.execute('update res_request set state=%s,date_sent=%s where id=%d', ('waiting', time.strftime('%Y-%m-%d %H:%M:%S'), id)) cr.execute('select act_from,act_to,body,date_sent from res_request where id=%d', (id,)) values = cr.dictfetchone() if len(values['body']) > 128: values['name'] = values['body'][:125] + '...' else: values['name'] = values['body'] or '/' values['req_id'] = id self.pool.get('res.request.history').create(cr, uid, values) return True
473430fbb567f91aa716f08ee1107dd738e25713 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/12853/473430fbb567f91aa716f08ee1107dd738e25713/res_request.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 590, 67, 4661, 12, 2890, 16, 4422, 16, 4555, 16, 3258, 16, 380, 1968, 4672, 364, 612, 316, 3258, 30, 4422, 18, 8837, 2668, 2725, 400, 67, 2293, 444, 919, 5095, 87, 16, 712, 67, 7569,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 590, 67, 4661, 12, 2890, 16, 4422, 16, 4555, 16, 3258, 16, 380, 1968, 4672, 364, 612, 316, 3258, 30, 4422, 18, 8837, 2668, 2725, 400, 67, 2293, 444, 919, 5095, 87, 16, 712, 67, 7569,...
if uname -s | grep -iq Cygwin ; then MONO=; else MONO=mono; fi
if uname -s | grep -iq Cygwin then MONO= else MONO=mono VER=`mono -V | head -1 | sed s/'Mono JIT compiler version \(.*\) (.*'/'\1/'` if [[ 2.1 < "$VER" && "$VER" < 2.4.3 ]] then MONO="mono -O=-branch" fi fi
def copy_cli_exe(self): # XXX messy main_exe = self.c_entryp._exe usession_path, main_exe_name = os.path.split(main_exe) pypylib_dll = os.path.join(usession_path, 'pypylib.dll')
f27957cd0045ea5e588820c56eb4dc8d49c68b75 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/6934/f27957cd0045ea5e588820c56eb4dc8d49c68b75/driver.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1610, 67, 4857, 67, 14880, 12, 2890, 4672, 468, 11329, 12755, 93, 2774, 67, 14880, 273, 365, 18, 71, 67, 4099, 84, 6315, 14880, 584, 893, 67, 803, 16, 2774, 67, 14880, 67, 529, 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, 1610, 67, 4857, 67, 14880, 12, 2890, 4672, 468, 11329, 12755, 93, 2774, 67, 14880, 273, 365, 18, 71, 67, 4099, 84, 6315, 14880, 584, 893, 67, 803, 16, 2774, 67, 14880, 67, 529, 273, ...
cmd = 'INSERT INTO InputData (JobID,LFN) VALUES (\'%s\', \'%s\' )' % ( jobID, lfn )
cmd = 'INSERT INTO InputData (JobID,LFN) VALUES (\'%s\', \'%s\' )' % ( jobID, lfn.strip() )
def setInputData (self, jobID, inputData): """Inserts input data for the given job """ cmd = 'DELETE FROM InputData WHERE JobID=\'%s\'' % (jobID) result = self._update( cmd ) if not result['OK']: result = S_ERROR('JobDB.setInputData: operation failed.')
44e45e9ba1cc236ff32c3503c6786a1665efb3fe /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/12864/44e45e9ba1cc236ff32c3503c6786a1665efb3fe/JobDB.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 21687, 751, 261, 2890, 16, 28913, 16, 24149, 4672, 3536, 14214, 810, 501, 364, 326, 864, 1719, 3536, 1797, 273, 296, 6460, 4571, 2741, 751, 4852, 22137, 31343, 9, 87, 11421, 738, 261, 46...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 21687, 751, 261, 2890, 16, 28913, 16, 24149, 4672, 3536, 14214, 810, 501, 364, 326, 864, 1719, 3536, 1797, 273, 296, 6460, 4571, 2741, 751, 4852, 22137, 31343, 9, 87, 11421, 738, 261, 46...
snp_value2color = self.snp_value2five_color
snp_value2color = cls.snp_value2five_color
def drawRegionAroundThisSNP(self, phenotype_method_id, this_snp, candidate_gene_set, gene_annotation, snp_info, analysis_method_id2gwr, \ LD_info, output_dir, which_LD_statistic, snp_region=None, min_distance=40000, list_type_id=None, label_gene=0, draw_LD_relative_to_center_SNP=0, commit=0, snpData=None, phenData=None, ecotype_info=None,\ snpData_before_impute=None, snp_matrix_data_type=1): """ 2009-4-30 deal with argument snp_matrix_data_type =4 (arbitrary non-diallelic SNP matrix) could handle both (chr,pos) and (chr,pos,offset) SNP representation skip drawing gene models if no SNPs in the region at all. return None if no SNPs are found in the region. 2009-3-23 add arguments snp_matrix_data_type to allow CNV or CNV amplitude to fill the SNP matrix 2008-12-01 add option snpData_before_impute 2008-11-30 add code to replace axe_LD with axe_strain_pca, axe_snp_matrix, axe_map to demonstrate the haplotype structure, phenotype and geographic source of strains. 2008-10-24 handle option commit to return png_data & svg_data 2008-10-01 remove the frame of ax1 and add a grid to ax1 leave axe_gene_model's xticks there as otherwise ax1's xticks will go with it as they share xticks. 2008-10-01 draw gene models on a separate axe, add a twinx axe to draw LD w.r.t the center SNP if output_dir is not a directory, it's treated as a filename. 2008-09-24 """ sys.stderr.write("Drawing region ... \n") phenotype = Stock_250kDB.PhenotypeMethod.get(phenotype_method_id) if not os.path.isdir(output_dir): output_fname_prefix = output_dir else: #list_type = Stock_250kDB.GeneListType.get(list_type_id) fname_basename = 'snp_%s_%s_id_%s_phenotype_%s_%s'%\ (this_snp.chromosome, this_snp.position, this_snp.snps_id, phenotype.id, phenotype.short_name) fname_basename = fname_basename.replace('/', '_') output_fname_prefix = os.path.join(output_dir, fname_basename) if snp_region: snps_within_this_region = snp_region elif getattr(this_snp, 'stop', None): snps_within_this_region = self.findSNPsInRegion(snp_info, this_snp.chromosome, this_snp.position, this_snp.stop) snps_within_this_region_snpData = self.findSNPsInRegion(snpData, this_snp.chromosome, this_snp.position, this_snp.stop) else: snps_within_this_region = self.getSNPsAroundThisSNP(this_snp, snp_info, min_distance) snps_within_this_region_snpData = snps_within_this_region if len(snps_within_this_region.chr_pos_ls)==0 and len(snps_within_this_region_snpData.chr_pos_ls)==0: return None pylab.clf() #fig = pylab.figure() axe_y_offset1 = 0.05 #y_offset for axe_LD, axe_strain_pca, axe_phenotype, axe_map axe_height1 = 0.55 #height of axe_LD or axe_snp_matrix axe_y_offset2 = axe_y_offset1+axe_height1 axe_height2 = 0.1 #height of axe_gene_model axe_y_offset3 = axe_y_offset2+axe_height2 axe_height3 = 0.25 #height of ax1 axe_y_offset4 = axe_y_offset3+axe_height3 axe_x_offset1 = 0.02 # axe_width1 = 0.2 #width of axe_strain_pca axe_x_offset2 = axe_x_offset1 + axe_width1 axe_width2 = 0.55 #width of ax1, axe_LD, or axe_snp_matrix axe_x_offset3 = axe_x_offset2 + axe_width2 axe_width3 = 0.02 #width of axe_phenotype axe_x_offset4 = axe_x_offset3 + axe_width3 axe_width4 = 0.2 #width of axe_map, axe_map_frame axe_x_offset5 = axe_x_offset4 + axe_width4 no_of_axes_drawn = 0 ax1 = pylab.axes([axe_x_offset2, axe_y_offset3, axe_width2, axe_height3], frameon=False) #left gap, bottom gap, width, height, axes for pvalue, gene models ax1.grid(True, alpha=0.3) ax1.set_xticklabels([]) #remove xtick labels on ax1 because axe_LD's xtick labels cover this. axe_LD_center_SNP = pylab.twinx() #axes for LD with center SNP, copy ax1's axe_LD_center_SNP.set_xticklabels([]) axe_gene_model = pylab.axes([axe_x_offset2, axe_y_offset2, axe_width2, axe_height2], frameon=False, sharex=ax1) #axe_gene_model.set_xticks([]) #this will set ax1's xticks off as well because the x-axis is shared. axe_gene_model.set_yticks([]) snp_region_tup = [snps_within_this_region_snpData.chr_pos_ls[0][0], snps_within_this_region_snpData.chr_pos_ls[0][1],\ snps_within_this_region_snpData.chr_pos_ls[-1][0], snps_within_this_region_snpData.chr_pos_ls[-1][1]] axe_snp_matrix_margin = abs(snp_region_tup[3]-snp_region_tup[1])/15. #offset to push strain labels on even rows further right if LD_info: axe_LD = pylab.axes([axe_x_offset2, axe_y_offset1, axe_width2, axe_height1], frameon=False) #axes for LD axe_LD_legend = pylab.axes([axe_x_offset3-0.1, axe_y_offset1+0.03, 0.1, 0.13], frameon=False) #axes for the legend of LD axe_LD_legend.set_xticks([]) axe_LD_legend.set_yticks([]) axe_to_put_pvalue_legend = axe_LD legend_loc = 'lower left' axe_pvalue_xlim = [snp_region_tup[1]-axe_snp_matrix_margin, snp_region_tup[3]+axe_snp_matrix_margin] elif snpData: phenotype_col_index = PlotGroupOfSNPs.findOutWhichPhenotypeColumn(phenData, Set([phenotype_method_id]))[0] genome_wide_result = analysis_method_id2gwr.get(1) if not genome_wide_result: sys.stderr.write("No genome association results for phenotype_method_id=%s, analysis_method_id=%s. Take a random one out of analysis_method_id2gwr.\n"%\ (phenotype_method_id, 1)) genome_wide_result = analysis_method_id2gwr.values()[0] #take random gwr if snp_matrix_data_type==1: chr_pos_ls = None else: chr_pos_ls = snpData.chr_pos2index.keys() #2008-12-08 for CNV probes. use snpData.chr_pos2index.keys() to locate top_snp_data because here snpData doesn't match genome_wide_result. top_snp_data = self.getTopSNPData(genome_wide_result, None, snp_region_tup, chr_pos_ls=chr_pos_ls) if snp_matrix_data_type==3: #2009-3-23 for CNV amplitude data, don't convert alleles into binary 0/1=major/minor form and use allele/amplitude to determine alpha need_convert_alleles2binary = False useAlleleToDetermineAlpha = True elif snp_matrix_data_type==4: #2009-3-27, for arbitrary non-diallelic SNP matrix need_convert_alleles2binary = False useAlleleToDetermineAlpha = False else: need_convert_alleles2binary = True useAlleleToDetermineAlpha = False subSNPData = self.getSubStrainSNPMatrix(snpData, phenData, phenotype_method_id, phenotype_col_index, top_snp_data.snp_id_ls, need_convert_alleles2binary=need_convert_alleles2binary) #2009-3-23 last argument is for CNV intensity matrix snp_value2color = None if snp_matrix_data_type==4: ##2009-3-27 it's for SNP matrix inferred from raw sequences, might have >2 alleles, heterozygous calls, deletions etc. from DrawSNPMatrix import DrawSNPMatrix subSNPData.data_matrix = DrawSNPMatrix.transformMatrixIntoTwoAllelesAndHetero(subSNPData.data_matrix) snp_value2color = self.snp_value2five_color #the two offsets below decides where the label of strains/snps should start in axe_snp_matrix last_chr_pos = snps_within_this_region_snpData.chr_pos_ls[-1] strain_id_label_x_offset=snps_within_this_region_snpData.chr_pos2adjacent_window[last_chr_pos][1] #right next to the rightmost SNP snp_id_label_y_offset=0.95 StrainID2PCAPosInfo = self.getStrainID2PCAPosInfo(subSNPData, pca_range=[0,1], snp_id_label_y_offset=snp_id_label_y_offset) #fake one SNPID2PCAPosInfo only for drawSNPMtrix() SNPID2PCAPosInfo = PassingData(step=None, snp_id2img_x_pos={}) for chr_pos, adjacent_window in snps_within_this_region_snpData.chr_pos2adjacent_window.iteritems(): chr_pos = map(str, chr_pos) snp_id = '_'.join(chr_pos) SNPID2PCAPosInfo.snp_id2img_x_pos[snp_id] = adjacent_window phenotype_cmap = mpl.cm.jet max_phenotype = numpy.nanmax(phenData.data_matrix[:,phenotype_col_index]) min_phenotype = numpy.nanmin(phenData.data_matrix[:,phenotype_col_index]) phenotype_gap = max_phenotype - min_phenotype phenotype_jitter = phenotype_gap/10. phenotype_norm = mpl.colors.Normalize(vmin=min_phenotype-phenotype_jitter, vmax=max_phenotype+phenotype_jitter) axe_map_phenotype_legend = pylab.axes([axe_x_offset4+0.02, axe_y_offset1, axe_width4-0.02, axe_height1/10.], frameon=False) cb = mpl.colorbar.ColorbarBase(axe_map_phenotype_legend, cmap=phenotype_cmap, norm=phenotype_norm, orientation='horizontal') cb.set_label('Phenotype Legend On the Map') axe_strain_map = None #no strain map axe_strain_pca = pylab.axes([axe_x_offset1, axe_y_offset1, axe_width1, axe_height1], frameon=False) axe_strain_map_pca_cover = None #not used. axe_strain_pca_xlim = [-0.05,1.05] axe_strain_pca_ylim = [0, 1] axe_strain_pca.set_xlim(axe_strain_pca_xlim) axe_strain_pca.set_ylim(axe_strain_pca_ylim) axe_strain_pca.grid(True, alpha=0.3) axe_strain_pca.set_xticks([]) axe_strain_pca.set_yticks([]) axe_strain_pca_legend =None self.drawStrainPCA(axe_strain_pca, axe_strain_map, axe_strain_map_pca_cover, axe_strain_pca_legend, StrainID2PCAPosInfo, \ ecotype_info, phenData, \ phenotype_col_index, phenotype_cmap, phenotype_norm, rightmost_x_value=axe_strain_pca_xlim[1],\ country_order_name='', strain_color_type=2, draw_axe_strain_map=False) axe_strain_pca.set_xlim(axe_strain_pca_xlim) axe_strain_pca.set_ylim(axe_strain_pca_ylim) no_of_axes_drawn += 1 if self.debug: pylab.savefig('%s_%s.png'%(output_fname_prefix, no_of_axes_drawn), dpi=400) #mark ecotypes on the map colored according to phenotype axe_map = pylab.axes([axe_x_offset4, axe_y_offset1, axe_width4, axe_height1], frameon=False) #axe_map_frame is used to connect strains from axe_phenotype to dot on the axe_map (another axe due to reasons stated in drawMap()) axe_map_frame = pylab.axes([axe_x_offset4, axe_y_offset1, axe_width4, axe_height1], frameon=False, sharey=axe_strain_pca) axe_map_frame.set_xticks([]) axe_map_frame.set_yticks([]) self.drawMap(axe_map_frame, axe_map, StrainID2PCAPosInfo, phenData, phenotype_col_index, phenotype_method_id, \ ecotype_info, phenotype_cmap, phenotype_norm) #axe_map.set_ylim([0,1]) no_of_axes_drawn += 1 if self.debug: pylab.savefig('%s_%s.png'%(output_fname_prefix, no_of_axes_drawn), dpi=400) axe_snp_matrix = pylab.axes([axe_x_offset2, axe_y_offset1, axe_width2, axe_height1], frameon=False, sharey=axe_strain_pca) #axe_snp_matrix.set_xticks([]) axe_snp_matrix.set_yticks([]) self.drawSNPMtrix(axe_snp_matrix, subSNPData, top_snp_data, StrainID2PCAPosInfo, SNPID2PCAPosInfo, \ ecotype_info, strain_id_label_x_offset, snp_id_label_y_offset, strain_id_label_x_offset_extra=axe_snp_matrix_margin,\ draw_snp_id_label=False, snpData_before_impute=snpData_before_impute, \ useAlleleToDetermineAlpha=useAlleleToDetermineAlpha,\ snp_value2color=snp_value2color) #2008-11-14 turn draw_snp_id_label off #axe_snp_matrix.set_xlim([0,1]) #axe_snp_matrix.set_ylim([0,1]) no_of_axes_drawn += 1 #pylab.savefig('%s_%s.png'%(self.output_fname_prefix, no_of_axes_drawn), dpi=400) axe_phenotype = pylab.axes([axe_x_offset3, axe_y_offset1, axe_width3, axe_height1], frameon=False, sharey=axe_snp_matrix) axe_phenotype.set_yticks([]) axe_phenotype.set_xticklabels([]) #no tick labels (axe_map_phenotype_legend has it already) self.drawPhenotype(axe_phenotype, StrainID2PCAPosInfo, phenData, phenotype_col_index, phenotype_method_id, ecotype_info) no_of_axes_drawn += 1 axe_phenotype.set_ylim([0,1]) axe_snp_matrix.set_ylim([0,1]) #without this, ylim of all 3 axes are set to [0,0.9] because axe_map automatically adjust to 0-0.9 #pylab.savefig('%s_%s.png'%(self.output_fname_prefix, no_of_axes_drawn), dpi=400) axe_to_put_pvalue_legend = ax1 #axe_LD is gone. put legend into ax1 itself. legend_loc = 'upper right' axe_LD = None axe_LD_legend = None axe_pvalue_xlim = [snp_region_tup[1]-axe_snp_matrix_margin, snp_region_tup[3]+axe_snp_matrix_margin*2] fig_title = 'SNP chr %s. pos %s.'%(this_snp.chromosome, this_snp.position) if getattr(this_snp, 'stop', None): fig_title += ' - %s. '%this_snp.stop fig_title += "Phenotype %s (id=%s)."%(phenotype.short_name, phenotype.id) ax1.title.set_text(fig_title) #main title using this snp. self.drawPvalue(ax1, axe_to_put_pvalue_legend, axe_LD_center_SNP, snps_within_this_region, analysis_method_id2gwr, LD_info, \ which_LD_statistic, draw_LD_relative_to_center_SNP=draw_LD_relative_to_center_SNP, legend_loc=legend_loc) gene_position_cycle = 5 base_y_value = 1 gene_width=0.8 gene_box_text_gap = min_distance*2*0.005 skip_gene_model = False if len(snps_within_this_region.chr_pos_ls)>0: _snps_within_this_region = snps_within_this_region elif len(snps_within_this_region_snpData.chr_pos_ls)>0: _snps_within_this_region = snps_within_this_region_snpData else: skip_gene_model = True if not skip_gene_model: return_data = self.drawGeneModel(axe_gene_model, _snps_within_this_region, gene_annotation, \ candidate_gene_set, gene_width=gene_width, gene_position_cycle=gene_position_cycle, \ base_y_value=base_y_value, gene_box_text_gap=gene_box_text_gap,\ label_gene=label_gene) matrix_of_gene_descriptions = return_data.matrix_of_gene_descriptions gene_model_min_y = base_y_value-gene_width gene_model_max_y = gene_position_cycle + base_y_value -1 + gene_width #"-1" because genes never sit on y=gene_position_cycle + base_y_value if not skip_gene_model: self.drawLD(axe_gene_model, axe_LD, _snps_within_this_region, LD_info, gene_model_min_y=gene_model_min_y,\ gene_model_max_y=gene_model_max_y, which_LD_statistic=which_LD_statistic) if LD_info: self.drawLDLegend(axe_LD_legend, which_LD_statistic) #adjust x, y limits and etc ax1.set_xlim(axe_pvalue_xlim) ax1_ylim = ax1.get_ylim() ax1.set_ylim((0, ax1_ylim[1])) #set ax1 to 0 to sit right above axe_gene_model axe_gene_model.set_ylim((gene_model_min_y, gene_model_max_y)) #LD panel right under gene models if LD_info: axe_LD.set_xlim(ax1.get_xlim()) #make the axe_LD and ax1 within the same X range axe_LD_x_span = (axe_LD.get_xlim()[1]-axe_LD.get_xlim()[0]) axe_LD.set_ylim((-axe_LD_x_span/2., 0)) #has to force here, don't know why. otherwise it's (0,1) axe_LD.set_yticks([]) #remove all Y ticks on LD plot elif snpData: axe_snp_matrix.set_xlim(ax1.get_xlim()) png_data = None svg_data = None png_output_fname = None if len(snps_within_this_region.chr_pos_ls)>0: distance = abs(snps_within_this_region.chr_pos_ls[-1][1] - snps_within_this_region.chr_pos_ls[0][1]) elif len(snps_within_this_region_snpData.chr_pos_ls)>0: distance = abs(snps_within_this_region_snpData.chr_pos_ls[-1][1] - snps_within_this_region_snpData.chr_pos_ls[0][1]) else: distance = 0 if commit: #2008-10-24 png_data = StringIO.StringIO() svg_data = StringIO.StringIO() pylab.savefig(png_data, format='png', dpi=600) if distance<=20000: #save the svg format if less than 80kb pylab.savefig(svg_data, format='svg', dpi=300) else: png_output_fname = '%s.png'%output_fname_prefix pylab.savefig(png_output_fname, dpi=600) if distance<=20000: #save the svg format if less than 80kb pylab.savefig('%s.svg'%output_fname_prefix, dpi=300) if self.debug: pylab.show() del ax1, axe_LD_center_SNP, axe_gene_model, axe_LD, axe_LD_legend sys.stderr.write("Done.\n") after_plot_data = PassingData(png_output_fname=png_output_fname, matrix_of_gene_descriptions=matrix_of_gene_descriptions, \ png_data=png_data,\ svg_data=svg_data,\ snps_within_this_region=snps_within_this_region) return after_plot_data
bdc3752350001c791e90fb2760fcc0578318b113 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9645/bdc3752350001c791e90fb2760fcc0578318b113/DrawSNPRegion.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3724, 5165, 30022, 2503, 13653, 52, 12, 2890, 16, 28825, 67, 2039, 67, 350, 16, 333, 67, 87, 6782, 16, 5500, 67, 11857, 67, 542, 16, 7529, 67, 11495, 16, 28648, 67, 1376, 16, 6285, 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, 3724, 5165, 30022, 2503, 13653, 52, 12, 2890, 16, 28825, 67, 2039, 67, 350, 16, 333, 67, 87, 6782, 16, 5500, 67, 11857, 67, 542, 16, 7529, 67, 11495, 16, 28648, 67, 1376, 16, 6285, 6...
version_number = float(version.split('/', 1)[1]) except ValueError:
base_version_number = version.split('/', 1)[1] version_number = base_version_number.split(".") if len(version_number) != 2: raise ValueError version_number = int(version_number[0]), int(version_number[1]) except (ValueError, IndexError):
def parse_request(self): """Parse a request (internal).
5f4df3753eb974dbd1cf239be74f9c0bc8da5122 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8125/5f4df3753eb974dbd1cf239be74f9c0bc8da5122/BaseHTTPServer.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1109, 67, 2293, 12, 2890, 4672, 3536, 3201, 279, 590, 261, 7236, 2934, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 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, 1109, 67, 2293, 12, 2890, 4672, 3536, 3201, 279, 590, 261, 7236, 2934, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, ...
elif message.type == gst.MESSAGE_SEGMENT_DONE:
elif message.type == gst.MESSAGE_EOS:
def _bus_watch(self, bus, message): if message.type == gst.MESSAGE_ERROR: print 'error', message self._stop_queries() m = gtk.MessageDialog(self.window, gtk.DIALOG_MODAL|gtk.DIALOG_DESTROY_WITH_PARENT, gtk.MESSAGE_ERROR, gtk.BUTTONS_CLOSE, "Error processing file") gerror, debug = message.parse_error() txt = ('There was an error processing your file: %s\n\n' 'Debug information:\n%s' % (gerror, debug)) m.format_secondary_text(txt) m.run() m.destroy() self.response(FAILURE) elif message.type == gst.MESSAGE_WARNING: print 'warning', message elif message.type == gst.MESSAGE_SEGMENT_DONE: # print 'eos, woot', message.src name = self.touri if name.startswith('file://'): name = name[7:] self.pdialog.set_task('Finished writing %s' % name) self.pdialog.update_position(self.stop_time) self._stop_queries() self.pdialog.set_completed(True) elif message.type == gst.MESSAGE_STATE_CHANGED: if message.src == self: old, new, pending = message.parse_state_changed() if ((old, new, pending) == (gst.STATE_READY, gst.STATE_PAUSED, gst.STATE_VOID_PENDING)): self.pdialog.set_task('Processing file') self.pdialog.update_position(self.start_time) self._start_queries() self.set_state(gst.STATE_PLAYING)
fd2078bb04e171e9715c0d5d0dda7af535ded793 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/1020/fd2078bb04e171e9715c0d5d0dda7af535ded793/remuxer.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 9274, 67, 7585, 12, 2890, 16, 5766, 16, 883, 4672, 309, 883, 18, 723, 422, 314, 334, 18, 8723, 67, 3589, 30, 1172, 296, 1636, 2187, 883, 365, 6315, 5681, 67, 13748, 1435, 312, 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, 389, 9274, 67, 7585, 12, 2890, 16, 5766, 16, 883, 4672, 309, 883, 18, 723, 422, 314, 334, 18, 8723, 67, 3589, 30, 1172, 296, 1636, 2187, 883, 365, 6315, 5681, 67, 13748, 1435, 312, 2...
di = result[index] yield Instruction(di, code[codeOffset + delta : codeOffset + delta + di.size])
di = result[index] yield Instruction(di, code[instruction_off : instruction_off + di.size])
def DecomposeGenerator(codeOffset, code, dt): """ @type codeOffset: long @param codeOffset: Memory address where the code is located. This is B{not} an offset into the code! It's the actual memory address where it was read from. @type code: str @param code: Code to disassemble. @type dt: int @param dt: Disassembly type. Can be one of the following: * L{Decode16Bits}: 80286 decoding * L{Decode32Bits}: IA-32 decoding * L{Decode64Bits}: AMD64 decoding @rtype: generator of TODO @return: Generator of TODO @raise ValueError: Invalid arguments. """ if not code: return if not codeOffset: codeOffset = 0 if dt not in (Decode16Bits, Decode32Bits, Decode64Bits): raise ValueError("Invalid decode type value: %r" % (dt,)) codeLen = len(code) code = create_string_buffer(code) p_code = addressof(code) result = (_DInst * MAX_INSTRUCTIONS)() p_result = byref(result) codeInfo = _CodeInfo(_OffsetType(codeOffset), _OffsetType(0), p_code, codeLen, dt, 0) while codeLen > 0: usedInstructionsCount = c_uint(0) status = internal_decompose(byref(codeInfo), p_result, MAX_INSTRUCTIONS, byref(usedInstructionsCount)) if status == DECRES_INPUTERR: raise ValueError("Invalid arguments passed to distorm_decode()") used = usedInstructionsCount.value if not used: break delta = 0 for index in xrange(used): di = result[index] yield Instruction(di, code[codeOffset + delta : codeOffset + delta + di.size]) delta += di.size if delta <= 0: break codeOffset = codeOffset + delta p_code = p_code + delta codeLen = codeLen - delta
b14352da15a7f1400c88d0dc92ac6c391430eee6 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/4918/b14352da15a7f1400c88d0dc92ac6c391430eee6/__init__.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 26824, 4150, 3908, 12, 710, 2335, 16, 981, 16, 3681, 4672, 3536, 632, 723, 225, 981, 2335, 30, 1525, 632, 891, 981, 2335, 30, 9251, 1758, 1625, 326, 981, 353, 13801, 18, 1220, 353, 605...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 26824, 4150, 3908, 12, 710, 2335, 16, 981, 16, 3681, 4672, 3536, 632, 723, 225, 981, 2335, 30, 1525, 632, 891, 981, 2335, 30, 9251, 1758, 1625, 326, 981, 353, 13801, 18, 1220, 353, 605...
if cf in RR: if not 0 < cf < 1: msg = "The argument cf (=%s) must be in ]0,1[."%cf raise NotImplementedError, msg
if slope in RR: if not 0 < slope < 1: msg = "The argument slope (=%s) must be in ]0,1[."%slope raise ValueError, msg
sage: def cf():
d352084048076a1147fa81ffe09ce8981f274743 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/9890/d352084048076a1147fa81ffe09ce8981f274743/word_generators.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 272, 410, 30, 1652, 6080, 13332, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 272, 410, 30, 1652, 6080, 13332, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -1...
self.offset += amount
self.address += amount
def consume(self, amount): res = memory._read(self.address, amount) self.offset += amount return res
8003dbc9e734c08d60cca0b2c3cd7789c7b670d1 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/6676/8003dbc9e734c08d60cca0b2c3cd7789c7b670d1/provider.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 7865, 12, 2890, 16, 3844, 4672, 400, 273, 3778, 6315, 896, 12, 2890, 18, 2867, 16, 3844, 13, 365, 18, 2867, 1011, 3844, 327, 400, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 7865, 12, 2890, 16, 3844, 4672, 400, 273, 3778, 6315, 896, 12, 2890, 18, 2867, 16, 3844, 13, 365, 18, 2867, 1011, 3844, 327, 400, 2, -100, -100, -100, -100, -100, -100, -100, -100, -10...
</tr>""" % (nbhits, weburl, urllib.quote(word), urllib.quote(f), urlarg_colls, word) elif len(browsed_words_in_colls) > 1:
</tr>""" % (nbhits, weburl, urllib.quote(phrase), urllib.quote(f), urlarg_colls, phrase) elif len(browsed_phrases_in_colls) > 1:
def browse_pattern(req, colls, p, f, rg): """Browse either biliographic phrases or words indexes, and display it.""" ## do we search in words indexes? if not f: return browse_in_bibwords(req, p, f) ## prepare collection urlargument for later printing: p_orig = p urlarg_colls = "" for coll in colls: urlarg_colls += "&c=%s" % urllib.quote(coll) ## okay, "real browse" follows: browsed_words = browse_in_bibxxx(p, f, rg) while not browsed_words: # try again and again with shorter and shorter pattern: try: p = p[:-1] browsed_words = browse_in_bibxxx(p, f, rg) except: # probably there are no hits at all: req.write("<p>No values found.") return ## try to check hits in these particular collection selection: browsed_words_in_colls = [] for word,nbhits in browsed_words: word_hitlist = HitList() word_hitlists = search_pattern("", word, f, colls, 'e') for coll in colls: word_hitlist.union(word_hitlists[coll]) word_hitlist.calculate_nbhits() if word_hitlist._nbhits > 0: # okay, this word has some hits in colls, so add it: browsed_words_in_colls.append([word, word_hitlist._nbhits]) ## were there hits in collections? if browsed_words_in_colls == []: if browsed_words != []: print_warning(req, """<p>No match close to <em>%s</em> found in given collections. Please try different term.<p>Displaying matches in any collection...""" % p_orig, "") browsed_words_in_colls = browsed_words ## display results now: out = """<table class="searchresultsbox"> <thead> <tr> <th class="searchresultsboxheader" align="left"> hits </th> <th class="searchresultsboxheader" width="15"> &nbsp; </th> <th class="searchresultsboxheader" align="left"> %s </th> </tr> </thead> <tbody>""" % f if len(browsed_words_in_colls) == 1: # one hit only found: word, nbhits = browsed_words_in_colls[0][0], browsed_words_in_colls[0][1] out += """<tr> <td class="searchresultsboxbody" align="right"> %s </td> <td class="searchresultsboxbody" width="15"> &nbsp; </td> <td class="searchresultsboxbody" align="left"> <a href="%s/search.py?p=%%22%s%%22&f=%s%s">%s</a> </td> </tr>""" % (nbhits, weburl, urllib.quote(word), urllib.quote(f), urlarg_colls, word) elif len(browsed_words_in_colls) > 1: # first display what was found but the last one: for word, nbhits in browsed_words_in_colls[:-1]: out += """<tr> <td class="searchresultsboxbody" align="right"> %s </td> <td class="searchresultsboxbody" width="15"> &nbsp; </td> <td class="searchresultsboxbody" align="left"> <a href="%s/search.py?p=%%22%s%%22&f=%s%s">%s</a> </td> </tr>""" % (nbhits, weburl, urllib.quote(word), urllib.quote(f), urlarg_colls, word) # now display last hit as "next term": word, nbhits = browsed_words_in_colls[-1] out += """<tr><td colspan="2" class="normal"> &nbsp; </td> <td class="normal"> <img src="%s/img/sn.gif" alt="" border="0"> next %s: <a href="%s/search.py?search=Browse&p=%s&f=%s%s">%s</a> </td> </tr>""" % (weburl, f, weburl, urllib.quote(word), urllib.quote(f), urlarg_colls, word) out += """</tbody> </table>""" req.write(out) return
c8bc8e9e8dcaad50892504a6b2ad935d0e8bb72d /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12027/c8bc8e9e8dcaad50892504a6b2ad935d0e8bb72d/search_engine.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 21670, 67, 4951, 12, 3658, 16, 645, 3251, 16, 293, 16, 284, 16, 14524, 4672, 3536, 27304, 3344, 324, 15700, 16983, 31413, 578, 4511, 5596, 16, 471, 2562, 518, 12123, 7541, 741, 732, 1623...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 21670, 67, 4951, 12, 3658, 16, 645, 3251, 16, 293, 16, 284, 16, 14524, 4672, 3536, 27304, 3344, 324, 15700, 16983, 31413, 578, 4511, 5596, 16, 471, 2562, 518, 12123, 7541, 741, 732, 1623...
return pooler.get_pool(self.cr.dbname).get('account.period').browse(self.cr,self.uid,form['period_from']).name
if 'period_from' in form and form['period_from']: return pooler.get_pool(self.cr.dbname).get('account.period').browse(self.cr,self.uid,form['period_from']).name return ''
def get_start_period(self, form): return pooler.get_pool(self.cr.dbname).get('account.period').browse(self.cr,self.uid,form['period_from']).name
af7c1f1bbe12cb2d916d673dd7c4ab1da7072471 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/7397/af7c1f1bbe12cb2d916d673dd7c4ab1da7072471/account_journal.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 67, 1937, 67, 6908, 12, 2890, 16, 646, 4672, 327, 2845, 264, 18, 588, 67, 6011, 12, 2890, 18, 3353, 18, 20979, 2934, 588, 2668, 4631, 18, 6908, 16063, 25731, 12, 2890, 18, 3353, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 67, 1937, 67, 6908, 12, 2890, 16, 646, 4672, 327, 2845, 264, 18, 588, 67, 6011, 12, 2890, 18, 3353, 18, 20979, 2934, 588, 2668, 4631, 18, 6908, 16063, 25731, 12, 2890, 18, 3353, ...
print 'SSH key setup complete'
self.ssh_host_log.debug('SSH key setup complete.')
def ssh_setup_key(self): try: print ('Performing ssh key setup on %s:%d as %s' % (self.hostname, self.port, self.user))
9d4e615576cfebafef9ccd86e7f480a5e9b92427 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/12268/9d4e615576cfebafef9ccd86e7f480a5e9b92427/ssh_host.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 7056, 67, 8401, 67, 856, 12, 2890, 4672, 775, 30, 1172, 7707, 4990, 310, 7056, 498, 3875, 603, 738, 87, 5319, 72, 487, 738, 87, 11, 738, 261, 2890, 18, 10358, 16, 365, 18, 655, 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, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 7056, 67, 8401, 67, 856, 12, 2890, 4672, 775, 30, 1172, 7707, 4990, 310, 7056, 498, 3875, 603, 738, 87, 5319, 72, 487, 738, 87, 11, 738, 261, 2890, 18, 10358, 16, 365, 18, 655, 16, ...
""" Returns the session value for one key """
def getSession(self, key, default): """ Returns the session value for one key """ return self.__getSession(key, default)
5e2c32dd33871476397a4f10e62760ac351975c5 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/3287/5e2c32dd33871476397a4f10e62760ac351975c5/session_manager.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 7183, 12, 2890, 16, 498, 16, 805, 4672, 327, 365, 16186, 588, 2157, 12, 856, 16, 805, 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, 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, 7183, 12, 2890, 16, 498, 16, 805, 4672, 327, 365, 16186, 588, 2157, 12, 856, 16, 805, 13, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -...
output.identifier+"-"+self.pid),"w") f.write(output.value)
"%s-%s" % (output.identifier,self.pid)),"w") f.write(str(output.value))
def _asReferenceOutput(self,templateOutput, output):
2374ca5206aa0076b3474128c4419ce257cea096 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/10967/2374ca5206aa0076b3474128c4419ce257cea096/Execute.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 345, 2404, 1447, 12, 2890, 16, 3202, 1447, 16, 876, 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, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 345, 2404, 1447, 12, 2890, 16, 3202, 1447, 16, 876, 4672, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, ...
"its text was '%s'." % (locator, excepted, actual) raise AssertionError(message) def element_text_should_be(self, locator, excepted, message=''):
"its text was '%s'." % (locator, expected, actual) raise AssertionError(message) def element_text_should_be(self, locator, expected, message=''):
def element_should_contain(self, locator, excepted, message=''): """Verifies element identified by `locator` contains text `expected`.
7e5a3533b01b02f3592aed251c78e2c3aac0db38 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/2148/7e5a3533b01b02f3592aed251c78e2c3aac0db38/assertion.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 930, 67, 13139, 67, 28744, 12, 2890, 16, 8871, 16, 1335, 329, 16, 883, 2218, 11, 4672, 3536, 19802, 930, 9283, 635, 1375, 20048, 68, 1914, 977, 1375, 3825, 8338, 2, 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, 930, 67, 13139, 67, 28744, 12, 2890, 16, 8871, 16, 1335, 329, 16, 883, 2218, 11, 4672, 3536, 19802, 930, 9283, 635, 1375, 20048, 68, 1914, 977, 1375, 3825, 8338, 2, -100, -100, -100, -...
data = c.getresponse().read()
data = c2.getresponse().read()
def test_HTTPSConnection_resume_session(self): pid = self.start_server(self.args) try: from M2Crypto import httpslib ctx = SSL.Context() ctx.load_verify_locations(cafile='tests/ca.pem') ctx.load_cert('tests/x509.pem') ctx.set_verify(SSL.verify_peer | SSL.verify_fail_if_no_peer_cert, 1) ctx.set_session_cache_mode(m2.SSL_SESS_CACHE_CLIENT) c = httpslib.HTTPSConnection(srv_host, srv_port, ssl_context=ctx) c.request('GET', '/') ses = c.get_session() t = ses.as_text() data = c.getresponse().read() c.close() ctx2 = SSL.Context() ctx2.load_verify_locations(cafile='tests/ca.pem') ctx2.load_cert('tests/x509.pem') ctx2.set_verify(SSL.verify_peer | SSL.verify_fail_if_no_peer_cert, 1) ctx2.set_session_cache_mode(m2.SSL_SESS_CACHE_CLIENT) c = httpslib.HTTPSConnection(srv_host, srv_port, ssl_context=ctx2) c.set_session(ses) c.request('GET', '/') ses2 = c.get_session() t2 = ses2.as_text() data = c.getresponse().read() c.close() assert t == t2, "Sessions did not match" finally: self.stop_server(pid) self.failIf(string.find(data, 's_server -quiet -www') == -1)
1a720a5c0213dd83b1591c8f9447ce741fa77206 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/8055/1a720a5c0213dd83b1591c8f9447ce741fa77206/test_ssl.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1842, 67, 18657, 1952, 67, 25158, 67, 3184, 12, 2890, 4672, 4231, 273, 365, 18, 1937, 67, 3567, 12, 2890, 18, 1968, 13, 775, 30, 628, 490, 22, 18048, 1930, 1062, 24760, 1103, 273, 7419...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 18657, 1952, 67, 25158, 67, 3184, 12, 2890, 4672, 4231, 273, 365, 18, 1937, 67, 3567, 12, 2890, 18, 1968, 13, 775, 30, 628, 490, 22, 18048, 1930, 1062, 24760, 1103, 273, 7419...
fileobj = file(filename, 'w') try: config.write(fileobj) fileobj.close() finally: fileobj.close()
config.save()
def _update_sample_config(self): from ConfigParser import ConfigParser config = ConfigParser() for section, options in self.config.defaults().items(): config.add_section(section) for name, value in options.items(): config.set(section, name, value) filename = os.path.join(self.env.path, 'conf', 'trac.ini.sample') try: fileobj = file(filename, 'w') try: config.write(fileobj) fileobj.close() finally: fileobj.close() self.log.info('Wrote sample configuration file with the new ' 'settings and their default values: %s', filename) except IOError, e: self.log.warn('Couldn\'t write sample configuration file (%s)', e, exc_info=True)
aba7d1bd7c048b1062a093f867de5968d23095ba /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/2831/aba7d1bd7c048b1062a093f867de5968d23095ba/env.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 2725, 67, 6358, 67, 1425, 12, 2890, 4672, 628, 25076, 1930, 25076, 642, 273, 25076, 1435, 364, 2442, 16, 702, 316, 365, 18, 1425, 18, 7606, 7675, 3319, 13332, 642, 18, 1289, 67, 3...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 2725, 67, 6358, 67, 1425, 12, 2890, 4672, 628, 25076, 1930, 25076, 642, 273, 25076, 1435, 364, 2442, 16, 702, 316, 365, 18, 1425, 18, 7606, 7675, 3319, 13332, 642, 18, 1289, 67, 3...
nim.advanced.lnb[x].longitude = configElement(cname + "advanced.lnb" + str(x) + ".longitude", configSequence, [5,100], configsequencearg.get("FLOAT", [(0,90),(0,999)])); nim.advanced.lnb[x].longitudeOrientation = configElement(cname + "advanced.lnb" + str(x) + ".longitudeOrientation", configSelection, 0, (_("East"), _("West"))) nim.advanced.lnb[x].latitude = configElement(cname + "advanced.lnb" + str(x) + ".latitude", configSequence, [50,767], configsequencearg.get("FLOAT", [(0,90),(0,999)]));
nim.advanced.lnb[x].longitude = configElement(cname + "advanced.lnb" + str(x) + ".longitude", configSequence, [5,100], configsequencearg.get("FLOAT", [(0,90),(0,999)])) nim.advanced.lnb[x].longitudeOrientation = configElement(cname + "advanced.lnb" + str(x) + ".longitudeOrientation", configSelection, 0, (("east", _("East")), ("west", _("West")))) nim.advanced.lnb[x].latitude = configElement(cname + "advanced.lnb" + str(x) + ".latitude", configSequence, [50,767], configsequencearg.get("FLOAT", [(0,90),(0,999)]))
def nimPortDChanged(slotid, configElement): nimmgr.nimPortDChanged(slotid, configElement.vals[configElement.value][1])
f503f202686fc9ff6859cf834e9a021922011b81 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/6652/f503f202686fc9ff6859cf834e9a021922011b81/NimManager.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 290, 381, 2617, 40, 5033, 12, 14194, 350, 16, 642, 1046, 4672, 290, 381, 13552, 18, 82, 381, 2617, 40, 5033, 12, 14194, 350, 16, 642, 1046, 18, 4524, 63, 1425, 1046, 18, 1132, 6362, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 290, 381, 2617, 40, 5033, 12, 14194, 350, 16, 642, 1046, 4672, 290, 381, 13552, 18, 82, 381, 2617, 40, 5033, 12, 14194, 350, 16, 642, 1046, 18, 4524, 63, 1425, 1046, 18, 1132, 6362, ...
try: self.total_vertices = len (self.vertex_list) except: print "ERROR: len ( ) exception 3" self.total_vertices = 0 self.vertex_list = [ ]
self.total_vertices = len (self.vertex_list)
def add_vertex (self, vertex_id, vertex_function, context):
cab9650924a72c9f0b9c2a8a02f7f0906f765e43 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/7242/cab9650924a72c9f0b9c2a8a02f7f0906f765e43/MotionTrail.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 527, 67, 15281, 261, 2890, 16, 5253, 67, 350, 16, 5253, 67, 915, 16, 819, 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, ...
[ 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 527, 67, 15281, 261, 2890, 16, 5253, 67, 350, 16, 5253, 67, 915, 16, 819, 4672, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, ...
values.append(key) for val in values: if val in overrides and seo_items.get(val+SUFFIX): state = self.setProperty(PROP_PREFIX+val, seo_items[val]) if state: return state elif context.hasProperty(PROP_PREFIX+val): delete_list.append(PROP_PREFIX+val)
seo_keys.append(key) for seo_key in seo_keys: if seo_key == 'custommetatags': self.manageSEOCustomMetaTagsProperties(**kw) else: if seo_key in seo_overrides_keys and seo_items.get(seo_key+SUFFIX): seo_value = seo_items[seo_key] t_value = 'string' if type(seo_value)==type([]) or type(seo_value)==type(()): t_value = 'lines' state = self.setProperty(PROP_PREFIX+seo_key, seo_value, type=t_value) if state: return state elif context.hasProperty(PROP_PREFIX+seo_key): delete_list.append(PROP_PREFIX+seo_key)
def manageSEOProps(self, **kw): context = aq_inner(self.context) state = '' delete_list, overrides, values = [], [], [] seo_items = dict([(k[len(SEO_PREFIX):],v) for k,v in kw.items() if k.startswith(SEO_PREFIX)]) for key in seo_items.keys(): if key.endswith(SUFFIX): overrides.append(key[:-len(SUFFIX)]) else: values.append(key) for val in values: if val in overrides and seo_items.get(val+SUFFIX): state = self.setProperty(PROP_PREFIX+val, seo_items[val]) if state: return state elif context.hasProperty(PROP_PREFIX+val): delete_list.append(PROP_PREFIX+val) if delete_list: context.manage_delProperties(delete_list) self.manageSEOCustomMetaTagsProperties(**kw) return state
0674fa9aa463c7545dbd47dbe697bc556ed8a9ef /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/10421/0674fa9aa463c7545dbd47dbe697bc556ed8a9ef/views.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 10680, 1090, 51, 5047, 12, 2890, 16, 2826, 9987, 4672, 819, 273, 279, 85, 67, 7872, 12, 2890, 18, 2472, 13, 919, 273, 875, 1430, 67, 1098, 16, 9515, 16, 924, 273, 5378, 16, 5378, 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, 10680, 1090, 51, 5047, 12, 2890, 16, 2826, 9987, 4672, 819, 273, 279, 85, 67, 7872, 12, 2890, 18, 2472, 13, 919, 273, 875, 1430, 67, 1098, 16, 9515, 16, 924, 273, 5378, 16, 5378, 16,...
title = "OSG usage summary (midnight to midnight central time) for %s\nincluding all jobs that finished in that time period.\nWall Duration is expressed in hours and rounded to the nearest hour.\nWall Duration is the duration between the instant the job start running and the instant the job ends its execution.\nDeltas are the differences with the previous day.\nIf the number of jobs stated for a site is always 1\nthen this number is actually the number of summary records sent.\n(nr) after after a VO name indicates that the VO is not registered with OSG.\n"
title = "OSG usage summary (midnight to midnight central time) for %s\nincluding all jobs that finished in that time period.\nWall Duration is expressed in hours and rounded to the nearest hour.\nWall Duration is the duration between the instant the job start running and the instant the job ends its execution.\nDeltas are the differences with the previous day.\nIf the number of jobs stated for a site is always 1\nthen this number is actually the number of summary records sent.\n(nr) after a VO name indicates that the VO is not registered with OSG.\n"
def GetData(self,start,end): return UpdateVOName(DailyVOSiteData(start,end),0,start, end)
33a4ca44cb79fb58546a509056a7bff882a73c25 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/637/33a4ca44cb79fb58546a509056a7bff882a73c25/AccountingReports.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 30837, 12, 2890, 16, 1937, 16, 409, 4672, 327, 2315, 16169, 461, 12, 40, 12857, 58, 4618, 1137, 751, 12, 1937, 16, 409, 3631, 20, 16, 1937, 16, 679, 13, 2, 0, 0, 0, 0, 0, 0, 0, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 30837, 12, 2890, 16, 1937, 16, 409, 4672, 327, 2315, 16169, 461, 12, 40, 12857, 58, 4618, 1137, 751, 12, 1937, 16, 409, 3631, 20, 16, 1937, 16, 679, 13, 2, -100, -100, -100, -100, -1...
for rho, theta in s_lines[1:]:
for rho, theta in lines[1:]:
def detect_directions(lines): assert(lines.total >= 2) s_lines = sorted([(l[0], l[1]) for l in lines], key = lambda x: x[1]) axes = [] rho, theta = s_lines[0] axes.append((theta, [(rho, theta)])) for rho, theta in s_lines[1:]: if abs(theta - axes[-1][0]) < param_directions_threshold: axes[-1][1].append((rho, theta)) else: axes.append((theta, [(rho, theta)])) if abs(axes[0][0] - axes[-1][0] + math.pi) < param_directions_threshold: axes[0][1].extend([(-rho, theta - math.pi) \ for rho, theta in axes[-1][1]]) del axes[-1] for i in range(0, len(axes)): avg = sum([theta for rho, theta in axes[i][1]]) / len(axes[i][1]) axes[i] = (avg, sorted(axes[i][1], key = lambda x: abs(x[0]))) if abs(axes[-1][0] - math.pi) < abs(axes[0][0]): axes = axes[-1:] + axes[0:-1] return axes
eeeb85797ac0ab6637c0f81ef25016c825bed99e /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12267/eeeb85797ac0ab6637c0f81ef25016c825bed99e/imageproc.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 5966, 67, 9855, 87, 12, 3548, 4672, 1815, 12, 3548, 18, 4963, 1545, 576, 13, 272, 67, 3548, 273, 3115, 3816, 12, 80, 63, 20, 6487, 328, 63, 21, 5717, 364, 328, 316, 2362, 6487, 498, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 5966, 67, 9855, 87, 12, 3548, 4672, 1815, 12, 3548, 18, 4963, 1545, 576, 13, 272, 67, 3548, 273, 3115, 3816, 12, 80, 63, 20, 6487, 328, 63, 21, 5717, 364, 328, 316, 2362, 6487, 498, ...
'docstrings',
'docstrings', 'no-docstrings',
def main(): global default_keywords try: opts, args = getopt.getopt( sys.argv[1:], 'ad:DEhk:Kno:p:S:Vvw:x:', ['extract-all', 'default-domain=', 'escape', 'help', 'keyword=', 'no-default-keywords', 'add-location', 'no-location', 'output=', 'output-dir=', 'style=', 'verbose', 'version', 'width=', 'exclude-file=', 'docstrings', ]) except getopt.error, msg: usage(1, msg) # for holding option values class Options: # constants GNU = 1 SOLARIS = 2 # defaults extractall = 0 # FIXME: currently this option has no effect at all. escape = 0 keywords = [] outpath = '' outfile = 'messages.pot' writelocations = 1 locationstyle = GNU verbose = 0 width = 78 excludefilename = '' docstrings = 0 options = Options() locations = {'gnu' : options.GNU, 'solaris' : options.SOLARIS, } # parse options for opt, arg in opts: if opt in ('-h', '--help'): usage(0) elif opt in ('-a', '--extract-all'): options.extractall = 1 elif opt in ('-d', '--default-domain'): options.outfile = arg + '.pot' elif opt in ('-E', '--escape'): options.escape = 1 elif opt in ('-D', '--docstrings'): options.docstrings = 1 elif opt in ('-k', '--keyword'): options.keywords.append(arg) elif opt in ('-K', '--no-default-keywords'): default_keywords = [] elif opt in ('-n', '--add-location'): options.writelocations = 1 elif opt in ('--no-location',): options.writelocations = 0 elif opt in ('-S', '--style'): options.locationstyle = locations.get(arg.lower()) if options.locationstyle is None: usage(1, _('Invalid value for --style: %s') % arg) elif opt in ('-o', '--output'): options.outfile = arg elif opt in ('-p', '--output-dir'): options.outpath = arg elif opt in ('-v', '--verbose'): options.verbose = 1 elif opt in ('-V', '--version'): print _('pygettext.py (xgettext for Python) %s') % __version__ sys.exit(0) elif opt in ('-w', '--width'): try: options.width = int(arg) except ValueError: usage(1, _('--width argument must be an integer: %s') % arg) elif opt in ('-x', '--exclude-file'): options.excludefilename = arg # calculate escapes make_escapes(options.escape) # calculate all keywords options.keywords.extend(default_keywords) # initialize list of strings to exclude if options.excludefilename: try: fp = open(options.excludefilename) options.toexclude = fp.readlines() fp.close() except IOError: print >> sys.stderr, _( "Can't read --exclude-file: %s") % options.excludefilename sys.exit(1) else: options.toexclude = [] # slurp through all the files eater = TokenEater(options) for filename in args: if filename == '-': if options.verbose: print _('Reading standard input') fp = sys.stdin closep = 0 else: if options.verbose: print _('Working on %s') % filename fp = open(filename) closep = 1 try: eater.set_filename(filename) try: tokenize.tokenize(fp.readline, eater) except tokenize.TokenError, e: print >> sys.stderr, '%s: %s, line %d, column %d' % ( e[0], filename, e[1][0], e[1][1]) finally: if closep: fp.close() # write the output if options.outfile == '-': fp = sys.stdout closep = 0 else: if options.outpath: options.outfile = os.path.join(options.outpath, options.outfile) fp = open(options.outfile, 'w') closep = 1 try: eater.write(fp) finally: if closep: fp.close()
6c846207c39841ddcb1877377b20ec30bef07b97 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/3187/6c846207c39841ddcb1877377b20ec30bef07b97/pygettext.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2774, 13332, 2552, 805, 67, 11771, 775, 30, 1500, 16, 833, 273, 336, 3838, 18, 588, 3838, 12, 2589, 18, 19485, 63, 21, 30, 6487, 296, 361, 30, 1639, 76, 79, 30, 47, 2135, 30, 84, 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, 2774, 13332, 2552, 805, 67, 11771, 775, 30, 1500, 16, 833, 273, 336, 3838, 18, 588, 3838, 12, 2589, 18, 19485, 63, 21, 30, 6487, 296, 361, 30, 1639, 76, 79, 30, 47, 2135, 30, 84, 3...
rng = numpy.random.RandomState(55) numpy_rng = numpy.random.RandomState(55)
rng = numpy.random.RandomState(utt.fetch_seed()) numpy_rng = numpy.random.RandomState(utt.fetch_seed())
def test_binomial_vector(self): rng_R = random_state_type() n = tensor.lvector() prob = tensor.vector() post_r, out = binomial(rng_R, n=n, prob=prob) assert out.ndim == 1 f = compile.function([rng_R, n, prob], [post_r, out], accept_inplace=True)
d5701303093e5943cc4df89bc18c7fecc19b0be2 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12438/d5701303093e5943cc4df89bc18c7fecc19b0be2/test_raw_random.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1842, 67, 4757, 11496, 67, 7737, 12, 2890, 4672, 11418, 67, 54, 273, 2744, 67, 2019, 67, 723, 1435, 290, 273, 8171, 18, 3070, 1229, 1435, 3137, 273, 8171, 18, 7737, 1435, 1603, 67, 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, 1842, 67, 4757, 11496, 67, 7737, 12, 2890, 4672, 11418, 67, 54, 273, 2744, 67, 2019, 67, 723, 1435, 290, 273, 8171, 18, 3070, 1229, 1435, 3137, 273, 8171, 18, 7737, 1435, 1603, 67, 86,...
trayicon = TrayIcon() trayicon.set_menu([(None, _("_Manage desklets"),
self.__trayicon = TrayIcon() self.__trayicon.set_menu([(None, _("_Manage desklets"),
def __init__(self):
f130e09e12f3896ea622d55fa03e59e2c9f2093e /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/5768/f130e09e12f3896ea622d55fa03e59e2c9f2093e/Starter.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 4672, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 4672, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -1...
_collect(ip)
collect(ip) events.setdefault(ip, set()).add(event)
def _collect(_inner, ip): lookup = self.whois.lookup(ip) try: while not lookup.was_source: item = yield inner, lookup except: channel.rethrow() else: channel.send(ip, item)
a3445adbfc335f066cc3fdeb24153538018edddc /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/14361/a3445adbfc335f066cc3fdeb24153538018edddc/whois.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 14676, 24899, 7872, 16, 2359, 4672, 3689, 273, 365, 18, 3350, 19606, 18, 8664, 12, 625, 13, 775, 30, 1323, 486, 3689, 18, 17416, 67, 3168, 30, 761, 273, 2824, 3443, 16, 3689, 1335...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 389, 14676, 24899, 7872, 16, 2359, 4672, 3689, 273, 365, 18, 3350, 19606, 18, 8664, 12, 625, 13, 775, 30, 1323, 486, 3689, 18, 17416, 67, 3168, 30, 761, 273, 2824, 3443, 16, 3689, 1335...
'trytond.modules.' + info['name'].lower(): info.get('xml', []), 'trytond.modules.' + info['name'].lower(): ['purchase.odt'],
'trytond.modules.' + info['name'].lower(): info.get('xml', []) \ + info.get('translation', []) \ + ['purchase.odt'],
def add_defaults(self): sdist.sdist.add_defaults(self) if self.distribution.has_pure_modules(): build_py = self.get_finalized_command('build_py') data = [] for package in build_py.packages: src_dir = build_py.get_package_dir(package) data.extend(build_py.find_data_files(package, src_dir)) self.filelist.extend(data)
fc5b371d92a8c28d4d8d226ba6488c6e879f17f0 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/9276/fc5b371d92a8c28d4d8d226ba6488c6e879f17f0/setup.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 527, 67, 7606, 12, 2890, 4672, 272, 4413, 18, 87, 4413, 18, 1289, 67, 7606, 12, 2890, 13, 309, 365, 18, 16279, 18, 5332, 67, 84, 594, 67, 6400, 13332, 1361, 67, 2074, 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, 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, 527, 67, 7606, 12, 2890, 4672, 272, 4413, 18, 87, 4413, 18, 1289, 67, 7606, 12, 2890, 13, 309, 365, 18, 16279, 18, 5332, 67, 84, 594, 67, 6400, 13332, 1361, 67, 2074, 273, 365, 18, ...
def __init__(self, *attrs): table.Table.__init__(self, *attrs) self.cursor = CoincDatabaseConnection.cursor()
connection = None def __init__(self, *attrs): table.Table.__init__(self, *attrs) self.cursor = self.connection.cursor()
def get_geocent_peak(self): return LIGOTimeGPS(self.peak_time, self.peak_time_ns)
bda9934b4450fe05001a0bec22c8b186ac2c3c12 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/5758/bda9934b4450fe05001a0bec22c8b186ac2c3c12/SnglBurstUtils.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 67, 908, 504, 319, 67, 10244, 12, 2890, 4672, 327, 511, 3047, 51, 950, 28983, 12, 2890, 18, 10244, 67, 957, 16, 365, 18, 10244, 67, 957, 67, 2387, 13, 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, 1, 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, 908, 504, 319, 67, 10244, 12, 2890, 4672, 327, 511, 3047, 51, 950, 28983, 12, 2890, 18, 10244, 67, 957, 16, 365, 18, 10244, 67, 957, 67, 2387, 13, 2, -100, -100, -100, -100,...
class MTimeVersioning(VersioningBase):
def max_mtime(files): return int(max([os.stat(media_root(f)).st_mtime for f in files]))
0e02a15674446c881685374d12739f634920ea7f /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/1268/0e02a15674446c881685374d12739f634920ea7f/__init__.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 943, 67, 10838, 12, 2354, 4672, 327, 509, 12, 1896, 3816, 538, 18, 5642, 12, 5829, 67, 3085, 12, 74, 13, 2934, 334, 67, 10838, 364, 284, 316, 1390, 22643, 225, 2, 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, 1, 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, 943, 67, 10838, 12, 2354, 4672, 327, 509, 12, 1896, 3816, 538, 18, 5642, 12, 5829, 67, 3085, 12, 74, 13, 2934, 334, 67, 10838, 364, 284, 316, 1390, 22643, 225, 2, -100, -100, -100, -...
package_dir = {idlelib:'.'},
package_dir = {idlelib: package_dir},
def _bytecode_filenames(self, files): files = [n for n in files if n.endswith('.py')] return install_lib._bytecode_filenames(self,files)
3e0edbf4d8cc7728fb75cb23602ca18c0282c192 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8546/3e0edbf4d8cc7728fb75cb23602ca18c0282c192/setup.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 1637, 16651, 67, 19875, 12, 2890, 16, 1390, 4672, 1390, 273, 306, 82, 364, 290, 316, 1390, 309, 290, 18, 5839, 1918, 2668, 18, 2074, 6134, 65, 327, 3799, 67, 2941, 6315, 1637, 166...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 389, 1637, 16651, 67, 19875, 12, 2890, 16, 1390, 4672, 1390, 273, 306, 82, 364, 290, 316, 1390, 309, 290, 18, 5839, 1918, 2668, 18, 2074, 6134, 65, 327, 3799, 67, 2941, 6315, 1637, 166...
default='False', cmd='-e', )
default=False, cmd='-e', )
def parse(self, argv, do_getopt=True): '''Parse options''' ret = {} if do_getopt: try: opts, args = getopt.getopt(argv, self.buildGetopt(), []) except getopt.GetoptError, err: self.helpExit(err) if '-h' in argv: self.helpExit('', 0) for key in self.keys(): option = self[key] if do_getopt: option.parse(opts, []) else: option.parse([], argv) if hasattr(option, '_value'): val = option.value self[key] = val
e5404471d08f1b3574caa4f172da78356079f8e6 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/11867/e5404471d08f1b3574caa4f172da78356079f8e6/Options.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1109, 12, 2890, 16, 5261, 16, 741, 67, 588, 3838, 33, 5510, 4672, 9163, 3201, 702, 26418, 325, 273, 2618, 309, 741, 67, 588, 3838, 30, 775, 30, 1500, 16, 833, 273, 336, 3838, 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, 1109, 12, 2890, 16, 5261, 16, 741, 67, 588, 3838, 33, 5510, 4672, 9163, 3201, 702, 26418, 325, 273, 2618, 309, 741, 67, 588, 3838, 30, 775, 30, 1500, 16, 833, 273, 336, 3838, 18, 588...
c.SEx_GAIN = HeAdEr0['GAIN']
c.SEx_GAIN = c.HeAdEr0['GAIN']
def UsageOfPyMorph(): print "Usage: pymorph [--edit-conf[-e]] [--with-psf] [--force[-f]] "\ "[--help[-h]] " sys.exit(0)
a30aab420b0c5a0cad9cd7a50f6983508269b0fb /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/8867/a30aab420b0c5a0cad9cd7a50f6983508269b0fb/pymorph.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 10858, 951, 9413, 30135, 13332, 1172, 315, 5357, 30, 2395, 81, 7657, 306, 413, 4619, 17, 3923, 18919, 73, 13563, 306, 413, 1918, 17, 1121, 74, 65, 306, 413, 5734, 18919, 74, 13563, 1548,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 10858, 951, 9413, 30135, 13332, 1172, 315, 5357, 30, 2395, 81, 7657, 306, 413, 4619, 17, 3923, 18919, 73, 13563, 306, 413, 1918, 17, 1121, 74, 65, 306, 413, 5734, 18919, 74, 13563, 1548,...
def __load_modules(self): if self.kmod_srcdir:
def _load_modules(self): if self.kmod_srcdir and self.modules_build_succeed:
def __load_modules(self): if self.kmod_srcdir: load_kvm_modules(module_dir=self.kmod_srcdir, extra_modules=self.extra_modules) else: load_kvm_modules(module_dir=self.userspace_srcdir, extra_modules=self.extra_modules)
af1538fa0992fc47a0e974597fc4ce7c48f4d4a8 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12268/af1538fa0992fc47a0e974597fc4ce7c48f4d4a8/build.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 945, 67, 6400, 12, 2890, 4672, 309, 365, 18, 79, 1711, 67, 4816, 1214, 471, 365, 18, 6400, 67, 3510, 67, 87, 5286, 5288, 30, 1262, 67, 79, 3489, 67, 6400, 12, 2978, 67, 1214, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 945, 67, 6400, 12, 2890, 4672, 309, 365, 18, 79, 1711, 67, 4816, 1214, 471, 365, 18, 6400, 67, 3510, 67, 87, 5286, 5288, 30, 1262, 67, 79, 3489, 67, 6400, 12, 2978, 67, 1214, ...
image.set_from_file(os.path.join(self.datarootpath,"img",
image.set_from_file(os.path.join(self.datarootpath, "img",
def validedChanges(*args): """Check for a least one selected kana portion (display of a message if not the case), catch parameters, then close the window.
64cfb9e0b60a3a976c72fa9d5d722987641133b9 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/3073/64cfb9e0b60a3a976c72fa9d5d722987641133b9/gtk_gui.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1244, 13898, 7173, 30857, 1968, 4672, 3536, 1564, 364, 279, 4520, 1245, 3170, 417, 13848, 14769, 261, 5417, 434, 279, 883, 309, 486, 326, 648, 3631, 1044, 1472, 16, 1508, 1746, 326, 2742, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1244, 13898, 7173, 30857, 1968, 4672, 3536, 1564, 364, 279, 4520, 1245, 3170, 417, 13848, 14769, 261, 5417, 434, 279, 883, 309, 486, 326, 648, 3631, 1044, 1472, 16, 1508, 1746, 326, 2742, ...
working_prec = 2*precision emb = K.embeddings(rings.RealField(working_prec))[0] ai = [emb(a) for a in E.a_invariants()] ER = EllipticCurve(ai) E_pari = ER.pari_curve(prec=working_prec) pt_pari = [pari(emb(self[0])), pari(emb(self[1]))]
working_prec = 2*working_prec if not K is rings.QQ: emb = refine_embedding(emb, working_prec) ai = [emb(a) for a in E.a_invariants()] E_work = EllipticCurve(ai) pt_pari = [pari(emb(self[0])), pari(emb(self[1]))] E_pari = E_work.pari_curve(prec=working_prec)
def elliptic_logarithm(self, embedding=None, precision=100, algorithm='pari'): """ Returns the elliptic logarithm of this elliptic curve point.
a9b66a2ea206d0cbe3c288b4e2cd2235a0a8c7e6 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9890/a9b66a2ea206d0cbe3c288b4e2cd2235a0a8c7e6/ell_point.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 415, 549, 21507, 67, 1330, 31249, 12, 2890, 16, 15853, 33, 7036, 16, 6039, 33, 6625, 16, 4886, 2218, 1065, 77, 11, 4672, 3536, 2860, 326, 415, 549, 21507, 613, 31249, 434, 333, 415, 54...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 415, 549, 21507, 67, 1330, 31249, 12, 2890, 16, 15853, 33, 7036, 16, 6039, 33, 6625, 16, 4886, 2218, 1065, 77, 11, 4672, 3536, 2860, 326, 415, 549, 21507, 613, 31249, 434, 333, 415, 54...
exec "from __future__ import (with_statement, division); with = 0"
exec "from __future__ import (print_function); print 0"
def test_parserhack(self): # test that the parser.c::future_hack function works as expected # Note: although this test must pass, it's not testing the original # bug as of 2.6 since the with statement is not optional and # the parser hack disabled. If a new keyword is introduced in # 2.6, change this to refer to the new future import. try: exec "from __future__ import division, with_statement; with = 0" except SyntaxError: pass else: self.fail("syntax error didn't occur")
bdca942ffcdb6e14758d3e2f7a9e9fbbfa931c06 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/8546/bdca942ffcdb6e14758d3e2f7a9e9fbbfa931c06/test_future.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1842, 67, 4288, 76, 484, 12, 2890, 4672, 468, 1842, 716, 326, 2082, 18, 71, 2866, 14343, 67, 76, 484, 445, 6330, 487, 2665, 468, 3609, 30, 26347, 333, 1842, 1297, 1342, 16, 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, 1842, 67, 4288, 76, 484, 12, 2890, 4672, 468, 1842, 716, 326, 2082, 18, 71, 2866, 14343, 67, 76, 484, 445, 6330, 487, 2665, 468, 3609, 30, 26347, 333, 1842, 1297, 1342, 16, 518, 1807, ...
print subVars("Headings","leaf-bulleted-heading",linenum,enum)
print subVars("Headings","bulleted-leaf-heading")
def handleBulleted(linenum,enum): global outline, parents v["%%"] = outline[linenum][0] children = getChildren(linenum) if enum == 1: print subVars("Headings","before-bulleted-headings",linenum,enum) if children: print subVars("Headings","branch-bulleted-heading",linenum,enum) parents.append([linenum,enum]) handleObjects(children) parents.pop() print subVars("Headings","after-bulleted-headings",linenum,enum) else: print subVars("Headings","leaf-bulleted-heading",linenum,enum)
06415efd07e1e7445f08ac0ea608650310478422 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/6154/06415efd07e1e7445f08ac0ea608650310478422/otl2tags.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1640, 38, 19994, 329, 12, 7511, 7924, 16, 7924, 4672, 2552, 16363, 16, 6298, 225, 331, 9614, 11438, 11929, 273, 16363, 63, 7511, 7924, 6362, 20, 65, 2325, 273, 10268, 12, 7511, 7924, 13,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1640, 38, 19994, 329, 12, 7511, 7924, 16, 7924, 4672, 2552, 16363, 16, 6298, 225, 331, 9614, 11438, 11929, 273, 16363, 63, 7511, 7924, 6362, 20, 65, 2325, 273, 10268, 12, 7511, 7924, 13,...
/.../RunChandler --create --catch=tests --profileDir=.../test_profile --parcelPath=.../tools/QATestScripts/DataFiles --chandlerTests=TestSharing -D2 -M0
/.../RunChandler --create --catch=tests --profileDir=test_profile --parcelPath=tools/QATestScripts/DataFiles --chandlerTests=TestSharing -D2 -M0
def main(options): """ >>> options = parseOptions() >>> options.dryrun = True >>> options.verbose = True >>> main(options) False Try and run a test that does not exist >>> options.single = 'TestFoo.py' >>> main(options) Test(s) not found False Try different single tests single unit test: >>> options.single = 'TestCrypto' >>> main(options) /.../RunPython... application/tests/TestCrypto.py -v - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + False unit test and functional test: >>> options.single = 'TestCrypto,TestSharing' >>> main(options) /.../RunChandler --create --catch=tests --profileDir=.../test_profile --parcelPath=.../tools/QATestScripts/DataFiles --chandlerTests=TestSharing -D2 -M0 - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + /.../RunPython application/tests/TestCrypto.py -v - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + False unit, functional and two perf tests, one of which is a startup test: >>> options.single = 'TestCrypto,TestSharing,PerfImportCalendar,startup_large' >>> main(options) /.../RunChandler --catch=tests --profileDir=.../test_profile --parcelPath=.../tools/QATestScripts/DataFiles --catsPerfLog=.../test_profile/time.log --scriptFile=tools/QATestScripts/Performance/PerfImportCalendar.py --create PerfImportCalendar.py | 0.00 - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + /.../RunChandler --create --catch=tests --profileDir=.../test_profile --parcelPath=.../tools/QATestScripts/DataFiles --chandlerTests=TestSharing -D2 -M0 - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + /.../RunPython application/tests/TestCrypto.py -v - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + Creating repository for startup time tests /.../RunChandler... --catch=tests --profileDir=.../test_profile --parcelPath=.../tools/QATestScripts/DataFiles --scriptFile=tools/QATestScripts/Performance/quit.py --restore=.../test_profile/__repository__.001 - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + Startup_with_large_calendar /usr/bin/time --format=%e -o .../test_profile/time.log .../RunChandler... --catch=tests --profileDir=.../test_profile --parcelPath=.../tools/QATestScripts/DataFiles --scriptFile=tools/QATestScripts/Performance/end.py 0.00 - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + ... False Try and specify an invalid mode >>> options.single = '' >>> options.mode = 'foo' >>> main(options) foo removed from mode list False Run unit tests with --dryrun >>> options.mode = None >>> options.unit = True >>> main(options) /.../RunPython... .../tests/TestReferenceAttributes.py -v ... /.../RunPython... .../projects/Chandler-EVDBPlugin/setup.py test -v ... False Run unitSuite with --dryrun >>> options.mode = None >>> options.unit = False >>> options.unitSuite = True >>> main(options) /.../RunPython... tools/run_tests.py -v application i18n osaf repository - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + False Run functional tests with --dryrun >>> options.unit = False >>> options.unitSuite = False >>> options.funcSuite = True >>> main(options) /.../RunChandler... --create --catch=tests --profileDir=.../test_profile --parcelPath=.../tools/QATestScripts/DataFiles --scriptFile=tools/cats/Functional/FunctionalTestSuite.py -D2 -M0 - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + False Run functional tests each in its on process >>> options.funcSuite = False >>> options.func = True >>> main(options) /.../RunChandler... --create --catch=tests --profileDir=.../test_profile --parcelPath=.../tools/QATestScripts/DataFiles --chandlerTests=TestCreateAccounts -D2 -M0 - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + ... False Run performance tests with --dryrun >>> options.func = False >>> options.perf = True >>> options.profile = False >>> main(options) /.../RunChandler... --catch=tests --profileDir=.../test_profile --parcelPath=.../tools/QATestScripts/DataFiles --catsPerfLog=.../test_profile/time.log --scriptFile=tools/QATestScripts/Performance/PerfImportCalendar.py --create PerfImportCalendar.py | 0.00 - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + ... /.../RunChandler... --catch=tests --profileDir=.../test_profile --parcelPath=.../tools/QATestScripts/DataFiles --catsPerfLog=.../test_profile/time.log --scriptFile=tools/QATestScripts/Performance/PerfLargeDataResizeCalendar.py --restore=.../test_profile/__repository__.001 PerfLargeDataResizeCalendar.py | 0.00 ... Creating repository for startup time tests /.../RunChandler... --catch=tests --profileDir=.../test_profile --parcelPath=.../tools/QATestScripts/DataFiles --scriptFile=tools/QATestScripts/Performance/quit.py --create - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + Startup /usr/bin/time --format=%e -o .../test_profile/time.log .../RunChandler... --catch=tests --profileDir=.../test_profile --parcelPath=.../tools/QATestScripts/DataFiles --scriptFile=tools/QATestScripts/Performance/end.py 0.00 - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + ... False """ checkOptions(options) if options.mode is None: options.modes = modes = ['release', 'debug'] # silently clear any missing modes if default list is specified for mode in modes: if not os.path.isdir(os.path.join(options.chandlerBin, mode)): options.modes.remove(mode) else: options.mode = options.mode.strip().lower() options.modes = [ options.mode ] # complain about any missing modes if mode was explicitly stated if not os.path.isdir(os.path.join(options.chandlerBin, options.mode)): options.modes.remove(options.mode) log('%s removed from mode list' % options.mode) failed = False try: # Empty the log file so that we won't be confused by old results later f = open(os.path.join(options.profileDir, 'chandler.log'), 'w') f.close() except IOError: pass # Remove old perf log files (we leave the the latest) for f in glob.glob(os.path.join(options.profileDir, '*.log.*')): try: os.remove(f) except OSError: pass if options.single: failed = runSingles(options) else: if options.unit: failed = runUnitTests(options) if not failed or options.noStop: if runPluginTests(options): failed = True if options.unitSuite and (not failed or options.noStop): if runUnitSuite(options): failed = True if options.funcSuite and (not failed or options.noStop): if runFuncTest(options): failed = True if options.func and (not failed or options.noStop): if runFuncTestsSingly(options): failed = True if options.recorded and (not failed or options.noStop): if runRecordedScripts(options): failed = True if options.perf and (not failed or options.noStop): if runPerfTests(options): failed = True if len(failedTests) > 0: log('+-' * 32) log('The following tests failed:') log('\n'.join(failedTests)) log('') return failed
58706c198c72ae85bd163dd339d4081bdd26b7be /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/9228/58706c198c72ae85bd163dd339d4081bdd26b7be/rt.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2774, 12, 2116, 4672, 3536, 4080, 702, 273, 1109, 1320, 1435, 4080, 702, 18, 25011, 2681, 225, 273, 1053, 4080, 702, 18, 11369, 273, 1053, 4080, 2774, 12, 2116, 13, 1083, 225, 6161, 471,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2774, 12, 2116, 4672, 3536, 4080, 702, 273, 1109, 1320, 1435, 4080, 702, 18, 25011, 2681, 225, 273, 1053, 4080, 702, 18, 11369, 273, 1053, 4080, 2774, 12, 2116, 13, 1083, 225, 6161, 471,...
self.curNode.appendChild(node)
def processingInstruction(self, target, data): node = self.document.createProcessingInstruction(target, data)
c24483579d2ef3b62fbbed2f05d121e7270d4c8a /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/3187/c24483579d2ef3b62fbbed2f05d121e7270d4c8a/pulldom.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4929, 11983, 12, 2890, 16, 1018, 16, 501, 4672, 756, 273, 365, 18, 5457, 18, 2640, 7798, 11983, 12, 3299, 16, 501, 13, 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, 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, 4929, 11983, 12, 2890, 16, 1018, 16, 501, 4672, 756, 273, 365, 18, 5457, 18, 2640, 7798, 11983, 12, 3299, 16, 501, 13, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -1...
file.Write(" const uint32 size = ComputeSize(_%s);\n" % last_arg.name) file.Write(" return NextImmediateCmdAddressTotalSize<ValueType>(" "cmd, size);\n")
file.Write(" return NextImmediateCmdAddress<ValueType>(" "cmd, _data_size);\n")
def WriteImmediateCmdSet(self, func, file): """Overrriden from TypeHandler.""" last_arg = func.GetLastOriginalArg() file.Write(" void* Set(void* cmd%s) {\n" % func.MakeTypedOriginalArgString("_", True)) file.Write(" static_cast<ValueType*>(cmd)->Init(%s);\n" % func.MakeOriginalArgString("_")) file.Write(" const uint32 size = ComputeSize(_%s);\n" % last_arg.name) file.Write(" return NextImmediateCmdAddressTotalSize<ValueType>(" "cmd, size);\n") file.Write(" }\n") file.Write("\n")
20d6af8de9f49c5a4b9a5d098840a1523ad90cb6 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/5060/20d6af8de9f49c5a4b9a5d098840a1523ad90cb6/build_gles2_cmd_buffer.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2598, 22651, 5931, 694, 12, 2890, 16, 1326, 16, 585, 4672, 3536, 22042, 1691, 275, 628, 1412, 1503, 12123, 1142, 67, 3175, 273, 1326, 18, 967, 3024, 8176, 4117, 1435, 585, 18, 3067, 2932...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2598, 22651, 5931, 694, 12, 2890, 16, 1326, 16, 585, 4672, 3536, 22042, 1691, 275, 628, 1412, 1503, 12123, 1142, 67, 3175, 273, 1326, 18, 967, 3024, 8176, 4117, 1435, 585, 18, 3067, 2932...
except PalabraParserError, e:
except ParserError, e:
def show_error(title, message): mdialog = gtk.MessageDialog(None, gtk.DIALOG_MODAL , gtk.MESSAGE_INFO, gtk.BUTTONS_NONE, message) mdialog.add_button(gtk.STOCK_CLOSE, gtk.RESPONSE_CLOSE) mdialog.set_title(title) mdialog.run() mdialog.destroy()
fa0e17b3862978c832d9f3ed1a48e7d54f229344 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/6427/fa0e17b3862978c832d9f3ed1a48e7d54f229344/gui.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2405, 67, 1636, 12, 2649, 16, 883, 4672, 3481, 3529, 273, 22718, 18, 1079, 6353, 12, 7036, 16, 22718, 18, 2565, 18683, 67, 6720, 1013, 269, 22718, 18, 8723, 67, 5923, 16, 22718, 18, 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, 2405, 67, 1636, 12, 2649, 16, 883, 4672, 3481, 3529, 273, 22718, 18, 1079, 6353, 12, 7036, 16, 22718, 18, 2565, 18683, 67, 6720, 1013, 269, 22718, 18, 8723, 67, 5923, 16, 22718, 18, 20...
self.alias = kaa.str_to_unicode(' '.join(re.split('[.-_ :]', VIDEO_SHOW_REGEXP_SPLIT(filename.lower())[0]))) self._season, self._episode = [ int(x) for x in re.search(VIDEO_SHOW_REGEXP, filename.lower()).groups() ]
self.alias = kaa.str_to_unicode(' '.join(re.split('[.-_ :]', VIDEO_SHOW_REGEXP_SPLIT(filename)[0]))) self._season, self._episode = [ int(x) for x in re.search(VIDEO_SHOW_REGEXP, filename).groups() ]
def __init__(self, tvdb, filename): self.filename = filename self.tvdb = tvdb if not re.search(VIDEO_SHOW_REGEXP, filename.lower()): self.alias = self._season = self._episode = None return self.alias = kaa.str_to_unicode(' '.join(re.split('[.-_ :]', VIDEO_SHOW_REGEXP_SPLIT(filename.lower())[0]))) self._season, self._episode = [ int(x) for x in re.search(VIDEO_SHOW_REGEXP, filename.lower()).groups() ]
7238b72ef0e162a547f3c35479521f36ead6bd1e /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/11700/7238b72ef0e162a547f3c35479521f36ead6bd1e/tvdb.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 16, 13521, 1966, 16, 1544, 4672, 365, 18, 3459, 273, 1544, 365, 18, 24161, 1966, 273, 13521, 1966, 309, 486, 283, 18, 3072, 12, 58, 27242, 67, 16677, 67, 282...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 13521, 1966, 16, 1544, 4672, 365, 18, 3459, 273, 1544, 365, 18, 24161, 1966, 273, 13521, 1966, 309, 486, 283, 18, 3072, 12, 58, 27242, 67, 16677, 67, 282...
self.putcmd("rcpt","to:%s" % quoteaddr(recip))
optionlist = '' if options and self.does_esmtp: optionlist = string.join(options, ' ') self.putcmd("rcpt","TO:%s %s" % (quoteaddr(recip),optionlist))
def rcpt(self,recip): """ SMTP 'rcpt' command. Indicates 1 recipient for this mail. """ self.putcmd("rcpt","to:%s" % quoteaddr(recip)) return self.getreply()
4be90e2b319a530f8ad5751d163daf7879d72218 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8125/4be90e2b319a530f8ad5751d163daf7879d72218/smtplib.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4519, 337, 12, 2890, 16, 266, 3449, 4672, 3536, 18102, 296, 1310, 337, 11, 1296, 18, 18336, 404, 8027, 364, 333, 4791, 18, 3536, 1456, 1098, 273, 875, 309, 702, 471, 365, 18, 20657, 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, 4519, 337, 12, 2890, 16, 266, 3449, 4672, 3536, 18102, 296, 1310, 337, 11, 1296, 18, 18336, 404, 8027, 364, 333, 4791, 18, 3536, 1456, 1098, 273, 875, 309, 702, 471, 365, 18, 20657, 67...
ftp_handler = TLS_FTPHandler ftp_handler.certfile = 'keycert.pem' ftp_handler.authorizer = authorizer address = ('0.0.0.0', 21) ftpd = ftpserver.FTPServer(address, ftp_handler)
ftp_handler = TLS_FTPHandlerFactory('demo/keycert.pem') ftpd = ftpserver.FTPServer(('localhost', 8021), ftp_handler)
def get_context(self):
4204924ec8de5e38248a54c0de1c7aa8a1fd4dfa /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/3782/4204924ec8de5e38248a54c0de1c7aa8a1fd4dfa/tls_ftpd.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 67, 2472, 12, 2890, 4672, 225, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,...
[ 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, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 67, 2472, 12, 2890, 4672, 225, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100,...
model=" 1" pdb=" CA GLN A 3 " C 1 (24.4820 -1.9270 8.7940)\
model=" 2" pdb=" CA GLN A 3 " C 1 (24.4820 -1.9270 8.7940)\
def exercise_xray_structure_simple(): pdb_inp = pdb.input(source_info=None, lines=flex.split_lines("""\
7473a442258a9c3d6ec6f871986d406d20ec9e1e /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/696/7473a442258a9c3d6ec6f871986d406d20ec9e1e/tst_ext.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 24165, 67, 92, 435, 67, 7627, 67, 9647, 13332, 10892, 67, 31647, 273, 10892, 18, 2630, 12, 3168, 67, 1376, 33, 7036, 16, 2362, 33, 27592, 18, 4939, 67, 3548, 2932, 3660, 64, 2, 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, 24165, 67, 92, 435, 67, 7627, 67, 9647, 13332, 10892, 67, 31647, 273, 10892, 18, 2630, 12, 3168, 67, 1376, 33, 7036, 16, 2362, 33, 27592, 18, 4939, 67, 3548, 2932, 3660, 64, 2, -100, ...
def _connect_to_hal():
def start():
def _connect_to_hal(): """ Connect to DBUS and start to connect to HAL. """ global _bus global _connection_timeout _connection_timeout -= 1 try: if not _bus: _bus = dbus.SystemBus() except Exception, e: # unable to connect to dbus if not _connection_timeout: # give up signals['failed'].emit('unable to connect to dbus') return False kaa.OneShotTimer(_connect_to_hal).start(2) return False try: obj = _bus.get_object('org.freedesktop.Hal', '/org/freedesktop/Hal/Manager') except Exception, e: # unable to connect to hal signals['failed'].emit('hal not found on dbus') return False # DONT ASK! dbus sucks! kaa.Timer(_connect_to_hal_because_dbus_sucks, obj).start(0.01) return False
7bcc500ce852b3f24bf880cd4b2a5023d541a0f2 /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/11703/7bcc500ce852b3f24bf880cd4b2a5023d541a0f2/hal.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 787, 13332, 3536, 8289, 358, 2383, 3378, 471, 787, 358, 3077, 358, 670, 1013, 18, 3536, 2552, 389, 9274, 2552, 389, 4071, 67, 4538, 389, 4071, 67, 4538, 3947, 404, 775, 30, 309, 486, 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, 787, 13332, 3536, 8289, 358, 2383, 3378, 471, 787, 358, 3077, 358, 670, 1013, 18, 3536, 2552, 389, 9274, 2552, 389, 4071, 67, 4538, 389, 4071, 67, 4538, 3947, 404, 775, 30, 309, 486, 3...
if type(self.config.processorSymbolsPathnameList) is not list: self.config.symbol_path = [x for x in self.config.processorSymbolsPathnameList.split()] self.config.commandLine = [config.stackwalk_serverPathname] + self.config.symbol_path
self.config.commandLine = [x for x in self.config.stackwalkCommandLine.split()]
def __init__(self, config): super(StackWalkerPool, self).__init__() self.config = config self.logger = config.logger self.logger.debug("creating stackWalkerPool") if type(self.config.processorSymbolsPathnameList) is not list: self.config.symbol_path = [x for x in self.config.processorSymbolsPathnameList.split()] self.config.commandLine = [config.stackwalk_serverPathname] + self.config.symbol_path
3663141708a1a6db724430844e98dbf9c5f21dfd /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/12383/3663141708a1a6db724430844e98dbf9c5f21dfd/stackwalker.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 16, 642, 4672, 2240, 12, 2624, 16246, 2864, 16, 365, 2934, 972, 2738, 972, 1435, 365, 18, 1425, 273, 642, 365, 18, 4901, 273, 642, 18, 4901, 365, 18, 4901, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 642, 4672, 2240, 12, 2624, 16246, 2864, 16, 365, 2934, 972, 2738, 972, 1435, 365, 18, 1425, 273, 642, 365, 18, 4901, 273, 642, 18, 4901, 365, 18, 4901, ...
self.realSubject = re.sub(r'.*?\[.*?\](.*)',r'\1',self.subject)
self.realSubject = re.sub(r'.*?\[.*?\] ?(.*)',r'\1',self.subject)
def __init__(self, context, message, defaultpage=DEFAULTPAGE, subscribersonly=1, trackerissue=0, checkrecipient=1, checksubject=1, ): BLATHER('mailin.py: processing incoming message:\n%s' % message) self.context = context self.defaultpage = defaultpage self.subscribersonly = subscribersonly self.trackerissue = trackerissue self.checkrecipient = checkrecipient self.checksubject = checksubject self.msg = email.message_from_string(message) self.date = self.msg['Date'] self.subject = re.sub(r'\n',r'',self.msg.get('Subject','')) self.realSubject = re.sub(r'.*?\[.*?\](.*)',r'\1',self.subject) self.messageid = self.msg.get('Message-id','') self.inreplyto = self.msg.get('In-reply-to','') self.From = self.msg.get('From') self.FromRealName = parseaddr(self.From)[0] self.FromEmail = parseaddr(self.From)[1] self.FromUserName = (self.FromRealName or re.sub(r'@.*$',r'',self.FromEmail)) self.sender = self.msg.get('Sender') self.senderEmail = (self.sender and parseaddr(self.sender)[1]) or None tos = self.msg.get_all('to', []) ccs = self.msg.get_all('cc', []) resent_tos = self.msg.get_all('resent-to', []) resent_ccs = self.msg.get_all('resent-cc', []) self.recipients = getaddresses(tos + ccs + resent_tos + resent_ccs)
e123d472238637f239073905782ebaa3423f53b7 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/5225/e123d472238637f239073905782ebaa3423f53b7/mailin.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 16, 819, 16, 883, 16, 805, 2433, 33, 5280, 11219, 16, 10189, 3565, 715, 33, 21, 16, 9745, 13882, 33, 20, 16, 866, 20367, 33, 21, 16, 866, 7857, 33, 21, 1...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 16, 819, 16, 883, 16, 805, 2433, 33, 5280, 11219, 16, 10189, 3565, 715, 33, 21, 16, 9745, 13882, 33, 20, 16, 866, 20367, 33, 21, 16, 866, 7857, 33, 21, 1...
'area':'length^2', 'capacitance':'time^4*current^2/(length^2*mass)', 'charge':'current*time', 'conductance':'current^2*time^3/(mass*length^2)', 'electric_potential':'mass*length^2/(current*time^3)', 'energy':'mass*length^2/time^2', 'fiber_linear_mass_density':'mass/length', 'force':'mass*length/time^2', 'frequency':'1/time', 'illuminance':'luminous_intensity*solid_angle/length^2', 'inductance':'length^2*mass/(time^2*current^2)', 'information_rate':'information/time', 'inverse_length':'1/length', 'luminance':'luminous_intensity/length^2', 'luminous_energy':'luminous_intensity*solid_angle*time', 'luminous_flux':'luminous_intensity*solid_angle', 'magnetic_field':'mass/(current*time^2)', 'magnetic_flux':'mass*length^2/(current*time^2)', 'magnetic_intensity':'current/length', 'magnetic_moment':'current*length^2', 'power':'mass*length^2/time^3', 'pressure':'mass/(length*time^2)', 'radiation':'1/time', 'radiation_absorbed':'length^2/time^2', 'radiation_ionizing':'current*time/mass', 'resistance':'mass*length^2/(current^2*time^3)', 'velocity':'length/time', 'viscosity_absolute':'mass/(length*time)', 'viscosity_kinematic':'length^2/time', 'viscosity_other':'length*time/mass', 'volume':'length^3' }
'area':'length^2', 'capacitance':'time^4*current^2/(length^2*mass)', 'charge':'current*time', 'conductance':'current^2*time^3/(mass*length^2)', 'electric_potential':'mass*length^2/(current*time^3)', 'energy':'mass*length^2/time^2', 'fiber_linear_mass_density':'mass/length', 'force':'mass*length/time^2', 'frequency':'1/time', 'illuminance':'luminous_intensity*solid_angle/length^2', 'inductance':'length^2*mass/(time^2*current^2)', 'information_rate':'information/time', 'inverse_length':'1/length', 'luminance':'luminous_intensity/length^2', 'luminous_energy':'luminous_intensity*solid_angle*time', 'luminous_flux':'luminous_intensity*solid_angle', 'magnetic_field':'mass/(current*time^2)', 'magnetic_flux':'mass*length^2/(current*time^2)', 'magnetic_intensity':'current/length', 'magnetic_moment':'current*length^2', 'power':'mass*length^2/time^3', 'pressure':'mass/(length*time^2)', 'radiation':'1/time', 'radiation_absorbed':'length^2/time^2', 'radiation_ionizing':'current*time/mass', 'resistance':'mass*length^2/(current^2*time^3)', 'velocity':'length/time', 'viscosity_absolute':'mass/(length*time)', 'viscosity_kinematic':'length^2/time', 'viscosity_other':'length*time/mass', 'volume':'length^3' }
def evalunitdict(): """ Replace all the string values of the unitdict variable by their evaluated forms, and builds some other tables for ease of use. This function is mainly used internally, for efficiency (and flexibility) purposes, making it easier to describe the units. EXAMPLES:: sage: sage.symbolic.units.evalunitdict() """ from sage.misc.all import sage_eval for key, value in unitdict.iteritems(): unitdict[key] = dict([(a,sage_eval(repr(b))) for a, b in value.iteritems()]) # FEATURE IDEA: create a function that would allow users to add # new entries to the table without having to know anything about # how the table is stored internally. # # Format the table for easier use. # for k, v in unitdict.iteritems(): for a in v: unit_to_type[a] = k for w in unitdict.iterkeys(): for j in unitdict[w].iterkeys(): if type(unitdict[w][j]) == tuple: unitdict[w][j] = unitdict[w][j][0] value_to_unit[w] = dict(zip(unitdict[w].itervalues(), unitdict[w].iterkeys()))
d9145e61c2e167a847618a21778e0e532a04af5d /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/9890/d9145e61c2e167a847618a21778e0e532a04af5d/units.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 5302, 4873, 1576, 13332, 3536, 6910, 777, 326, 533, 924, 434, 326, 2836, 1576, 2190, 635, 3675, 12697, 10138, 16, 471, 10736, 2690, 1308, 4606, 364, 28769, 434, 999, 18, 1220, 445, 353, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 5302, 4873, 1576, 13332, 3536, 6910, 777, 326, 533, 924, 434, 326, 2836, 1576, 2190, 635, 3675, 12697, 10138, 16, 471, 10736, 2690, 1308, 4606, 364, 28769, 434, 999, 18, 1220, 445, 353, ...
self.options = parser.parse_args(args=my_args)[0]
(self.options, args) = parser.parse_args(args=my_args) if (len(args) == 1): self.options.page = args[0]
def set_options(self): """Parse commandline and set options attribute""" my_args = [] for arg in wikipedia.handleArgs(): my_args.append(arg) parser = optparse.OptionParser() parser.add_option("-r", "--edit_redirect", action="store_true", default=False, help="Ignore/edit redirects") parser.add_option("-p", "--page", help="Page to edit") parser.add_option("-w", "--watch", action="store_true", default=False, help="Watch article after edit") #parser.add_option("-n", "--new_data", default="", help="Automatically generated content") self.options = parser.parse_args(args=my_args)[0]
00bf009187b16cabee8cff7f8c051831bdc95ff3 /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/4404/00bf009187b16cabee8cff7f8c051831bdc95ff3/editarticle.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 444, 67, 2116, 12, 2890, 4672, 3536, 3201, 28305, 471, 444, 702, 1566, 8395, 3399, 67, 1968, 273, 5378, 364, 1501, 316, 21137, 18, 4110, 2615, 13332, 3399, 67, 1968, 18, 6923, 12, 3175, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 67, 2116, 12, 2890, 4672, 3536, 3201, 28305, 471, 444, 702, 1566, 8395, 3399, 67, 1968, 273, 5378, 364, 1501, 316, 21137, 18, 4110, 2615, 13332, 3399, 67, 1968, 18, 6923, 12, 3175, ...
socketDataProcessed.release()
def test_main(): rootLogger = logging.getLogger("") rootLogger.setLevel(logging.DEBUG) hdlr = logging.StreamHandler(sys.stdout) fmt = logging.Formatter(logging.BASIC_FORMAT) hdlr.setFormatter(fmt) rootLogger.addHandler(hdlr) #Set up a handler such that all events are sent via a socket to the log #receiver (logrecv). #The handler will only be added to the rootLogger for some of the tests hdlr = logging.handlers.SocketHandler('localhost', logging.handlers.DEFAULT_TCP_LOGGING_PORT) #Configure the logger for logrecv so events do not propagate beyond it. #The sockLogger output is buffered in memory until the end of the test, #and printed at the end. sockOut = cStringIO.StringIO() sockLogger = logging.getLogger("logrecv") sockLogger.setLevel(logging.DEBUG) sockhdlr = logging.StreamHandler(sockOut) sockhdlr.setFormatter(logging.Formatter( "%(name)s -> %(levelname)s: %(message)s")) sockLogger.addHandler(sockhdlr) sockLogger.propagate = 0 #Set up servers threads = [] tcpserver = LogRecordSocketReceiver() #sys.stdout.write("About to start TCP server...\n") threads.append(threading.Thread(target=runTCP, args=(tcpserver,))) for thread in threads: thread.start() try: banner("log_test0", "begin") rootLogger.addHandler(hdlr) test0() hdlr.close() rootLogger.removeHandler(hdlr) banner("log_test0", "end") banner("log_test1", "begin") test1() banner("log_test1", "end") banner("log_test2", "begin") test2() banner("log_test2", "end") banner("log_test3", "begin") test3() banner("log_test3", "end") finally: #wait for TCP receiver to terminate socketDataProcessed.acquire() socketDataProcessed.wait() socketDataProcessed.release() for thread in threads: thread.join() banner("logrecv output", "begin") sys.stdout.write(sockOut.getvalue()) sockOut.close() banner("logrecv output", "end") sys.stdout.flush()
f9addb676d7ef864c6685a1ac8423b5b2663ec68 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8546/f9addb676d7ef864c6685a1ac8423b5b2663ec68/test_logging.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1842, 67, 5254, 13332, 1365, 3328, 273, 2907, 18, 588, 3328, 2932, 7923, 1365, 3328, 18, 542, 2355, 12, 11167, 18, 9394, 13, 366, 5761, 86, 273, 2907, 18, 1228, 1503, 12, 9499, 18, 102...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 5254, 13332, 1365, 3328, 273, 2907, 18, 588, 3328, 2932, 7923, 1365, 3328, 18, 542, 2355, 12, 11167, 18, 9394, 13, 366, 5761, 86, 273, 2907, 18, 1228, 1503, 12, 9499, 18, 102...
def set_time_slides(self): """ Turns on the --time-slides argument. """ self.add_var_opt('time-slides') self.__time_slides = True
def get_table_name(self): """ Return the table_name that's set. """ return self.__table_name
feb333d086cdfebe13dfeee626539609fa32c85a /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/5758/feb333d086cdfebe13dfeee626539609fa32c85a/inspiral.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 67, 2121, 67, 529, 12, 2890, 4672, 3536, 2000, 326, 1014, 67, 529, 716, 1807, 444, 18, 3536, 327, 365, 16186, 2121, 67, 529, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 67, 2121, 67, 529, 12, 2890, 4672, 3536, 2000, 326, 1014, 67, 529, 716, 1807, 444, 18, 3536, 327, 365, 16186, 2121, 67, 529, 2, -100, -100, -100, -100, -100, -100, -100, -100, -10...
print >>dagfile, """<dax id="%s" file="%s">""" % (id, subdax_name)
print >>dagfile, """<dax id="%s" file="%s">""" % (id_tag, subdax_name)
def write_abstract_dag(self): """ Write all the nodes in the workflow to the DAX file. """ if not self.__dax_file_path: # this workflow is not dax-compatible, so just return return try: dagfile = open( self.__dag_file_path, 'w' ) except: raise CondorDAGError, "Cannot open file " + self.__dag_file_path
7fb1d24f3397a3b9a71a336ec908e6d1cc315062 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/3589/7fb1d24f3397a3b9a71a336ec908e6d1cc315062/pipeline.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1045, 67, 17801, 67, 30204, 12, 2890, 4672, 3536, 2598, 777, 326, 2199, 316, 326, 6095, 358, 326, 463, 2501, 585, 18, 3536, 309, 486, 365, 16186, 72, 651, 67, 768, 67, 803, 30, 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, 1045, 67, 17801, 67, 30204, 12, 2890, 4672, 3536, 2598, 777, 326, 2199, 316, 326, 6095, 358, 326, 463, 2501, 585, 18, 3536, 309, 486, 365, 16186, 72, 651, 67, 768, 67, 803, 30, 468, ...
return simplejson.loads(body)
return json.loads(body)
def subscribe(self, topic, protocol, endpoint): """ Subscribe to a Topic.
c9b03e890813a446c33a59b53e43f4554d42eae7 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/1098/c9b03e890813a446c33a59b53e43f4554d42eae7/__init__.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 9129, 12, 2890, 16, 3958, 16, 1771, 16, 2494, 4672, 3536, 18014, 358, 279, 11789, 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, ...
[ 1, 1, 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...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 9129, 12, 2890, 16, 3958, 16, 1771, 16, 2494, 4672, 3536, 18014, 358, 279, 11789, 18, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -...
layout.setContentsMargins(0,0,0,0)
try: layout.setContentsMargins(0,0,0,0) except AttributeError: pass
def __init__(self,parent,detachbutton=True): QtGui.QWidget.__init__(self,parent)
3d21124133c251af25d95b3c8acfff38c6d1f1bd /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/381/3d21124133c251af25d95b3c8acfff38c6d1f1bd/gui_qt4.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 16, 2938, 16, 8238, 497, 5391, 33, 5510, 4672, 23425, 18, 53, 4609, 16186, 2738, 972, 12, 2890, 16, 2938, 13, 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, 1001, 2738, 972, 12, 2890, 16, 2938, 16, 8238, 497, 5391, 33, 5510, 4672, 23425, 18, 53, 4609, 16186, 2738, 972, 12, 2890, 16, 2938, 13, 2, -100, -100, -100, -100, -100, -100, -100, -1...
files=Open(**options).show() return files.split()
return Open(**options).show()
def askopenfilenames(**options): """Ask for multiple filenames to open Returns a list of filenames or empty list if cancel button selected """ options["multiple"]=1 files=Open(**options).show() return files.split()
3ef9ad10778df71252c6b207079341e7bcf5f62c /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12029/3ef9ad10778df71252c6b207079341e7bcf5f62c/tkFileDialog.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 6827, 3190, 19875, 12, 636, 2116, 4672, 3536, 23663, 364, 3229, 9066, 358, 1696, 225, 2860, 279, 666, 434, 9066, 578, 1008, 666, 309, 3755, 3568, 3170, 3536, 702, 9614, 9622, 11929, 33, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 6827, 3190, 19875, 12, 636, 2116, 4672, 3536, 23663, 364, 3229, 9066, 358, 1696, 225, 2860, 279, 666, 434, 9066, 578, 1008, 666, 309, 3755, 3568, 3170, 3536, 702, 9614, 9622, 11929, 33, ...
outfile.write(component+" ")
outfile.write("%s %7.4f "%(component,logflux))
def flux2size(flux,lam=0.21): k=1.3807e-23 T=1.e12 return sqrt(lam**2 * flux * 1.e-26 / (2.*pi*k*T))
fb918803ed19fb2b5fac0735f623b32c075aabe7 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/6216/fb918803ed19fb2b5fac0735f623b32c075aabe7/makeScintillationLightcurves.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 11772, 22, 1467, 12, 7994, 16, 28448, 33, 20, 18, 5340, 4672, 417, 33, 21, 18, 23, 3672, 27, 73, 17, 4366, 399, 33, 21, 18, 73, 2138, 327, 5700, 12, 28448, 636, 22, 380, 11772, 380...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 11772, 22, 1467, 12, 7994, 16, 28448, 33, 20, 18, 5340, 4672, 417, 33, 21, 18, 23, 3672, 27, 73, 17, 4366, 399, 33, 21, 18, 73, 2138, 327, 5700, 12, 28448, 636, 22, 380, 11772, 380...
sage: sr1 = mq.SR(2,2,2,4) sage: sr2 = mq.SR(2,2,2,4)
sage: sr1 = mq.SR(2, 2, 2, 4) sage: sr2 = mq.SR(2, 2, 2, 4)
def __cmp__(self, other): """ Two generators are considered equal if they agree on all parameters passed to them during construction.
26b5b14a2a46b23848ccefac3b41425cf353e86a /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/9417/26b5b14a2a46b23848ccefac3b41425cf353e86a/sr.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 9625, 972, 12, 2890, 16, 1308, 4672, 3536, 16896, 13327, 854, 7399, 3959, 309, 2898, 1737, 992, 603, 777, 1472, 2275, 358, 2182, 4982, 16171, 18, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 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, 9625, 972, 12, 2890, 16, 1308, 4672, 3536, 16896, 13327, 854, 7399, 3959, 309, 2898, 1737, 992, 603, 777, 1472, 2275, 358, 2182, 4982, 16171, 18, 2, -100, -100, -100, -100, -100, -...
if page.exists() and not page.isRedirectPage():
if page.exists() and not page.isRedirectPage() and not page.isCategoryRedirect():
def getFoundInCorrectNamespace(self, site): """ If we found a page that has the expected namespace on the given site while working on the subject, this method returns it. If several ones have been found, the first one will be returned. Otherwise, None will be returned. """ for tree in [self.done, self.pending, self.todo]: for page in tree.filter(site): if page.namespace() == self.originPage.namespace(): if page.exists() and not page.isRedirectPage(): return page return None
f16d711ee4d69f05a569882514fadb88191f35f4 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/4404/f16d711ee4d69f05a569882514fadb88191f35f4/interwiki.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 2043, 382, 16147, 3402, 12, 2890, 16, 2834, 4672, 3536, 971, 732, 1392, 279, 1363, 716, 711, 326, 2665, 1981, 603, 326, 864, 2834, 1323, 5960, 603, 326, 3221, 16, 333, 707, 1135, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 2043, 382, 16147, 3402, 12, 2890, 16, 2834, 4672, 3536, 971, 732, 1392, 279, 1363, 716, 711, 326, 2665, 1981, 603, 326, 864, 2834, 1323, 5960, 603, 326, 3221, 16, 333, 707, 1135, ...
period = period_obj.browse(cursor, user, data['form']['period'],
period = period_obj.browse(cursor, user, period_id,
def _action_open_journal(self, cursor, user, data, context=None): journal_period_obj = self.pool.get('account.journal.period') journal_obj = self.pool.get('account.journal') period_obj = self.pool.get('account.period') if not journal_period_obj.search(cursor, user, [ ('journal', '=', data['form']['journal']), ('period', '=', data['form']['period']), ], context=context): journal = journal_obj.browse(cursor, user, data['form']['journal'], context=context) period = period_obj.browse(cursor, user, data['form']['period'], context=context) journal_period_obj.create(cursor, user, { 'name': journal.name + ' - ' + period.name, 'journal': journal.id, 'period': period.id, }, context=context) return { 'domain': str([ ('journal', '=', data['form']['journal']), ('period', '=', data['form']['period']), ]), 'view_type': 'form', 'view_mode': 'tree,form', 'res_model': 'account.move.line', 'type': 'ir.action.act_window', 'context': str({ 'journal': data['form']['journal'], 'period': data['form']['period'], }), }
60e0d87eee85daaf85629446d9431c13253c663f /local1/tlutelli/issta_data/temp/all_python//python/2008_temp/2008/9290/60e0d87eee85daaf85629446d9431c13253c663f/move.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 1128, 67, 3190, 67, 22644, 12, 2890, 16, 3347, 16, 729, 16, 501, 16, 819, 33, 7036, 4672, 13001, 67, 6908, 67, 2603, 273, 365, 18, 6011, 18, 588, 2668, 4631, 18, 22644, 18, 6908...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1128, 67, 3190, 67, 22644, 12, 2890, 16, 3347, 16, 729, 16, 501, 16, 819, 33, 7036, 4672, 13001, 67, 6908, 67, 2603, 273, 365, 18, 6011, 18, 588, 2668, 4631, 18, 22644, 18, 6908...
self.context_menu = UpdatedMenu(self, [], tearoff = 0, auto_rebuild = self.build_context_menu) self.context_menu.Popup(event.x_root, event.y_root)
if self["state"]==NORMAL: self.context_menu = UpdatedMenu(self, [], tearoff = 0, auto_rebuild = self.build_context_menu) self.context_menu.Popup(event.x_root, event.y_root)
def popup_context_menu(self, event): self.context_menu = UpdatedMenu(self, [], tearoff = 0, auto_rebuild = self.build_context_menu) self.context_menu.Popup(event.x_root, event.y_root)
6e3b5717549fe6d33a683042f42e617f4b76035f /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/3123/6e3b5717549fe6d33a683042f42e617f4b76035f/ttk_ext.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 10431, 67, 2472, 67, 5414, 12, 2890, 16, 871, 4672, 365, 18, 2472, 67, 5414, 273, 19301, 4599, 12, 2890, 16, 5378, 16, 268, 2091, 3674, 273, 374, 16, 3656, 67, 266, 3510, 273, 365, 1...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 10431, 67, 2472, 67, 5414, 12, 2890, 16, 871, 4672, 365, 18, 2472, 67, 5414, 273, 19301, 4599, 12, 2890, 16, 5378, 16, 268, 2091, 3674, 273, 374, 16, 3656, 67, 266, 3510, 273, 365, 1...
self.ref = "%" + value.graph.name
self.ref = self.make_ref('%', value.graph.name)
def __init__(self, db, value): self.db = db self.value = value self.ref = "%" + value.graph.name self.graph = value.graph remove_same_as(self.graph) remove_double_links(self.db._translator, self.graph)
15d1ee50e5137e5da6a59c6c1ddd1eade9adb121 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/6934/15d1ee50e5137e5da6a59c6c1ddd1eade9adb121/funcnode.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 16, 1319, 16, 460, 4672, 365, 18, 1966, 273, 1319, 365, 18, 1132, 273, 460, 365, 18, 1734, 282, 273, 365, 18, 6540, 67, 1734, 29909, 2187, 460, 18, 4660, 1...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 1319, 16, 460, 4672, 365, 18, 1966, 273, 1319, 365, 18, 1132, 273, 460, 365, 18, 1734, 282, 273, 365, 18, 6540, 67, 1734, 29909, 2187, 460, 18, 4660, 1...
def callback(self, result): if self.stan!="": print "guiUpdate" nr=0 for i in self.profiles: if i==result: self.togglegroup.value_set(nr) nr=nr+1
def setCurrentProfile(self, obj, event, name, *args, **kargs): """ Set the current profile to `name` """ self.dbusObj.SetProfile(name) self.ProfileNameUpdate()
def callback(self, result): if self.stan!="": print "guiUpdate" nr=0 for i in self.profiles: if i==result: self.togglegroup.value_set(nr) nr=nr+1
9c3cb95486879f5c9a72c2e03af50842b2b8bdfa /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/11428/9c3cb95486879f5c9a72c2e03af50842b2b8bdfa/shr_profile.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1348, 12, 2890, 16, 563, 4672, 309, 365, 18, 541, 5, 1546, 6877, 1172, 315, 20292, 1891, 6, 9884, 33, 20, 364, 277, 316, 365, 18, 18314, 30, 309, 277, 631, 2088, 30, 365, 18, 14401, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1348, 12, 2890, 16, 563, 4672, 309, 365, 18, 541, 5, 1546, 6877, 1172, 315, 20292, 1891, 6, 9884, 33, 20, 364, 277, 316, 365, 18, 18314, 30, 309, 277, 631, 2088, 30, 365, 18, 14401, ...
clone = self.activeFormattingElements[i].cloneNode()
entry = self.activeFormattingElements[i] clone = entry.cloneNode()
def reconstructActiveFormattingElements(self): # Within this algorithm the order of steps described in the # specification is not quite the same as the order of steps in the # code. It should still do the same though.
2c0a091732a5ae0de23474d9903258632f674478 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/10463/2c0a091732a5ae0de23474d9903258632f674478/_base.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 23243, 3896, 23974, 3471, 12, 2890, 4672, 468, 3423, 267, 333, 4886, 326, 1353, 434, 6075, 11893, 316, 326, 468, 7490, 353, 486, 25102, 326, 1967, 487, 326, 1353, 434, 6075, 316, 326, 46...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 23243, 3896, 23974, 3471, 12, 2890, 4672, 468, 3423, 267, 333, 4886, 326, 1353, 434, 6075, 11893, 316, 326, 468, 7490, 353, 486, 25102, 326, 1967, 487, 326, 1353, 434, 6075, 316, 326, 46...
if string.upper(string.lstrip(msg[3], ':')) == string.upper('!join'): print "Joining a channel!" if privcheck(HOSTMASK): if len(msg) > 4: if msg[4][0] == " ircbpconfig.addchan(msg[4]) irccommand("JOIN " + msg[4])
if string.upper(string.lstrip(msg[3], ':')) == string.upper('!join'): print "Joining a channel!" if privcheck(HOSTMASK): if len(msg) > 4: if msg[4][0] == " ircbpconfig.addchan(msg[4]) irccommand("JOIN " + msg[4]) else: irccommand("PRIVMSG " + CHANNEL + " :" + msg[4] + " is not a channel")
#def isusingprefix(INDATA,COMMAND):
6f69720b65c00f6f32167dead3ff3b3dd6098428 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/2452/6f69720b65c00f6f32167dead3ff3b3dd6098428/ircbp.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 468, 536, 353, 9940, 3239, 12, 2356, 3706, 16, 19104, 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, ...
[ 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, 468, 536, 353, 9940, 3239, 12, 2356, 3706, 16, 19104, 4672, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100,...
def handle_missing_module(m_name, m_namespace):
def handle_missing_module(*args, **kwargs):
def handle_missing_module(m_name, m_namespace): global webServicesmodulesDict def get_wsdl_from_namespace(m_namespace): try: wsdl = m_namespace.split("|") return wsdl[0] except: print "invalid namespace" return None wsdl = get_wsdl_from_namespace(m_namespace) if wsdl: outdated_list = [] updated_list = [] error_list = [] print "Downloading %s and adding to the Module list..."%wsdl pathfile = os.path.join(core.system.default_dot_vistrails(), "webServices", "modules.conf") if os.path.isfile(pathfile): #Verify if there is a need to update the modules configuration #file (modules.conf) (outdated_list, updated_list, error_list) = verify_wsdl([wsdl]) #print "verified: createconfig file is %s"%createconfigfile else: #If the modules configuration file doesn't exist, create it outdated_list = [wsdl] #If the stub files are not updated or there is not information in # the header about the modification date of the web service, the # stubs files and a modules configuration file will be created # otherwise the information of the modules will be obtained from # the modules.conf files that contains serialized data of the methods # and the complex types of the web services # print outdated_list, updated_list, error_list if os.path.isfile(pathfile): try: inf = open(pathfile) webServicesmodulesDict = cPickle.load(inf) inf.close() except: print "Error loading configuration file" return False try: (res,not_loaded) = load_wsdl_no_config(updated_list) #print "done loading_no_config" if not res: outdated_list.extend([wsdl]) (res, not_loaded) = load_wsdl_with_config(outdated_list) #print "done loading_with_config" if res: #add new url to package config file wsdlList = [] if configuration.check('wsdlList'): wsdlList = configuration.wsdlList.split(";") if wsdl not in wsdlList: wsdlList.append(wsdl) swsdlList = ";".join(wsdlList) configuration.wsdlList = swsdlList print "done." return True else: msg = """ There were problems loading the webservice.
c1f2f8599b539d65ccebe6ec507680ba3f507273 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/6341/c1f2f8599b539d65ccebe6ec507680ba3f507273/init.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1640, 67, 7337, 67, 2978, 30857, 1968, 16, 2826, 4333, 4672, 2552, 3311, 5676, 6400, 5014, 1652, 336, 67, 4749, 5761, 67, 2080, 67, 4937, 12, 81, 67, 4937, 4672, 775, 30, 17642, 273, 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, 1640, 67, 7337, 67, 2978, 30857, 1968, 16, 2826, 4333, 4672, 2552, 3311, 5676, 6400, 5014, 1652, 336, 67, 4749, 5761, 67, 2080, 67, 4937, 12, 81, 67, 4937, 4672, 775, 30, 17642, 273, 3...
if otherLabel == 0 and map.face(0).area() < -self.mapArea + 1:
if otherLabel == 0 and map.face(0).area() < -self._mapArea + 1:
def mouseMoved(self, x, y): if not self.painting: return # comment out to get mouse-over face output
65254bc446b7c353066fe806e0424030a38d558d /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/10394/65254bc446b7c353066fe806e0424030a38d558d/tools.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 7644, 25317, 12, 2890, 16, 619, 16, 677, 4672, 309, 486, 365, 18, 84, 1598, 310, 30, 327, 468, 2879, 596, 358, 336, 7644, 17, 1643, 7945, 876, 2, 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, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 7644, 25317, 12, 2890, 16, 619, 16, 677, 4672, 309, 486, 365, 18, 84, 1598, 310, 30, 327, 468, 2879, 596, 358, 336, 7644, 17, 1643, 7945, 876, 2, -100, -100, -100, -100, -100, -100, ...
File "<doctest schoolbell.app.tests.test_app.run_unit_tests[3]>", line 3, in test2 self.assertEquals(2 * 2, 5) File "/usr/lib/python2.3/unittest.py", line 302, in failUnlessEqual raise self.failureException, \
...
... def test2(self):
c2b6bb22450645ad437b435afd894c559a740dc4 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/7127/c2b6bb22450645ad437b435afd894c559a740dc4/test_app.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1372, 377, 1652, 1842, 22, 12, 2890, 4672, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 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, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1372, 377, 1652, 1842, 22, 12, 2890, 4672, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100...
>>> unsetIdOnDeactivation(event)
>>> unsetIdOnDeactivation(perm1, event)
... def __init__(self, obj, name):
e267dc5d29490b7d8ea30de5ed3c08f2e6ad84d0 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/9520/e267dc5d29490b7d8ea30de5ed3c08f2e6ad84d0/permission.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1372, 377, 1652, 1001, 2738, 972, 12, 2890, 16, 1081, 16, 508, 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, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1372, 377, 1652, 1001, 2738, 972, 12, 2890, 16, 1081, 16, 508, 4672, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, ...
Tabify, Untabify, RemoveTrailingWhitespace,
Tabify, Untabify, RemoveTrailingWhitespace, JoinLines,
def getActions(self): return [CapitalizeWord, UpcaseWord, DowncaseWord, SwapcaseWord,
b11dcc87cadd59628872d0c0d9785129a9b52399 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/11522/b11dcc87cadd59628872d0c0d9785129a9b52399/text_transforms.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 6100, 12, 2890, 4672, 327, 306, 4664, 7053, 554, 3944, 16, 1948, 3593, 3944, 16, 10077, 3593, 3944, 16, 12738, 3593, 3944, 16, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 336, 6100, 12, 2890, 4672, 327, 306, 4664, 7053, 554, 3944, 16, 1948, 3593, 3944, 16, 10077, 3593, 3944, 16, 12738, 3593, 3944, 16, 2, -100, -100, -100, -100, -100, -100, -100, -100, -10...
def create_planning(self,cr, uid, ids, context={}):
def create_planning(self,cr, uid, ids, context=None): if context is None: context = {}
def create_planning(self,cr, uid, ids, context={}): product_obj = self.pool.get('product.product') planning_obj=self.pool.get('stock.planning') mod_obj =self.pool.get('ir.model.data') for f in self.browse(cr, uid, ids, context=context): if f.forecasted_products: cr.execute("SELECT product_id \ FROM stock_sale_forecast \ WHERE (period_id = %s) AND (warehouse_id = %s)", (f.period_id2.id, f.warehouse_id2.id)) products_id1 = [x for x, in cr.fetchall()] else: prod_categ_obj=self.pool.get('product.category') template_obj=self.pool.get('product.template') categ_ids = f.product_categ_id2.id and [f.product_categ_id2.id] or [] prod_categ_ids=prod_categ_obj.search(cr,uid,[('parent_id','child_of',categ_ids)]) templates_ids = template_obj.search(cr,uid,[('categ_id','in',prod_categ_ids)]) products_id1 = product_obj.search(cr,uid,[('product_tmpl_id','in',templates_ids)]) if len(products_id1)==0: raise osv.except_osv(_('Error !'), _('No forecasts for selected period or no products in selected category !'))
6a21b5d661b74602c870fac41f3c8c42e8bc6c33 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/7397/6a21b5d661b74602c870fac41f3c8c42e8bc6c33/stock_planning.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 752, 67, 412, 10903, 12, 2890, 16, 3353, 16, 4555, 16, 3258, 16, 819, 33, 7036, 4672, 309, 819, 353, 599, 30, 819, 273, 2618, 3017, 67, 2603, 273, 365, 18, 6011, 18, 588, 2668, 5896,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 752, 67, 412, 10903, 12, 2890, 16, 3353, 16, 4555, 16, 3258, 16, 819, 33, 7036, 4672, 309, 819, 353, 599, 30, 819, 273, 2618, 3017, 67, 2603, 273, 365, 18, 6011, 18, 588, 2668, 5896,...
document.body.insert(z-2, "\\family default")
document.body.insert(z - 2, "\\family default")
def revert_flex_inset(document, name, LaTeXname, position): " Convert flex insets to TeX code " i = position while True: i = find_token(document.body, '\\begin_inset Flex ' + name, i) if i == -1: return z = find_end_of_inset(document.body, i) if z == -1: document.warning("Malformed LyX document: Can't find end of Flex " + name + " inset.") return # remove the \end_inset document.body[z - 2:z + 1] = put_cmd_in_ert("}") # we need to reset character layouts if necessary j = find_token(document.body, '\\emph on', i) k = find_token(document.body, '\\noun on', i) l = find_token(document.body, '\\series', i) m = find_token(document.body, '\\family', i) n = find_token(document.body, '\\shape', i) o = find_token(document.body, '\\color', i) p = find_token(document.body, '\\size', i) q = find_token(document.body, '\\bar under', i) r = find_token(document.body, '\\uuline on', i) s = find_token(document.body, '\\uwave on', i) t = find_token(document.body, '\\strikeout on', i) if j != -1 and j < z: document.body.insert(z-2, "\\emph default") if k != -1 and k < z: document.body.insert(z-2, "\\noun default") if l != -1 and l < z: document.body.insert(z-2, "\\series default") if m != -1 and m < z: document.body.insert(z-2, "\\family default") if n != -1 and n < z: document.body.insert(z-2, "\\shape default") if o != -1 and o < z: document.body.insert(z-2, "\\color inherit") if p != -1 and p < z: document.body.insert(z-2, "\\size default") if q != -1 and q < z: document.body.insert(z-2, "\\bar default") if r != -1 and r < z: document.body.insert(z-2, "\\uuline default") if s != -1 and s < z: document.body.insert(z-2, "\\uwave default") if t != -1 and t < z: document.body.insert(z-2, "\\strikeout default") document.body[i:i + 4] = put_cmd_in_ert(LaTeXname + "{") i += 1
bcd8b9a1f1241c461beb5db1d5a69424a9a25950 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/7514/bcd8b9a1f1241c461beb5db1d5a69424a9a25950/lyx_2_0.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 15226, 67, 27592, 67, 267, 542, 12, 5457, 16, 508, 16, 21072, 21575, 60, 529, 16, 1754, 4672, 315, 4037, 16600, 23576, 358, 28602, 60, 981, 315, 277, 273, 1754, 1323, 1053, 30, 277, 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, 15226, 67, 27592, 67, 267, 542, 12, 5457, 16, 508, 16, 21072, 21575, 60, 529, 16, 1754, 4672, 315, 4037, 16600, 23576, 358, 28602, 60, 981, 315, 277, 273, 1754, 1323, 1053, 30, 277, 27...
messages = [randomCommit() for i in xrange(10000)]
messages = [randomCommit(i) for i in xrange(10000)]
def main(self): # Load rulesets print "Loading rulesets..." for ruleset in self.rulesets: self.server.ruleset.store(self.key, ruleset)
d0ac1c2d2a3f14e3f1f3b6256e4b4de7af15ee27 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/9478/d0ac1c2d2a3f14e3f1f3b6256e4b4de7af15ee27/torture_stats.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 2774, 12, 2890, 4672, 468, 4444, 2931, 2413, 1172, 315, 10515, 2931, 2413, 7070, 364, 25303, 316, 365, 18, 7482, 2413, 30, 365, 18, 3567, 18, 7482, 278, 18, 2233, 12, 2890, 18, 856, 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, 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, 2774, 12, 2890, 4672, 468, 4444, 2931, 2413, 1172, 315, 10515, 2931, 2413, 7070, 364, 25303, 316, 365, 18, 7482, 2413, 30, 365, 18, 3567, 18, 7482, 278, 18, 2233, 12, 2890, 18, 856, 16...
@files(['bam/', 'clipped/', 'sam/', 'sorted/'], None)
@files(['sam/', 'sorted/'], None)
def create_intervals_generator(): for infile in glob('deduped/*.bam'): outfile = '%(line)s_s_%(lane)s.intervals' % filename_re.search(infile).groupdict() yield [infile, 'intervals/%s' % outfile]
00ba79a4892e8201d23095f8268553b639ea2057 /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/14572/00ba79a4892e8201d23095f8268553b639ea2057/recalibrate_qs.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 752, 67, 19812, 67, 8812, 13332, 364, 14568, 316, 4715, 2668, 785, 416, 329, 30987, 11477, 11, 4672, 8756, 273, 21063, 1369, 13, 87, 67, 87, 10185, 12, 29351, 13, 87, 18, 19812, 11, 73...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 752, 67, 19812, 67, 8812, 13332, 364, 14568, 316, 4715, 2668, 785, 416, 329, 30987, 11477, 11, 4672, 8756, 273, 21063, 1369, 13, 87, 67, 87, 10185, 12, 29351, 13, 87, 18, 19812, 11, 73...
ValueError.__init__(self, _('Could not find reasonable point at which to split: %s Sub-tree size: %d KB')%
ValueError.__init__(self, _('Could not find reasonable point at which to split: %s Sub-tree size: %d KB')%
def __init__(self, path, root): size = len(tostring(root))/1024. ValueError.__init__(self, _('Could not find reasonable point at which to split: %s Sub-tree size: %d KB')% (os.path.basename(path), size))
e869684a299f6ee49985cfc2ed305b42306b26d6 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/9125/e869684a299f6ee49985cfc2ed305b42306b26d6/split.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1001, 2738, 972, 12, 2890, 16, 589, 16, 1365, 4672, 963, 273, 562, 12, 14627, 371, 12, 3085, 3719, 19, 2163, 3247, 18, 2068, 16186, 2738, 972, 12, 2890, 16, 389, 2668, 4445, 486, 1104,...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 589, 16, 1365, 4672, 963, 273, 562, 12, 14627, 371, 12, 3085, 3719, 19, 2163, 3247, 18, 2068, 16186, 2738, 972, 12, 2890, 16, 389, 2668, 4445, 486, 1104,...
correct.get_result('rmsd_phi')))
correct.get_result('rmsd_phi'))
def _integrate_finish(self): '''Finish off the integration by running correct.'''
8be8d25995eac9c9ed21e2c9c2897ce736260f3b /local1/tlutelli/issta_data/temp/all_python//python/2007_temp/2007/3290/8be8d25995eac9c9ed21e2c9c2897ce736260f3b/XDSIntegrater.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 14970, 5141, 67, 13749, 12, 2890, 4672, 9163, 11641, 3397, 326, 12040, 635, 3549, 3434, 1093, 6309, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 14970, 5141, 67, 13749, 12, 2890, 4672, 9163, 11641, 3397, 326, 12040, 635, 3549, 3434, 1093, 6309, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -1...
if indepVar1:
if indepVar1 is not None:
def exprFromPattern(self, nodeList1, edge, nodeList2): rels = []
8646d50126c55931291904836b90660c854e7004 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/5223/8646d50126c55931291904836b90660c854e7004/parser.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 3065, 1265, 3234, 12, 2890, 16, 10198, 21, 16, 3591, 16, 10198, 22, 4672, 19214, 273, 5378, 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, 3065, 1265, 3234, 12, 2890, 16, 10198, 21, 16, 3591, 16, 10198, 22, 4672, 19214, 273, 5378, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -...
if __debug__: print "already colorizing"
if DEBUG: print "already colorizing"
def recolorize(self): self.after_id = None if not self.delegate: if __debug__: print "no delegate" return if not self.allow_colorizing: if __debug__: print "auto colorizing is off" return if self.colorizing: if __debug__: print "already colorizing" return try: self.stop_colorizing = 0 self.colorizing = 1 if __debug__: print "colorizing..." t0 = time.clock() self.recolorize_main() t1 = time.clock() if __debug__: print "%.3f seconds" % (t1-t0) finally: self.colorizing = 0 if self.allow_colorizing and self.tag_nextrange("TODO", "1.0"): if __debug__: print "reschedule colorizing" self.after_id = self.after(1, self.recolorize) if self.close_when_done: top = self.close_when_done self.close_when_done = None top.destroy()
4fe2a7039a545a4d36f56a714ca7de67724d5db9 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/12029/4fe2a7039a545a4d36f56a714ca7de67724d5db9/ColorDelegator.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 283, 3266, 554, 12, 2890, 4672, 365, 18, 5205, 67, 350, 273, 599, 309, 486, 365, 18, 22216, 30, 309, 1001, 4148, 972, 30, 1172, 315, 2135, 7152, 6, 327, 309, 486, 365, 18, 5965, 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, 283, 3266, 554, 12, 2890, 4672, 365, 18, 5205, 67, 350, 273, 599, 309, 486, 365, 18, 22216, 30, 309, 1001, 4148, 972, 30, 1172, 315, 2135, 7152, 6, 327, 309, 486, 365, 18, 5965, 67, ...
lcolor = [color[0], color[1], color[2], 1.0]
lcolor = (color[0], color[1], color[2], 1.0) else: lcolor = color
def schedule_cylinder(color, pos1, pos2, radius, capped=0): """\ Schedule a cylinder for rendering whenever ColorSorter thinks is appropriate. """ if TEST_PYREX_OPENGL and ColorSorter.sorting: if len(color) == 3: lcolor = [color[0], color[1], color[2], 1.0] ColorSorter._cur_shapelist.add_cylinder(lcolor, pos1, pos2, radius, ColorSorter._gl_name_stack[-1], capped) else: ColorSorter.schedule(color, drawcylinder_worker, (pos1, pos2, radius, capped))
29d1ead022d00c9c6ff179533709f9303571de80 /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/11221/29d1ead022d00c9c6ff179533709f9303571de80/drawer.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 4788, 67, 2431, 80, 14055, 12, 3266, 16, 949, 21, 16, 949, 22, 16, 5725, 16, 3523, 1845, 33, 20, 4672, 3536, 64, 10674, 279, 27331, 14055, 364, 9782, 17334, 5563, 24952, 15507, 87, 353...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 4788, 67, 2431, 80, 14055, 12, 3266, 16, 949, 21, 16, 949, 22, 16, 5725, 16, 3523, 1845, 33, 20, 4672, 3536, 64, 10674, 279, 27331, 14055, 364, 9782, 17334, 5563, 24952, 15507, 87, 353...
def finish(self):
def finished(self): print 'Converter.finished'
def finish(self): self.converting = False Pipeline.finish(self)
9fbe5a6b2f9d9ecbf3c2e79d0b111d153cffa4dc /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/2369/9fbe5a6b2f9d9ecbf3c2e79d0b111d153cffa4dc/soundconverter.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 6708, 12, 2890, 4672, 1172, 296, 5072, 18, 13527, 11, 365, 18, 6283, 310, 273, 1083, 13671, 18, 13749, 12, 2890, 13, 2, 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, 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, 6708, 12, 2890, 4672, 1172, 296, 5072, 18, 13527, 11, 365, 18, 6283, 310, 273, 1083, 13671, 18, 13749, 12, 2890, 13, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, ...
stateStr = "0.1f" % (ccdSetTemp)
stateStr = "%0.1f" % (ccdSetTemp,)
def _updCCDSetTemp(self, dataList, isCurrent, keyVar=None): #print "_updCCDSetTemp(ccdSetTempInfo=%s, isCurrent=%s)" % (ccdSetTempInfo, isCurrent) ccdSetTemp, tempStatus = dataList[0:2] if ccdSetTemp == None: stateStr = "?" else: stateStr = "0.1f" % (ccdSetTemp) if tempStatus != None: tempStatus = tempStatus.lower() dispStr, severity = self.ccdTempStateDict.get(tempStatus, (tempStatus, RO.Constants.sevWarning)) if dispStr != None: stateStr = "%s %s" % (stateStr, dispStr) self.ccdSetTempWdg.set(stateStr, isCurrent=isCurrent, severity=severity) if not isCurrent or severity != RO.Constants.sevNormal: self.environStateSet.setState(DevCCDSetTemp, isCurrent = isCurrent, severity = severity, stateStr=stateStr) else: self.environStateSet.clearState(DevCCDSetTemp)
b73361a8f3308342ea9a6c7f530ef4b872f38ad5 /local1/tlutelli/issta_data/temp/all_python//python/2009_temp/2009/6354/b73361a8f3308342ea9a6c7f530ef4b872f38ad5/StatusConfigInputWdg.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 389, 5533, 6743, 40, 694, 7185, 12, 2890, 16, 501, 682, 16, 25694, 16, 498, 1537, 33, 7036, 4672, 468, 1188, 4192, 5533, 6743, 40, 694, 7185, 12, 952, 72, 694, 7185, 966, 5095, 87, 1...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 6743, 40, 694, 7185, 12, 2890, 16, 501, 682, 16, 25694, 16, 498, 1537, 33, 7036, 4672, 468, 1188, 4192, 5533, 6743, 40, 694, 7185, 12, 952, 72, 694, 7185, 966, 5095, 87, 1...
assert dlog[1] == ('jit-backend-counts', [('debug_print', '0:10')])
assert ('jit-backend-counts', [('debug_print', '0:10')]) in dlog
def test_debugger_on(self): from pypy.tool.logparser import parse_log_file, extract_category from pypy.rlib import debug loop = """ [i0] debug_merge_point('xyz', 0) i1 = int_add(i0, 1) i2 = int_ge(i1, 10) guard_false(i2) [] jump(i1) """ ops = parse(loop) debug._log = dlog = debug.DebugLog() try: self.cpu.assembler.set_debug(True) self.cpu.compile_loop(ops.inputargs, ops.operations, ops.token) self.cpu.set_future_value_int(0, 0) self.cpu.execute_token(ops.token) # check debugging info name, struct = self.cpu.assembler.loop_run_counters[0] assert name == 0 # 'xyz' assert struct.i == 10 self.cpu.finish_once() finally: debug._log = None assert dlog[1] == ('jit-backend-counts', [('debug_print', '0:10')])
0462dce79f066405e8fa78a3a75eea70a0e9374a /local1/tlutelli/issta_data/temp/all_python//python/2010_temp/2010/6934/0462dce79f066405e8fa78a3a75eea70a0e9374a/test_runner.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 1842, 67, 4148, 693, 67, 265, 12, 2890, 4672, 628, 18951, 93, 18, 6738, 18, 1330, 4288, 1930, 1109, 67, 1330, 67, 768, 16, 2608, 67, 4743, 628, 18951, 93, 18, 1321, 495, 1930, 1198, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 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, 4148, 693, 67, 265, 12, 2890, 4672, 628, 18951, 93, 18, 6738, 18, 1330, 4288, 1930, 1109, 67, 1330, 67, 768, 16, 2608, 67, 4743, 628, 18951, 93, 18, 1321, 495, 1930, 1198, ...
re-gzip .gz files with -9 -n
re-gzip .gz files with -9 -n to get maximum compression and avoid meaningless changes overpopulating the database.
def do(self):
0713e7b5dcd981275578b92b3f4e4f777590f51d /local1/tlutelli/issta_data/temp/all_python//python/2006_temp/2006/8747/0713e7b5dcd981275578b92b3f4e4f777590f51d/policy.py
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 741, 12, 2890, 4672, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 8585, 326, 22398, 316, 326, 981, 30, 1652, 741, 12, 2890, 4672, 2, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -100, -1...