messages
listlengths
2
2
language
stringclasses
8 values
prompt_type
stringclasses
2 values
lint_errors
int64
0
129
⌀
cyclomatic_complexity
int64
0
32
⌀
license
stringclasses
7 values
commit
stringlengths
40
40
repos
stringlengths
5
116k
new_file
stringlengths
4
220
status
stringclasses
6 values
error
stringlengths
26
74
⌀
is_valid_syntax
bool
2 classes
[ { "role": "user", "content": "Write python code for the following: Add a small driver for plotting skeletons." }, { "role": "assistant", "content": "#!/usr/bin/env python\n\nimport climate\n\nimport database\nimport plots\n\n\n@climate.annotate(\n root='plot data rooted at this path',\n pa...
python
new_file
1
2
mit
f0da1774514c839b4b97fa92d2202437932dc99a
lmjohns3/cube-experiment,lmjohns3/cube-experiment,lmjohns3/cube-experiment
analysis/plot-skeleton.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n\n\nfrom rdflib.graph import ConjunctiveGraph\nimport unittest\n\nclass TestTrixParse(unittest.TestCase):\n\n def setUp(self):\n pass\n\n def tearDown(self):\n pass\n\n def testAperture(self): \...
python
edit
1
1
bsd-3-clause
2c900f8bddc9efb40d900bf28f8c6b3188add71e
RDFLib/rdflib,avorio/rdflib,yingerj/rdflib,ssssam/rdflib,ssssam/rdflib,marma/rdflib,armandobs14/rdflib,armandobs14/rdflib,dbs/rdflib,dbs/rdflib,RDFLib/rdflib,marma/rdflib,RDFLib/rdflib,yingerj/rdflib,avorio/rdflib,ssssam/rdflib,armandobs14/rdflib,RDFLib/rdflib,dbs/rdflib,marma/rdflib,marma/rdflib,ssssam/rdflib,armandob...
test/test_trix_parse.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport commands.cmds as cmds\n\ndef handle(self, chat_raw):\n self.logger.info(\"Handling command: \" + chat_raw + \" (for player\" + self.fquid + \")\")\n _atmp1 = chat_raw.split(\" \")\n _atmp2 = list(_atmp1[0])\n del _atmp2[0...
python
edit
1
2
mit
2b380d501b80afad8c7c5ec27537bcc682ed2775
TiberiumPY/puremine,Armored-Dragon/pymineserver
commands/handle.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add a utility script to print duplicates" }, { "role": "assistant", "content": "#!/usr/bin/env python3\n\nimport json\nimport os\nimport random\n\nscriptpath = os.path.dirname(__file__)\ndata_dir = os.path.join(scriptpath, 'data'...
python
new_file
3
0
mit
550d8bcd49e5ec591286f3f42de7dd54ef853bb8
mubaris/motivate,mubaris/motivate
find_dupes.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add VCF -> non-reference likelihood table script." }, { "role": "assistant", "content": "from __future__ import print_function\nimport sys\nimport cyvcf\nfrom argparse import ArgumentParser, FileType\nimport toolz as tz\n\ndescri...
python
new_file
1
0
mit
24b8437003269ebd10c46d0fbdaa3e432d7535d6
roryk/junkdrawer,roryk/junkdrawer
genotype-likelihoods.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Implement function for displaying tuning guidance on a DIY 8-segment LEDs display" }, { "role": "assistant", "content": "import math\nfrom gpiozero import LED\nfrom time import sleep\n\n\ng0 = LED(12)\nf0 = LED(16)\na0 = LED(20)\...
python
new_file
4
3
mit
0970115f9bc1bab019c23ab46e64b26d5e754313
Bastien-Brd/pi-tuner
led_display.py
rejected_lint
Too many lint violations: 4
true
[ { "role": "user", "content": "Write python code for the following: Add the answer to the sixth question of Assignment 3" }, { "role": "assistant", "content": "\"\"\" Q6- Write a program that counts up the number of vowels contained in the string s. Valid vowels are: 'a', 'e', 'i',\n'o', and 'u'....
python
new_file
1
5
mit
a635a8d58e46cf4ef1bc225f8824d73984971fee
SuyashD95/python-assignments
countVowels.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\nfrom pymisp import PyMISP\nfrom keys import misp_url, misp_key, misp_verifycert\nimport argparse\nimport tools\n\ndef init(url, key):\n return PyMISP(url, key, misp_verifycert, 'json')\n\...
python
edit
1
0
bsd-2-clause
836845abde53ee55bca93f098ece78880ab6b5c6
pombredanne/PyMISP,iglocska/PyMISP
examples/events/create_massive_dummy_events.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add a sequence module for optimizing gating\n\n--CAR" }, { "role": "assistant", "content": "\"\"\"\nSequences for optimizing gating timing.\n\"\"\"\nfrom ..PulsePrimitives import *\nfrom ..Compiler import compile_to_hardware\n\nd...
python
new_file
13
2
apache-2.0
501c38ac9e8b9fbb35b64321e103a0dfe064e718
calebjordan/PyQLab,Plourde-Research-Lab/PyQLab,BBN-Q/PyQLab,rmcgurrin/PyQLab
QGL/BasicSequences/BlankingSweeps.py
rejected_lint
Too many lint violations: 13
true
[ { "role": "user", "content": "Write python code for the following: Add MOBIB Basic reader script" }, { "role": "assistant", "content": "#!/bin/env python3\n\nimport sys\n\nfrom smartcard.System import readers\n\nCALYPSO_CLA = [0x94]\nSELECT_INS = [0xA4]\nREAD_RECORD_INS = [0xB2]\nGET_RESPONSE_IN...
python
new_file
4
6
mit
163da52a48eb0d84cde47f7cfe99e1188350db47
bparmentier/mobib-reader
mobib_basic.py
rejected_lint
Too many lint violations: 4
true
[ { "role": "user", "content": "Write python code for the following: Test we can approve Flutterwave bank accounts" }, { "role": "assistant", "content": "from bluebottle.files.tests.factories import PrivateDocumentFactory\nfrom bluebottle.funding.tests.factories import FundingFactory, PlainPayoutA...
python
new_file
1
1
bsd-3-clause
f0392ebda49fa0222a3b317f50002d7e03659f47
onepercentclub/bluebottle,onepercentclub/bluebottle,onepercentclub/bluebottle,onepercentclub/bluebottle,onepercentclub/bluebottle
bluebottle/funding_flutterwave/tests/test_states.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Copy paste artist from filename1 to filename2\n\nUtility to help consolidate groups of mp3s while preserving metadata in their filenames" }, { "role": "assistant", "content": "# Extract the artist name from songs with filenames i...
python
new_file
3
2
mit
92f799d0584b598f368df44201446531dffd7d13
daveinnyc/various,daveinnyc/various,daveinnyc/various,daveinnyc/various,daveinnyc/various,daveinnyc/various,daveinnyc/various
python/utilities/transform_mp3_filenames.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add test to ensure no mutable default arguments" }, { "role": "assistant", "content": "import importlib\nimport inspect\nimport pkgutil\nimport types\n\nimport six\nimport unittest\n\nimport chainer\nfrom chainer import testing\n...
python
new_file
1
8
mit
3d18f6e3ba3519422aa30bd25f3511f62361d5ca
wkentaro/chainer,niboshi/chainer,chainer/chainer,niboshi/chainer,wkentaro/chainer,pfnet/chainer,niboshi/chainer,hvy/chainer,wkentaro/chainer,chainer/chainer,okuta/chainer,wkentaro/chainer,okuta/chainer,okuta/chainer,chainer/chainer,chainer/chainer,hvy/chainer,niboshi/chainer,hvy/chainer,okuta/chainer,hvy/chainer
tests/chainer_tests/test_chainer_objects.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add script to list objects" }, { "role": "assistant", "content": "#!/usr/bin/env python\n\nimport os.path as osp\n\nimport rospkg\n\n\nPKG_PATH = rospkg.RosPack().get_path('jsk_arc2017_common')\n\nobject_names = ['__background__'...
python
new_file
1
0
bsd-3-clause
58e0ea4b555cf89ace4f5d97c579dbba905e7eeb
pazeshun/jsk_apc,pazeshun/jsk_apc,pazeshun/jsk_apc,pazeshun/jsk_apc,pazeshun/jsk_apc
jsk_arc2017_common/scripts/list_objects.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: feat: Add a script which use the iterative parsing to process the map file and find out not only what tags are there, but also how many, to get the feeling on how much of which data you can expect to have in the map." }, { "role": "a...
python
new_file
1
3
mit
4fe4cad49367b462c2201b98cce4382bff3a0206
aguijarro/DataSciencePython
DataWrangling/CaseStudy/mapparser.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add in team id spider" }, { "role": "assistant", "content": "import scrapy\n\nclass TeamSpider(scrapy.Spider):\n\tname = \"team\"\n\tstart_urls = [\n\t\t'http://www.espn.com/mens-college-basketball/teams',\n\t]\n\n\tdef parse(sel...
python
new_file
1
3
mit
dcca93fbb66e5cd8bf0e0500aca3f187922e8806
danmoeller/ncaa-bball-attendance,danmoeller/ncaa-bball-attendance,danmoeller/ncaa-bball-attendance
scrapy_espn/scrapy_espn/spiders/team_spider.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Move log related functions over to this file\n\nMeant for global use in SpicyTwitch" }, { "role": "assistant", "content": "# Imports-----------------------------------------------------------------------\nimport logging\nimport o...
python
new_file
1
3
mit
fcb07c7cd94f96cd533c55d18a657673f9eeac7f
NekoGamiYuki/SpicyTwitch
SpicyTwitch/Log_tools.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add simple unit tests to validate all configs\n\nSummary: Add simple unit tests to validate all configs: as demonstrated by the previous diff, this can not hurt :)\n\nReviewed By: vkhalidov\n\nDifferential Revision: D20491383\n\nfbshipit-sou...
python
new_file
1
4
apache-2.0
4061e5db7097a680405282e371ab3bf07758648a
facebookresearch/detectron2,facebookresearch/detectron2,facebookresearch/detectron2
projects/DensePose/tests/test_setup.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add functional test for cluster check recover\n\nChange-Id: Icb4ef7f754ba3b5764cf8f6d8f5999f0e2d2f3c2" }, { "role": "assistant", "content": "# Licensed under the Apache License, Version 2.0 (the \"License\"); you may\n# not use t...
python
new_file
1
1
apache-2.0
458cf526a4ebb72b4fad84e8cd2b665e0f093c1b
openstack/senlin,openstack/senlin,tengqm/senlin-container,openstack/senlin,stackforge/senlin,stackforge/senlin,tengqm/senlin-container
senlin/tests/functional/test_cluster_health.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add Fibonacci Series Using Recursion" }, { "role": "assistant", "content": "# Fibonacci Sequence Using Recursion\n\ndef recur_fibo(n):\n if n <= 1:\n return n\n else:\n return(recur_fibo(n-1) + recur_fibo(n-2))\n ...
python
new_file
1
2
mit
8fb4df5367b5c03d2851532063f6fa781fe2f980
TheAlgorithms/Python
Maths/fibonacciSeries.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add partial simple greedy algorithm (baseline)." }, { "role": "assistant", "content": "import networkx as nx\r\nfrom sys import argv\r\n\r\ndef main():\r\n # G = nx.read_gml(argv[1])\r\n G = nx.read_gml(\"steiner-small.gml\")\r...
python
new_file
5
10
mit
48c008b4ac08114e30f4bee7a208d5d3fb925296
karulont/combopt
problem1/steiner-simplegreedy.py
rejected_lint
Too many lint violations: 5
true
[ { "role": "user", "content": "Write python code for the following: Add tests for language api" }, { "role": "assistant", "content": "import json\nfrom server.tests.helpers import FlaskTestCase, fixtures\n\n\nclass TestLanguageAPI(FlaskTestCase):\n\n @fixtures('base.json')\n def test_get_em...
python
new_file
4
1
mit
e07c699caf699852c98b3396150b343553a386c4
ganemone/ontheside,ganemone/ontheside,ganemone/ontheside
server/tests/api/test_language_api.py
rejected_lint
Too many lint violations: 4
true
[ { "role": "user", "content": "Write python code for the following: Implement ArgumentSelector for overload disambiguation" }, { "role": "assistant", "content": "import collections\nimport copy\n\nfrom thinglang.compiler.errors import NoMatchingOverload\nfrom thinglang.lexer.values.identifier imp...
python
new_file
1
5
mit
de38b3e7b3d8458920b913316b06bb10b886df9f
ytanay/thinglang,ytanay/thinglang,ytanay/thinglang,ytanay/thinglang
thinglang/symbols/argument_selector.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Solve the most wanted letter problem." }, { "role": "assistant", "content": "def checkio(word):\n word = word.lower()\n arr = dict()\n for i in range(len(word)):\n char = word[i]\n if not str.isalpha(char):...
python
new_file
1
8
mit
084ebff19703c42c50621eb94ac070c6a471e983
edwardzhu/checkio-solution
Home/mostWantedLetter.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add utils for graph visualization." }, { "role": "assistant", "content": "#!/usr/bin/env python\n\nimport itertools\nimport os\nimport tempfile\n\nimport conn\nimport matplotlib.pyplot as plt\nimport networkx as nx\n\ndef imdisp(...
python
new_file
9
11
bsd-3-clause
ac823e61fd214f9818bb7a893a8ed52a3bfa3af4
cerrno/neurokernel
neurokernel/conn_utils.py
rejected_lint
Too many lint violations: 9
true
[ { "role": "user", "content": "Write python code for the following: Add a coupld tests to create exception classes from error code names" }, { "role": "assistant", "content": "# Copyright (c) 2014 Amazon.com, Inc. or its affiliates.\n# All Rights Reserved\n#\n# Permission is hereby granted, free ...
python
new_file
1
1
mit
dd1d0893823561efec203cdfbb927b8edac7a72a
darjus-amzn/boto,Asana/boto,vishnugonela/boto,podhmo/boto,weebygames/boto,SaranyaKarthikeyan/boto,clouddocx/boto,bleib1dj/boto,TiVoMaker/boto,tpodowd/boto,rayluo/boto,tpodowd/boto,disruptek/boto,stevenbrichards/boto,revmischa/boto,pfhayes/boto,ekalosak/boto,ryansb/boto,shaunbrady/boto,acourtney2015/boto,alfredodeza/bot...
tests/unit/beanstalk/test_exception.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add a proper unit test for xreload.py." }, { "role": "assistant", "content": "\"\"\"Doctests for module reloading.\n\n>>> from xreload import xreload\n>>> from test.test_xreload import make_mod\n>>> make_mod()\n>>> import x\n>>> ...
python
new_file
3
5
mit
97ae80b08958646e0c937f65a1b396171bf61e72
sk-/python2.7-type-annotator,sk-/python2.7-type-annotator,sk-/python2.7-type-annotator
Lib/test/test_xreload.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add Python-based opcode enum parser" }, { "role": "assistant", "content": "import os\n\nimport re\n\nBASE_DIR = os.path.dirname(os.path.abspath(__file__))\nENUM_PARSER = re.compile(r'(.*)\\s*?=\\s*?(\\d+)')\n\ndef read_opcodes():...
python
new_file
1
6
mit
4d16ae6d1ad8b308c14c23e802349001b81ae461
ytanay/thinglang,ytanay/thinglang,ytanay/thinglang,ytanay/thinglang
thinglang/compiler/opcodes.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: auth: Add abstract class for HAP channels\n\nRelates to #1255" }, { "role": "assistant", "content": "\"\"\"Base class for HAP based channels (connections).\"\"\"\nfrom abc import ABC, abstractmethod\nimport asyncio\nimport loggin...
python
new_file
1
1
mit
eb71a3d3319480b3f99cb44f934a51bfb1b5bd67
postlund/pyatv,postlund/pyatv
pyatv/auth/hap_channel.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport sys\nimport re\nimport vim\n\nfrom tasklib.task import TaskWarrior, Task\n\n# Insert the taskwiki on the python path\nsys.path.insert(0, vim.eval(\"s:plugin_path\") + '/taskwiki')\n\nfrom regexp import *\nfrom task import VimwikiTask...
python
edit
6
1
mit
90d079928eaf48e370d21417e4d6e649ec0f5f6f
phha/taskwiki,Spirotot/taskwiki
taskwiki/taskwiki.py
rejected_lint
Too many lint violations: 6
true
[ { "role": "user", "content": "Write python code for the following: Add Classical multidimensional scaling algorithm." }, { "role": "assistant", "content": "\"\"\"\nSimple implementation of classical MDS.\nSee http://www.stat.cmu.edu/~ryantibs/datamining/lectures/09-dim3-marked.pdf for more detai...
python
new_file
2
5
mit
2d320058c96f88348d8226fa4a827a6c2c973237
ntduong/ML
mds.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add `OrganizationOption` tests based on `ProjectOption`." }, { "role": "assistant", "content": "# -*- coding: utf-8 -*-\n\nfrom __future__ import absolute_import\n\nfrom sentry.models import OrganizationOption\nfrom sentry.testut...
python
new_file
1
1
bsd-3-clause
eb91b11930319369bc9cfc3b1b15c0b92fb4d85c
JamesMura/sentry,gencer/sentry,nicholasserra/sentry,gencer/sentry,fotinakis/sentry,looker/sentry,JackDanger/sentry,gencer/sentry,looker/sentry,fotinakis/sentry,looker/sentry,jean/sentry,daevaorn/sentry,ifduyue/sentry,beeftornado/sentry,zenefits/sentry,alexm92/sentry,mvaled/sentry,mitsuhiko/sentry,nicholasserra/sentry,z...
tests/sentry/models/test_organizationoption.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add command to dump and restore user pointers.\n\nFor use in database migrations.\n\n(imported from commit f06ae569fe986da5e7d144c277bf27be534c04f9)" }, { "role": "assistant", "content": "from optparse import make_option\nfrom dj...
python
new_file
2
3
apache-2.0
a086307e6aac341ed8a6596d0a05b7a8d198c7ec
brainwane/zulip,dwrpayne/zulip,dotcool/zulip,nicholasbs/zulip,ikasumiwt/zulip,DazWorrall/zulip,xuanhan863/zulip,tdr130/zulip,alliejones/zulip,brainwane/zulip,vabs22/zulip,Qgap/zulip,DazWorrall/zulip,souravbadami/zulip,developerfm/zulip,mdavid/zulip,mohsenSy/zulip,rishig/zulip,shubhamdhama/zulip,kaiyuanheshang/zulip,hac...
zephyr/management/commands/dump_pointers.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add a couple unit tests for teuthology.parallel\n\nSigned-off-by: Zack Cerza <<EMAIL>>" }, { "role": "assistant", "content": "from ..parallel import parallel\n\n\ndef identity(item, input_set=None, remove=False):\n if input_se...
python
new_file
1
3
mit
43c4595ae26a7663538e712af37553c7a64fade7
michaelsevilla/teuthology,caibo2014/teuthology,ceph/teuthology,SUSE/teuthology,SUSE/teuthology,t-miyamae/teuthology,zhouyuan/teuthology,ktdreyer/teuthology,robbat2/teuthology,yghannam/teuthology,yghannam/teuthology,dmick/teuthology,dreamhost/teuthology,zhouyuan/teuthology,dmick/teuthology,ivotron/teuthology,caibo2014/t...
teuthology/test/test_parallel.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add create image functional negative tests\n\nThe negative tests of create image API are not covered enough\nin functional tests. We want to add the conflict tests of\nwhen the create image API runs in the unexpected state\n(e.g. not ACTIVE)...
python
new_file
1
3
apache-2.0
45cb6df45df84cb9ae85fc8aa15710bde6a15bad
rahulunair/nova,rahulunair/nova,mahak/nova,vmturbo/nova,klmitch/nova,hanlind/nova,openstack/nova,mikalstill/nova,jianghuaw/nova,klmitch/nova,hanlind/nova,vmturbo/nova,Juniper/nova,rajalokan/nova,Juniper/nova,klmitch/nova,gooddata/openstack-nova,rajalokan/nova,Juniper/nova,klmitch/nova,rajalokan/nova,phenoxim/nova,mahak...
nova/tests/functional/test_images.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add GDB plugin for printing ABC values" }, { "role": "assistant", "content": "deadbeef = 0xdeadbeefdeadbeef\n\nabc_any = gdb.lookup_type(\"union any\")\n\ndef color(s, c):\n return \"\\x1b[\" + str(c) + \"m\" + s + \"\\x1b[0m\...
python
new_file
8
13
bsd-3-clause
bd01797f18012927202b87872dc33caf685306c0
klkblake/abcc,klkblake/abcc,klkblake/abcc,klkblake/abcc
gdb.py
rejected_lint
Too many lint violations: 8
true
[ { "role": "user", "content": "Write python code for the following: Test our new happenings-by-year view." }, { "role": "assistant", "content": "# -*- coding: utf-8 -*-\nimport datetime\nimport pytest\n\nfrom django.core.urlresolvers import reverse\n\nfrom components.people.factories import Group...
python
new_file
4
3
apache-2.0
f264f8804c208f2b55471f27f92a9e8c1ab5d778
hello-base/web,hello-base/web,hello-base/web,hello-base/web
tests/correlations/test_views.py
rejected_lint
Too many lint violations: 4
true
[ { "role": "user", "content": "Write python code for the following: Test that specific Failures are caught before parent Failures" }, { "role": "assistant", "content": "from twisted.trial import unittest\n\nimport ooni.errors\n\nclass TestErrors(unittest.TestCase):\n\n def test_catch_child_fai...
python
new_file
1
3
bsd-2-clause
525a8438bd601592c4f878ca5d42d3dab8943be0
0xPoly/ooni-probe,0xPoly/ooni-probe,0xPoly/ooni-probe,0xPoly/ooni-probe
ooni/tests/test_errors.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add test coverage for rdopkg.guess version2tag and tag2version\n\nadding coverage unittest, there are some not well handled input cases\nbut better to capture existing behavior and update tests and code to\nhandle things better\n\nChange-Id:...
python
new_file
1
2
apache-2.0
173565f7f2b9ffa548b355a0cbc8f972f1445a50
redhat-openstack/rdopkg,redhat-openstack/rdopkg,openstack-packages/rdopkg,openstack-packages/rdopkg
tests/test_guess.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add workup vebose name change migration." }, { "role": "assistant", "content": "# -*- coding: utf-8 -*-\nfrom __future__ import unicode_literals\n\nfrom django.db import migrations, models\n\n\nclass Migration(migrations.Migratio...
python
new_file
1
0
mit
a78d879c9c097c32c58f5246d46a4a188b17d99c
SaturdayNeighborhoodHealthClinic/clintools,SaturdayNeighborhoodHealthClinic/clintools,SaturdayNeighborhoodHealthClinic/clintools
workup/migrations/0002_add_verbose_names.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add first pass at integration style tests\n\nIn order to better prevent regressions (such as related to concurrency),\nAdd a integration test framework to simulate running flake8 with\narguments." }, { "role": "assistant", "conte...
python
new_file
1
2
mit
8b4bbd23bf37fb946b664f5932e4903f802c6e0d
wdv4758h/flake8,lericson/flake8
flake8/tests/test_integration.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add tests for get_uid() method for common DB models." }, { "role": "assistant", "content": "# contributor license agreements. See the NOTICE file distributed with\n# this work for additional information regarding copyright owner...
python
new_file
1
1
apache-2.0
6dfc5a3d7845633570b83aac06c47756292cf8ac
dennybaa/st2,StackStorm/st2,pixelrebel/st2,Itxaka/st2,Plexxi/st2,pixelrebel/st2,nzlosh/st2,punalpatel/st2,nzlosh/st2,Itxaka/st2,emedvedev/st2,dennybaa/st2,tonybaloney/st2,Plexxi/st2,punalpatel/st2,peak6/st2,dennybaa/st2,StackStorm/st2,tonybaloney/st2,peak6/st2,StackStorm/st2,StackStorm/st2,armab/st2,alfasin/st2,nzlosh/...
st2common/tests/unit/test_db_model_uids.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add migration for latitute and longitude of event" }, { "role": "assistant", "content": "# -*- coding: utf-8 -*-\n# Generated by Django 1.9.5 on 2016-06-17 13:50\nfrom __future__ import unicode_literals\n\nfrom django.db import m...
python
new_file
1
0
bsd-3-clause
77af87198d1116b77df431d9139b30f76103dd64
softwaresaved/fat,softwaresaved/fat,softwaresaved/fat,softwaresaved/fat
fellowms/migrations/0023_auto_20160617_1350.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add http directory listing with content display" }, { "role": "assistant", "content": "#!/bin/env python3\nimport http.server\nimport string\nimport click\nimport pathlib\nimport urllib.parse\nimport os\n\n\n@click.command()\n@cl...
python
new_file
1
4
mit
c6f6278c1915ef90e8825f94cc33a4dea4124722
dgengtek/scripts,dgengtek/scripts
network/http_server_cat.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add Diagonal Difference HackerRank Problem\n\n* https://www.hackerrank.com/challenges/diagonal-difference" }, { "role": "assistant", "content": "#!/usr/bin/env python\n\n\ndef get_matrix_row_from_input():\n return [int(index) ...
python
new_file
1
2
mit
2bf763e39e91ef989c121bba420e4ae09ea0a569
PlattsSEC/HackerRank,PlattsSEC/HackerRank,PlattsSEC/HackerRank,PlattsSEC/HackerRank,PlattsSEC/HackerRank,PlattsSEC/HackerRank
algorithms/diagonal_difference/kevin.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add helper-lib for json object conversion and split dicts" }, { "role": "assistant", "content": "#! /usr/bin/env python2.7\n\nimport datetime\n\ndef typecast_json(o):\n\tif isinstance(o, datetime.datetime) or isinstance(o, dateti...
python
new_file
1
3
bsd-3-clause
24f21146b01ff75a244df40d1626c54883abeb1a
UngaForskareStockholm/medlem2
lib/helpers.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add test for water polygon name dropping." }, { "role": "assistant", "content": "# -*- encoding: utf-8 -*-\nfrom . import FixtureTest\n\n\nclass WaterLayerTooBigTest(FixtureTest):\n\n def test_drop_label(self):\n from t...
python
new_file
1
2
mit
0ba11dd47dac04f3f7a314cf320558ccbc9eb148
mapzen/vector-datasource,mapzen/vector-datasource,mapzen/vector-datasource
integration-test/1477-water-layer-too-big.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n# Copyright (c) 2013 The Chromium Authors. All rights reserved.\n# Use of this source code is governed by a BSD-style license that can be\n# found in the LICENSE file.\n\nimport os\nimport subprocess\nimport sys\n\nBU...
python
edit
2
3
bsd-3-clause
9e6a016c5a59b25199426f6825b2c83571997e68
ondra-novak/chromium.src,hgl888/chromium-crosswalk,jaruba/chromium.src,dednal/chromium.src,TheTypoMaster/chromium-crosswalk,hgl888/chromium-crosswalk,Pluto-tv/chromium-crosswalk,fujunwei/chromium-crosswalk,markYoungH/chromium.src,krieger-od/nwjs_chromium.src,dushu1203/chromium.src,jaruba/chromium.src,ltilve/chromium,Ch...
build/android/buildbot/tests/bb_run_bot_test.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add flask api app creation to init" }, { "role": "assistant", "content": "from flask_sqlalchemy import SQLAlchemy\nimport connexion\n\nfrom config import config\n\ndb = SQLAlchemy()\n\n\ndef create_app(config_name):\n app = co...
python
new_file
2
1
mit
eb9f9d8bfa5ea278e1fb39c59ed660a223b1f6a9
EdwinKato/bucket-list,EdwinKato/bucket-list,EdwinKato/bucket-list,EdwinKato/bucket-list,EdwinKato/bucket-list
api/__init__.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Enforce unique paths and names" }, { "role": "assistant", "content": "# -*- coding: utf-8 -*-\n# Generated by Django 1.9 on 2015-12-15 02:12\nfrom __future__ import unicode_literals\n\nfrom django.db import migrations, models\n\n...
python
new_file
1
0
mit
9e128fdd5af0598a233416de5a1e8f2d3a74fdc0
jgillick/Spaces,jgillick/Spaces,jgillick/Spaces,jgillick/Spaces,jgillick/Spaces,jgillick/Spaces
spaces/migrations/0006_unique_space_document.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add script to create overlays" }, { "role": "assistant", "content": "\"\"\"Varcan smart tool.\"\"\"\n\nimport click\n\nfrom dtoolcore import DataSet\n\n\n@click.command()\n@click.argument('dataset_uri')\n@click.option('--config-p...
python
new_file
1
2
mit
8249d33898500d9d39e8bee3d44d39c2a6034659
JIC-Image-Analysis/senescence-in-field,JIC-Image-Analysis/senescence-in-field,JIC-Image-Analysis/senescence-in-field
scripts/create_overlays.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Coffee: Add symbol translator to make utf-8 variables compilable" }, { "role": "assistant", "content": "\"\"\"Translation table from utf-8 to greek variable names, taken from:\nhttps://gist.github.com/piquadrat/765262#file-greek_...
python
new_file
1
2
mit
0f5c0168b257436882f837e5d521cce46a740ad6
FInAT/FInAT
finat/greek_alphabet.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Test module for Predictor class." }, { "role": "assistant", "content": "#! /usr/env/bin python\nimport numpy as np\n\nfrom pyboas import predictor, models\n\n# Build random 3-parameter normal posterior.\nposterior = np.random.ran...
python
new_file
3
3
mit
27cb9279670bd513a1559f4865500d84869bb9f0
exord/pyboas
tests/test_predictor.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add management command to list installed spiders" }, { "role": "assistant", "content": "from django.core.management import BaseCommand\nfrom raw.utils import list_spiders\n\n\nclass Command(BaseCommand):\n help = 'List install...
python
new_file
2
2
mit
865dc29421c1e9ef4bf340bf32164863cc5f2006
legco-watch/legco-watch,comsaint/legco-watch,legco-watch/legco-watch,comsaint/legco-watch,legco-watch/legco-watch,comsaint/legco-watch,comsaint/legco-watch,legco-watch/legco-watch
app/raw/management/commands/list_spiders.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add download apikey test case" }, { "role": "assistant", "content": "# -*- coding: utf-8 -*-\n\nfrom django.core.urlresolvers import reverse\nfrom django.test import TestCase\nfrom tastypie.test import ResourceTestCase\nfrom djan...
python
new_file
5
2
bsd-3-clause
c486b8df5861fd883b49ea8118d40d73f5b4e7b8
pansapiens/mytardis,pansapiens/mytardis,pansapiens/mytardis,pansapiens/mytardis
tardis/tardis_portal/tests/test_download_apikey.py
rejected_lint
Too many lint violations: 5
true
[ { "role": "user", "content": "Write python code for the following: Add tool to create combined smart contract files\n\nUseful for various cases where a single source file is needed e.g. when\nverifying contracts on etherscan." }, { "role": "assistant", "content": "import os\n\nimport click\nimpo...
python
new_file
1
9
mit
34d5b5cdc058f1c9055b82151b518251fa3b4f74
tomashaber/raiden,hackaugusto/raiden,tomashaber/raiden,tomashaber/raiden,hackaugusto/raiden,tomashaber/raiden,tomashaber/raiden
tools/join-contracts.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add migration to remove models." }, { "role": "assistant", "content": "# Generated by Django 2.1.4 on 2019-03-04 18:13\n\nfrom django.db import migrations\n\n\nclass Migration(migrations.Migration):\n\n dependencies = [\n ...
python
new_file
1
0
apache-2.0
e06416a61826229ebd0cccdc519b6dc39d8a0fd9
sheagcraig/sal,sheagcraig/sal,sheagcraig/sal,salopensource/sal,salopensource/sal,salopensource/sal,salopensource/sal,sheagcraig/sal
server/migrations/0088_auto_20190304_1313.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Solve Code Fights lineup problem" }, { "role": "assistant", "content": "#!/usr/local/bin/python\n# Code Fights Lineup Problem\n\n\ndef lineUp(commands):\n aligned, tmp = 0, 0\n com_dict = {\"L\": 1, \"A\": 0, \"R\": -1}\n ...
python
new_file
1
3
mit
5f12ada7fe0ddb44274e18decbaea0d05ab4471f
HKuz/Test_Code
CodeFights/lineUp.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add simple windows registry read/write functions" }, { "role": "assistant", "content": "import _winreg\n\nkeyName = \"myKey\"\n\n\ndef write_to_registry():\n try:\n key = _winreg.CreateKey(_winreg.HKEY_CURRENT_USER, \"S...
python
new_file
1
3
mit
f5970d1488d28f27c5f20dd11619187d0c13c960
ddubson/code-dojo-py
os/win_registry.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Bring back the Root URL config\n\nThe file was probably deleted by a mistake, we need it, so took it back." }, { "role": "assistant", "content": "__author__ = 'ankesh'\nfrom django.conf.urls import patterns, include, url\nfrom dj...
python
new_file
1
0
bsd-2-clause
37e674f05547c7b6b93f447477443644865975d1
ankeshanand/benchmark,ankeshanand/benchmark,ankeshanand/benchmark,ankeshanand/benchmark
urls.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add Find Command MCEdit filter" }, { "role": "assistant", "content": "# MCEdit filter\n\nfrom albow import alert\n\ndisplayName = \"Find Command\"\n\ninputs = (\n (\"Command:\", (\"string\", \"value=\")),\n)\n\ndef perform(lev...
python
new_file
1
6
mit
4dd66150c922e1c700fad74727955ef72c045f37
satgo1546/dot-product,satgo1546/dot-product,satgo1546/dot-product,satgo1546/dot-product,satgo1546/dot-product
minecraft/FindCommand.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Solve Code Fights addition without carrying problem" }, { "role": "assistant", "content": "#!/usr/local/bin/python\n# Code Fights Addition Without Carrying Problem\n\n\ndef additionWithoutCarrying(param1, param2):\n s1, s2 = s...
python
new_file
1
5
mit
1de668219f618a0632fac80fd892a0a229b8fa05
HKuz/Test_Code
CodeFights/additionWithoutCarrying.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add test for file creation of low level library" }, { "role": "assistant", "content": "import os\n\nfrom cffitsio._cfitsio import ffi, lib\n\n\ndef test_create_file(tmpdir):\n filename = str(tmpdir.join('test.fits'))\n f = ...
python
new_file
1
1
mit
dcd1d962feec4f3cd914677545f74924ad9e6351
mindriot101/fitsio-cffi
testing/test_direct_wrapper.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add script to delete unused users on JupyterHub\n\nNote that this doesn't actually delete their home directories\nor any data - just the entry in the JupyterHub DB. As soon as\nthey log in again, a new entry is created.\n\nThis is really jus...
python
new_file
1
8
bsd-3-clause
66137a8710bf3b778c860af8d6278ee0c97bbab4
ryanlovett/datahub,berkeley-dsep-infra/datahub,ryanlovett/datahub,berkeley-dsep-infra/datahub,berkeley-dsep-infra/datahub,ryanlovett/datahub
scripts/delete-unused-users.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Solve the Longest Lines challenge using Python3" }, { "role": "assistant", "content": "# Longest Lines\n#\n# https://www.codeeval.com/open_challenges/2/\n#\n# Challenge Description: Write a program which reads a file and prints t...
python
new_file
1
0
mit
b4b2b80cb1d0c0729e8e98085c2cfc3bc55ddda3
TommyN94/CodeEvalSolutions,TommyN94/CodeEvalSolutions
LongestLines.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add sample of scheduler using celery" }, { "role": "assistant", "content": "from celery import Celery\n\n# The host in which RabbitMQ is running\nHOST = 'amqp://guest@localhost'\n\napp = Celery('pages_celery', broker=HOST)\n\n@ap...
python
new_file
2
1
apache-2.0
eea33e6207da7446e1713eb4d78b76d37ae5eaf2
jovannypcg/python_scheduler
with_celery.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add a new script to clean up a habitica user given user email\n\n- Looks up uuid\n- uses that to lookup password\n- calls delete method\n\nSimple!" }, { "role": "assistant", "content": "import argparse\nimport sys\nimport logging...
python
new_file
3
0
bsd-3-clause
1437bb868844731d3fdb13c6dd52dfd706df6f63
sunil07t/e-mission-server,shankari/e-mission-server,sunil07t/e-mission-server,yw374cornell/e-mission-server,e-mission/e-mission-server,yw374cornell/e-mission-server,shankari/e-mission-server,e-mission/e-mission-server,e-mission/e-mission-server,yw374cornell/e-mission-server,shankari/e-mission-server,yw374cornell/e-miss...
bin/ext_service/clean_habitica_user.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add test case for list invoice" }, { "role": "assistant", "content": "import httpretty\n\nfrom paystackapi.tests.base_test_case import BaseTestCase\nfrom paystackapi.invoice import Invoice\n\n\nclass TestInvoice(BaseTestCase):\n\...
python
new_file
1
1
mit
151e8fc71e5ef2e31db13730bff57bc8fd915c30
andela-sjames/paystack-python
paystackapi/tests/test_invoice.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add forgotten font leader lib" }, { "role": "assistant", "content": "import os\nimport sys\nimport logging\n\nFONT_FILE_NAME_LIST = (\n \"fontawesome-webfont.ttf\",\n )\n\nFONT_DIRECTORY = \"share\"\nFONT_DIRECTORY_...
python
new_file
3
5
mit
83d4ac6c3565044727c9b3fcbada9966d529a80e
Nadeflore/dakara-player-vlc
lib/font_loader.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Create Video Stream program for webcam" }, { "role": "assistant", "content": "import cv2\r\nimport numpy as np\r\n\r\ncap = cv2.VideoCapture(0)\r\n\r\nprint('Beginning Capture Device opening...\\n')\r\nprint('Capture device opene...
python
new_file
3
0
apache-2.0
90399f50a3f50d9193ae1e6b2042215fb388230f
SentientCNC/Sentient-CNC
VideoStream.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add py solution for 459. Repeated Substring Pattern\n\n459. Repeated Substring Pattern: https://leetcode.com/problems/repeated-substring-pattern/" }, { "role": "assistant", "content": "class Solution(object):\n def repeatedSub...
python
new_file
3
5
apache-2.0
280e72331d99a8c49783196951287627a933a659
ckclark/leetcode,ckclark/leetcode,ckclark/leetcode,ckclark/leetcode,ckclark/leetcode,ckclark/leetcode
py/repeated-substring-pattern.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add tests for pylama isort" }, { "role": "assistant", "content": "import os\n\nfrom isort.pylama_isort import Linter\n\n\nclass TestLinter:\n instance = Linter()\n\n def test_allow(self):\n assert not self.instance.a...
python
new_file
1
1
mit
0882c8885b88618ea55b97ace256cdf833a1547d
PyCQA/isort,PyCQA/isort
tests/test_pylama_isort.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add some generic python utilities as a basis for scripts" }, { "role": "assistant", "content": "from __future__ import print_function\n\nimport os\n\ndef game_root_path():\n file_path = os.path.dirname(os.path.abspath(__file__...
python
new_file
1
6
mit
871f79a0b2bd235df457e3a1dc502d5c18bd934a
Oletus/gameutils.js,Oletus/gameutils.js
tools/build/common_utils.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add tests for JsonBackend __init__ and commit methods" }, { "role": "assistant", "content": "import pytest\n\nfrom shadho.backend.base.tests.test_db import TestBaseBackend\nfrom shadho.backend.json.db import JsonBackend\n\nimport...
python
new_file
5
1
mit
0fa30986e1f97331f96444e0b3b0f86cbe20c68a
jeffkinnison/shadho,jeffkinnison/shadho
shadho/backend/json/tests/test_db.py
rejected_lint
Too many lint violations: 5
true
[ { "role": "user", "content": "Write python code for the following: Add function to create view for Span candidate subclasses" }, { "role": "assistant", "content": "\n\ndef create_serialized_candidate_view(session, C, verbose=True):\n \"\"\"Creates a view in the database for a Candidate sub-cl...
python
new_file
1
3
apache-2.0
f6c2d5e37685b149cfd447545c58ce1fc4d836b9
jasontlam/snorkel,HazyResearch/snorkel,HazyResearch/snorkel,jasontlam/snorkel,jasontlam/snorkel,HazyResearch/snorkel
snorkel/models/views.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport six\nfrom django.contrib import messages\nfrom six.moves import map\n\n\nclass FlashMessages(object):\n \"\"\"\n Intermediate container for flash messages.\n\n This is useful as, at the time of creating the message, we don't...
python
edit
3
3
bsd-3-clause
8affeda715b1facf12de1dab1d445bbe54616306
jmt4/django-oscar,jmt4/django-oscar,dongguangming/django-oscar,lijoantony/django-oscar,kapt/django-oscar,okfish/django-oscar,vovanbo/django-oscar,bnprk/django-oscar,Bogh/django-oscar,sasha0/django-oscar,ahmetdaglarbas/e-commerce,solarissmoke/django-oscar,bnprk/django-oscar,spartonia/django-oscar,WillisXChen/django-osca...
oscar/core/ajax.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Implement utility for colored, tabular output using fabric's color controls." }, { "role": "assistant", "content": "\"\"\"\nPretty table generation.\n\"\"\"\nfrom itertools import cycle\nfrom string import capwords\nfrom fabric.c...
python
new_file
2
3
apache-2.0
e426afbe9ccbc72a1aa0d00032144e8b9b2b8cdc
locationlabs/gusset
gusset/colortable.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add pebble sdk version for detecting sdk features" }, { "role": "assistant", "content": "from waflib.Configure import conf\n\n\n@conf\ndef compare_sdk_version(ctx, platform, version):\n target_env = ctx.all_envs[platform] if p...
python
new_file
1
5
mit
f622255dc2c6695b785213c8d69cb57ae5d8a5e9
jiangege/pebblejs-project,youtux/PebbleShows,bkbilly/Tvheadend-EPG,bkbilly/Tvheadend-EPG,pebble/pebblejs,fletchto99/pebblejs,sunshineyyy/CatchOneBus,fletchto99/pebblejs,pebble/pebblejs,carlo-colombo/dublin-bus-pebble,youtux/PebbleShows,jsfi/pebblejs,daduke/LMSController,jiangege/pebblejs-project,sunshineyyy/CatchOneBus...
waftools/pebble_sdk_version.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# encoding: utf-8\nfrom django import forms\nfrom django.utils.html import escape\n\nfrom seahub.profile.models import Profile, DetailedProfile\n\nclass ProfileForm(forms.Form):\n nickname = forms.CharField(max_length=64, required=False)...
python
edit
1
1
apache-2.0
9c53e59ee0c4e5418b54d47c932454b7b907dc03
madflow/seahub,Chilledheart/seahub,cloudcopy/seahub,madflow/seahub,Chilledheart/seahub,cloudcopy/seahub,miurahr/seahub,miurahr/seahub,cloudcopy/seahub,Chilledheart/seahub,miurahr/seahub,madflow/seahub,madflow/seahub,madflow/seahub,Chilledheart/seahub,cloudcopy/seahub,miurahr/seahub,Chilledheart/seahub
seahub/profile/forms.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Create script to transform shapefile into csv distance matrix" }, { "role": "assistant", "content": "\"\"\"Create a csv matrix of distances between shapefile geometry objects.\n\nRequirements: fiona, shapely\n\nWritten by: Taylor...
python
new_file
3
4
mit
0c8b7fa865df535f5baa33025c184bbf4234b7b1
tayden-hakai/Island_MST
shp_to_csv_distances.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add a slow bot to test timeout feature" }, { "role": "assistant", "content": "import random\nimport asyncio\n\nimport sc2\nfrom sc2 import Race, Difficulty\nfrom sc2.constants import *\nfrom sc2.player import Bot, Computer\n\nfro...
python
new_file
2
1
mit
75dc32ef71fd32c7728269b01a74faf840690473
Dentosal/python-sc2
examples/too_slow_bot.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Print the trending Python repos on GitHub" }, { "role": "assistant", "content": "#!/usr/bin/env python3\n\nimport bs4\nimport requests\n\nurl = 'https://github.com/trending?l=Python'\nsoup = bs4.BeautifulSoup(requests.get(url).co...
python
new_file
1
0
apache-2.0
ec6dff24e3049ddaab392f0bc5b8d8b724e41e20
cclauss/Ten-lines-or-less
trending_python.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add commands for cases and variants" }, { "role": "assistant", "content": "# -*- coding: utf-8 -*-\nimport logging\nimport click\n\nfrom . import base_command\n\nlogger = logging.getLogger(__name__)\n\n@base_command.command()\n@c...
python
new_file
1
5
mit
3609c5842b33ca4146ad14b74c76f8954545aaa8
moonso/loqusdb
loqusdb/commands/view.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add helper enums for type encodings" }, { "role": "assistant", "content": "REDIS_ENCODING_ID_RAW = 0\nREDIS_ENCODING_ID_INT = 1\nREDIS_ENCODING_ID_EMBSTR = 2\nREDIS_ENCODING_ID_HASHTABLE = 3\nREDIS_ENCODING_ID_ZIPLIST = 4\nREDIS_...
python
new_file
1
2
mit
2cd1da31b099cbf37552b2a049c3df6619e0e64f
gamenet/redis-memory-analyzer
rma/redis_types.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add next traversal util function" }, { "role": "assistant", "content": "\"\"\"\nscrapple.utils.config\n~~~~~~~~~~~~~~~~~~~~~\n\nFunctions related to traversing the configuration file\n\"\"\"\n\nfrom __future__ import print_functi...
python
new_file
1
7
mit
23cf747a3ff24f75d3300547f4bfdecf10c4a325
scrappleapp/scrapple,AlexMathew/scrapple,AlexMathew/scrapple,scrappleapp/scrapple,AlexMathew/scrapple
scrapple/utils/config.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: [Crawler] Add youtube-dl library sample of operation" }, { "role": "assistant", "content": "#!/usr/bin/env python2\n#-*- coding: utf-8 -*-\n\nimport sys\nimport youtube_dl\n\n\ndef main():\n if len(sys.argv) < 2:\n prin...
python
new_file
1
7
mit
a086e7328ca920f269812a87be095ce638467f95
daineseh/python_code
crawler/youtube_dl_op_sample.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add test for stack outputs\n\nAdd test for output list and output show\n\nDepends-On: I1bc1cee1c78ecf0c9a18ecc0a871d38e4141e0f7\nChange-Id: I1ee226494b5b04ec2d43edf0c03ab31e452fedf0" }, { "role": "assistant", "content": "# Lic...
python
new_file
1
1
apache-2.0
82b9a66ea826b4463d82c69ba1703eab213efe83
cwolferh/heat-scratch,noironetworks/heat,jasondunsmore/heat,jasondunsmore/heat,noironetworks/heat,openstack/heat,steveb/heat,dims/heat,steveb/heat,dims/heat,openstack/heat,cwolferh/heat-scratch
heat_integrationtests/functional/test_stack_outputs.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add a utility class to normalize input" }, { "role": "assistant", "content": "from unidecode import unidecode\n\n\nclass Normalizer:\n\n def normalize(text):\n text = Normalizer.remove_extra_whitespaces(text)\n t...
python
new_file
1
1
mit
4a30d30b82fbdccbb0f15ebb5c094b13ce791f7f
davidmogar/genderator
genderator/utils.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add py solution for 575. Distribute Candies\n\n575. Distribute Candies: https://leetcode.com/problems/distribute-candies/" }, { "role": "assistant", "content": "class Solution(object):\n def distributeCandies(self, candies):\n...
python
new_file
1
1
apache-2.0
03fce72b60eb8cad2368447cf23f72f8084f4a4b
ckclark/leetcode,ckclark/leetcode,ckclark/leetcode,ckclark/leetcode,ckclark/leetcode,ckclark/leetcode
py/distribute-candies.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add first version of the code" }, { "role": "assistant", "content": "#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\nimport re\nfrom collections import OrderedDict\nimport codecs\n\nclass BibEntry:\n \n def __init__(self,...
python
new_file
2
14
mit
6ae82ecdd749b936289b496a10faa2caf1aa94c6
derherrg/pybibsort
bibsort.py
rejected_complexity
Cyclomatic complexity too high: 14
true
[ { "role": "user", "content": "Write python code for the following: Add missing migration related to django-simple-history update" }, { "role": "assistant", "content": "# -*- coding: utf-8 -*-\n# Generated by Django 1.11.2 on 2017-06-13 09:41\nfrom __future__ import unicode_literals\n\nfrom djang...
python
new_file
1
0
mit
b7bf4586fea207453225a87fb85df59ccfc94e80
datasciencebr/jarbas,datasciencebr/jarbas,marcusrehm/serenata-de-amor,marcusrehm/serenata-de-amor,datasciencebr/jarbas,datasciencebr/serenata-de-amor,datasciencebr/serenata-de-amor,marcusrehm/serenata-de-amor,datasciencebr/jarbas,marcusrehm/serenata-de-amor
jarbas/core/migrations/0032_auto_20170613_0641.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add tool to fix links.\n\nSigned-off-by: Jason Kuster <<EMAIL>>" }, { "role": "assistant", "content": "\"\"\"Script to fix the links in the staged website.\nFinds all internal links which do not have index.html at the end and app...
python
new_file
4
0
apache-2.0
1058a9cb6e667c850f56b6003038496b77c359c5
rangadi/beam,robertwb/incubator-beam,lukecwik/incubator-beam,lukecwik/incubator-beam,markflyhigh/incubator-beam,chamikaramj/beam,chamikaramj/beam,RyanSkraba/beam,rangadi/incubator-beam,lukecwik/incubator-beam,robertwb/incubator-beam,charlesccychen/incubator-beam,chamikaramj/beam,rangadi/beam,charlesccychen/beam,markfly...
website/tools/append_index_html_to_internal_links.py
rejected_lint
Too many lint violations: 4
true
[ { "role": "user", "content": "Write python code for the following: Create foundation for input file generation (csv for connectivity table, etc.)" }, { "role": "assistant", "content": "import csv\nimport argparse\nimport itertools\n\nfrom thermo_utils import csv_row_writer, read_csv_rows\n\n# Re...
python
new_file
6
0
mit
f59749db263291f481c4bdc9f6ede2f6de6cb6d4
ndebuhr/openfea,ndebuhr/openfea
create_input_files.py
rejected_lint
Too many lint violations: 6
true
[ { "role": "user", "content": "Write python code for the following: Add Chuanping Yu's solutions to Problem02" }, { "role": "assistant", "content": "#!/usr/bin/env python3\n\n\"\"\"This script is written by Chuanping Yu, on Jul 24, 2017,\nfor the Assignment#1 in IDEaS workshop\"\"\"\n\n#Problem 2...
python
new_file
1
0
bsd-3-clause
d34dcf1179e6e5c2b864627266ae1788d10142aa
GT-IDEaS/SkillsWorkshop2017,GT-IDEaS/SkillsWorkshop2017,GT-IDEaS/SkillsWorkshop2017
Week01/Problem02/cyu_02.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add tests for Generic Interface." }, { "role": "assistant", "content": "# -*- coding: utf-8 -*-\nfrom __future__ import absolute_import\nfrom __future__ import print_function\nfrom typing import Any\n\nimport mock\nimport json\n\...
python
new_file
3
1
apache-2.0
e5be29bc3c5a77493fe64bb3fc8b52611cc13469
rht/zulip,mahim97/zulip,rht/zulip,mahim97/zulip,brainwane/zulip,hackerkid/zulip,zulip/zulip,eeshangarg/zulip,Galexrt/zulip,vabs22/zulip,kou/zulip,rishig/zulip,amanharitsh123/zulip,punchagan/zulip,eeshangarg/zulip,andersk/zulip,shubhamdhama/zulip,showell/zulip,jackrzhang/zulip,eeshangarg/zulip,hackerkid/zulip,vabs22/zul...
zerver/tests/test_outgoing_webhook_interfaces.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add worker to send queue mails" }, { "role": "assistant", "content": "# -*- coding: utf-8 -*-\n# Copyright (c) 2016 Aladom SAS & Hosting Dvpt SAS\nfrom django.core.management.base import BaseCommand\n\nfrom ...utils import send_q...
python
new_file
1
2
mit
f18fd5c4ad61adb56ac7524a006ce9977aa06a31
Aladom/django-mailing,Aladom/django-mailing
mailing/management/commands/send_queued_mails_worker.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add solution to exercise 3.3." }, { "role": "assistant", "content": "# 3-3 Your Own List\ntransportation = [\"mountainbike\", \"teleportation\", \"Citroën DS3\"]\n\nprint(\"A \" + transportation[0] + \" is good when exercising in...
python
new_file
1
0
mit
8d6ca433d33551cc1fe5c08edcf68ec65e5447b0
HenrikSamuelsson/python-crash-course
exercises/chapter_03/exercise_03_03/exercies_03_03.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add test for pixel CLI" }, { "role": "assistant", "content": "\"\"\" Test ``yatsm line``\n\"\"\"\nimport os\n\nfrom click.testing import CliRunner\nimport pytest\n\nfrom yatsm.cli.main import cli\n\n\n@pytest.mark.skipif(\"DISPLA...
python
new_file
1
1
mit
c4b7bd5b74aaba210a05f946d59c98894b60b21f
ceholden/yatsm,c11/yatsm,ceholden/yatsm,valpasq/yatsm,c11/yatsm,valpasq/yatsm
tests/cli/test_pixel.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Create a test for re-evaluating external tasks while a workflow is running." }, { "role": "assistant", "content": "# Copyright (c) 2015\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\"); you may not\n# use th...
python
new_file
3
1
apache-2.0
555cfbb827532c54598cecde01ef4e6e5e07714d
dlstadther/luigi,ViaSat/luigi,adaitche/luigi,humanlongevity/luigi,PeteW/luigi,Houzz/luigi,ZhenxingWu/luigi,springcoil/luigi,ContextLogic/luigi,ivannotes/luigi,percyfal/luigi,belevtsoff/luigi,Yoone/luigi,meyerson/luigi,tuulos/luigi,dkroy/luigi,Houzz/luigi,Dawny33/luigi,theoryno3/luigi,JackDanger/luigi,Magnetic/luigi,bow...
test/worker_external_task_test.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add some code to auto-remove Ltac" }, { "role": "assistant", "content": "import re\n\n__all__ = [\"recursively_remove_ltac\"]\n\nLTAC_REG = re.compile(r'^\\s*(?:Local\\s+|Global\\s+)?Ltac\\s+([^\\s]+)', re.MULTILINE)\n\ndef recur...
python
new_file
1
5
mit
ab53993b708b3f9cf3b5762664fef58bae99ea20
JasonGross/coq-tools,JasonGross/coq-tools
recursive_remove_ltac.py
accepted
null
true