lines
listlengths
1
444
raw_lines
listlengths
1
444
label
listlengths
1
444
type
listlengths
1
444
[ "def FUNC_3(*VAR_17, **VAR_18):...\n", "return {'id': uuidutils.generate_uuid()}\n" ]
[ "def _return_id_key(*args, **kwargs):...\n", "return {'id': uuidutils.generate_uuid()}\n" ]
[ 0, 0 ]
[ "FunctionDef'", "Return'" ]
[ "@app.route('/api/indi_profiles', methods=['POST'])...\n", "" ]
[ "@app.route('/api/indi_profiles', methods=['POST'])...\n", "" ]
[ 0, 0 ]
[ "Condition", "Condition" ]
[ "def FUNC_22(self, VAR_2, VAR_3, VAR_4, *VAR_5):...\n", "self.write_data({'type': 'shutdown', 'event': VAR_5[0]})\n" ]
[ "def on_shutdown(self, subject, changetype, objectID, *args):...\n", "self.write_data({'type': 'shutdown', 'event': args[0]})\n" ]
[ 0, 0 ]
[ "FunctionDef'", "Expr'" ]
[ "def FUNC_0(self):...\n", "super(CLASS_0, self).setUp()\n", "self.configuration = mox.MockObject(conf.Configuration)\n", "self.configuration.append_config_values(mox.IgnoreArg())\n", "self.configuration.san_is_local = False\n", "self.configuration.san_ip = '10.0.0.1'\n", "self.configuration.san_login = ...
[ "def setUp(self):...\n", "super(DellEQLSanISCSIDriverTestCase, self).setUp()\n", "self.configuration = mox.MockObject(conf.Configuration)\n", "self.configuration.append_config_values(mox.IgnoreArg())\n", "self.configuration.san_is_local = False\n", "self.configuration.san_ip = '10.0.0.1'\n", "self.confi...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Expr'", "Assign'", "Expr'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "As...
[ "def FUNC_1(self, VAR_1):...\n", "self.__init__()\n", "self.name = VAR_1.get('name')\n", "self.vars = VAR_1.get('vars', dict())\n", "self.depth = VAR_1.get('depth', 0)\n", "self.hosts = VAR_1.get('hosts', [])\n", "self._hosts = None\n", "VAR_7 = VAR_1.get('parent_groups', [])\n", "for parent_data in...
[ "def deserialize(self, data):...\n", "self.__init__()\n", "self.name = data.get('name')\n", "self.vars = data.get('vars', dict())\n", "self.depth = data.get('depth', 0)\n", "self.hosts = data.get('hosts', [])\n", "self._hosts = None\n", "parent_groups = data.get('parent_groups', [])\n", "for parent_...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Expr'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "For", "Assign'", "Expr'", "Expr'" ]
[ "@VAR_1.route('/register', methods=['GET', 'POST'])...\n", "if VAR_14.g.user:\n", "return VAR_14.redirect(FUNC_5())\n", "VAR_4 = forms.RegisterForm(VAR_14.request.form)\n", "if VAR_14.request.method == 'POST' and VAR_4.validate():\n", "VAR_3 = models.User(VAR_12=form.username.data.strip(), email=form.emai...
[ "@bp.route('/register', methods=['GET', 'POST'])...\n", "if flask.g.user:\n", "return flask.redirect(redirect_url())\n", "form = forms.RegisterForm(flask.request.form)\n", "if flask.request.method == 'POST' and form.validate():\n", "user = models.User(username=form.username.data.strip(), email=form.email....
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "Condition", "Condition", "Return'", "Assign'", "Condition", "Assign'", "Return'", "Assign'", "Assign'", "Expr'", "Expr'", "Condition", "Expr'", "Condition", "Expr'", "Assign'", "Return'", "Expr'", "Expr'", "Assign'", "Assign'", "Assign'", "Assign'", "Return'" ]
[ "def FUNC_16(self, VAR_14):...\n", "" ]
[ "def is_datetime(self, col_name):...\n", "" ]
[ 0, 0 ]
[ "FunctionDef'", "Condition" ]
[ "def FUNC_7(self, VAR_17=None):...\n", "if not VAR_17:\n", "VAR_17 = self._error\n", "if VAR_17:\n", "VAR_101.errors.add(VAR_17)\n" ]
[ "def error(self, e=None):...\n", "if not e:\n", "e = self._error\n", "if e:\n", "c.errors.add(e)\n" ]
[ 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Condition", "Assign'", "Condition", "Expr'" ]
[ "def FUNC_36(self, VAR_14):...\n", "return self.__class__(self.get_related_model(VAR_14), self.session)\n" ]
[ "def get_related_interface(self, col_name):...\n", "return self.__class__(self.get_related_model(col_name), self.session)\n" ]
[ 0, 0 ]
[ "FunctionDef'", "Return'" ]
[ "def FUNC_13(self):...\n", "self._tab_after('ls --help')\n", "eq_(self.terminal.method_calls, [('write', (' ',), {})])\n", "self._tab_after('-')\n", "assert 'help' not in self.terminal.method_calls[2][1][0]\n", "assert '-h' not in self.terminal.method_calls[2][1][0]\n" ]
[ "def test_complete_consumed_switches(self):...\n", "self._tab_after('ls --help')\n", "eq_(self.terminal.method_calls, [('write', (' ',), {})])\n", "self._tab_after('-')\n", "assert 'help' not in self.terminal.method_calls[2][1][0]\n", "assert '-h' not in self.terminal.method_calls[2][1][0]\n" ]
[ 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Expr'", "Expr'", "Expr'", "Assert'", "Assert'" ]
[ "def FUNC_39(VAR_101):...\n", "VAR_101.output = VAR_69, VAR_70\n", "return VAR_101\n" ]
[ "def decorate(ruleinfo):...\n", "ruleinfo.output = paths, kwpaths\n", "return ruleinfo\n" ]
[ 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Return'" ]
[ "def FUNC_12(self):...\n", "return self._omnicomp\n" ]
[ "def GetOmniCompleter(self):...\n", "return self._omnicomp\n" ]
[ 0, 0 ]
[ "FunctionDef'", "Return'" ]
[ "@user_passes_test(user_is_staff)...\n", "if VAR_0.method == 'GET':\n", "VAR_4 = {'form': TestrailConfigurationForm()}\n", "if VAR_0.method == 'POST':\n", "return render(VAR_0, 'testcases/tc_testrails_new.html', VAR_4)\n", "VAR_19 = get_object_or_404(TestRailInstance, username='testrail@west.com')\n", "...
[ "@user_passes_test(user_is_staff)...\n", "if request.method == 'GET':\n", "context = {'form': TestrailConfigurationForm()}\n", "if request.method == 'POST':\n", "return render(request, 'testcases/tc_testrails_new.html', context)\n", "instance = get_object_or_404(TestRailInstance, username='testrail@west.c...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "Condition", "Condition", "Assign'", "Condition", "Return'", "Assign'", "Assign'", "Assign'", "Condition", "Assign'", "Expr'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Return'", "Assign'", "Assign'", "Assign'", "Assign'", "For", "Expr'", "Assign'", "Exp...
[ "def __init__(self, VAR_3, VAR_4, VAR_1=(), VAR_2={}, VAR_5=None, VAR_6=None,...\n", "super().__init__(*VAR_8, **pkvargs)\n", "self.name = VAR_5 if VAR_5 else type(self).__name__\n", "self.start_timer = VAR_6\n", "self.poll_timeout = VAR_7 if VAR_7 else 5 * 1000\n", "self.call = VAR_4, VAR_1, VAR_2\n", ...
[ "def __init__(self, wz_addr, fun, args=(), kvargs={}, name=None, start_timer...\n", "super().__init__(*pargs, **pkvargs)\n", "self.name = name if name else type(self).__name__\n", "self.start_timer = start_timer\n", "self.poll_timeout = poll_timeout if poll_timeout else 5 * 1000\n", "self.call = fun, args...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 7 ]
[ "Condition", "Expr'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'" ]
[ "def FUNC_14(VAR_1):...\n", "\"\"\"docstring\"\"\"\n", "return partial(FUNC_5, VAR_1)\n" ]
[ "def make_token_getter(remote):...\n", "\"\"\"docstring\"\"\"\n", "return partial(token_getter, remote)\n" ]
[ 0, 0, 0 ]
[ "FunctionDef'", "Docstring", "Return'" ]
[ "@integration_synonym_api...\n", "FUNC_2(VAR_2)\n", "FUNC_3(VAR_2, 'PSYCHO', VAR_7='1')\n", "FUNC_5(VAR_4, VAR_5, VAR_11='SYCHO', VAR_10=[{'name': '----SYCHO'}, {'name':\n 'PSYCHO'}])\n" ]
[ "@integration_synonym_api...\n", "clean_database(solr)\n", "seed_database_with(solr, 'PSYCHO', id='1')\n", "verify_results(client, jwt, query='SYCHO', expected=[{'name': '----SYCHO'},\n {'name': 'PSYCHO'}])\n" ]
[ 0, 0, 0, 0 ]
[ "Condition", "Expr'", "Expr'", "Expr'" ]
[ "def FUNC_5(self, VAR_12, VAR_8):...\n", "\"\"\"docstring\"\"\"\n", "if not isinstance(VAR_12, str) or not isinstance(VAR_8, str):\n", "self.extra_data[VAR_12] = VAR_8\n" ]
[ "def set_attribute(self, key, value):...\n", "\"\"\"docstring\"\"\"\n", "if not isinstance(key, str) or not isinstance(value, str):\n", "self.extra_data[key] = value\n" ]
[ 0, 0, 0, 0 ]
[ "FunctionDef'", "Docstring", "Condition", "Assign'" ]
[ "def FUNC_0(VAR_0):...\n", "VAR_1 = []\n", "VAR_2 = FUNC_1(VAR_0)\n", "if VAR_2:\n", "VAR_1.append(VAR_2)\n", "VAR_3 = os.listdir(VAR_0)\n", "VAR_3 = []\n", "for name in VAR_3:\n", "return VAR_1\n", "VAR_4 = os.path.join(VAR_0, name)\n", "if not os.path.isdir(VAR_4):\n", "VAR_1 += FUNC_0(VAR_4...
[ "def find_repositories(path):...\n", "repos = []\n", "client = get_vcs_client(path)\n", "if client:\n", "repos.append(client)\n", "listdir = os.listdir(path)\n", "listdir = []\n", "for name in listdir:\n", "return repos\n", "subpath = os.path.join(path, name)\n", "if not os.path.isdir(subpath):\...
[ 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 1 ]
[ "FunctionDef'", "Assign'", "Assign'", "Condition", "Expr'", "Assign'", "Assign'", "For", "Return'", "Assign'", "Condition", "AugAssign'" ]
[ "def FUNC_8(self):...\n", "\"\"\"docstring\"\"\"\n", "VAR_47 = re.compile('^.*[,();].*')\n", "VAR_48 = ['select', 'create', 'insert', 'delete', 'drop', 'update', 'case']\n", "VAR_49 = ['concat', 'concat_ws', 'if', 'ifnull', 'nullif', 'coalesce',\n 'connection_id', 'current_user', 'database', 'last_insert...
[ "def sanitize_fields(self):...\n", "\"\"\"docstring\"\"\"\n", "sub_query_regex = re.compile('^.*[,();].*')\n", "blacklisted_keywords = ['select', 'create', 'insert', 'delete', 'drop',\n 'update', 'case']\n", "blacklisted_functions = ['concat', 'concat_ws', 'if', 'ifnull', 'nullif',\n 'coalesce', 'conn...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 4, 0, 0, 0, 4, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Docstring", "Assign'", "Assign'", "Assign'", "FunctionDef'", "Expr'", "FunctionDef'", "Condition", "Expr'", "Condition", "For", "Expr'", "Condition", "For", "Condition", "Expr'", "For", "Expr'", "Condition", "Expr'", "For", "Expr'", "Expr'", "Expr'" ]
[ "from __future__ import absolute_import, division, print_function, unicode_literals\n", "import os\n", "from builtins import open\n", "from future.utils import text_type\n", "from pants.backend.graph_info.subsystems.cloc_binary import ClocBinary\n", "from pants.base.workunit import WorkUnitLabel\n", "fr...
[ "from __future__ import absolute_import, division, print_function, unicode_literals\n", "import os\n", "from builtins import open\n", "from future.utils import text_type\n", "from pants.backend.graph_info.subsystems.cloc_binary import ClocBinary\n", "from pants.base.workunit import WorkUnitLabel\n", "fr...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "ImportFrom'", "Import'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "Expr'", "Condition", "Return'" ]
[ "import sys\n", "import logging\n", "import sqlalchemy as sa\n", "from . import filters\n", "from sqlalchemy.orm import joinedload\n", "from sqlalchemy.exc import IntegrityError\n", "from sqlalchemy import func\n", "from sqlalchemy.orm.properties import SynonymProperty\n", "from ..base import BaseIn...
[ "import sys\n", "import logging\n", "import sqlalchemy as sa\n", "from . import filters\n", "from sqlalchemy.orm import joinedload\n", "from sqlalchemy.exc import IntegrityError\n", "from sqlalchemy import func\n", "from sqlalchemy.orm.properties import SynonymProperty\n", "from ..base import BaseIn...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "Import'", "Import'", "Import'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "Assign'", "FunctionDef'", "For", "Condition", "Expr'", "Expr'", "Assign'", ...
[ "def FUNC_0(self):...\n", "super(CLASS_0, self).setUp()\n", "self.count = 0\n", "self.initialize(GigaChannelCommunity, 2)\n" ]
[ "def setUp(self):...\n", "super(TestGigaChannelUnits, self).setUp()\n", "self.count = 0\n", "self.initialize(GigaChannelCommunity, 2)\n" ]
[ 0, 0, 0, 0 ]
[ "FunctionDef'", "Expr'", "Assign'", "Expr'" ]
[ "def FUNC_6(self):...\n", "VAR_91 = Subreddit._by_fullname(VAR_102.post.keys())\n", "return VAR_91.values()\n" ]
[ "def run(self):...\n", "subreddits = Subreddit._by_fullname(request.post.keys())\n", "return subreddits.values()\n" ]
[ 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Return'" ]
[ "def FUNC_0(self):...\n", "self._mox = mox.Mox()\n", "self.mock(logging, 'error', lambda *_: None)\n", "self.mock(logging, 'exception', lambda *_: None)\n", "self.mock(logging, 'info', lambda *_: None)\n", "self.mock(logging, 'warning', lambda *_: None)\n", "self._mox.StubOutWithMock(time, 'sleep')\n", ...
[ "def setUp(self):...\n", "self._mox = mox.Mox()\n", "self.mock(logging, 'error', lambda *_: None)\n", "self.mock(logging, 'exception', lambda *_: None)\n", "self.mock(logging, 'info', lambda *_: None)\n", "self.mock(logging, 'warning', lambda *_: None)\n", "self._mox.StubOutWithMock(time, 'sleep')\n", ...
[ 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Expr'", "Expr'", "Expr'", "Expr'", "Expr'", "Expr'" ]
[ "def __init__(self, VAR_6, VAR_7=None):...\n", "super().__init__(VAR_6, VAR_7)\n", "self.type = 'port'\n" ]
[ "def __init__(self, name, display_name=None):...\n", "super().__init__(name, display_name)\n", "self.type = 'port'\n" ]
[ 0, 0, 0 ]
[ "FunctionDef'", "Expr'", "Assign'" ]
[ "@VAR_2.user_loader...\n", "return User.get(VAR_6)\n" ]
[ "@login_manager.user_loader...\n", "return User.get(user_id)\n" ]
[ 0, 0 ]
[ "Condition", "Return'" ]
[ "def __eq__(self, VAR_10):...\n", "if VAR_10:\n", "return vars(self) == vars(VAR_10)\n", "return False\n" ]
[ "def __eq__(self, other):...\n", "if other:\n", "return vars(self) == vars(other)\n", "return False\n" ]
[ 0, 0, 0, 0 ]
[ "FunctionDef'", "Condition", "Return'", "Return'" ]
[ "def FUNC_4(VAR_6):...\n", "VAR_7 = HttpResponse(VAR_6)\n", "VAR_7['Access-Control-Allow-Origin'] = '*'\n", "return VAR_7\n" ]
[ "def respond_text(text):...\n", "response = HttpResponse(text)\n", "response['Access-Control-Allow-Origin'] = '*'\n", "return response\n" ]
[ 0, 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Assign'", "Return'" ]
[ "def FUNC_41(self):...\n", "self.compilation_ko(\"\"\"\nmacommande \"Toto\";\n\"\"\")\n" ]
[ "def test_unknown_control(self):...\n", "self.compilation_ko(\"\"\"\nmacommande \"Toto\";\n\"\"\")\n" ]
[ 0, 0 ]
[ "FunctionDef'", "Expr'" ]
[ "def FUNC_23(self, VAR_21, VAR_27, VAR_28):...\n", "\"\"\"docstring\"\"\"\n", "VAR_57 = self.getfile(VAR_21)\n", "if VAR_57 == False:\n", "if VAR_27 != -1:\n", "VAR_57[VAR_3] = VAR_27\n", "if VAR_28 != -1:\n", "VAR_57[VAR_4] = VAR_28\n" ]
[ "def chown(self, path, uid, gid):...\n", "\"\"\"docstring\"\"\"\n", "p = self.getfile(path)\n", "if p == False:\n", "if uid != -1:\n", "p[A_UID] = uid\n", "if gid != -1:\n", "p[A_GID] = gid\n" ]
[ 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Docstring", "Assign'", "Condition", "Condition", "Assign'", "Condition", "Assign'" ]
[ "def FUNC_0():...\n", "\"\"\"docstring\"\"\"\n", "VAR_3 = {'TEST_STACK': str(CLASS_0.DEFAULT_TEST_ID), 'TEST_APP': \n 'smoketest' + CLASS_0.DEFAULT_TEST_ID}\n", "return st.ScenarioTestRunner.main(CLASS_0, default_binding_overrides=\n defaults, test_case_list=[AwsSmokeTest])\n" ]
[ "def main():...\n", "\"\"\"docstring\"\"\"\n", "defaults = {'TEST_STACK': str(AwsSmokeTestScenario.DEFAULT_TEST_ID),\n 'TEST_APP': 'smoketest' + AwsSmokeTestScenario.DEFAULT_TEST_ID}\n", "return st.ScenarioTestRunner.main(AwsSmokeTestScenario,\n default_binding_overrides=defaults, test_case_list=[AwsSmo...
[ 0, 0, 0, 0 ]
[ "FunctionDef'", "Docstring", "Assign'", "Return'" ]
[ "def FUNC_4(self):...\n", "VAR_59 = defer.Deferred()\n", "self.account = IMAPAccount(self._user_id, self.soledad, VAR_59)\n", "return VAR_59\n" ]
[ "def _initialize_imap_account(self):...\n", "account_ready_cb = defer.Deferred()\n", "self.account = IMAPAccount(self._user_id, self.soledad, account_ready_cb)\n", "return account_ready_cb\n" ]
[ 0, 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Assign'", "Return'" ]
[ "def FUNC_48(self, VAR_22, VAR_6=None):...\n", "if VAR_6:\n", "VAR_5 = VAR_5 = self.session.query(self.obj)\n", "return self.session.query(self.obj).get(VAR_22)\n", "VAR_35 = VAR_6.copy()\n", "VAR_35.add_filter(self.get_pk_name(), self.FilterEqual, VAR_22)\n", "VAR_5 = self._get_base_query(VAR_5=query, ...
[ "def get(self, id, filters=None):...\n", "if filters:\n", "query = query = self.session.query(self.obj)\n", "return self.session.query(self.obj).get(id)\n", "_filters = filters.copy()\n", "_filters.add_filter(self.get_pk_name(), self.FilterEqual, id)\n", "query = self._get_base_query(query=query, filter...
[ 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Condition", "Assign'", "Return'", "Assign'", "Expr'", "Assign'", "Return'" ]
[ "@atomic...\n", "\"\"\"docstring\"\"\"\n", "VAR_5, VAR_6 = self.common()\n", "VAR_19 = Path('head')\n", "VAR_20 = []\n", "while True:\n", "VAR_31 = self.get_mfs_path(VAR_5, VAR_6, branch_info=curr_commit)\n", "VAR_32 = VAR_31 / 'metadata'\n", "VAR_21 = self.ipfs.files_stat(VAR_31)['Hash']\n", "VAR...
[ "@atomic...\n", "\"\"\"docstring\"\"\"\n", "fs_repo_root, branch = self.common()\n", "curr_commit = Path('head')\n", "commits = []\n", "while True:\n", "mfs_commit = self.get_mfs_path(fs_repo_root, branch, branch_info=curr_commit)\n", "mfs_commit_meta = mfs_commit / 'metadata'\n", "mfs_commit_hash =...
[ 0, 0, 0, 1, 0, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 1, 1, 0, 1 ]
[ "Condition", "Docstring", "Assign'", "Assign'", "Assign'", "Condition", "Assign'", "Assign'", "Assign'", "Assign'", "Return'", "Assign'", "Condition", "Assign'", "Assign'", "Condition", "Condition", "Expr'", "Expr'", "Expr'", "Assign'" ]
[ "import itertools\n", "from django.core.exceptions import ValidationError\n", "from django.db import models, connection\n", "from django.db.models import Q, F, Case, When\n", "from django.utils import translation\n", "from django.utils.functional import cached_property\n", "from django.utils.translation...
[ "import itertools\n", "from django.core.exceptions import ValidationError\n", "from django.db import models, connection\n", "from django.db.models import Q, F, Case, When\n", "from django.utils import translation\n", "from django.utils.functional import cached_property\n", "from django.utils.translation...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0 ]
[ "Import'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "Assign'", "...
[ "def FUNC_3(VAR_9):...\n", "VAR_13, VAR_14, VAR_14, VAR_14 = VAR_3.find(VAR_9)\n", "return VAR_13['passed']\n" ]
[ "def is_passed(model):...\n", "entry, _, _, _ = cached_points.find(model)\n", "return entry['passed']\n" ]
[ 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Return'" ]
[ "def FUNC_0(VAR_0=None):...\n", "VAR_9 = frappe._dict(template='templates/includes/blog/blog.html', get_list\n =get_blog_list, hide_filters=True, children=get_children(), title=_('Blog')\n )\n", "VAR_10 = (frappe.local.form_dict.blog_category or frappe.local.form_dict.\n category)\n", "if VAR_10:\n",...
[ "def get_list_context(context=None):...\n", "list_context = frappe._dict(template='templates/includes/blog/blog.html',\n get_list=get_blog_list, hide_filters=True, children=get_children(),\n title=_('Blog'))\n", "category = (frappe.local.form_dict.blog_category or frappe.local.form_dict.\n category)\n"...
[ 0, 0, 3, 0, 0, 0, 0, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Assign'", "Condition", "Assign'", "For", "Assign'", "Assign'", "For", "Assign'", "Assign'", "Assign'", "Condition", "Assign'", "Assign'", "Assign'", "Expr'", "Return'" ]
[ "def FUNC_14(self):...\n", "\"\"\"docstring\"\"\"\n", "VAR_21 = 'string'\n", "self.console.info(\"\"\"\nsos-collector (version %s)\n\"\"\" % __version__)\n", "VAR_22 = self._fmt_msg(VAR_21 % self.config['tmp_dir'])\n", "self.console.info(VAR_22)\n", "VAR_23 = \"\"\"\nPress ENTER to continue, or CTRL-C t...
[ "def prep(self):...\n", "\"\"\"docstring\"\"\"\n", "disclaimer = \"\"\"This utility is used to collect sosreports from multiple nodes simultaneously. It uses the python-paramiko library to manage the SSH connections to remote systems. If this library is not acceptable for use in your environment, you should not...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Docstring", "Assign'", "Expr'", "Assign'", "Expr'", "Assign'", "Condition", "Expr'", "Condition", "Expr'", "Condition", "Assign'", "Expr'", "Condition", "Expr'", "Assign'", "Condition", "Condition", "Assign'", "Expr'", "Condition", "Condition", "Conditi...
[ "def FUNC_0(self):...\n", "self.client = Client()\n" ]
[ "def setUp(self):...\n", "self.client = Client()\n" ]
[ 0, 0 ]
[ "FunctionDef'", "Assign'" ]
[ "def FUNC_19(self, VAR_6):...\n", "VAR_49 = self.nodes.get(VAR_6['name'])\n", "VAR_50 = []\n", "VAR_51 = []\n", "dep_resolve(VAR_49, VAR_50, VAR_51)\n", "for VAR_49 in VAR_50:\n", "self.logger.debug(\"node name '%s' vs. comp name '%s'\" % (VAR_49.comp_name,\n VAR_6['name']))\n", "self.logger.debug(...
[ "def start_component(self, comp):...\n", "node = self.nodes.get(comp['name'])\n", "res = []\n", "unres = []\n", "dep_resolve(node, res, unres)\n", "for node in res:\n", "self.logger.debug(\"node name '%s' vs. comp name '%s'\" % (node.comp_name,\n comp['name']))\n", "self.logger.debug(\"All dependen...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Assign'", "Assign'", "Expr'", "For", "Expr'", "Expr'", "Condition", "Assign'", "Expr'", "Condition", "Assign'", "Expr'", "Expr'", "Condition", "Return'", "Expr'", "Expr'", "Expr'", "Assign'", "Condition", "Expr'", "Assign'", "Condition", ...
[ "def FUNC_6(self, VAR_47):...\n", "if VAR_101.user_is_admin:\n", "return True\n", "if VAR_101.user_is_loggedin:\n", "VAR_18 = Thing._by_fullname(VAR_47, data=True)\n", "abort(403, 'forbidden')\n", "VAR_109 = VAR_18.subreddit_slow\n", "if VAR_109.is_special(VAR_101.user):\n", "return True\n" ]
[ "def run(self, thing_name):...\n", "if c.user_is_admin:\n", "return True\n", "if c.user_is_loggedin:\n", "item = Thing._by_fullname(thing_name, data=True)\n", "abort(403, 'forbidden')\n", "subreddit = item.subreddit_slow\n", "if subreddit.is_special(c.user):\n", "return True\n" ]
[ 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Condition", "Return'", "Condition", "Assign'", "Expr'", "Assign'", "Condition", "Return'" ]
[ "def FUNC_15(VAR_0):...\n", "\"\"\"docstring\"\"\"\n", "VAR_52 = VAR_0.GET.copy()\n", "VAR_12 = VAR_52.get('target', None)\n", "VAR_11 = VAR_52.get('p_ids', None)\n", "VAR_72 = VAR_52.get('sep', None)\n", "if VAR_12 and VAR_11 and VAR_72:\n", "VAR_11 = [k for k in VAR_11.split(VAR_72) if k]\n", "VAR...
[ "def get_prod_related_obj_json(request):...\n", "\"\"\"docstring\"\"\"\n", "data = request.GET.copy()\n", "target = data.get('target', None)\n", "p_pks = data.get('p_ids', None)\n", "sep = data.get('sep', None)\n", "if target and p_pks and sep:\n", "p_pks = [k for k in p_pks.split(sep) if k]\n", "re...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Docstring", "Assign'", "Assign'", "Assign'", "Assign'", "Condition", "Assign'", "Assign'", "Assign'", "Return'" ]
[ "def FUNC_18(self):...\n", "" ]
[ "def view_action(self):...\n", "" ]
[ 0, 0 ]
[ "FunctionDef'", "Condition" ]
[ "def FUNC_11(self, VAR_17):...\n", "\"\"\"docstring\"\"\"\n", "VAR_44 = 'confirmation', 'paging', 'events', 'formatoutput'\n", "VAR_0.error(_('Failed to setup the Dell EqualLogic driver'))\n", "for feature in VAR_44:\n", "self._eql_execute('cli-settings', feature, 'off')\n", "for line in self._eql_execu...
[ "def do_setup(self, context):...\n", "\"\"\"docstring\"\"\"\n", "disabled_cli_features = 'confirmation', 'paging', 'events', 'formatoutput'\n", "LOG.error(_('Failed to setup the Dell EqualLogic driver'))\n", "for feature in disabled_cli_features:\n", "self._eql_execute('cli-settings', feature, 'off')\n", ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Docstring", "Assign'", "Expr'", "For", "Expr'", "For", "Condition", "Expr'", "Assign'", "Assign'" ]
[ "def FUNC_7(self, VAR_12, VAR_13):...\n", "self._credentials[VAR_12] = VAR_13\n" ]
[ "def add_user(self, username, password):...\n", "self._credentials[username] = password\n" ]
[ 0, 0 ]
[ "FunctionDef'", "Assign'" ]
[ "def FUNC_4(self):...\n", "return MySQLdb\n" ]
[ "def dbapiModule(self):...\n", "return MySQLdb\n" ]
[ 0, 0 ]
[ "FunctionDef'", "Return'" ]
[ "def FUNC_2(self):...\n", "self.assertTrue({'name': 'DocType', 'issingle': 0} in DatabaseQuery(\n 'DocType').execute(fields=['name', 'issingle'], limit_page_length=None))\n" ]
[ "def test_fields(self):...\n", "self.assertTrue({'name': 'DocType', 'issingle': 0} in DatabaseQuery(\n 'DocType').execute(fields=['name', 'issingle'], limit_page_length=None))\n" ]
[ 0, 0 ]
[ "FunctionDef'", "Expr'" ]
[ "def FUNC_1(VAR_14, VAR_15=None):...\n", "VAR_13 = '{}/getUpdates?timeout={}'.format(VAR_1, VAR_14)\n", "if VAR_15:\n", "VAR_13 += '&offset={}'.format(VAR_15)\n", "return FUNC_0(VAR_13)\n" ]
[ "def get_updates(timeout, offset=None):...\n", "url = '{}/getUpdates?timeout={}'.format(base_url, timeout)\n", "if offset:\n", "url += '&offset={}'.format(offset)\n", "return get_json_from_url(url)\n" ]
[ 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Condition", "AugAssign'", "Return'" ]
[ "def FUNC_3(self):...\n", "GenericRequest._prepare(self)\n", "VAR_15, VAR_16 = tempfile.mkstemp()\n", "self.files = list(zip(self.submission_format, self.filenames)) + [('input',\n VAR_16)]\n" ]
[ "def _prepare(self):...\n", "GenericRequest._prepare(self)\n", "_, temp_filename = tempfile.mkstemp()\n", "self.files = list(zip(self.submission_format, self.filenames)) + [('input',\n temp_filename)]\n" ]
[ 0, 0, 0, 0 ]
[ "FunctionDef'", "Expr'", "Assign'", "Assign'" ]
[ "def FUNC_3(self):...\n", "self.objects.gt.code = 'HP'\n", "self.objects.gt.save()\n", "VAR_2, VAR_3 = create_detail_formset(self.objects.doc)\n", "VAR_4 = {'habits-TOTAL_FORMS': '2', 'habits-INITIAL_FORMS': '1',\n 'habits-MIN_NUM_FORMS': '0', 'habits-MAX_NUM_FORMS': '1000',\n 'habits-0-id': self.obje...
[ "def test_product_surveyed_field(self):...\n", "self.objects.gt.code = 'HP'\n", "self.objects.gt.save()\n", "_, HnPFormSet = create_detail_formset(self.objects.doc)\n", "data = {'habits-TOTAL_FORMS': '2', 'habits-INITIAL_FORMS': '1',\n 'habits-MIN_NUM_FORMS': '0', 'habits-MAX_NUM_FORMS': '1000',\n 'ha...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Expr'", "Assign'", "Assign'", "Assign'", "Expr'", "Assign'", "Assign'", "Expr'" ]
[ "@classmethod...\n", "\"\"\"docstring\"\"\"\n", "VAR_11 = request.args.get('virkningFra', None)\n", "VAR_12 = request.args.get('virkningTil', None)\n", "VAR_13 = request.args.get('registreretFra', None)\n", "VAR_14 = request.args.get('registreretTil', None)\n", "VAR_5 = request.args.get('uuid', None)\n"...
[ "@classmethod...\n", "\"\"\"docstring\"\"\"\n", "virkning_fra = request.args.get('virkningFra', None)\n", "virkning_til = request.args.get('virkningTil', None)\n", "registreret_fra = request.args.get('registreretFra', None)\n", "registreret_til = request.args.get('registreretTil', None)\n", "uuid = requ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "Condition", "Docstring", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Condition", "Assign'", "Assign'", "Assign'", "Condition", "Assign'", "Return'" ]
[ "from flask import Flask, render_template, redirect, session, url_for\n", "from database import conn, cursor\n", "VAR_0 = Flask(__name__)\n", "from views import users, message, comment, like_msg, like_cmt\n", "VAR_0.register_blueprint(users.mod)\n", "VAR_0.register_blueprint(VAR_5.mod)\n", "VAR_0.regist...
[ "from flask import Flask, render_template, redirect, session, url_for\n", "from database import conn, cursor\n", "app = Flask(__name__)\n", "from views import users, message, comment, like_msg, like_cmt\n", "app.register_blueprint(users.mod)\n", "app.register_blueprint(message.mod)\n", "app.register_blu...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 4, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0 ]
[ "ImportFrom'", "ImportFrom'", "Assign'", "ImportFrom'", "Expr'", "Expr'", "Expr'", "Expr'", "Expr'", "Condition", "Condition", "Return'", "Assign'", "Assign'", "Expr'", "Assign'", "Assign'", "For", "Assign'", "Return'", "Assign'", "Assign'", "Expr'", "Assign'", "Expr'...
[ "@frappe.whitelist()...\n", "\"\"\"docstring\"\"\"\n", "VAR_15 = date.today()\n", "VAR_11 = 'string' % VAR_15.isoformat()\n", "frappe.db.sql(VAR_11, auto_commit=True)\n", "print('Unexpected error setting first listed date.')\n" ]
[ "@frappe.whitelist()...\n", "\"\"\"docstring\"\"\"\n", "date_today = date.today()\n", "sql = (\n \"\"\"\n update `tabItem` it\n set it.on_sale_from_date = '%s'\n where it.on_sale_from_date is NULL\n and it.ebay_id REGEXP '^[0-9]+$';\n \"\"\"\n % date_today.isoformat())\n", "frappe.db.s...
[ 0, 0, 0, 4, 0, 0 ]
[ "Condition", "Docstring", "Assign'", "Assign'", "Expr'", "Expr'" ]
[ "def FUNC_51(self):...\n", "self.cursor.execute('create table t1(n int, s varchar(20))')\n", "self.cursor.execute(\"insert into t1 values (1, 'test1')\")\n", "self.cursor.execute(\"insert into t1 values (1, 'test2')\")\n", "VAR_29 = self.cursor.execute('select n, s from t1 order by s').fetchall()\n", "sel...
[ "def test_row_gtlt(self):...\n", "self.cursor.execute('create table t1(n int, s varchar(20))')\n", "self.cursor.execute(\"insert into t1 values (1, 'test1')\")\n", "self.cursor.execute(\"insert into t1 values (1, 'test2')\")\n", "rows = self.cursor.execute('select n, s from t1 order by s').fetchall()\n", ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Expr'", "Expr'", "Expr'", "Assign'", "Expr'", "Expr'", "Expr'", "Expr'", "Expr'", "Assign'", "Expr'" ]
[ "def FUNC_22(VAR_30, VAR_3):...\n", "if not isinstance(VAR_30, _IOFile):\n", "return IOFile(VAR_30, VAR_16=self)\n", "return VAR_30.apply_wildcards(VAR_3, fill_missing=f in self.dynamic_input,\n fail_dynamic=self.dynamic_output)\n" ]
[ "def concretize_iofile(f, wildcards):...\n", "if not isinstance(f, _IOFile):\n", "return IOFile(f, rule=self)\n", "return f.apply_wildcards(wildcards, fill_missing=f in self.dynamic_input,\n fail_dynamic=self.dynamic_output)\n" ]
[ 0, 0, 0, 0 ]
[ "FunctionDef'", "Condition", "Return'", "Return'" ]
[ "@utils.synchronized('3par', external=True)...\n", "self.common.client_login()\n", "VAR_19 = self.common.get_volume_stats(VAR_5)\n", "VAR_19['storage_protocol'] = 'iSCSI'\n", "VAR_20 = self.configuration.safe_get('volume_backend_name')\n", "VAR_19['volume_backend_name'] = VAR_20 or self.__class__.__name__...
[ "@utils.synchronized('3par', external=True)...\n", "self.common.client_login()\n", "stats = self.common.get_volume_stats(refresh)\n", "stats['storage_protocol'] = 'iSCSI'\n", "backend_name = self.configuration.safe_get('volume_backend_name')\n", "stats['volume_backend_name'] = backend_name or self.__class...
[ 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "Condition", "Expr'", "Assign'", "Assign'", "Assign'", "Assign'", "Expr'", "Return'" ]
[ "def FUNC_3(self, VAR_6, VAR_7):...\n", "self.model.reset()\n", "self.load_channels(1, 50)\n" ]
[ "def _on_view_sort(self, column, ascending):...\n", "self.model.reset()\n", "self.load_channels(1, 50)\n" ]
[ 0, 0, 0 ]
[ "FunctionDef'", "Expr'", "Expr'" ]
[ "def __init__(self, VAR_7, **VAR_8):...\n", "if 'user' not in VAR_8:\n", "if 'password' not in VAR_8:\n", "VAR_8['backend'] = 'IBMBackend'\n", "super().__init__(VAR_7, **kwargs)\n" ]
[ "def __init__(self, wires, **kwargs):...\n", "if 'user' not in kwargs:\n", "if 'password' not in kwargs:\n", "kwargs['backend'] = 'IBMBackend'\n", "super().__init__(wires, **kwargs)\n" ]
[ 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Condition", "Condition", "Assign'", "Expr'" ]
[ "@app.route('/api/server/devices/<name>/properties', methods=['GET'])...\n", "VAR_6 = controller.indi_server.device(VAR_5=name)\n", "return [p.to_map() for p in VAR_6.properties()]\n" ]
[ "@app.route('/api/server/devices/<name>/properties', methods=['GET'])...\n", "device = controller.indi_server.device(name=name)\n", "return [p.to_map() for p in device.properties()]\n" ]
[ 0, 0, 0 ]
[ "Condition", "Assign'", "Return'" ]
[ "import sys\n", "import logging\n", "import sqlalchemy as sa\n", "from . import filters\n", "from sqlalchemy.orm import joinedload\n", "from sqlalchemy.exc import IntegrityError\n", "from sqlalchemy import func\n", "from sqlalchemy.orm.properties import SynonymProperty\n", "from ..base import BaseIn...
[ "import sys\n", "import logging\n", "import sqlalchemy as sa\n", "from . import filters\n", "from sqlalchemy.orm import joinedload\n", "from sqlalchemy.exc import IntegrityError\n", "from sqlalchemy import func\n", "from sqlalchemy.orm.properties import SynonymProperty\n", "from ..base import BaseIn...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "Import'", "Import'", "Import'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "Assign'", "FunctionDef'", "For", "Condition", "Expr'", "Expr'", "Assign'", ...
[ "def FUNC_5(self, VAR_20=None, VAR_18=None, **VAR_3):...\n", "self.__execute(self.__prepare(VAR_20, VAR_18), VAR_3)\n" ]
[ "def execute(self, sql=None, filename=None, **kwargs):...\n", "self.__execute(self.__prepare(sql, filename), kwargs)\n" ]
[ 0, 0 ]
[ "FunctionDef'", "Expr'" ]
[ "import argparse, sys, tld\n", "import urllib.parse, os\n", "from files import config\n", "from core.colors import R, G\n", "from core.updater import updater\n", "VAR_0 = argparse.ArgumentParser('python3 xsrfprobe.py')\n", "VAR_0._action_groups.pop()\n", "VAR_1 = VAR_0.add_argument_group('Required Arg...
[ "import argparse, sys, tld\n", "import urllib.parse, os\n", "from files import config\n", "from core.colors import R, G\n", "from core.updater import updater\n", "parser = argparse.ArgumentParser('python3 xsrfprobe.py')\n", "parser._action_groups.pop()\n", "required = parser.add_argument_group('Requir...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5...
[ "Import'", "Import'", "ImportFrom'", "ImportFrom'", "ImportFrom'", "Assign'", "Expr'", "Assign'", "Assign'", "Expr'", "Expr'", "Expr'", "Expr'", "Expr'", "Expr'", "Expr'", "Expr'", "Expr'", "Expr'", "Expr'", "Expr'", "Expr'", "Expr'", "Expr'", "Expr'", "Expr'", "A...
[ "def FUNC_3(VAR_1):...\n", "\"\"\"docstring\"\"\"\n", "return db.engine.execute('string' + VAR_1 + \"';\")\n" ]
[ "def query_signed_intromember(member):...\n", "\"\"\"docstring\"\"\"\n", "return db.engine.execute(\n \"\"\"\n SELECT DISTINCT packet.freshman_username AS username, signature_fresh.signed AS signed FROM packet \n INNER JOIN signature_fresh ON packet.id = signature_fresh.packet_id \n ...
[ 0, 0, 4 ]
[ "FunctionDef'", "Docstring", "Return'" ]
[ "def FUNC_2(self, VAR_9, VAR_10):...\n", "\"\"\"docstring\"\"\"\n" ]
[ "def ensure_export(self, context, volume):...\n", "\"\"\"docstring\"\"\"\n" ]
[ 0, 0 ]
[ "FunctionDef'", "Docstring" ]
[ "def FUNC_15(VAR_38):...\n", "\"\"\"docstring\"\"\"\n", "if not VAR_38:\n", "return None\n", "if isinstance(VAR_38, basestring):\n", "for d in self.doc_types:\n", "if not any(d['name'] == VAR_38['name'] for d in VAR_27):\n", "if d['name'] == VAR_38:\n", "VAR_38 = VAR_38.copy()\n", "return VAR_38['...
[ "def add_doc_type(tp):...\n", "\"\"\"docstring\"\"\"\n", "if not tp:\n", "return None\n", "if isinstance(tp, basestring):\n", "for d in self.doc_types:\n", "if not any(d['name'] == tp['name'] for d in doc_types):\n", "if d['name'] == tp:\n", "tp = tp.copy()\n", "return tp['name']\n", "tp = d\n",...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Docstring", "Condition", "Return'", "Condition", "For", "For", "Condition", "Assign'", "Return'", "Assign'", "Assign'", "Expr'" ]
[ "def FUNC_6(self):...\n", "if not VAR_101.user_is_sponsor:\n", "abort(403, 'forbidden')\n" ]
[ "def run(self):...\n", "if not c.user_is_sponsor:\n", "abort(403, 'forbidden')\n" ]
[ 0, 0, 0 ]
[ "FunctionDef'", "Condition", "Expr'" ]
[ "def FUNC_0():...\n", "if 'DATABASE_URL' in os.environ and os.environ['DATABASE_URL']:\n", "urllib.parse.uses_netloc.append('postgres')\n", "VAR_12 = psycopg2.connect(database='expenses')\n", "VAR_18 = urllib.parse.urlparse(os.environ['DATABASE_URL'])\n", "return VAR_12\n", "VAR_12 = psycopg2.connect(da...
[ "def check_heroku_db():...\n", "if 'DATABASE_URL' in os.environ and os.environ['DATABASE_URL']:\n", "urllib.parse.uses_netloc.append('postgres')\n", "conn = psycopg2.connect(database='expenses')\n", "url = urllib.parse.urlparse(os.environ['DATABASE_URL'])\n", "return conn\n", "conn = psycopg2.connect(da...
[ 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Condition", "Expr'", "Assign'", "Assign'", "Return'", "Assign'", "Return'" ]
[ "@property...\n", "\"\"\"docstring\"\"\"\n", "return self._webui_url\n" ]
[ "@property...\n", "\"\"\"docstring\"\"\"\n", "return self._webui_url\n" ]
[ 0, 0, 0 ]
[ "Condition", "Docstring", "Return'" ]
[ "def __init__(self, VAR_1, VAR_4=None):...\n", "\"\"\"docstring\"\"\"\n", "super(CLASS_0, self).__init__(VAR_1, VAR_4)\n", "VAR_1 = self.bindings\n", "VAR_1['TEST_APP_COMPONENT_NAME'] = '{app}-{stack}-{detail}'.format(app=\n bindings['TEST_APP'], stack=bindings['TEST_STACK'], detail=bindings[\n 'TEST_...
[ "def __init__(self, bindings, agent=None):...\n", "\"\"\"docstring\"\"\"\n", "super(GoogleSmokeTestScenario, self).__init__(bindings, agent)\n", "bindings = self.bindings\n", "bindings['TEST_APP_COMPONENT_NAME'] = '{app}-{stack}-{detail}'.format(app=\n bindings['TEST_APP'], stack=bindings['TEST_STACK'], ...
[ 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Docstring", "Expr'", "Assign'", "Assign'", "Assign'" ]
[ "def FUNC_1(VAR_0, VAR_2, VAR_3, VAR_4, VAR_1):...\n", "\"\"\"docstring\"\"\"\n", "VAR_24 = False\n", "VAR_18 = sql.connect('./resources/users.db')\n", "VAR_20 = 'string'\n", "VAR_21 = VAR_18.cursor()\n", "print(''.join(traceback.format_exception(etype=type(e), value=e, tb=e.\n __traceback__)))\n", ...
[ "def add_user(username, firstname, lastname, bio, password):...\n", "\"\"\"docstring\"\"\"\n", "added = False\n", "con = sql.connect('./resources/users.db')\n", "cmd = \"\"\"INSERT INTO users (username, firstname, lastname, bio, password)\n VALUES (?, ?, ?, ?, ?);\n \"\"\"\n", "cur...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Docstring", "Assign'", "Assign'", "Assign'", "Assign'", "Expr'", "Expr'", "Expr'", "Expr'", "Return'", "Expr'", "Assign'", "Assign'" ]
[ "def FUNC_12(self, VAR_9):...\n", "if not self.logged_in():\n", "print('shrub: unauthenticated; use \"login [username] to log in first')\n", "VAR_20 = self.send_cmd('list_repo_issues{} {}'.format(self.insecure_mode,\n VAR_9))\n", "return\n", "print(VAR_20)\n" ]
[ "def do_list_repo_issues(self, line):...\n", "if not self.logged_in():\n", "print('shrub: unauthenticated; use \"login [username] to log in first')\n", "response = self.send_cmd('list_repo_issues{} {}'.format(self.insecure_mode,\n line))\n", "return\n", "print(response)\n" ]
[ 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Condition", "Expr'", "Assign'", "Return'", "Expr'" ]
[ "@VAR_0.route('/getSession')...\n", "if 'username' in VAR_19:\n", "return VAR_19['user']\n", "return 'No Session avalibale!'\n" ]
[ "@app.route('/getSession')...\n", "if 'username' in session:\n", "return session['user']\n", "return 'No Session avalibale!'\n" ]
[ 0, 0, 0, 0 ]
[ "Condition", "Condition", "Return'", "Return'" ]
[ "@login_required...\n", "\"\"\"docstring\"\"\"\n", "return render_to_response('student_account/account_settings.html', FUNC_11(\n VAR_3))\n" ]
[ "@login_required...\n", "\"\"\"docstring\"\"\"\n", "return render_to_response('student_account/account_settings.html',\n account_settings_context(request))\n" ]
[ 0, 0, 0 ]
[ "Condition", "Docstring", "Return'" ]
[ "def FUNC_1():...\n", "VAR_4 = VAR_6.get('modtokens', [])\n", "VAR_5 = None\n", "if len(VAR_4) < 100:\n", "VAR_5 = hashlib.sha1(str(random.random())).hexdigest()\n", "VAR_5 = VAR_4[-1]\n", "VAR_4.append(VAR_5)\n", "VAR_6['modtokens'] = VAR_4\n", "VAR_6.save()\n", "return VAR_5\n" ]
[ "def make_token():...\n", "tokens = session.get('modtokens', [])\n", "token = None\n", "if len(tokens) < 100:\n", "token = hashlib.sha1(str(random.random())).hexdigest()\n", "token = tokens[-1]\n", "tokens.append(token)\n", "session['modtokens'] = tokens\n", "session.save()\n", "return token\n" ]
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Assign'", "Condition", "Assign'", "Assign'", "Expr'", "Assign'", "Expr'", "Return'" ]
[ "def FUNC_7(*VAR_15, **VAR_16):...\n", "\"\"\"docstring\"\"\"\n", "return VAR_0(VAR_1, *VAR_15, **kwargs)\n" ]
[ "def new_object(*args, **kwargs):...\n", "\"\"\"docstring\"\"\"\n", "return cls(name, *args, **kwargs)\n" ]
[ 0, 0, 0 ]
[ "FunctionDef'", "Docstring", "Return'" ]
[ "import base64\n", "import collections\n", "import datetime\n", "import hmac\n", "import json\n", "import os\n", "import re\n", "import subprocess\n", "import time\n", "import psycopg2\n", "import requests\n", "import unidiff\n", "import yaml\n", "from flask import abort\n", "def FUNC_0(...
[ "import base64\n", "import collections\n", "import datetime\n", "import hmac\n", "import json\n", "import os\n", "import re\n", "import subprocess\n", "import time\n", "import psycopg2\n", "import requests\n", "import unidiff\n", "import yaml\n", "from flask import abort\n", "def update_...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "Import'", "Import'", "Import'", "Import'", "Import'", "Import'", "Import'", "Import'", "Import'", "Import'", "Import'", "Import'", "Import'", "ImportFrom'", "FunctionDef'", "Docstring", "Condition", "Assign'", "FunctionDef'", "Expr'", "Expr'", "Docstring", "Expr'", "As...
[ "def FUNC_2(self, VAR_7):...\n", "VAR_25 = ''\n", "VAR_26 = '%s> ' % self.configuration.eqlx_group_name\n", "while not VAR_25.endswith(VAR_26):\n", "VAR_25 += VAR_7.recv(102400)\n", "VAR_0.debug(_('CLI output\\n%s'), VAR_25)\n", "return VAR_25.splitlines()\n" ]
[ "def _get_output(self, chan):...\n", "out = ''\n", "ending = '%s> ' % self.configuration.eqlx_group_name\n", "while not out.endswith(ending):\n", "out += chan.recv(102400)\n", "LOG.debug(_('CLI output\\n%s'), out)\n", "return out.splitlines()\n" ]
[ 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Assign'", "Condition", "AugAssign'", "Expr'", "Return'" ]
[ "def FUNC_17(self):...\n", "VAR_7 = Pa11yCrawler('')\n", "VAR_7.generate_html_reports()\n", "self._mock_sh.assert_has_calls([call(\n 'pa11ycrawler json-to-html --pa11ycrawler-reports-dir={}'.format(VAR_7.\n pa11y_report_dir))])\n" ]
[ "def test_generate_html_reports(self):...\n", "suite = Pa11yCrawler('')\n", "suite.generate_html_reports()\n", "self._mock_sh.assert_has_calls([call(\n 'pa11ycrawler json-to-html --pa11ycrawler-reports-dir={}'.format(suite.\n pa11y_report_dir))])\n" ]
[ 0, 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Expr'", "Expr'" ]
[ "def FUNC_12():...\n", "\"\"\"docstring\"\"\"\n", "VAR_39 = VAR_40.environ.get('CUDA_VISIBLE_DEVICES', None)\n", "if VAR_39 is None:\n", "return None\n", "if VAR_39 == '':\n", "return []\n", "return [int(i) for i in VAR_39.split(',')]\n" ]
[ "def get_cuda_visible_devices():...\n", "\"\"\"docstring\"\"\"\n", "gpu_ids_str = os.environ.get('CUDA_VISIBLE_DEVICES', None)\n", "if gpu_ids_str is None:\n", "return None\n", "if gpu_ids_str == '':\n", "return []\n", "return [int(i) for i in gpu_ids_str.split(',')]\n" ]
[ 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Docstring", "Assign'", "Condition", "Return'", "Condition", "Return'", "Return'" ]
[ "def FUNC_4(VAR_0, VAR_3):...\n", "VAR_4 = VAR_0.cursor()\n", "VAR_5 = 'ALTER TABLE Presets DROP COLUMN id;'\n", "VAR_4.execute(VAR_5)\n", "VAR_5 = (\n 'ALTER TABLE Presets ADD COLUMN id INT AUTO_INCREMENT PRIMARY KEY NOT NULL FIRST;'\n )\n", "VAR_4.execute(VAR_5)\n", "VAR_6 = Table('Presets')\n",...
[ "def get_descriptin(conn, key):...\n", "cursor = conn.cursor()\n", "quer = 'ALTER TABLE Presets DROP COLUMN id;'\n", "cursor.execute(quer)\n", "quer = (\n 'ALTER TABLE Presets ADD COLUMN id INT AUTO_INCREMENT PRIMARY KEY NOT NULL FIRST;'\n )\n", "cursor.execute(quer)\n", "extable = Table('Presets'...
[ 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Assign'", "Expr'", "Assign'", "Expr'", "Assign'", "Assign'", "Expr'", "Assign'", "Expr'", "Assign'", "Assign'", "Return'" ]
[ "def FUNC_30(self):...\n", "VAR_0 = [SleepCheck(1), SleepCheck(1), SleepCheck(1),\n KeyboardInterruptCheck(phase='setup')]\n", "self._run_checks(VAR_0, 2)\n" ]
[ "def test_kbd_interrupt_in_setup_with_limited_concurrency(self):...\n", "checks = [SleepCheck(1), SleepCheck(1), SleepCheck(1),\n KeyboardInterruptCheck(phase='setup')]\n", "self._run_checks(checks, 2)\n" ]
[ 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Expr'" ]
[ "def FUNC_3(self, VAR_3, VAR_6, VAR_7):...\n", "VAR_14 = 0\n", "VAR_15 = 1\n", "VAR_16 = 2\n", "VAR_17 = 3\n", "VAR_18 = 4\n", "VAR_8 = \"SELECT * FROM ranks WHERE scene = '{}' AND date='{}';\".format(str(\n VAR_3), VAR_7)\n", "VAR_11 = self.db.exec(VAR_8)\n", "if len(VAR_11) > 0:\n", "VAR_0.in...
[ "def process_ranks(self, scene, urls, recent_date):...\n", "PLAYER1 = 0\n", "PLAYER2 = 1\n", "WINNER = 2\n", "DATE = 3\n", "SCENE = 4\n", "sql = \"SELECT * FROM ranks WHERE scene = '{}' AND date='{}';\".format(str(\n scene), recent_date)\n", "res = self.db.exec(sql)\n", "if len(res) > 0:\n", "L...
[ 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "Condition", "Expr'", "Assign'", "Return'", "Expr'", "Assign'", "For", "Assign'", "Assign'", "Assign'", "Assign'", "Assign'", "For", "Assign'", "Assign'", "Expr'", "Condition"...
[ "\"\"\"string\"\"\"\n", "import cookielib\n", "import logging\n", "import os\n", "import re\n", "import signal\n", "import socket\n", "import subprocess\n", "import tempfile\n", "import time\n", "import sys\n", "import urllib\n", "import urllib2\n", "VAR_0 = os.path.dirname(os.path.abspath...
[ "\"\"\"Setups a local GAE instance to test against a live server for integration\ntests.\n\nIt makes sure Google AppEngine SDK is found and starts the server on a free\ninbound TCP port.\n\"\"\"\n", "import cookielib\n", "import logging\n", "import os\n", "import re\n", "import signal\n", "import socket...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 0, 0, 0, 0, 0 ]
[ "Expr'", "Import'", "Import'", "Import'", "Import'", "Import'", "Import'", "Import'", "Import'", "Import'", "Import'", "Import'", "Import'", "Assign'", "Assign'", "FunctionDef'", "Docstring", "Condition", "Return'", "Assign'", "Condition", "Condition", "Assign'", "Assig...
[ "def FUNC_3(VAR_2):...\n", "if not VAR_2:\n", "return []\n", "VAR_9 = []\n", "VAR_10 = frappe.db.get_value('Department', {'name': VAR_2}, ['lft', 'rgt'],\n as_dict=True)\n", "VAR_11 = frappe.db.sql(\n \"\"\"select name from `tabDepartment`\n\t\twhere lft >= %s and rgt <= %s order by lft desc\n\t\t\"...
[ "def get_approvers(department):...\n", "if not department:\n", "return []\n", "approvers = []\n", "department_details = frappe.db.get_value('Department', {'name': department},\n ['lft', 'rgt'], as_dict=True)\n", "department_list = frappe.db.sql(\n \"\"\"select name from `tabDepartment`\n\t\twhere lf...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Condition", "Return'", "Assign'", "Assign'", "Assign'", "For", "Expr'", "Return'" ]
[ "def FUNC_1(self):...\n", "VAR_15 = '/usr/bin/tmsh save sys config'\n", "VAR_16 = shellutil.run(VAR_15)\n", "if VAR_16 != 0:\n", "logger.error('WARNING: Cannot save sys config on 1st boot.')\n", "return VAR_16\n" ]
[ "def _save_sys_config(self):...\n", "cmd = '/usr/bin/tmsh save sys config'\n", "rc = shellutil.run(cmd)\n", "if rc != 0:\n", "logger.error('WARNING: Cannot save sys config on 1st boot.')\n", "return rc\n" ]
[ 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Assign'", "Condition", "Expr'", "Return'" ]
[ "def FUNC_1(self):...\n", "\"\"\"docstring\"\"\"\n", "VAR_11 = VAR_0[:]\n", "if self.user is not None:\n", "VAR_11.append((Allow, self.user.login, ('view', 'view.file')))\n", "return VAR_11\n" ]
[ "def get_userdatas_acl(self):...\n", "\"\"\"docstring\"\"\"\n", "acl = DEFAULT_PERM[:]\n", "if self.user is not None:\n", "acl.append((Allow, self.user.login, ('view', 'view.file')))\n", "return acl\n" ]
[ 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Docstring", "Assign'", "Condition", "Expr'", "Return'" ]
[ "def FUNC_0(VAR_3):...\n", "VAR_3 = FUNC_1(VAR_3)\n", "VAR_4 = (\n 'SELECT barnivore_product_name, barnivore_status, barnivore_country ' +\n 'FROM barnivore_product ' +\n \"WHERE lower(barnivore_product_name) like lower('% \\\\%s %')\")\n", "VAR_1 = psycopg2.connect(VAR_0)\n", "print('Error %s' % e...
[ "def getAlcoholByName(name):...\n", "name = fixTypingErrors(name)\n", "QUERY = (\n 'SELECT barnivore_product_name, barnivore_status, barnivore_country ' +\n 'FROM barnivore_product ' +\n \"WHERE lower(barnivore_product_name) like lower('% \\\\%s %')\")\n", "conn = psycopg2.connect(connectionString)\n...
[ 0, 0, 4, 0, 0, 0, 0, 0, 0, 4, 0 ]
[ "FunctionDef'", "Assign'", "Assign'", "Assign'", "Expr'", "Condition", "Return'", "Assign'", "Expr'", "Expr'", "Assign'" ]
[ "def __getattribute__(self, VAR_3):...\n", "\"\"\"docstring\"\"\"\n", "abort_thread()\n", "if VAR_3 == 'write':\n", "return self.write_both\n", "if VAR_3 == 'close':\n", "return super(CLASS_0, self).__getattribute__(VAR_3)\n", "VAR_5 = super(CLASS_0, self).__getattribute__('redirection_source')\n", ...
[ "def __getattribute__(self, item):...\n", "\"\"\"docstring\"\"\"\n", "abort_thread()\n", "if item == 'write':\n", "return self.write_both\n", "if item == 'close':\n", "return super(RedirectBuffer, self).__getattribute__(item)\n", "source = super(RedirectBuffer, self).__getattribute__('redirection_sour...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Docstring", "Expr'", "Condition", "Return'", "Condition", "Return'", "Assign'", "Condition", "Return'", "Return'" ]
[ "def FUNC_13(self):...\n", "VAR_19 = list(filter(lambda VAR_28: VAR_28.protected, self.expanded_output))\n", "if VAR_19:\n" ]
[ "def check_protected_output(self):...\n", "protected = list(filter(lambda f: f.protected, self.expanded_output))\n", "if protected:\n" ]
[ 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Condition" ]
[ "@VAR_0.route('/email/unsubscribe/', defaults={'email': None}, methods=[...\n", "VAR_12 = True\n", "if not request.form.get('email') == None:\n", "VAR_6 = request.form.get('email')\n", "if VAR_6 == None:\n", "VAR_7 = 'You need to enter your email address to unsubscribe'\n", "VAR_17 = User.query.filter_b...
[ "@app.route('/email/unsubscribe/', defaults={'email': None}, methods=['GET',...\n", "show_form = True\n", "if not request.form.get('email') == None:\n", "email = request.form.get('email')\n", "if email == None:\n", "msg = 'You need to enter your email address to unsubscribe'\n", "results = User.query.fi...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ]
[ "Condition", "Assign'", "For", "Assign'", "Condition", "Assign'", "Assign'", "Return'", "Condition", "Assign'", "Assign'", "Assign'", "Expr'", "Assign'" ]
[ "def __init__(self):...\n", "" ]
[ "def __init__(self):...\n", "" ]
[ 0, 0 ]
[ "FunctionDef'", "Condition" ]
[ "def FUNC_7(VAR_7, VAR_8):...\n", "VAR_4 = input(FUNC_3(VAR_7, VAR_2='blue'))\n", "if int(VAR_4) > VAR_8 or int(VAR_4) < 0:\n", "print(FUNC_3('out of range!', VAR_2='red'))\n", "return int(VAR_4)\n", "FUNC_7(VAR_7, VAR_8)\n" ]
[ "def selection(hint, range):...\n", "index = input(rainbow(hint, color='blue'))\n", "if int(index) > range or int(index) < 0:\n", "print(rainbow('out of range!', color='red'))\n", "return int(index)\n", "selection(hint, range)\n" ]
[ 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Condition", "Expr'", "Return'", "Expr'" ]
[ "def FUNC_3(self, VAR_9):...\n", "if not users.get_current_user():\n", "self.redirect(users.create_login_url(self.request.url))\n", "if not users.is_current_user_admin():\n", "return\n", "self.response.set_status(403)\n", "VAR_0[VAR_9](self).get()\n", "return\n" ]
[ "def get(self, command):...\n", "if not users.get_current_user():\n", "self.redirect(users.create_login_url(self.request.url))\n", "if not users.is_current_user_admin():\n", "return\n", "self.response.set_status(403)\n", "commands[command](self).get()\n", "return\n" ]
[ 0, 5, 5, 5, 0, 0, 0, 0 ]
[ "FunctionDef'", "Condition", "Expr'", "Condition", "Return'", "Expr'", "Expr'", "Return'" ]
[ "def FUNC_14(self, VAR_15):...\n", "self.username = VAR_15\n" ]
[ "def setUsername(self, username):...\n", "self.username = username\n" ]
[ 0, 0 ]
[ "FunctionDef'", "Assign'" ]
[ "def FUNC_2(VAR_0, VAR_1, VAR_2):...\n", "VAR_9 = {'class': DT, 'results': {start_url: [{'endpoint': VAR_0, 'params':\n VAR_1, 'method': VAR_2}]}}\n", "VAR_4 = ''\n", "if VAR_2 == 'GET':\n", "VAR_4 = FUNC_0(VAR_0, VAR_1)\n", "return VAR_9, VAR_4\n" ]
[ "def genDT(endpoint, params, method):...\n", "scope = {'class': DT, 'results': {start_url: [{'endpoint': endpoint,\n 'params': params, 'method': method}]}}\n", "script = ''\n", "if method == 'GET':\n", "script = createGetScript(endpoint, params)\n", "return scope, script\n" ]
[ 0, 0, 0, 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Assign'", "Condition", "Assign'", "Return'" ]
[ "def FUNC_4(self, **VAR_6):...\n", "VAR_14 = super().get_context_data(**kwargs)\n", "return VAR_14\n" ]
[ "def get_context_data(self, **kwargs):...\n", "context = super().get_context_data(**kwargs)\n", "return context\n" ]
[ 0, 0, 0 ]
[ "FunctionDef'", "Assign'", "Return'" ]
[ "def FUNC_15(self, VAR_17, VAR_18):...\n", "if VAR_6 in VAR_18.bookmarks:\n", "VAR_29 = ((x, None) if x not in VAR_17.collections else (x, VAR_17.\n collections[x]) for x in VAR_17.parameters.keys())\n", "self._store.append(dict(VAR_29))\n" ]
[ "def test(self, pathctx, levelctx):...\n", "if bookmark in levelctx.bookmarks:\n", "found = ((x, None) if x not in pathctx.collections else (x, pathctx.\n collections[x]) for x in pathctx.parameters.keys())\n", "self._store.append(dict(found))\n" ]
[ 0, 0, 0, 0 ]
[ "FunctionDef'", "Condition", "Assign'", "Expr'" ]
[ "def FUNC_19(self, VAR_3=None):...\n", "if not VAR_3:\n", "VAR_3 = self.make_reqid()\n", "return b'Router', b'auth-clear', [], VAR_3\n" ]
[ "def make_auth_clear_data(self, reqid=None):...\n", "if not reqid:\n", "reqid = self.make_reqid()\n", "return b'Router', b'auth-clear', [], reqid\n" ]
[ 0, 0, 0, 0 ]
[ "FunctionDef'", "Condition", "Assign'", "Return'" ]
[ "def FUNC_21(VAR_16):...\n", "return (VAR_16.input, VAR_16.dynamic_input) if VAR_4 else (VAR_16.output,\n VAR_16.dynamic_output)\n" ]
[ "def get_io(rule):...\n", "return (rule.input, rule.dynamic_input) if input else (rule.output, rule.\n dynamic_output)\n" ]
[ 0, 0 ]
[ "FunctionDef'", "Return'" ]
[ "def FUNC_9(VAR_17):...\n", "if os.path.isfile(VAR_17):\n", "os.remove(VAR_17)\n" ]
[ "def clear_log(file_path):...\n", "if os.path.isfile(file_path):\n", "os.remove(file_path)\n" ]
[ 0, 0, 0 ]
[ "FunctionDef'", "Condition", "Expr'" ]