Search is not available for this dataset
id
int32
source_tokens
list
has_bug
bool
error_location
int32
repair_candidates
list
bug_kind
int32
bug_kind_name
string
repair_targets
list
edges
list
provenances
list
template_name
string
template
string
rendered_input
string
rendered_output
string
700
[ "#NEWLINE#", "def _pick_exit(", "self", ",", "block_address", ",", "stmt_idx", ",", "target_ips", ")", ":", "#NEWLINE#", "#INDENT#", "'\\n Include an exit in the final slice.\\n\\n :param block_address: Address of the basic block.\\n :param stmt_idx: ID of the...
false
0
[ "6", "18", "stmt_idx", "15", "25", "46", "tpl", "8", "20", "target_ips", "4", "31", "41", "block_address", "2", "27", "37", "self" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 12, "after_index": 13, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 14, "after_index": 1...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "angr/angr/angr/analyses/backward_slice.py", "license": "bsd-2-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def _pick_exit(self, block_address, stmt_idx, target_ips) : ' Include an exit in the final slice. :param block_address: Address of the basic block. :param stmt_idx: ID of the exit statement. :param target_ips: The target address of this exit statement. ' ...
No
701
[ "#NEWLINE#", "def on_pubmsg(", "self", ",", "c", ",", "e", ")", ":", "#NEWLINE#", "#INDENT#", "content", "=", "e", ".", "arguments", "[", "0", "]", "#NEWLINE#", "stream", "=", "e", ".", "target", "#NEWLINE#", "sender", "=", "zulip_sender", "(", "e", ".",...
false
0
[ "6", "13", "22", "30", "e", "20", "78", "stream", "4", "c", "11", "88", "content", "2", "self", "26", "36", "68", "sender" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 16, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 19, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "zulip/zulip/bots/irc-mirror.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def on_pubmsg(self, c, e) : content = e.arguments [0] stream = e.target sender = zulip_sender (e.source) if sender.endswith (('_zulip@' + IRC_DOMAIN)) : return print (zulip_client.send_message ({ 'forged' : 'yes', 'sender' : sender, 'type' : 'stream', 't...
No
702
[ "#NEWLINE#", "def single(", "self", ",", "table", ",", "request", ",", "obj_id", ")", ":", "#NEWLINE#", "#INDENT#", "if", "(", "(", "'domain_context'", "not in", "request", ".", "session", ")", "or", "(", "request", ".", "session", "[", "'domain_context'", "...
false
0
[ "2", "self", "8", "31", "51", "61", "obj_id", "4", "table", "6", "18", "24", "49", "54", "63", "78", "102", "request", "41", "70", "86", "domain" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 13, "after_index": 22, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 17, "after_index": 1...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "openstack/horizon/openstack_dashboard/dashboards/identity/domains/tables.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def single(self, table, request, obj_id) : if (('domain_context' not in request.session) or (request.session ['domain_context'] != obj_id)) : try : domain = api.keystone.domain_get (request, obj_id) request.session ['domain_context'] = obj_id request.session ['domain...
No
703
[ "#NEWLINE#", "def matchFact(", "self", ",", "otherFact", ",", "unmatchedFactsStack", "=", "None", ",", "deemP0inf", "=", "False", ")", ":", "#NEWLINE#", "#INDENT#", "'Finds matching fact, by XBRL 2.1 duplicate definition (if tuple), or by\\n QName and VEquality (if an item),...
false
0
[ "2", "22", "self", "20", "29", "40", "50", "61", "70", "87", "96", "108", "119", "129", "142", "fact", "10", "76", "78", "deemP0inf", "6", "42", "44", "unmatchedFactsStack", "4", "36", "65", "74", "100", "123", "133", "otherFact" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 16, "after_index": 17, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 19, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "Arelle/Arelle/arelle/ModelXbrl.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def matchFact(self, otherFact, unmatchedFactsStack = None, deemP0inf = False) : 'Finds matching fact, by XBRL 2.1 duplicate definition (if tuple), or by QName and VEquality (if an item), lang and accuracy equality, as in formula and test case usage :param otherFact: Fact to match :...
No
704
[ "#NEWLINE#", "def createFact(", "self", ",", "conceptQname", ",", "attributes", "=", "None", ",", "text", "=", "None", ",", "parent", "=", "None", ",", "afterSibling", "=", "None", ",", "beforeSibling", "=", "None", ",", "validate", "=", "True", ")", ":", ...
false
0
[ "2", "46", "53", "107", "114", "147", "160", "166", "190", "198", "222", "230", "238", "245", "265", "273", "279", "self", "10", "73", "75", "text", "18", "77", "79", "afterSibling", "22", "81", "83", "beforeSibling", "26", "152", "158", "validate", ...
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 32, "after_index": 33, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 35, "after_index": 3...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "Arelle/Arelle/arelle/ModelXbrl.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def createFact(self, conceptQname, attributes = None, text = None, parent = None, afterSibling = None, beforeSibling = None, validate = True) : "Creates new fact, as in formula output instance creation, and validates into object model :param conceptQname: QNames of concept :type conceptQna...
No
705
[ "#NEWLINE#", "def sendSubmitSmResponse(", "self", ",", "reqPDU", ")", ":", "#NEWLINE#", "#INDENT#", "if", "(", "reqPDU", ".", "params", "[", "'short_message'", "]", "==", "'test_error: ESME_RTHROTTLED'", ")", ":", "#NEWLINE#", "#INDENT#", "status", "=", "CommandStat...
false
0
[ "2", "93", "124", "128", "self", "4", "11", "36", "61", "97", "101", "reqPDU", "23", "48", "73", "84", "105", "107", "status" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 9, "after_index": 17, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 92, "after_index": 10...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "jookies/jasmin/jasmin/protocols/smpp/test/smsc_simulator.py", "license": "apache-2.0", "note": "license: manual_eval" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def sendSubmitSmResponse(self, reqPDU) : if (reqPDU.params ['short_message'] == 'test_error: ESME_RTHROTTLED') : status = CommandStatus.ESME_RTHROTTLED else : if (reqPDU.params ['short_message'] == 'test_error: ESME_RSYSERR') : status = CommandStatus.ESME_RSYSERR else : ...
No
706
[ "#NEWLINE#", "def __init__(", "self", ",", "nModels", ",", "pi", "=", "0.5", ",", "learnPi", "=", "False", ",", "group_spike", "=", "True", ",", "variance", "=", "1.0", ",", "name", "=", "'SSMRDPrior'", ",", "**kw", ")", ":", "#NEWLINE#", "#INDENT#", "se...
false
0
[ "2", "31", "37", "47", "self", "6", "52", "54", "pi", "4", "33", "35", "nModels", "14", "60", "62", "group_spike", "18", "64", "66", "variance", "73", "kw", "22", "68", "70", "name", "10", "56", "58", "learnPi" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 30, "after_index": 35, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 36, "after_index": 4...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "SheffieldML/GPy/GPy/models/ss_mrd.py", "license": "bsd-3-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def __init__(self, nModels, pi = 0.5, learnPi = False, group_spike = True, variance = 1.0, name = 'SSMRDPrior', **kw) : self.nModels = nModels self._b_prob_all = 0.5 super (SpikeAndSlabPrior_SSMRD, self).__init__ (pi = pi, learnPi = learnPi, group_spike = group_spike, variance = variance, name = name, **...
No
707
[ "#NEWLINE#", "def test_node_create_mac_validation(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "maccaddresses", "=", "(", "(", "'60a44c3528ff'", ",", "400", ")", ",", "(", "'60:a4:4c:35:28'", ",", "400", ")", ",", "(", "'60:a4:4c:35:28:fg'", ",", "400", ")", ",...
false
0
[ "2", "66", "100", "113", "self", "64", "117", "response", "55", "86", "mac", "57", "107", "121", "http_code", "7", "60", "maccaddresses" ]
0
NONE
[]
[ [ { "before_index": 6, "after_index": 15, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 53, "after_index": 56, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 53, "after_index": ...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "openstack/fuel-web/nailgun/nailgun/test/integration/test_node_collection_handlers.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def test_node_create_mac_validation(self) : maccaddresses = (('60a44c3528ff', 400), ('60:a4:4c:35:28', 400), ('60:a4:4c:35:28:fg', 400), ('76:DC:7C:CA:G4:75', 400), ('76-DC-7C-CA-G4-75', 400), ('60:a4:4c:35:28:ff', 201), ('48-2C-6A-1E-59-3D', 201)) for (mac, http_code) in maccaddresses : response = s...
No
708
[ "#NEWLINE#", "def setVisProperties(", "obj", ",", "colorModeEnabled", ")", ":", "#NEWLINE#", "#INDENT#", "if", "colorModeEnabled", ":", "#NEWLINE#", "#INDENT#", "alpha", "=", "1.0", "#NEWLINE#", "pointSize", "=", "4.0", "#NEWLINE#", "colorBy", "=", "'rgb'", "#NEWLIN...
false
0
[ "14", "31", "50", "alpha", "2", "44", "53", "obj", "4", "10", "colorModeEnabled", "22", "39", "colorBy", "18", "35", "59", "pointSize" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 9, "after_index": 10, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 43, "after_index": 49...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "RobotLocomotion/director/src/python/director/colorize.py", "license": "bsd-3-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def setVisProperties(obj, colorModeEnabled) : if colorModeEnabled : alpha = 1.0 pointSize = 4.0 colorBy = 'rgb' else : alpha = 0.5 pointSize = 1.0 colorBy = None obj.setProperty ('Alpha', alpha) obj.setProperty ('Point Size', pointSize) Is there a bug ...
No
709
[ "#NEWLINE#", "def test_joined_string_regex(", ")", ":", "#NEWLINE#", "#INDENT#", "schema", "=", "JoinedString", ".", "using", "(", "separator", "=", "', '", ",", "separator_regex", "=", "re", ".", "compile", "(", "'X*,X*'", ")", ")", "#NEWLINE#", "el", "=", "s...
false
0
[ "45", "49", "78", "82", "child", "6", "28", "61", "schema", "26", "35", "51", "59", "68", "84", "el" ]
0
NONE
[]
[ [ { "before_index": 5, "after_index": 15, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 25, "after_index": 29, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 33, "after_index": ...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "jek/flatland/tests/schema/test_compound.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def test_joined_string_regex() : schema = JoinedString.using (separator = ', ', separator_regex = re.compile ('X*,X*')) el = schema ('abc') assert (el.value == 'abc') assert ([child.value for child in el] == ['abc']) el = schema ('abcX,Xdef') assert (el.value == 'abc, def') assert ([c...
No
710
[ "#NEWLINE#", "def update(", "self", ",", "other", ")", ":", "#NEWLINE#", "#INDENT#", "for", "(", "name", ",", "other_key", ")", "in", "other", ".", "db_config_keys_name_index", ".", "iteritems", "(", ")", ":", "#NEWLINE#", "#INDENT#", "if", "(", "isinstance", ...
false
0
[ "2", "37", "47", "66", "self", "13", "30", "56", "72", "other_key", "4", "16", "other", "11", "41", "51", "70", "name" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 9, "after_index": 12, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 9, "after_index": 21,...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "VisTrails/VisTrails/vistrails/core/configuration.py", "license": "bsd-3-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def update(self, other) : for (name, other_key) in other.db_config_keys_name_index.iteritems () : if (isinstance (other_key.value, ConfigurationObject) and self.has (name)) : self.get (name).update (other_key.value) else : self.__setattr__ (name, other_key.value) Is there a bu...
No
711
[ "#NEWLINE#", "def testEnterReturnValue(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "m", "=", "Gaffer", ".", "PerformanceMonitor", "(", ")", "#NEWLINE#", "with", "m", "as", "n", ":", "#NEWLINE#", "#INDENT#", "pass", "#NEWLINE#", "#UNINDENT#", "self", ".", "asse...
false
0
[ "18", "32", "n", "2", "25", "self", "7", "16", "30", "m" ]
0
NONE
[]
[ [ { "before_index": 6, "after_index": 12, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 24, "after_index": 28, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 12, "after_index": ...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "ImageEngine/gaffer/python/GafferTest/PerformanceMonitorTest.py", "license": "bsd-3-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def testEnterReturnValue(self) : m = Gaffer.PerformanceMonitor () with m as n : pass self.assertTrue ((m is n)) Is there a bug in the code above?
No
712
[ "#NEWLINE#", "@", "withActionContext", "#NEWLINE#", "def test_addCallbacksErrbackResult(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "'\\n An errback added with DeferredContext.addCallbacks has its result passed\\n on to the next callback.\\n '", "#NEWLINE#", "exception...
false
0
[ "12", "22", "69", "exception", "5", "57", "61", "self", "18", "25", "29", "32", "65", "d" ]
0
NONE
[]
[ [ { "before_index": 9, "after_index": 10, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 11, "after_index": 15, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 17, "after_index": ...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "ClusterHQ/eliot/eliot/tests/test_twisted.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
@ withActionContext def test_addCallbacksErrbackResult(self) : ' An errback added with DeferredContext.addCallbacks has its result passed on to the next callback. ' exception = ZeroDivisionError () d = fail (exception) d = DeferredContext (d) d.addCallbacks ((lambda x :...
No
713
[ "#NEWLINE#", "def __init__(", "self", ",", "length", "=", "None", ",", "router_id", "=", "'0.0.0.0'", ",", "area_id", "=", "'0.0.0.0'", ",", "au_type", "=", "1", ",", "authentication", "=", "0", ",", "checksum", "=", "None", ",", "version", "=", "_VERSION"...
false
0
[ "24", "71", "checksum", "2", "54", "76", "self", "8", "63", "router_id", "20", "69", "authentication", "4", "61", "length", "12", "65", "area_id", "16", "67", "au_type", "32", "39", "42", "44", "78", "80", "lsa_requests", "28", "73", "version" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 38, "after_index": 43, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 49, "after_index": 6...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "osrg/ryu/ryu/lib/packet/ospf.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def __init__(self, length = None, router_id = '0.0.0.0', area_id = '0.0.0.0', au_type = 1, authentication = 0, checksum = None, version = _VERSION, lsa_requests = None) : lsa_requests = (lsa_requests if lsa_requests else []) super (OSPFLSReq, self).__init__ (OSPF_MSG_LS_REQ, length, router_id, area_id, au_typ...
No
714
[ "#NEWLINE#", "def get_form(", "self", ",", "request", ",", "obj", "=", "None", ",", "**kwargs", ")", ":", "#NEWLINE#", "#INDENT#", "form", "=", "super", "(", "ChannelAdmin", ",", "self", ")", ".", "get_form", "(", "request", ",", "obj", ",", "**", "kwarg...
false
0
[ "152", "202", "_get_json_channel_recursivelly", "124", "_get_json_channel", "216", "250", "layout_list", "2", "21", "self", "4", "26", "request", "6", "28", "204", "obj", "235", "262", "layout_choices", "224", "226", "l", "94", "175", "_get_template_path", "239"...
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 14, "after_index": 27, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 33, "after_index": 3...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "opps/opps/opps/channels/admin.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def get_form(self, request, obj = None, **kwargs) : form = super (ChannelAdmin, self).get_form (request, obj, ** kwargs) channel_json = [] def _get_template_path(_path) : template = get_template_path (_path) with open (template) as f : _jsonData = f.read ().replace (' ', ''...
No
715
[ "#NEWLINE#", "def hook(", "self", ",", "subdir", ",", "callback", ")", ":", "#NEWLINE#", "#INDENT#", "if", "(", "subdir", "in", "self", ".", "callbacks", ")", ":", "#NEWLINE#", "#INDENT#", "log", ".", "warning", "(", "(", "\"The HTTP subdirectory `%s` was alread...
true
41
[ "2", "15", "34", "41", "47", "6", "43", "4", "13", "29", "38", "49" ]
1
VARIABLE_MISUSE
[ 6, 43 ]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 11, "after_index": 14, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 33, "after_index": 4...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "ProgVal/Limnoria/src/httpserver.py", "license": "bsd-3-clause", "note": "license: manual_eval" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def hook(self, subdir, callback) : if (subdir in self.callbacks) : log.warning (("The HTTP subdirectory `%s` was already hooked but has been claimed by another plugin (or maybe you reloaded the plugin and it didn't properly unhook. Forced unhook." % subdir)) self.callbacks [subdir] = self callback.d...
Yes
716
[ "#NEWLINE#", "def test_available_for_one_included_one_not(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "'Get a list of available cases, one included'", "#NEWLINE#", "data", "=", "self", ".", "_setup_for_one_included_one_not", "(", ")", "#NEWLINE#", "exp_objects", "=", "[", "...
true
35
[ "2", "11", "20", "31", "42", "9", "24", "17", "35", "46", "48" ]
1
VARIABLE_MISUSE
[ 9, 24 ]
[ [ { "before_index": 6, "after_index": 7, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 14, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 16, "after_index": 19...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "mozilla/moztrap/tests/model/library/api/test_caseversion_resource.py", "license": "bsd-2-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def test_available_for_one_included_one_not(self) : 'Get a list of available cases, one included' data = self._setup_for_one_included_one_not () exp_objects = [self.get_exp_obj (data ['cv2'])] self._do_test (exp_objects ['t'].id, self.available_param, exp_objects = exp_objects) Is there a bug in t...
Yes
717
[ "#NEWLINE#", "def get_report_metadata(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "'Extract the DMARC metadata as defined here: \\n\\t\\thttp://www.dmarc.org/draft-dmarc-base-00-02.txt in Appendix C\\n\\t\\tIf no data is found, return NA\\n\\t\\t'", "#NEWLINE#", "orgName", "=", "self", "."...
true
88
[ "24", "123", "115", "145", "54", "127", "9", "121", "91", "106", "110", "131", "2", "11", "26", "41", "56", "71", "88", "93", "139", "148", "161", "170", "174", "69", "84", "129", "39", "125" ]
1
VARIABLE_MISUSE
[ 69, 84, 129 ]
[ [ { "before_index": 6, "after_index": 7, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 18, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 23, "after_index": 33...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "thinkingserious/sendgrid-python-dmarc-parser/dmarc_parser/parse_dmarc.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def get_report_metadata(self) : 'Extract the DMARC metadata as defined here: \t\thttp://www.dmarc.org/draft-dmarc-base-00-02.txt in Appendix C \t\tIf no data is found, return NA \t\t' orgName = self.doc.findtext ('report_metadata/org_name', default = 'NA') email = self.doc.findtext ('report_metadata/ema...
Yes
718
[ "#NEWLINE#", "@", "staticmethod", "#NEWLINE#", "def _invoke_action(", "action_exec_spec", ",", "params", ",", "context", "=", "None", ")", ":", "#NEWLINE#", "#INDENT#", "'\\n Schedule an action execution.\\n\\n :type action_exec_spec: :class:`ActionExecutionSpecDB`\\n\\...
true
42
[ "7", "25", "33", "50", "9", "42", "44", "46", "5", "20", "18", "31", "36", "54", "63", "56", "67" ]
1
VARIABLE_MISUSE
[ 18, 31 ]
[ [ { "before_index": 1, "after_index": 6, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 15, "after_index": 16, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 17, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "StackStorm/st2/st2reactor/st2reactor/rules/enforcer.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
@ staticmethod def _invoke_action(action_exec_spec, params, context = None) : ' Schedule an action execution. :type action_exec_spec: :class:`ActionExecutionSpecDB` :param params: Parameters to execute the action with. :type params: ``dict`` :rtype: :class:`LiveActionDB`...
Yes
719
[ "#NEWLINE#", "@", "classmethod", "#NEWLINE#", "def load(", "self", ",", "filename", ")", ":", "#NEWLINE#", "#INDENT#", "'Loads scoring function from a pickle file.\\n\\n Parameters\\n ----------\\n filename: string\\n Pickle filename\\n\\n Retur...
true
19
[ "5", "19", "7" ]
1
VARIABLE_MISUSE
[ 7 ]
[ [ { "before_index": 1, "after_index": 6, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 11, "after_index": 12, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 14, "after_index": 1...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "oddt/oddt/oddt/scoring/__init__.py", "license": "bsd-3-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
@ classmethod def load(self, filename) : 'Loads scoring function from a pickle file. Parameters ---------- filename: string Pickle filename Returns ------- sf: scorer-like object Scoring function object loaded from a pickle ...
Yes
720
[ "#NEWLINE#", "def find_tag(", "fid", ",", "node", ",", "findkind", ")", ":", "#NEWLINE#", "#INDENT#", "'Find Tag in an open FIF file descriptor\\n\\n Parameters\\n ----------\\n fid : file-like\\n Open file.\\n node : dict\\n Node to search.\\n findkind : int\\n ...
true
28
[ "2", "49", "4", "15", "6", "41", "26", "28", "37", "51" ]
1
VARIABLE_MISUSE
[ 4, 15 ]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 11, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 13, "after_index": 1...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "mne-tools/mne-python/mne/io/tag.py", "license": "bsd-3-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def find_tag(fid, node, findkind) : 'Find Tag in an open FIF file descriptor Parameters ---------- fid : file-like Open file. node : dict Node to search. findkind : int Tag kind to find. Returns ------- tag : instance of Tag The first tag found. ...
Yes
721
[ "#NEWLINE#", "def test_get_config_dict(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "env", "=", "{", "#NEWLINE#", "#INDENT#", "'cwd'", ":", "get_fixture_path", "(", "'project'", ")", ",", "#NEWLINE#", "#UNINDENT#", "}", "#NEWLINE#", "expected_type", "=", "{", "#N...
true
72
[ "2", "57", "66", "7", "63", "72", "55", "70", "23" ]
1
VARIABLE_MISUSE
[ 23 ]
[ [ { "before_index": 6, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 22, "after_index": 25, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 54, "after_index": 6...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "Kuniwak/vint/test/unit/vint/linting/config/test_config_project_source.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def test_get_config_dict(self) : env = { 'cwd' : get_fixture_path ('project'), } expected_type = { 'cmdargs' : { 'verbose' : bool, 'error-limit' : int, 'severity' : Enum, }, } config_source = self.initialize_config_source_with_env (ConfigProject...
Yes
722
[ "#NEWLINE#", "def _update_hosting_device_statuses(", "self", ",", "hosting_devices", ",", "statuses", ")", ":", "#NEWLINE#", "#INDENT#", "adm_ctxt", "=", "n_context", ".", "get_admin_context", "(", ")", "#NEWLINE#", "core_plugin", "=", "manager", ".", "NeutronManager", ...
true
58
[ "2", "31", "47", "45", "4", "38", "11", "56", "33", "58", "73", "6", "40", "19", "52" ]
1
VARIABLE_MISUSE
[ 45 ]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 16, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 18, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "openstack/networking-cisco/networking_cisco/tests/unit/cisco/l3/test_l3_routertype_aware_schedulers.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def _update_hosting_device_statuses(self, hosting_devices, statuses) : adm_ctxt = n_context.get_admin_context () core_plugin = manager.NeutronManager.get_plugin () for (hosting_device, status) in zip (hosting_devices, statuses) : hd = hosting_device ['hosting_device'] core_plugin.update...
Yes
723
[ "#NEWLINE#", "def __init__(", "self", ",", "user", "=", "0", ",", "system", "=", "0", ",", "idle", "=", "0", ")", ":", "#NEWLINE#", "#INDENT#", "self", ".", "update", "(", "user", ",", "self", ",", "idle", ")" ]
true
25
[ "4", "23", "2", "19", "25", "12", "27", "8" ]
1
VARIABLE_MISUSE
[ 8 ]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 18, "after_index": 24, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 24, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "ton1517/ttop/ttop/core.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def __init__(self, user = 0, system = 0, idle = 0) : self.update (user, self, idle) Is there a bug in the code above?
Yes
724
[ "#NEWLINE#", "def test_replace_route_table(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "data", "=", "self", ".", "client", ".", "create_subnet", "(", "VpcId", "=", "self", ".", "vpc_id", ",", "CidrBlock", "=", "self", ".", "SUBNET_CIDR", ")", "#NEWLINE#", "s...
true
198
[ "38", "486", "148", "168", "176", "240", "265", "422", "439", "247", "446", "198", "317", "328", "346", "357", "378", "7", "30", "66", "107", "122", "137", "150", "181", "223", "242", "268", "309", "319", "425", "449", "469", "135", "261", "435",...
1
VARIABLE_MISUSE
[ 7, 30, 66, 107, 122, 137, 150, 181, 223, 242, 268, 309, 319, 425, 449, 469 ]
[ [ { "before_index": 6, "after_index": 20, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 27, "after_index": 34, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 37, "after_index": ...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "openstack/ec2-api/ec2api/tests/functional/api/test_routes.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def test_replace_route_table(self) : data = self.client.create_subnet (VpcId = self.vpc_id, CidrBlock = self.SUBNET_CIDR) subnet_id = data ['Subnet'] ['SubnetId'] res_clean_subnet = self.addResourceCleanUp (self.client.delete_subnet, SubnetId = subnet_id) self.get_subnet_waiter ().wait_available (su...
Yes
725
[ "#NEWLINE#", "def test_save_errors(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "floatingip", "=", "floating_ip", ".", "FloatingIP", "(", "context", "=", "self", ".", "context", ",", "id", "=", "123", ",", "host", "=", "'foo'", ")", "#NEWLINE#", "floatingip",...
true
73
[ "2", "15", "40", "65", "73", "7", "28", "48", "53", "59" ]
1
VARIABLE_MISUSE
[ 7, 28, 48, 53, 59 ]
[ [ { "before_index": 6, "after_index": 18, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 27, "after_index": 31, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 33, "after_index": ...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "openstack/nova/nova/tests/unit/objects/test_floating_ip.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def test_save_errors(self) : floatingip = floating_ip.FloatingIP (context = self.context, id = 123, host = 'foo') floatingip.obj_reset_changes () floating_ip.address = '1.2.3.4' self.assertRaises (exception.ObjectActionError, floatingip.save) floatingip.obj_reset_changes () floatingip.fixe...
Yes
726
[ "#NEWLINE#", "def safe_summary(", "self", ",", "encoded", ")", ":", "#NEWLINE#", "#INDENT#", "(", "algorithm", ",", "salt", ",", "data", ")", "=", "encoded", ".", "split", "(", "'$'", ",", "2", ")", "#NEWLINE#", "assert", "(", "algorithm", "==", "self", ...
true
45
[ "12", "54", "14", "45", "65", "4", "17", "2", "30", "10", "28", "32" ]
1
VARIABLE_MISUSE
[ 10, 28, 32 ]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 22, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 26, "after_index": 29...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "AppScale/appscale/AppServer/lib/django-1.4/django/contrib/auth/hashers.py", "license": "apache-2.0", "note": "license: github_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def safe_summary(self, encoded) : (algorithm, salt, data) = encoded.split ('$', 2) assert (algorithm == self.algorithm) return SortedDict ([(_ ('algorithm'), data), (_ ('salt'), salt), (_ ('hash'), mask_hash (data, show = 3))]) Is there a bug in the code above?
Yes
727
[ "#NEWLINE#", "def testCommitList(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "'Test commit list.'", "#NEWLINE#", "cl", "=", "self", ".", "_gh", "(", "'https://github.com/api/v2/xml/commits/list/mojombo/grit/master?page=1'", ",", "'data/commits.xml'", ")", ".", "commits", ...
true
98
[ "41", "54", "65", "76", "87", "109", "122", "134", "150", "163", "176", "189", "9", "37", "43", "2", "11", "29", "48", "59", "70", "81", "92", "98", "103", "114", "128", "144", "157", "170", "183" ]
1
VARIABLE_MISUSE
[ 41, 54, 65, 76, 87, 109, 122, 134, 150, 163, 176, 189 ]
[ [ { "before_index": 6, "after_index": 7, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 25, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 28, "after_index": 34...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "dustin/py-github/github/githubtest.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def testCommitList(self) : 'Test commit list.' cl = self._gh ('https://github.com/api/v2/xml/commits/list/mojombo/grit/master?page=1', 'data/commits.xml').commits.forBranch ('mojombo', 'grit') self.assertEquals (30, len (cl)) c = cl [0] self.assertEquals ('Regenerated gemspec for version 1.1.1'...
Yes
728
[ "#NEWLINE#", "def testShowIssue(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "'Show an individual issue.'", "#NEWLINE#", "i", "=", "self", ".", "_gh", "(", "'https://github.com/api/v2/xml/issues/show/dustin/py-github/1'", ",", "'data/issues.show.xml'", ")", ".", "issues", ...
true
48
[ "9", "37", "59", "70", "81", "92", "103", "114", "125", "2", "11", "31", "42", "48", "53", "64", "75", "86", "97", "108", "119" ]
1
VARIABLE_MISUSE
[ 9, 37, 59, 70, 81, 92, 103, 114, 125 ]
[ [ { "before_index": 6, "after_index": 7, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 25, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 30, "after_index": 36...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "dustin/py-github/github/githubtest.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def testShowIssue(self) : 'Show an individual issue.' i = self._gh ('https://github.com/api/v2/xml/issues/show/dustin/py-github/1', 'data/issues.show.xml').issues.show ('dustin', 'py-github', 1) self.assertEquals ('dustin', i.user) self.assertEquals ('2009-04-17T18:37:04-07:00', self.updated_at) ...
Yes
729
[ "#NEWLINE#", "def get(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "ctx", "=", "template", ".", "Context", "(", "{", "#NEWLINE#", "#INDENT#", "'session'", ":", "ctx", ".", "session", ",", "#NEWLINE#", "#UNINDENT#", "}", ")", "#NEWLINE#", "self", ".", "respo...
true
18
[ "7", "18", "39", "2", "27" ]
1
VARIABLE_MISUSE
[ 2, 27 ]
[ [ { "before_index": 6, "after_index": 12, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 26, "after_index": 34, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 12, "after_index": ...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "aht/suas/main.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def get(self) : ctx = template.Context ({ 'session' : ctx.session, }) self.response.out.write (HOME_VIEW.render (ctx)) Is there a bug in the code above?
Yes
730
[ "#NEWLINE#", "@", "then", "(", "'the output will contain the text \"{expected}\"'", ")", "#NEWLINE#", "def output_will_contain(", "context", ",", "expected", ")", ":", "#NEWLINE#", "#INDENT#", "expected", "=", "expected", ".", "format", "(", "**", "context", ".", "int...
false
0
[ "10", "15", "17", "29", "46", "expected", "8", "22", "31", "48", "context" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 14, "after_index": 20, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 27, "after_index": 3...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "coddingtonbear/jirafs/tests/steps/basic.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
@ then ('the output will contain the text "{expected}"') def output_will_contain(context, expected) : expected = expected.format (** context.integration_testing) assert (expected in context.executions [0] ['stdout']), ('%s not in %s' % (expected, context.executions [0] ['stdout'])) Is there a bug in the co...
No
731
[ "#NEWLINE#", "def __init__(", "self", ",", "spdom", ")", ":", "#NEWLINE#", "#INDENT#", "self", ".", "minx", "=", "spdom", ".", "westbc", "#NEWLINE#", "self", ".", "miny", "=", "spdom", ".", "southbc", "#NEWLINE#", "self", ".", "maxx", "=", "spdom", ".", ...
false
0
[ "4", "13", "21", "29", "37", "spdom", "2", "9", "17", "25", "33", "self" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 14, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 16, "after_index": 22...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "geopython/OWSLib/owslib/fgdc.py", "license": "bsd-3-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def __init__(self, spdom) : self.minx = spdom.westbc self.miny = spdom.southbc self.maxx = spdom.eastbc self.maxy = spdom.northbc Is there a bug in the code above?
No
732
[ "#NEWLINE#", "def test_tracked_client_not_tracked_server(", "not_tracked_server", ")", ":", "#NEWLINE#", "#INDENT#", "with", "client", "(", "port", "=", "(", "PORT", "+", "3", ")", ")", "as", "c", ":", "#NEWLINE#", "#INDENT#", "assert", "(", "c", ".", "_upgraded...
false
0
[ "45", "60", "69", "80", "a", "2", "not_tracked_server", "19", "25", "32", "38", "47", "c" ]
0
NONE
[]
[ [ { "before_index": 18, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 18, "after_index": 19, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 23, "after_index": ...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "eleme/thriftpy/tests/test_tracking.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def test_tracked_client_not_tracked_server(not_tracked_server) : with client (port = (PORT + 3)) as c : assert (c._upgraded is False) c.ping () c.hello ('cat') a = c.get_phonenumbers ('hello', 54) assert (len (a) == 2) assert ((a [0].number == 'sdaf') and (a [1...
No
733
[ "#NEWLINE#", "def render(", "self", ",", "template_name", ",", "**kwargs", ")", ":", "#NEWLINE#", "#INDENT#", "kwargs", ".", "update", "(", "self", ".", "get_template_namespace", "(", ")", ")", "#NEWLINE#", "self", ".", "write", "(", "self", ".", "render_templ...
false
0
[ "2", "15", "22", "26", "self", "4", "30", "template_name", "11", "33", "kwargs" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 14, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 21, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "dropbox/trapperkeeper/trapdoor/utils.py", "license": "apache-2.0", "note": "license: manual_eval" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def render(self, template_name, **kwargs) : kwargs.update (self.get_template_namespace ()) self.write (self.render_template (template_name, ** kwargs)) Is there a bug in the code above?
No
734
[ "#NEWLINE#", "def __init__(", "self", ",", "dn", ",", "fn", ",", "inv", ")", ":", "#NEWLINE#", "#INDENT#", "self", ".", "invention", "=", "inv", "#NEWLINE#", "self", ".", "file", "=", "self", ".", "create_TeX_file", "(", "dn", ",", "fn", ")", "#NEWLINE#"...
false
0
[ "2", "13", "19", "23", "32", "36", "42", "46", "52", "56", "62", "66", "72", "76", "82", "86", "self", "6", "29", "fn", "4", "27", "dn", "8", "17", "inv" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 12, "after_index": 17, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 18, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "antiboredom/patent-generator/latex_pdf.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def __init__(self, dn, fn, inv) : self.invention = inv self.file = self.create_TeX_file (dn, fn) self.title = self.create_title () self.abstract = self.create_abstract () self.illustrations = self.create_illustrations () self.description = self.create_description () self.claims = self...
No
735
[ "#NEWLINE#", "def test_spaces_in_names(", ")", ":", "#NEWLINE#", "#INDENT#", "'Test that spaces in filenames are errors.'", "#NEWLINE#", "package", "=", "MockXPI", "(", "{", "#NEWLINE#", "#INDENT#", "'foo/bar/foo.bar '", ":", "None", ",", "#NEWLINE#", "'foo/bar/ foo.bar'", ...
false
0
[ "8", "41", "package", "29", "39", "45", "55", "err" ]
0
NONE
[]
[ [ { "before_index": 5, "after_index": 6, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 7, "after_index": 11, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 28, "after_index": 32...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "mozilla/app-validator/tests/test_packagelayout.py", "license": "bsd-3-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def test_spaces_in_names() : 'Test that spaces in filenames are errors.' package = MockXPI ({ 'foo/bar/foo.bar ' : None, 'foo/bar/ foo.bar' : None, }) err = ErrorBundle () packagelayout.test_blacklisted_files (err, package) assert err.failed () assert (len (err.errors) =...
No
736
[ "#NEWLINE#", "def test_log_with_authors(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "vcs", "=", "self", ".", "get_vcs", "(", ")", "#NEWLINE#", "self", ".", "_set_author", "(", "'Another Committer <ac@d.not.zm.exist>'", ")", "#NEWLINE#", "check_call", "(", "(", "'c...
false
0
[ "52", "67", "73", "91", "101", "115", "133", "143", "157", "183", "revisions", "7", "40", "46", "56", "77", "119", "161", "167", "vcs", "2", "9", "15", "28", "97", "139", "self" ]
0
NONE
[]
[ [ { "before_index": 6, "after_index": 12, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 14, "after_index": 18, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 21, "after_index": ...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "dropbox/changes/tests/changes/vcs/test_hg.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def test_log_with_authors(self) : vcs = self.get_vcs () self._set_author ('Another Committer <ac@d.not.zm.exist>') check_call (('cd %s && touch BAZ && hg add BAZ && hg commit -m "bazzy"' % (self.remote_path,)), shell = True) vcs.clone () vcs.update () revisions = list (vcs.log ()) ass...
No
737
[ "#NEWLINE#", "@", "classmethod", "#NEWLINE#", "def upload_app(", "cls", ",", "options", ")", ":", "#NEWLINE#", "#INDENT#", "'Uploads the given App Engine application into AppScale.\\n\\n Args:\\n options: A Namespace that has fields for each parameter that can be\\n passed in ...
false
0
[ "152", "160", "169", "176", "config_error", "601", "610", "apps_result", "554", "649", "663", "sleep_time", "287", "348", "388", "397", "470", "516", "525", "586", "acc", "43", "81", "110", "714", "created_dir", "358", "372", "password", "564", "608", "6...
0
NONE
[]
[ [ { "before_index": 1, "after_index": 6, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 11, "after_index": 12, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 14, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "AppScale/appscale-tools/lib/appscale_tools.py", "license": "apache-2.0", "note": "license: github_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
@ classmethod def upload_app(cls, options) : 'Uploads the given App Engine application into AppScale. Args: options: A Namespace that has fields for each parameter that can be passed in via the command-line interface. Returns: A tuple containing the host and port where the application...
No
738
[ "#NEWLINE#", "def main(", "argv", "=", "None", ")", ":", "#NEWLINE#", "#INDENT#", "'script main.\\n\\n parses command line options in sys.argv, unless *argv* is given.\\n '", "#NEWLINE#", "if", "(", "not", "argv", ")", ":", "#NEWLINE#", "#INDENT#", "argv", "=", "sys",...
false
0
[ "621", "702", "1284", "1347", "outfile1", "1338", "1355", "1359", "1367", "1384", "1388", "1396", "entry", "336", "366", "382", "388", "394", "407", "434", "450", "462", "473", "495", "511", "547", "568", "583", "592", "598", "607", "623", "633", "65...
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 11, "after_index": 13,...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "CGATOxford/cgat/scripts/fastq2fastq.py", "license": "bsd-3-clause", "note": "license: manual_eval" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def main(argv = None) : 'script main. parses command line options in sys.argv, unless *argv* is given. ' if (not argv) : argv = sys.argv parser = E.OptionParser (version = '%prog version: $Id$', usage = globals () ['__doc__']) parser.add_option ('-m', '--method', dest = 'method', type ...
No
739
[ "#NEWLINE#", "def authenticate_user_cookie(", "nick", ",", "token", ")", ":", "#NEWLINE#", "#INDENT#", "user", "=", "api", ".", "actor_get_safe", "(", "api", ".", "ROOT", ",", "nick", ")", "#NEWLINE#", "if", "(", "not", "user", ")", ":", "#NEWLINE#", "#INDEN...
false
0
[ "4", "50", "token", "2", "19", "48", "nick", "9", "25", "34", "46", "67", "81", "user", "42", "56", "71", "cached_token" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 18, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 22, "after_index": 24...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "CollabQ/CollabQ/common/user.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def authenticate_user_cookie(nick, token) : user = api.actor_get_safe (api.ROOT, nick) if (not user) : return None user.access_level = api.DELETE_ACCESS cached_token = lookup_user_auth_token (user.nick, token) if (not cached_token) : return None if (user.password != cached_token)...
No
740
[ "#NEWLINE#", "def write_exports(", "exports", ",", "stream", ")", ":", "#NEWLINE#", "#INDENT#", "if", "(", "sys", ".", "version_info", "[", "0", "]", ">=", "3", ")", ":", "#NEWLINE#", "#INDENT#", "stream", "=", "codecs", ".", "getwriter", "(", "'utf-8'", "...
false
0
[ "48", "69", "v", "36", "59", "143", "158", "cp", "67", "79", "90", "105", "109", "117", "135", "149", "entry", "46", "63", "147", "k", "88", "99", "123", "129", "153", "s", "4", "23", "32", "162", "stream", "2", "51", "exports" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 9, "after_index": 17, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 35, "after_index": 41...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "anzev/hedwig/build/pip/pip/_vendor/distlib/util.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def write_exports(exports, stream) : if (sys.version_info [0] >= 3) : stream = codecs.getwriter ('utf-8') (stream) cp = configparser.ConfigParser () for (k, v) in exports.items () : cp.add_section (k) for entry in v.values () : if (entry.suffix is None) : ...
No
741
[ "#NEWLINE#", "def iglob(", "path_glob", ")", ":", "#NEWLINE#", "#INDENT#", "'Extended globbing function that supports ** and {opt1,opt2,opt3}.'", "#NEWLINE#", "if", "_CHECK_RECURSIVE_GLOB", ".", "search", "(", "path_glob", ")", ":", "#NEWLINE#", "#INDENT#", "msg", "=", "'in...
false
0
[ "2", "14", "29", "39", "54", "62", "path_glob", "19", "27", "44", "52", "msg" ]
0
NONE
[]
[ [ { "before_index": 6, "after_index": 7, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 9, "after_index": 13, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 34, "after_index": 38...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "anzev/hedwig/build/pip/pip/_vendor/distlib/util.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def iglob(path_glob) : 'Extended globbing function that supports ** and {opt1,opt2,opt3}.' if _CHECK_RECURSIVE_GLOB.search (path_glob) : msg = 'invalid glob %r: recursive glob "**" must be used alone' raise ValueError ((msg % path_glob)) if _CHECK_MISMATCH_SET.search (path_glob) : ...
No
742
[ "#NEWLINE#", "def get_dependency(", "self", ",", "worker_ctx", ")", ":", "#NEWLINE#", "#INDENT#", "def get_context_value(", "key", ")", ":", "#NEWLINE#", "#INDENT#", "return", "worker_ctx", ".", "data", ".", "get", "(", "key", ")", "#NEWLINE#", "#UNINDENT#", "retu...
false
0
[ "27", "get_context_value", "2", "self", "4", "16", "worker_ctx" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 26, "after_index": 27, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 15, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "onefinestay/nameko/test/standalone/test_rpc_proxy.py", "license": "apache-2.0", "note": "license: github_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def get_dependency(self, worker_ctx) : def get_context_value(key) : return worker_ctx.data.get (key) return get_context_value Is there a bug in the code above?
No
743
[ "#NEWLINE#", "def start_serving(", "self", ",", "delegate", ")", ":", "#NEWLINE#", "#INDENT#", "'Starts serving requests on this connection.\\n\\n :arg delegate: a `.HTTPServerConnectionDelegate`\\n '", "#NEWLINE#", "assert", "isinstance", "(", "delegate", ",", "httputi...
false
0
[ "4", "14", "29", "delegate", "2", "21", "25", "32", "40", "self" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 11, "after_index": 15,...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "RobotWebTools/rosbridge_suite/rosbridge_server/src/tornado/http1connection.py", "license": "bsd-3-clause", "note": "license: manual_eval" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def start_serving(self, delegate) : 'Starts serving requests on this connection. :arg delegate: a `.HTTPServerConnectionDelegate` ' assert isinstance (delegate, httputil.HTTPServerConnectionDelegate) self._serving_future = self._server_request_loop (delegate) self.stream.io_loop.add...
No
744
[ "#NEWLINE#", "def encode(", "self", ",", "o", ")", ":", "#NEWLINE#", "#INDENT#", "'\\n Return a JSON string representation of a Python data structure.\\n\\n >>> JSONEncoder().encode({\"foo\": [\"bar\", \"baz\"]})\\n \\'{\"foo\":[\"bar\", \"baz\"]}\\'\\n '", "#NEWLINE#...
false
0
[ "4", "19", "o", "11", "28", "chunks", "2", "15", "self" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 14,...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "jpic/playlistnow.fm/opensocial/simplejson/encoder.py", "license": "apache-2.0", "note": "license: manual_eval" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def encode(self, o) : ' Return a JSON string representation of a Python data structure. >>> JSONEncoder().encode({"foo": ["bar", "baz"]}) \'{"foo":["bar", "baz"]}\' ' chunks = list (self.iterencode (o)) return ''.join (chunks) Is there a bug in the code above?
No
745
[ "#NEWLINE#", "def BuildMultilayer(", "src_filenames", ")", ":", "#NEWLINE#", "#INDENT#", "assert", "(", "(", "1", "<=", "len", "(", "src_filenames", ")", ")", "and", "(", "len", "(", "src_filenames", ")", "<=", "4", ")", ")", "#NEWLINE#", "imgs", "=", "[",...
false
0
[ "82", "130", "164", "171", "186", "alpha_bands", "152", "i", "101", "R", "43", "69", "146", "expected_size", "52", "78", "159", "184", "image_mode", "28", "45", "59", "90", "imgs", "2", "14", "21", "40", "src_filenames", "116", "134", "new_img", "103",...
0
NONE
[]
[ [ { "before_index": 7, "after_index": 17, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 27, "after_index": 30, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 42, "after_index": ...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "kleientertainment/ds_mod_tools/pkg/unix/Python27/Lib/site-packages/klei/texture.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def BuildMultilayer(src_filenames) : assert ((1 <= len (src_filenames)) and (len (src_filenames) <= 4)) imgs = [Image.open (filename) for filename in src_filenames] expected_size = imgs [0].size image_mode = 'RGBA' for img in imgs : assert (img.size == expected_size) assert (i...
No
746
[ "#NEWLINE#", "def test_validate_invalid_status(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "expected", "=", "'Result status has to be OK, ERROR or WARN, not InvalidStatus'", "#NEWLINE#", "result", "=", "server_plugins", ".", "Result", "(", ")", "#NEWLINE#", "result", ".", ...
false
0
[ "7", "64", "expected", "2", "27", "self", "11", "19", "21", "32", "34", "55", "result", "51", "66", "exc_info" ]
0
NONE
[]
[ [ { "before_index": 6, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 16, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 18, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "gooddata/smoker/tests/server/test_plugins.py", "license": "bsd-3-clause", "note": "license: manual_eval" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def test_validate_invalid_status(self) : expected = 'Result status has to be OK, ERROR or WARN, not InvalidStatus' result = server_plugins.Result () result.result = copy.deepcopy (self.result_to_validate) result.result ['status'] = 'InvalidStatus' with pytest.raises (smoker_exceptions.Validatio...
No
747
[ "#NEWLINE#", "def get_link_url(", "self", ",", "datum", "=", "None", ")", ":", "#NEWLINE#", "#INDENT#", "container_name", "=", "http", ".", "urlquote", "(", "datum", ".", "name", ")", "#NEWLINE#", "args", "=", "(", "wrap_delimiter", "(", "container_name", ")",...
false
0
[ "22", "39", "41", "args", "2", "35", "self", "4", "17", "datum", "11", "27", "container_name" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 16, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 21, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "CiscoSystems/avos/openstack_dashboard/dashboards/project/containers/tables.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def get_link_url(self, datum = None) : container_name = http.urlquote (datum.name) args = (wrap_delimiter (container_name),) return reverse (self.url, args = args) Is there a bug in the code above?
No
748
[ "#NEWLINE#", "def arg_cleanup_code(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "arg_strings", "=", "[", "]", "#NEWLINE#", "have_cleanup", "=", "filter", "(", "(", "lambda", "x", ":", "x", ".", "cleanup_code", "(", ")", ")", ",", "self", ".", "arg_specs", ...
false
0
[ "12", "35", "have_cleanup", "2", "27", "self", "33", "44", "59", "arg", "39", "51", "55", "68", "76", "80", "90", "code", "7", "72", "86", "arg_strings" ]
0
NONE
[]
[ [ { "before_index": 6, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 11, "after_index": 26, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 32, "after_index": 3...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "scipy/scipy/scipy/weave/ext_tools.py", "license": "bsd-3-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def arg_cleanup_code(self) : arg_strings = [] have_cleanup = filter ((lambda x : x.cleanup_code ()), self.arg_specs) for arg in have_cleanup : code = ('if(%s) ' % arg.init_flag ()) code += '{ ' code += indent (arg.cleanup_code (), 4) code += '} ' arg_strings.a...
No
749
[ "#NEWLINE#", "def set_compiler(", "self", ",", "compiler", ")", ":", "#NEWLINE#", "#INDENT#", "self", ".", "compiler", "=", "compiler", "#NEWLINE#", "for", "arg", "in", "self", ".", "arg_specs", ":", "#NEWLINE#", "#INDENT#", "arg", ".", "set_compiler", "(", "c...
false
0
[ "2", "9", "18", "self", "16", "24", "arg", "4", "11", "13", "28", "compiler" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 13, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 15, "after_index": 16...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "scipy/scipy/scipy/weave/ext_tools.py", "license": "bsd-3-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def set_compiler(self, compiler) : self.compiler = compiler for arg in self.arg_specs : arg.set_compiler (compiler) Is there a bug in the code above?
No
750
[ "#NEWLINE#", "def kl_est_sample(", "from_gen", ",", "of_gen", ",", "target_cells", ",", "constraints", ")", ":", "#NEWLINE#", "#INDENT#", "'Estimate Kullback-Liebler divergence of `of_gen` from `from_gen`.\\n\\n Specifically, let P be the distribution over the given target\\n cells i...
false
0
[ "28", "63", "74", "targeted_data", "2", "19", "59", "from_gen", "68", "83", "of_assessment", "36", "46", "x", "8", "25", "65", "76", "constraints", "32", "41", "i", "6", "23", "51", "target_cells", "4", "70", "of_gen", "16", "53", "data", "34", "43",...
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 12, "after_index": 13, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 14, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "probcomp/bayeslite/src/geweke_testing.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def kl_est_sample(from_gen, of_gen, target_cells, constraints) : 'Estimate Kullback-Liebler divergence of `of_gen` from `from_gen`. Specifically, let P be the distribution over the given target cells induced by the generator `from_gen` conditioned on the constraints, and let Q be same induced by the `...
No
751
[ "#NEWLINE#", "def migrate_filenodes(", ")", ":", "#NEWLINE#", "#INDENT#", "for", "node_settings", "in", "paginated", "(", "osfstorage_model", ".", "OsfStorageNodeSettings", ")", ":", "#NEWLINE#", "#INDENT#", "if", "(", "node_settings", ".", "owner", "is", "None", ")...
false
0
[ "7", "20", "37", "54", "80", "197", "264", "node_settings", "271", "278", "290", "298", "304", "x", "60", "255", "273", "listing", "102", "108", "134", "159", "191", "193", "versions", "179", "245", "259", "new_node", "66", "96", "106", "113", "119",...
0
NONE
[]
[ [ { "before_index": 6, "after_index": 7, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 6, "after_index": 10, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 9,...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "CenterForOpenScience/osf.io/scripts/osfstorage/migrate_to_generic.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def migrate_filenodes() : for node_settings in paginated (osfstorage_model.OsfStorageNodeSettings) : if (node_settings.owner is None) : logger.warning ('OsfStorageNodeSettings {} has no parent; skipping'.format (node_settings._id)) continue logger.info ('Migrating files for {!r}...
No
752
[ "#NEWLINE#", "def recent_commits(", "request", ",", "slug", ")", ":", "#NEWLINE#", "#INDENT#", "repo", "=", "get_object_or_404", "(", "CodeRepository", ",", "slug", "=", "slug", ")", "#NEWLINE#", "commits", "=", "repo", ".", "get_recent_commits", "(", ")", "#NEW...
false
0
[ "4", "15", "17", "slug", "2", "63", "request", "20", "53", "commits", "9", "22", "35", "48", "repo" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 14, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 19, "after_index": 25...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "alex/django-vcs/django_vcs/views.py", "license": "bsd-3-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def recent_commits(request, slug) : repo = get_object_or_404 (CodeRepository, slug = slug) commits = repo.get_recent_commits () return render_to_response ([('django_vcs/%s/recent_commits.html' % repo.name), 'django_vcs/recent_commits.html'], { 'repo' : repo, 'commits' : commits, }, con...
No
753
[ "#NEWLINE#", "@", "testing", ".", "crashes", "(", "'sqlite'", ",", "':memory: connection not suitable here'", ")", "#NEWLINE#", "def test_orm_many_engines(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "metadata", "=", "MetaData", "(", "self", ".", "engine", ")", "#N...
false
0
[ "153", "459", "m2", "446", "go", "17", "32", "66", "106", "450", "metadata", "12", "21", "self", "60", "137", "159", "table2", "26", "118", "172", "table1", "112", "457", "m1", "166", "461", "m3" ]
0
NONE
[]
[ [ { "before_index": 16, "after_index": 20, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 25, "after_index": 31, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 59, "after_index":...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "zzzeek/sqlalchemy/test/aaa_profiling/test_memusage.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
@ testing.crashes ('sqlite', ':memory: connection not suitable here') def test_orm_many_engines(self) : metadata = MetaData (self.engine) table1 = Table ('mytable', metadata, Column ('col1', Integer, primary_key = True, test_needs_autoincrement = True), Column ('col2', String (30))) table2 = Table ('myt...
No
754
[ "#NEWLINE#", "def undeploy_api_gateway(", "self", ",", "project_name", ")", ":", "#NEWLINE#", "#INDENT#", "'\\n Delete a deployed REST API Gateway.\\n\\n Returns\\n\\n '", "#NEWLINE#", "print", "(", "'Deleting API Gateway..'", ")", "#NEWLINE#", "client", "=", ...
false
0
[ "39", "50", "71", "api", "2", "18", "self", "63", "response", "27", "41", "all_apis", "16", "22", "29", "65", "client", "4", "55", "project_name" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 12,...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "Miserlou/Zappa/zappa/zappa.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def undeploy_api_gateway(self, project_name) : ' Delete a deployed REST API Gateway. Returns ' print ('Deleting API Gateway..') client = self.boto_session.client ('apigateway') all_apis = client.get_rest_apis (limit = 500) for api in all_apis ['items'] : if (a...
No
755
[ "#NEWLINE#", "def network_get_by_cidr(", "context", ",", "cidr", ")", ":", "#NEWLINE#", "#INDENT#", "'Get a network by cidr or raise if it does not exist.'", "#NEWLINE#", "return", "IMPL", ".", "network_get_by_cidr", "(", "context", ",", "cidr", ")" ]
false
0
[ "2", "16", "context", "4", "18", "cidr" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 11, "after_index": 17,...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "BU-NU-CLOUD-SP16/Trusted-Platform-Module-nova/nova/db/api.py", "license": "apache-2.0", "note": "license: github_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def network_get_by_cidr(context, cidr) : 'Get a network by cidr or raise if it does not exist.' return IMPL.network_get_by_cidr (context, cidr) Is there a bug in the code above?
No
756
[ "#NEWLINE#", "def quota_usage_get_all_by_project_and_user(", "context", ",", "project_id", ",", "user_id", ")", ":", "#NEWLINE#", "#INDENT#", "'Retrieve all usage associated with a given resource.'", "#NEWLINE#", "return", "IMPL", ".", "quota_usage_get_all_by_project_and_user", "("...
false
0
[ "2", "18", "context", "4", "20", "project_id", "6", "22", "user_id" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 11, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 13, "after_index": 1...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "BU-NU-CLOUD-SP16/Trusted-Platform-Module-nova/nova/db/api.py", "license": "apache-2.0", "note": "license: github_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def quota_usage_get_all_by_project_and_user(context, project_id, user_id) : 'Retrieve all usage associated with a given resource.' return IMPL.quota_usage_get_all_by_project_and_user (context, project_id, user_id) Is there a bug in the code above?
No
757
[ "#NEWLINE#", "def console_get_by_pool_instance(", "context", ",", "pool_id", ",", "instance_uuid", ")", ":", "#NEWLINE#", "#INDENT#", "'Get console entry for a given instance and pool.'", "#NEWLINE#", "return", "IMPL", ".", "console_get_by_pool_instance", "(", "context", ",", ...
false
0
[ "6", "22", "instance_uuid", "2", "18", "context", "4", "20", "pool_id" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 11, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 13, "after_index": 1...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "BU-NU-CLOUD-SP16/Trusted-Platform-Module-nova/nova/db/api.py", "license": "apache-2.0", "note": "license: github_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def console_get_by_pool_instance(context, pool_id, instance_uuid) : 'Get console entry for a given instance and pool.' return IMPL.console_get_by_pool_instance (context, pool_id, instance_uuid) Is there a bug in the code above?
No
758
[ "#NEWLINE#", "def console_get(", "context", ",", "console_id", ",", "instance_uuid", "=", "None", ")", ":", "#NEWLINE#", "#INDENT#", "'Get a specific console (possibly on a given instance).'", "#NEWLINE#", "return", "IMPL", ".", "console_get", "(", "context", ",", "consol...
false
0
[ "6", "24", "instance_uuid", "2", "20", "context", "4", "22", "console_id" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 12, "after_index": 13, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 15, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "BU-NU-CLOUD-SP16/Trusted-Platform-Module-nova/nova/db/api.py", "license": "apache-2.0", "note": "license: github_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def console_get(context, console_id, instance_uuid = None) : 'Get a specific console (possibly on a given instance).' return IMPL.console_get (context, console_id, instance_uuid) Is there a bug in the code above?
No
759
[ "#NEWLINE#", "def flavor_access_get_by_flavor_id(", "context", ",", "flavor_id", ")", ":", "#NEWLINE#", "#INDENT#", "'Get flavor access by flavor id.'", "#NEWLINE#", "return", "IMPL", ".", "flavor_access_get_by_flavor_id", "(", "context", ",", "flavor_id", ")" ]
false
0
[ "2", "16", "context", "4", "18", "flavor_id" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 11, "after_index": 17,...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "BU-NU-CLOUD-SP16/Trusted-Platform-Module-nova/nova/db/api.py", "license": "apache-2.0", "note": "license: github_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def flavor_access_get_by_flavor_id(context, flavor_id) : 'Get flavor access by flavor id.' return IMPL.flavor_access_get_by_flavor_id (context, flavor_id) Is there a bug in the code above?
No
760
[ "#NEWLINE#", "def flavor_access_add(", "context", ",", "flavor_id", ",", "project_id", ")", ":", "#NEWLINE#", "#INDENT#", "'Add flavor access for project.'", "#NEWLINE#", "return", "IMPL", ".", "flavor_access_add", "(", "context", ",", "flavor_id", ",", "project_id", ")...
false
0
[ "2", "18", "context", "6", "22", "project_id", "4", "20", "flavor_id" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 11, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 13, "after_index": 1...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "BU-NU-CLOUD-SP16/Trusted-Platform-Module-nova/nova/db/api.py", "license": "apache-2.0", "note": "license: github_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def flavor_access_add(context, flavor_id, project_id) : 'Add flavor access for project.' return IMPL.flavor_access_add (context, flavor_id, project_id) Is there a bug in the code above?
No
761
[ "#NEWLINE#", "def s3_image_create(", "context", ",", "image_uuid", ")", ":", "#NEWLINE#", "#INDENT#", "'Create local s3 image represented by provided uuid.'", "#NEWLINE#", "return", "IMPL", ".", "s3_image_create", "(", "context", ",", "image_uuid", ")" ]
false
0
[ "2", "16", "context", "4", "18", "image_uuid" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 11, "after_index": 17,...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "BU-NU-CLOUD-SP16/Trusted-Platform-Module-nova/nova/db/api.py", "license": "apache-2.0", "note": "license: github_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def s3_image_create(context, image_uuid) : 'Create local s3 image represented by provided uuid.' return IMPL.s3_image_create (context, image_uuid) Is there a bug in the code above?
No
762
[ "#NEWLINE#", "def set_dimension(", "self", ",", "name", ",", "length", ")", ":", "#NEWLINE#", "#INDENT#", "self", ".", "ds", ".", "createDimension", "(", "name", ",", "size", "=", "length", ")" ]
false
0
[ "4", "17", "name", "6", "21", "length", "2", "11", "self" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 18, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 18, "after_index": 1...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "pydata/xarray/xarray/backends/netCDF4_.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def set_dimension(self, name, length) : self.ds.createDimension (name, size = length) Is there a bug in the code above?
No
763
[ "#NEWLINE#", "def close(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "ds", "=", "self", ".", "ds", "#NEWLINE#", "while", "(", "ds", ".", "parent", "is not", "None", ")", ":", "#NEWLINE#", "#INDENT#", "ds", "=", "ds", ".", "parent", "#NEWLINE#", "#UNINDENT...
false
0
[ "7", "11", "15", "24", "26", "31", "ds", "2", "9", "self" ]
0
NONE
[]
[ [ { "before_index": 6, "after_index": 10, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 13, "after_index": 18, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 30, "after_index": ...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "pydata/xarray/xarray/backends/netCDF4_.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def close(self) : ds = self.ds while (ds.parent is not None) : ds = ds.parent ds.close () Is there a bug in the code above?
No
764
[ "#NEWLINE#", "def register_connection(", "id", ",", "conn", ")", ":", "#NEWLINE#", "#INDENT#", "if", "(", "id", "in", "connections", ")", ":", "#NEWLINE#", "#INDENT#", "connections", "[", "id", "]", ".", "close", "(", ")", "#NEWLINE#", "#UNINDENT#", "conn", ...
false
0
[ "4", "28", "36", "41", "conn", "2", "11", "20", "32", "id" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 9, "after_index": 12, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 27, "after_index": 32...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "zulip/zulip/zerver/lib/socket.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def register_connection(id, conn) : if (id in connections) : connections [id].close () conn.client_id = id connections [conn.client_id] = conn Is there a bug in the code above?
No
765
[ "#NEWLINE#", "def ndl(", "data", ")", ":", "#NEWLINE#", "#INDENT#", "vec", "=", "DictVectorizer", "(", "dtype", "=", "float", ",", "sparse", "=", "False", ")", "#NEWLINE#", "D", "=", "(", "vec", ".", "fit_transform", "(", "[", "explode", "(", "c", ")", ...
false
0
[ "116", "267", "C1", "78", "91", "101", "row", "205", "226", "239", "i", "177", "232", "247", "O", "53", "71", "73", "n", "7", "23", "57", "186", "292", "vec", "244", "272", "O1", "20", "80", "224", "D", "144", "211", "237", "X", "85", "98", ...
0
NONE
[]
[ [ { "before_index": 6, "after_index": 14, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 19, "after_index": 40, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 52, "after_index": ...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "rmalouf/learning/ndl.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def ndl(data) : vec = DictVectorizer (dtype = float, sparse = False) D = (vec.fit_transform ([explode (c) for c in data.Cues]) * data.Frequency [:, np.newaxis]) n = len (vec.get_feature_names ()) C = np.zeros ((n, n)) for row in D : for nz in np.nonzero (row) : C [nz] += r...
No
766
[ "#NEWLINE#", "def _format_security_group(", "self", ",", "context", ",", "group", ")", ":", "#NEWLINE#", "#INDENT#", "security_group", "=", "{", "#NEWLINE#", "#INDENT#", "#NEWLINE#", "#UNINDENT#", "}", "#NEWLINE#", "security_group", "[", "'id'", "]", "=", "group", ...
false
0
[ "69", "86", "rule", "6", "25", "35", "45", "55", "71", "group", "2", "80", "self", "4", "84", "context", "78", "90", "100", "formatted_rule", "11", "20", "30", "40", "50", "60", "94", "106", "security_group" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 13, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 19, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "BU-NU-CLOUD-SP16/Trusted-Platform-Module-nova/nova/api/openstack/compute/legacy_v2/contrib/security_groups.py", "license": "apache-2.0", "note": "license: github_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def _format_security_group(self, context, group) : security_group = { } security_group ['id'] = group ['id'] security_group ['description'] = group ['description'] security_group ['name'] = group ['name'] security_group ['tenant_id'] = group ['project_id'] security_group ['rules'...
No
767
[ "#NEWLINE#", "def __eq__(", "self", ",", "other", ")", ":", "#NEWLINE#", "#INDENT#", "return", "(", "(", "type", "(", "other", ")", "is", "type", "(", "self", ")", ")", "and", "(", "self", ".", "_size", "==", "other", ".", "_size", ")", ")" ]
false
0
[ "2", "19", "24", "self", "4", "14", "28", "other" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 9, "after_index": 22, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 16, "after_index": 13...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "programa-stic/barf-project/barf/barf/core/reil/reil.py", "license": "bsd-2-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def __eq__(self, other) : return ((type (other) is type (self)) and (self._size == other._size)) Is there a bug in the code above?
No
768
[ "#NEWLINE#", "def gen_add(", "self", ",", "src1", ",", "src2", ",", "dst", ")", ":", "#NEWLINE#", "#INDENT#", "'Return an ADD instruction.\\n '", "#NEWLINE#", "return", "self", ".", "build", "(", "ReilMnemonic", ".", "ADD", ",", "src1", ",", "src2", ",", ...
false
0
[ "2", "16", "self", "4", "24", "src1", "6", "26", "src2", "8", "28", "dst" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 12, "after_index": 13, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 15, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "programa-stic/barf-project/barf/barf/core/reil/reil.py", "license": "bsd-2-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def gen_add(self, src1, src2, dst) : 'Return an ADD instruction. ' return self.build (ReilMnemonic.ADD, src1, src2, dst) Is there a bug in the code above?
No
769
[ "#NEWLINE#", "def process_drop_sentry_privilege(", "self", ",", "seqid", ",", "iprot", ",", "oprot", ")", ":", "#NEWLINE#", "#INDENT#", "args", "=", "drop_sentry_privilege_args", "(", ")", "#NEWLINE#", "args", ".", "read", "(", "iprot", ")", "#NEWLINE#", "iprot", ...
false
0
[ "32", "42", "100", "123", "result", "13", "19", "52", "args", "6", "23", "26", "iprot", "4", "120", "seqid", "2", "46", "self", "57", "87", "118", "msg_type", "8", "112", "127", "130", "136", "oprot", "83", "97", "ex" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 12, "after_index": 16, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 18, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "cloudera/hue/desktop/libs/libsentry/gen-py/sentry_policy_service/SentryPolicyService.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def process_drop_sentry_privilege(self, seqid, iprot, oprot) : args = drop_sentry_privilege_args () args.read (iprot) iprot.readMessageEnd () result = drop_sentry_privilege_result () try : result.success = self._handler.drop_sentry_privilege (args.request) msg_type = TMessageT...
No
770
[ "#NEWLINE#", "def __repr__(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "L", "=", "[", "(", "'%s=%r'", "%", "(", "key", ",", "value", ")", ")", "for", "(", "key", ",", "value", ")", "in", "self", ".", "__dict__", ".", "iteritems", "(", ")", "]", "...
false
0
[ "2", "26", "40", "self", "7", "50", "L", "16", "23", "value", "14", "21", "key" ]
0
NONE
[]
[ [ { "before_index": 6, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 35, "after_index": 38, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 9, "after_index": 12...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "cloudera/hue/desktop/libs/libsentry/gen-py/sentry_policy_service/SentryPolicyService.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def __repr__(self) : L = [('%s=%r' % (key, value)) for (key, value) in self.__dict__.iteritems ()] return ('%s(%s)' % (self.__class__.__name__, ', '.join (L))) Is there a bug in the code above?
No
771
[ "#NEWLINE#", "def consume(", "self", ",", "t", ",", "src", ",", "state", ")", ":", "#NEWLINE#", "#INDENT#", "code", "=", "self", ".", "language", "(", ")", ".", "comment", "(", "self", ".", "shortStr", "(", ")", ")", "#NEWLINE#", "assignment_template", "...
false
0
[ "8", "144", "151", "186", "state", "89", "dst_set_func", "126", "148", "expr_inits", "170", "191", "innercode", "39", "dst_name", "75", "97", "dst_fieldnum", "2", "15", "23", "41", "49", "82", "91", "116", "129", "172", "180", "184", "self", "47", "dst...
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 12, "after_index": 22, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 29, "after_index": 3...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "uwescience/raco/raco/backends/cpp/cppcommon.py", "license": "bsd-3-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def consume(self, t, src, state) : code = self.language ().comment (self.shortStr ()) assignment_template = _cgenv.get_template ('assignment.cpp') dst_name = self.newtuple.name dst_type_name = self.newtuple.getTupleTypename () code += _cgenv.get_template ('tuple_declaration.cpp').render (locals...
No
772
[ "#NEWLINE#", "def consume(", "self", ",", "t", ",", "src", ",", "state", ")", ":", "#NEWLINE#", "#INDENT#", "code", "=", "''", "#NEWLINE#", "resdecl", "=", "(", "'std::vector<%s> result;\\n'", "%", "t", ".", "getTupleTypename", "(", ")", ")", "#NEWLINE#", "s...
false
0
[ "8", "29", "104", "state", "2", "50", "61", "87", "98", "self", "6", "src", "4", "22", "43", "72", "102", "t", "13", "38", "59", "96", "110", "code", "17", "34", "resdecl" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 12, "after_index": 15, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 16, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "uwescience/raco/raco/backends/cpp/cppcommon.py", "license": "bsd-3-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def consume(self, t, src, state) : code = '' resdecl = ('std::vector<%s> result; ' % t.getTupleTypename ()) state.addDeclarations ([resdecl]) code += ('result.push_back(%s); ' % t.name) if (self.emit_print == EMIT_CONSOLE) : code += self.language ().log_unquoted (('%s' % t.name), 2) e...
No
773
[ "#NEWLINE#", "def test_convert_accepts_unicode(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "r1", "=", "self", ".", "pc", ".", "convert", "(", "'2012-1-1'", ",", "None", ",", "self", ".", "axis", ")", "#NEWLINE#", "r2", "=", "self", ".", "pc", ".", "conve...
false
0
[ "2", "9", "19", "26", "39", "44", "self", "7", "48", "r1", "24", "50", "r2" ]
0
NONE
[]
[ [ { "before_index": 6, "after_index": 16, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 23, "after_index": 36, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 43, "after_index": ...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "pydata/pandas/pandas/tseries/tests/test_converter.py", "license": "bsd-3-clause", "note": "license: manual_eval" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def test_convert_accepts_unicode(self) : r1 = self.pc.convert ('2012-1-1', None, self.axis) r2 = self.pc.convert (u ('2012-1-1'), None, self.axis) self.assert_equal (r1, r2, 'PeriodConverter.convert should accept unicode') Is there a bug in the code above?
No
774
[ "#NEWLINE#", "def jsonify(", "data", ",", "status", "=", "None", ")", ":", "#NEWLINE#", "#INDENT#", "indent", "=", "None", "#NEWLINE#", "if", "(", "flask", ".", "current_app", ".", "config", "[", "'JSONIFY_PRETTYPRINT_REGULAR'", "]", "and", "(", "not", "flask"...
false
0
[ "11", "38", "54", "56", "indent", "4", "59", "61", "status", "2", "52", "data" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 13, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 15, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "viniciuschiele/flask-apscheduler/flask_apscheduler/json.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def jsonify(data, status = None) : indent = None if (flask.current_app.config ['JSONIFY_PRETTYPRINT_REGULAR'] and (not flask.request.is_xhr)) : indent = 2 return flask.current_app.response_class (dumps (data, indent = indent), status = status, mimetype = 'application/json') Is there a bug in the c...
No
775
[ "#NEWLINE#", "def __init__(", "self", ",", "url", ",", "path", ",", "chunkSize", "=", "defaultChunkSize", ",", "stream", "=", "FileDownloader", ".", "defaultStream", ")", ":", "#NEWLINE#", "#INDENT#", "super", "(", "HttpFileDownloader", ",", "self", ")", ".", ...
false
0
[ "6", "32", "path", "2", "25", "37", "self", "8", "39", "41", "chunkSize", "12", "34", "stream", "4", "30", "url" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 20, "after_index": 31, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 36, "after_index": 4...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "ga4gh/server/scripts/utils.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def __init__(self, url, path, chunkSize = defaultChunkSize, stream = FileDownloader.defaultStream) : super (HttpFileDownloader, self).__init__ (url, path, stream) self.chunkSize = chunkSize Is there a bug in the code above?
No
776
[ "#NEWLINE#", "def test_nodes_from_config(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "config", "=", "{", "#NEWLINE#", "#INDENT#", "'PSDASH_NODES'", ":", "[", "{", "#NEWLINE#", "#INDENT#", "'name'", ":", "'test-node'", ",", "#NEWLINE#", "'host'", ":", "'remotehost....
false
0
[ "2", "48", "64", "77", "95", "113", "self", "41", "54", "70", "81", "99", "117", "r", "7", "45", "config" ]
0
NONE
[]
[ [ { "before_index": 6, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 40, "after_index": 44, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 47, "after_index": 6...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "Jahaja/psdash/tests/test_run.py", "license": "cc0-1.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def test_nodes_from_config(self) : config = { 'PSDASH_NODES' : [{ 'name' : 'test-node', 'host' : 'remotehost.org', 'port' : 5000, }], } r = PsDashRunner (config) self.assertEqual (len (r.get_nodes ()), 2) self.assertIn ('remotehost.org:5000', r.get_n...
No
777
[ "#NEWLINE#", "def random_design_matrix(", "self", ",", "m", ")", ":", "#NEWLINE#", "#INDENT#", "'\\n .. todo::\\n\\n WRITEME\\n '", "#NEWLINE#", "Z", "=", "self", ".", "s_rng", ".", "normal", "(", "size", "=", "(", "m", ",", "self", ".", "...
false
0
[ "2", "13", "24", "51", "61", "self", "4", "22", "m", "11", "59", "Z" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 33,...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "lisa-lab/pylearn2/pylearn2/distributions/mnd.py", "license": "bsd-3-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def random_design_matrix(self, m) : ' .. todo:: WRITEME ' Z = self.s_rng.normal (size = (m, self.mu.shape [0]), avg = 0.0, std = 1.0, dtype = config.floatX) return (self.mu + T.dot (Z, self.L.T)) Is there a bug in the code above?
No
778
[ "#NEWLINE#", "def addUniqueExecutables(", "self", ",", "graph", ",", "struct", ")", ":", "#NEWLINE#", "#INDENT#", "allTools", "=", "[", "]", "#NEWLINE#", "for", "phase", "in", "struct", ".", "phaseInformation", ":", "#NEWLINE#", "#INDENT#", "phaseTools", "=", "[...
false
0
[ "11", "165", "190", "allTools", "17", "37", "110", "phase", "31", "50", "task", "116", "145", "158", "filename", "2", "59", "70", "88", "97", "118", "141", "154", "176", "205", "215", "self", "4", "46", "graph", "25", "66", "80", "84", "128", "16...
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 13, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 16, "after_index": 1...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "gkno/gkno_launcher/src/gkno/makefiles.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def addUniqueExecutables(self, graph, struct) : allTools = [] for phase in struct.phaseInformation : phaseTools = [] for task in struct.phaseInformation [phase].tasks : tool = graph.getGraphNodeAttribute (task, 'tool') if (tool in self.toolPaths) : ...
No
779
[ "#NEWLINE#", "def completeFile(", "self", ",", "outputs", ")", ":", "#NEWLINE#", "#INDENT#", "for", "filename", "in", "self", ".", "filenamesList", ":", "#NEWLINE#", "#INDENT#", "filehandle", "=", "self", ".", "filehandles", "[", "filename", "]", "#NEWLINE#", "k...
false
0
[ "10", "24", "46", "73", "84", "filename", "2", "12", "20", "37", "42", "self", "4", "75", "outputs", "18", "56", "69", "92", "100", "109", "118", "127", "136", "145", "154", "163", "172", "181", "190", "199", "208", "filehandle", "27", "77", "key...
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 9, "after_index": 10, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 9, "after_index": 13,...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "gkno/gkno_launcher/src/gkno/makefiles.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def completeFile(self, outputs) : for filename in self.filenamesList : filehandle = self.filehandles [filename] key = (str (111) if (not self.isMultipleMakefiles) else self.keys [filename]) print ('### Generate a file indicating successful execution of makefile', file = filehandle) ...
No
780
[ "#NEWLINE#", "def render_video(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "src_fname", "=", "os", ".", "path", ".", "splitext", "(", "os", ".", "path", ".", "basename", "(", "self", ".", "src", ")", ")", "[", "0", "]", "#NEWLINE#", "tempfile1", "=", ...
false
0
[ "93", "109", "173", "193", "229", "sub", "30", "83", "273", "287", "tempfile1", "171", "221", "i", "7", "47", "src_fname", "2", "21", "60", "66", "71", "79", "86", "95", "105", "123", "132", "142", "155", "159", "163", "178", "189", "207", "225",...
0
NONE
[]
[ [ { "before_index": 6, "after_index": 26, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 29, "after_index": 42, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 59, "after_index": ...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "dthpham/butterflow/butterflow/render.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def render_video(self) : src_fname = os.path.splitext (os.path.basename (self.src)) [0] tempfile1 = os.path.join (settings ['tempdir'], '~{}.{}'.format (src_fname, settings ['v_container']).lower ()) self.fr_source = OpenCvFrameSource (self.src) self.fr_source.open () self.mk_render_pipe (tempf...
No
781
[ "#NEWLINE#", "def use(", "self", ",", "player", ",", "game", ")", ":", "#NEWLINE#", "#INDENT#", "super", "(", ")", ".", "use", "(", "player", ",", "game", ")", "#NEWLINE#", "for", "i", "in", "range", "(", "0", ",", "player", ".", "effective_spell_damage"...
false
0
[ "6", "19", "45", "56", "65", "game", "39", "52", "69", "targets", "63", "72", "target", "2", "78", "self", "4", "17", "29", "player", "23", "i" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 18, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 22, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "danielyule/hearthbreaker/hearthbreaker/cards/spells/paladin.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def use(self, player, game) : super ().use (player, game) for i in range (0, player.effective_spell_damage (8)) : targets = copy.copy (game.other_player.minions) targets.append (game.other_player.hero) target = game.random_choice (targets) target.damage (1, self) Is there...
No
782
[ "#NEWLINE#", "def popmin(", "a", ",", "b", ")", ":", "#NEWLINE#", "#INDENT#", "\"\\n popmin(a, b) -> (i, a', b')\\n\\n where i is min(a[0], b[0]) and a'/b' are the results of removing i from the\\n relevant sequence.\\n \"", "#NEWLINE#", "if", "(", "len", "(", "a", ")", ...
false
0
[ "2", "15", "30", "58", "63", "79", "99", "115", "120", "a", "4", "25", "32", "48", "69", "84", "94", "101", "126", "b" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 11, "after_index": 17,...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "spotify/luigi/test/visualiser/visualiser_test.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def popmin(a, b) : " popmin(a, b) -> (i, a', b') where i is min(a[0], b[0]) and a'/b' are the results of removing i from the relevant sequence. " if (len (a) == 0) : return (b [0], a, b [1 :]) else : if (len (b) == 0) : return (a [0], a [1 :], b) else : ...
No
783
[ "#NEWLINE#", "def __repr__(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "result", "=", "'<IMAPClientCommand '", "#NEWLINE#", "if", "(", "self", ".", "tag", "is not", "None", ")", ":", "#NEWLINE#", "#INDENT#", "result", "+=", "(", "\"tag: '%s'\"", "%", "self", ...
false
0
[ "7", "22", "44", "65", "91", "96", "result", "77", "80", "x", "2", "13", "27", "35", "49", "56", "82", "self" ]
0
NONE
[]
[ [ { "before_index": 6, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 11, "after_index": 16, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 33, "after_index": 3...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "scanner/asimap/asimap/parse.py", "license": "bsd-3-clause", "note": "license: manual_eval" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def __repr__(self) : result = '<IMAPClientCommand ' if (self.tag is not None) : result += ("tag: '%s'" % self.tag) if (self.command is not None) : result += (" command: '%s'" % self.command) if (self.command == 'fetch') : result += (': ' + ' '.join ([str (x) for x in s...
No
784
[ "#NEWLINE#", "def btndown(", "self", ",", "canvas", ",", "event", ",", "data_x", ",", "data_y", ")", ":", "#NEWLINE#", "#INDENT#", "self", ".", "move_crosshair", "(", "self", ".", "fitsimage", ",", "data_x", ",", "data_y", ")" ]
false
0
[ "10", "25", "data_y", "6", "event", "4", "canvas", "2", "15", "19", "self", "8", "23", "data_x" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 14, "after_index": 22, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 22, "after_index": 1...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "ejeschke/ginga/ginga/misc/plugins/Crosshair.py", "license": "bsd-3-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def btndown(self, canvas, event, data_x, data_y) : self.move_crosshair (self.fitsimage, data_x, data_y) Is there a bug in the code above?
No
785
[ "#NEWLINE#", "def test_callRemote_cancellation_during_request(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "'\\n The Deferred returned by callRemote can be cancelled while waiting on a\\n response.\\n '", "#NEWLINE#", "self", ".", "assertFalse", "(", "self", ".", ...
false
0
[ "20", "31", "41", "d", "2", "9", "13", "22", "37", "self" ]
0
NONE
[]
[ [ { "before_index": 6, "after_index": 7, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 12, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 19, "after_index": 27...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "flowroute/txjason/txjason/tests/test_netstring.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def test_callRemote_cancellation_during_request(self) : ' The Deferred returned by callRemote can be cancelled while waiting on a response. ' self.assertFalse (self.endpoint.connected) d = self.factory.callRemote ('spam') d.cancel () self.failureResultOf (d, defer.Cancel...
No
786
[ "#NEWLINE#", "@", "tornado", ".", "gen", ".", "coroutine", "#NEWLINE#", "def preconnect(", "self", ",", "size", "=", "(", "-", "1", ")", ")", ":", "#NEWLINE#", "#INDENT#", "'(pre)Connects some or all redis clients inside the pool.\\n\\n Args:\\n size (int)...
false
0
[ "81", "106", "clients", "104", "114", "client", "55", "98", "limit", "11", "26", "60", "68", "size", "9", "35", "62", "76", "86", "110", "self", "92", "_" ]
0
NONE
[]
[ [ { "before_index": 1, "after_index": 10, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 20, "after_index": 21, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 23, "after_index": ...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "thefab/tornadis/tornadis/pool.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
@ tornado.gen.coroutine def preconnect(self, size = (- 1)) : '(pre)Connects some or all redis clients inside the pool. Args: size (int): number of redis clients to build and to connect (-1 means all clients if pool max_size > -1) Raises: ClientError: when ...
No
787
[ "#NEWLINE#", "def mutually_exclusive_fix(", "sender", ",", "instance", ",", "created", ",", "**kwargs", ")", ":", "#NEWLINE#", "#INDENT#", "try", ":", "#NEWLINE#", "#INDENT#", "following", "=", "RelationshipStatus", ".", "objects", ".", "following", "(", ")", "#NE...
true
82
[ "27", "33", "69", "52", "67", "87", "94", "124", "4", "58", "78", "106", "112", "118", "2", "6", "17", "23", "62", "82", "89" ]
1
VARIABLE_MISUSE
[ 27, 33, 69 ]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 16, "after_index": 24, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 26, "after_index": 3...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "coleifer/django-relationships/relationships/listeners.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def mutually_exclusive_fix(sender, instance, created, **kwargs) : try : following = RelationshipStatus.objects.following () blocking = RelationshipStatus.objects.blocking () except RelationshipStatus.DoesNotExist : pass else : other = None if (instance.status == follo...
Yes
788
[ "#NEWLINE#", "@", "property", "#NEWLINE#", "def headers(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "cols", "=", "[", "DataTablesColumn", "(", "_", "(", "'Message Text'", ")", ")", ",", "DataTablesColumn", "(", "_", "(", "'Risk Profile'", ")", ")", "]", "#...
true
80
[ "10", "48", "64", "31", "41", "59", "67", "39", "54", "5", "33", "80" ]
1
VARIABLE_MISUSE
[ 59, 67 ]
[ [ { "before_index": 9, "after_index": 12, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 30, "after_index": 31, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 30, "after_index": ...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "dimagi/commcare-hq/custom/fri/reports/reports.py", "license": "bsd-3-clause", "note": "license: manual_eval" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
@ property def headers(self) : cols = [DataTablesColumn (_ ('Message Text')), DataTablesColumn (_ ('Risk Profile'))] for case in self.interactive_participants : header_text = case.get_case_property ('name_and_pid') cols.append (DataTablesColumn (header_text)) header = DataTablesHeader (* c...
Yes
789
[ "#NEWLINE#", "def get_participant_message_counts(", "self", ",", "message_bank_messages", ",", "case", ")", ":", "#NEWLINE#", "#INDENT#", "result", "=", "{", "#NEWLINE#", "#INDENT#", "#NEWLINE#", "#UNINDENT#", "}", "#NEWLINE#", "for", "entry", "in", "message_bank_messag...
true
101
[ "6", "46", "11", "27", "106", "119", "4", "23", "91", "101", "21", "29", "40", "52", "50", "59", "67", "80", "89", "97", "108", "2", "42" ]
1
VARIABLE_MISUSE
[ 11, 27, 106, 119 ]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 13, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 20, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "dimagi/commcare-hq/custom/fri/reports/reports.py", "license": "bsd-3-clause", "note": "license: manual_eval" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def get_participant_message_counts(self, message_bank_messages, case) : result = { } for entry in message_bank_messages : result [entry ['message']._id] = 0 participant_messages = self.get_participant_messages (case) for sms in participant_messages : if ((sms.xforms_session_c...
Yes
790
[ "#NEWLINE#", "def _fmt(", "self", ",", "val", ")", ":", "#NEWLINE#", "#INDENT#", "return", "format_datatables_data", "(", "self", ",", "val", ")" ]
true
12
[ "4", "14", "2", "12" ]
1
VARIABLE_MISUSE
[ 4, 14 ]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 9, "after_index": 13, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 13, "after_index": 10...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "dimagi/commcare-hq/custom/fri/reports/reports.py", "license": "bsd-3-clause", "note": "license: manual_eval" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def _fmt(self, val) : return format_datatables_data (self, val) Is there a bug in the code above?
Yes
791
[ "#NEWLINE#", "def _current_obj(", "self", ")", ":", "#NEWLINE#", "#INDENT#", "'Returns the current active object being proxied to\\n\\n In the event that no object was pushed, the default object if\\n provided will be used. Otherwise, a TypeError will be raised.\\n\\n '", "#NEWL...
true
15
[ "15", "51", "66", "74", "13", "19", "27", "33", "38", "2", "53", "87" ]
1
VARIABLE_MISUSE
[ 2, 53, 87 ]
[ [ { "before_index": 6, "after_index": 7, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 32, "after_index": 33, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 12, "after_index": 1...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "cloudera/hue/desktop/core/ext-py/Paste-2.0.1/paste/registry.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def _current_obj(self) : 'Returns the current active object being proxied to In the event that no object was pushed, the default object if provided will be used. Otherwise, a TypeError will be raised. ' try : objects = obj.____local__.objects except AttributeError : ...
Yes
792
[ "#NEWLINE#", "def make_registry_manager(", "app", ",", "global_conf", ")", ":", "#NEWLINE#", "#INDENT#", "return", "RegistryManager", "(", "global_conf", ")" ]
true
12
[ "2", "4", "12" ]
1
VARIABLE_MISUSE
[ 2 ]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 9, "after_index": 11, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 11, "after_index": 10...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "cloudera/hue/desktop/core/ext-py/Paste-2.0.1/paste/registry.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def make_registry_manager(app, global_conf) : return RegistryManager (global_conf) Is there a bug in the code above?
Yes
793
[ "#NEWLINE#", "def write_dist_info(", "self", ",", "site_pkgs", ")", ":", "#NEWLINE#", "#INDENT#", "'Write dist-info folder, according to PEP 376'", "#NEWLINE#", "metadata", "=", "common", ".", "make_metadata", "(", "self", ".", "module", ",", "self", ".", "ini_info", ...
true
403
[ "263", "376", "390", "99", "107", "136", "140", "259", "269", "2", "17", "21", "111", "148", "178", "193", "211", "229", "275", "273", "281", "287", "292", "299", "339", "345", "358", "360", "381", "314", "330", "383", "11", "40", "44", "103", ...
1
VARIABLE_MISUSE
[ 4, 33, 364 ]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 9, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 20,...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "takluyver/flit/flit/install.py", "license": "bsd-3-clause", "note": "license: manual_eval" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def write_dist_info(self, site_pkgs) : 'Write dist-info folder, according to PEP 376' metadata = common.make_metadata (self.module, self.ini_info) dist_info = (pathlib.Path (site_pkgs) / '{}-{}.dist-info'.format (metadata.name, metadata.version)) try : dist_info.mkdir () except FileExistsE...
Yes
794
[ "#NEWLINE#", "def update_candidate_distributions(", "self", ",", "distribution_iter", ")", ":", "#NEWLINE#", "#INDENT#", "for", "dist", "in", "distribution_iter", ":", "#NEWLINE#", "#INDENT#", "if", "self", ".", "can_add", "(", "dist", ")", ":", "#NEWLINE#", "#INDEN...
true
48
[ "2", "17", "44", "48", "10", "21", "34", "4", "12" ]
1
VARIABLE_MISUSE
[ 10, 21, 34 ]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 9, "after_index": 10, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 9, "after_index": 12,...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "pantsbuild/pex/pex/environment.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def update_candidate_distributions(self, distribution_iter) : for dist in distribution_iter : if self.can_add (dist) : with TRACER.timed (('Adding %s' % dist), V = 2) : self.add (self) Is there a bug in the code above?
Yes
795
[ "#NEWLINE#", "def _format_item(", "self", ",", "item", ")", ":", "#NEWLINE#", "#INDENT#", "value", "=", "self", ".", "loader", ".", "format", "(", "item", ".", "data", ")", "#NEWLINE#", "return", "(", "value", "[", "0", "]", ",", "value", "[", "1", "]"...
true
17
[ "9", "24", "29", "2", "11", "4", "17" ]
1
VARIABLE_MISUSE
[ 2, 11 ]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 8, "after_index": 16, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 22, "after_index": 28...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "flask-admin/flask-admin/flask_admin/model/fields.py", "license": "bsd-3-clause", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def _format_item(self, item) : value = self.loader.format (item.data) return (value [0], value [1], True) Is there a bug in the code above?
Yes
796
[ "#NEWLINE#", "def __init__(", "self", ",", "saveto", ",", "**kwargs", ")", ":", "#NEWLINE#", "#INDENT#", "self", ".", "folder", "=", "self", "#NEWLINE#", "super", "(", "LoadNMT", ",", "self", ")", ".", "__init__", "(", "saveto", ",", "**", "kwargs", ")" ]
true
15
[ "4", "26", "29", "2", "11", "15", "21" ]
1
VARIABLE_MISUSE
[ 4, 26 ]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 10, "after_index": 15, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 16, "after_index": 2...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "mila-udem/blocks-examples/machine_translation/checkpoint.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def __init__(self, saveto, **kwargs) : self.folder = self super (LoadNMT, self).__init__ (saveto, ** kwargs) Is there a bug in the code above?
Yes
797
[ "#NEWLINE#", "def merge_aggregate(", "obj_a", ",", "obj_b", ")", ":", "#NEWLINE#", "#INDENT#", "return", "_yamlex_merge_recursive", "(", "obj_b", ",", "obj_b", ",", "level", "=", "1", ")" ]
true
12
[ "2", "4", "12", "14" ]
1
VARIABLE_MISUSE
[ 2 ]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 9, "after_index": 13, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 13, "after_index": 10...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "saltstack/salt/salt/utils/dictupdate.py", "license": "apache-2.0", "note": "license: manual_eval" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def merge_aggregate(obj_a, obj_b) : return _yamlex_merge_recursive (obj_b, obj_b, level = 1) Is there a bug in the code above?
Yes
798
[ "#NEWLINE#", "def clear_opts_related_cache(", "model_class", ")", ":", "#NEWLINE#", "#INDENT#", "opts", "=", "model_class", ".", "_meta", "#NEWLINE#", "children", "=", "[", "model_class", ".", "related_model", "for", "related_object", "in", "opts", ".", "__dict__", ...
true
16
[ "46", "54", "2", "9", "16", "7", "22", "39", "20", "34", "13", "48" ]
1
VARIABLE_MISUSE
[ 20, 34 ]
[ [ { "before_index": 6, "after_index": 10, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 12, "after_index": 15, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 38, "after_index": ...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "charettes/django-mutant/mutant/compat.py", "license": "mit", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def clear_opts_related_cache(model_class) : opts = model_class._meta children = [model_class.related_model for related_object in opts.__dict__.get ('related_objects', []) if related_object.parent_link] opts._expire_cache () for child in children : clear_opts_related_cache (child) Is there...
Yes
799
[ "#NEWLINE#", "def failIf(", "self", ",", "expr", ")", ":", "#NEWLINE#", "#INDENT#", "return", "self", ".", "assertFalse", "(", "self", ")" ]
true
14
[ "2", "10", "14", "4" ]
1
VARIABLE_MISUSE
[ 4 ]
[ [ { "before_index": 1, "after_index": 3, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 9, "after_index": 13, "edge_type": 7, "edge_type_name": "enum_FIELD" } ], [ { "before_index": 13, "after_index": 11...
[ { "datasetProvenance": { "datasetName": "ETHPy150Open", "filepath": "nlloyd/SubliminalCollaborator/libs/zope/interface/tests/test_interfaces.py", "license": "apache-2.0", "note": "license: bigquery_api" } } ]
bug detection
{% set indent = ' ' %} {% set ns = namespace(indent_size=0, result=[]) %} {% for token in source_tokens %} {% if token== '#INDENT#' %} {% set ns.indent_size = ns.indent_size + 1 %} {% set ns.result = ns.result + [indent * ns.indent_size] %} {% elif token == '#NEWLINE#' %} {% set ns.r...
def failIf(self, expr) : return self.assertFalse (self) Is there a bug in the code above?
Yes