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": "Here is the current file:\n```python\n# MIT License\n# Copyright (c) 2017 MassChallenge, Inc.\n\n# METHOD_OVERRIDE_HEADER = 'HTTP_X_HTTP_METHOD_OVERRIDE'\nMETHOD_OVERRIDE_HEADER = 'X-HTTP-Method-Override'\n\nclass MethodOverrideMiddleware(object):\n def process_request(self,...
python
edit
1
3
mit
5f9cf67c473ef7d304da067b70b56d77f71ca4fa
masschallenge/impact-api,masschallenge/impact-api,masschallenge/impact-api,masschallenge/impact-api
web/impact/impact/middleware/method_override_middleware.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom __future__ import unicode_literals\n\nfrom django.utils.translation import pgettext\nfrom satchless import cart\nfrom satchless.item import ItemList, ClassifyingPartitioner\n\nfrom ..product.models import DigitalShip\n\n\nclass Shipped...
python
edit
1
2
bsd-3-clause
2ad16c44adb20e9ba023e873149d67068504c34c
avorio/saleor,laosunhust/saleor,hongquan/saleor,maferelo/saleor,avorio/saleor,car3oon/saleor,tfroehlich82/saleor,UITools/saleor,car3oon/saleor,Drekscott/Motlaesaleor,maferelo/saleor,hongquan/saleor,josesanch/saleor,taedori81/saleor,KenMutemi/saleor,tfroehlich82/saleor,spartonia/saleor,mociepka/saleor,itbabu/saleor,UITo...
saleor/cart/__init__.py
rejected_duplicate
Near-duplicate of sample 19378
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# import the right SWIG module depending on Python version\nfrom sys import version_info\nfrom sys import path as sys_path\nfrom os import path as os_path\nif version_info[0] >= 3:\n sys_path.insert(0, os_path.join(os_path.dirname(__file...
python
edit
3
0
apache-2.0
39650fe82bea3fc2bc036b8292f6f0b783b2b4d6
open-power/eCMD,open-power/eCMD,open-power/eCMD,open-power/eCMD,open-power/eCMD
ecmd-core/pyapi/init/__init__.py
rejected_duplicate
Near-duplicate of sample 13166
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.contrib import admin\n\nfrom api import models\n\n\nclass UserProfileAdmin(admin.ModelAdmin):\n list_display = ('user', 'country', )\n\n\nclass EventAdmin(admin.ModelAdmin):\n prepopulated_fields = {'slug': ('title',)}\n ...
python
edit
1
0
mit
b03c8ebe8cc426e21b45f4de0d8d6e7176a4a647
codeeu/coding-events,michelesr/coding-events,michelesr/coding-events,michelesr/coding-events,codeeu/coding-events,codeeu/coding-events,michelesr/coding-events,codeeu/coding-events,codeeu/coding-events,michelesr/coding-events
api/admin.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport sys\nfrom threading import local\n\ndef debug():\n def pm(etype, value, tb): # pragma no cover\n import pdb, traceback\n try:\n from IPython.ipapi import make_session; make_session()\n from IPyt...
python
edit
3
4
mit
eab299ce4bd3fa4734b8a3adbc805c3f5863bfc5
moreati/kajiki,ollyc/kajiki,ollyc/kajiki,moreati/kajiki,moreati/kajiki,ollyc/kajiki
fastpt/v2/util.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\n Object Oriented implementation of Flickr API.\n \n Important notes:\n - For consistency, the nameing of methods might differ from the name\n in the official API. Please check the method \"docstring\" to know\n ...
python
edit
4
0
bsd-3-clause
eb313bcced5a71f80cff8b3314d3346a151297a9
alexis-mignon/python-flickr-api,alexis-mignon/python-flickr-api,bryndin/tornado-flickr-api
flickr_api/__init__.py
rejected_lint
Too many lint violations: 4
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# Lint as: python3\n# Copyright 2020 Google LLC. All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of th...
python
edit
1
1
apache-2.0
c1c2503933243fe51bb14f7d63222f958178d7e7
tensorflow/tfx,tensorflow/tfx
tfx/components/transform/executor_v2_test.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.http import QueryDict\n\nclass HttpMethodOverrideMiddleware:\n \"\"\"\n Facilitate for overriding the HTTP method with the X-HTTP-Method-Override\n header or a '_method' HTTP POST parameter.\n \"\"\"\n\n def proce...
python
edit
1
5
mit
1a242dc184adf4a3917b6c82742a667399c16ae9
jgorset/django-respite,jgorset/django-respite,jgorset/django-respite
respite/middleware.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport sublime, sublime_plugin\n\nclass CopyrightmeCommand(sublime_plugin.TextCommand):\n\tdef run(self, edit, text):\n\t\tregion = self.view.visible_region()\n\n\t\tif text not in self.view.substr(region):\n\t\t\tself.view.split_by_newline...
python
edit
3
2
mit
c6e16cf939e74640fc8aec3475bf917214ee8ee6
tatarin0/CopyrightMe,tatarin0/CopyrightMe
copyrightme.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n\n\"\"\"\nTest for scratchnet.py\n\"\"\"\n\nimport unittest\nimport pexpect\n\nclass testScratchNet( unittest.TestCase ):\n\n opts = [ \"1 packets transmitted, 1 received, 0% packet loss\", pexpect.EOF ]\n\n def...
python
edit
1
1
bsd-3-clause
1eb6f65e40fccb3cea4b35374e7ddc25dd574dfa
mininet/mininet,mininet/mininet,mininet/mininet
examples/test/test_scratchnet.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\nimport unittest\n\nimport opensim as osim\n\ntest_dir = os.path.join(os.path.dirname(os.path.abspath(osim.__file__)),\n 'tests')\n\n# Silence warning messages if mesh (.vtp) files cannot be found.\nosim.Mod...
python
edit
1
1
apache-2.0
47c5bb272040f47bc20cde647f76b9a8e673698c
opensim-org/opensim-core,opensim-org/opensim-core,opensim-org/opensim-core,opensim-org/opensim-core,opensim-org/opensim-core,opensim-org/opensim-core,opensim-org/opensim-core
Bindings/Python/tests/test_component_interface.py
rejected_duplicate
Near-duplicate of sample 18680
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.db import models\nfrom django.utils import timezone\n\n\nclass Station(models.Model):\n id = models.IntegerField(unique=True, primary_key=True)\n name = models.CharField(u'name', max_length=100)\n longitude = models.Flo...
python
edit
1
1
bsd-3-clause
04e243aafbd08008556d83d73fbbf22e5398aab4
idan/telostats,idan/telostats,idan/telostats
telostats/stations/models.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom sqlalchemy import create_engine\nfrom sqlalchemy.orm import scoped_session, sessionmaker\nfrom sqlalchemy.ext.declarative import declarative_base\nfrom bookmarks import app\n\nDATABASE_URL = 'postgresql://{}:{}@{}/{}'.format(\n app....
python
edit
3
1
apache-2.0
f3ae9106bf738fc3e86609fbf4d7ed26d4c76354
byanofsky/bookmarks,byanofsky/bookmarks,byanofsky/bookmarks
bookmarks/database.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# Copyright 2015 Google Inc. All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# ...
python
edit
5
0
apache-2.0
62622d78c5cd45fbbe04497de856ff5424051678
sandeepdsouza93/TensorFlow-15712,alsrgv/tensorflow,annarev/tensorflow,EvenStrangest/tensorflow,chemelnucfin/tensorflow,SnakeJenny/TensorFlow,Carmezim/tensorflow,admcrae/tensorflow,cxxgtxy/tensorflow,anilmuthineni/tensorflow,benoitsteiner/tensorflow-xsmm,ppwwyyxx/tensorflow,calebfoss/tensorflow,MostafaGazar/tensorflow,h...
tensorflow/models/rnn/__init__.py
rejected_lint
Too many lint violations: 5
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport re\nfrom os import path\nfrom ..interpreter import *\nfrom ..SIMode import SIMode\nfrom ..utils import endswith\n\nclass ScssInterpreter(Interpreter):\n def run(self):\n self.settings = {\n \"extensions\": [\".scss\"],\n ...
python
edit
7
4
mit
bd0310663a4f646873119e6b01afe585d0ef40bb
vinpac/sublime-simple-import,vini175pa/sublime-simple-import,vini175pa/sublime-simple-import,vini175pa/simple-import-js,vini175pa/simple-import-js
lib/interpreters/ScssInterpreter.py
rejected_lint
Too many lint violations: 7
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n\nimport os\nfrom jinja2 import Template\n\nclusters = ['2_0', '2_1', '2_2']\n# Commenting out this as we only have one example and it breaks\ntiles = [] # [d for d in os.listdir('../examples') if os.path.isdir(os.pat...
python
edit
2
0
apache-2.0
de2ea6f02af98902bf50afbef25f51760715fc4a
cf-platform-eng/tile-generator,cf-platform-eng/tile-generator,cf-platform-eng/tile-generator,cf-platform-eng/tile-generator
ci/generate_pipeline_yml.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.conf.urls import url\nfrom django.contrib.staticfiles.urls import staticfiles_urlpatterns\n\nfrom . import views\n\n\nurlpatterns = [\n url(r'^noreload$', views.CardDisplay.as_view(), name='card_display_noreload'),\n url(r...
python
edit
1
0
mit
5831fe52a4b8296bd4f0c71e5e98369d704b8fc3
adam-thomas/imperial-painter,adam-thomas/imperial-painter,adam-incuna/imperial-painter,adam-incuna/imperial-painter
painter/urls.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.utils.timezone import make_aware, utc\n\nfrom .models import Photo\n\n\ndef update_photos(photos):\n for i in photos:\n image = i.images['standard_resolution']\n\n obj, created = Photo.objects.update_or_create(p...
python
edit
1
3
bsd-3-clause
4971f5cd840d17df237fc09dbd11cb8e265bc6e8
blancltd/django-quick-photos,kmlebedev/mezzanine-instagram-quickphotos
quickphotos/utils.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# Copyright 2015 Mirantis, Inc.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\"); you may\n# not use this file except in compliance with the License. You may obtain\n# a copy of the License at\n#\n# ...
python
edit
1
2
apache-2.0
47162e68dd7662efd8f1c2463d11dc9228726523
openstack/solar,pigmej/solar,openstack/solar,openstack/solar,pigmej/solar,pigmej/solar
solar/dblayer/standalone_session_wrapper.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.test import TestCase\n\nfrom .models import Character, Team\n\n\nclass TeamGetAbsoluteUrl(TestCase):\n def test_slug_appears_in_url(self):\n slug_value = \"slug-value\"\n\n team = Team()\n team.slug = \"d...
python
edit
1
1
mit
fb8fa7fedd18d751aeb7c060786377c96a8b2319
evanepio/dotmanca,evanepio/dotmanca,evanepio/dotmanca
characters/tests.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"Verifies that instance_links are being retrieved properly from LINKS. Verifies that app_data.json.j2\ncontains the instance link information\"\"\"\nfrom unittest import mock\n\nfrom foremast.plugin_manager import PluginManager\n\nMANA...
python
edit
2
1
apache-2.0
fd599497011fcb94d8b5c29dc696128eafb9d603
gogoair/foremast,gogoair/foremast
tests/app/test_create_app.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n\n\"\"\"\nInstall the packages you have listed in the requirements file you input as\nfirst argument.\n\"\"\"\n\nfrom __future__ import (absolute_import, division, print_function, \n unicode_lit...
python
edit
1
6
bsd-3-clause
3f5867695e5b980e05f1516f2bcbd246cdc3241f
Neurita/boyle
install_deps.py
rejected_duplicate
Near-duplicate of sample 19842
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\n\nfrom setuptools import setup, find_packages\n\ndef read(*paths):\n \"\"\"Build a file path from *paths* and return the contents.\"\"\"\n with open(os.path.join(*paths), 'r') as f:\n return f.read()\n\nsetup(\n n...
python
edit
1
1
mit
8465394884eea4fd6fa0eb9e45f9ec91bec57cb9
ilyakava/sumproduct
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import setup, find_packages\n\nsetup(\n name='panoptes_client',\n url='https://github.com/zooniverse/panoptes-python-client',\n author='Adam McMaster',\n author_email='<EMAIL>',\n version='1.0.3',\n package...
python
edit
1
0
apache-2.0
44b311eade20016f613311a98d666b2463826ad1
zooniverse/panoptes-python-client
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom common.bounty import *\nfrom common.peers import *\nfrom common import settings\nfrom time import sleep\nfrom common.safeprint import safeprint\n\ndef main():\n settings.setup()\n try:\n import miniupnpc\n except:\n ...
python
edit
7
2
mit
74d4868a0e43e5eb089d6d7a0a07545b7f829806
gappleto97/Senior-Project
main.py
rejected_lint
Too many lint violations: 7
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n\nfrom setuptools import setup\n\nrequirements = [\n 'boto3',\n 'pandas<0.20',\n 'psycopg2',\n]\n\ntest_requirements = [\n 'pytest',\n]\n\nsetup(\n name='demae',\n version='0.8.0',\n description=\...
python
edit
1
0
mit
c72500abaeb1149d35fd6fcb28cb6a321b998045
uiureo/demae
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.conf import settings\nfrom django.core.management.base import BaseCommand\n\nclass Command(BaseCommand):\n\n help = \"Update value type of fs_site and fs_uuid in mongo instances to make string type to int type\"\n\n def ha...
python
edit
1
6
bsd-2-clause
34452461de40c35d28bfc8b2a18b6fa14ebb875d
awemulya/fieldsight-kobocat,awemulya/fieldsight-kobocat,awemulya/fieldsight-kobocat,awemulya/fieldsight-kobocat
onadata/apps/fsforms/management/commands/update_mongo_value_type.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nCopyright (c) 2014, Joseph Cross.\n\nPermission is hereby granted, free of charge, to any person obtaining a copy\nof this software and associated documentation files (the \"Software\"), to deal\nin the Software without restriction,...
python
edit
1
0
mit
f1eae848aa48ef3891407f400410827d59d7c880
numberoverzero/pyservice
pyservice/__init__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.conf.urls import patterns, include, url\nfrom django.contrib import admin\n\nurlpatterns = patterns('',\n url(r'^$', 'devlol.views.index'),\n\n # Static Stuff\n url(r'^location/$', 'devlol.views.location'),\n url(r'^...
python
edit
1
0
mit
0bd76b828fbd81ac85b7384174692e46e8ef3205
DevLoL/devlol.at,DevLoL/devlol.at,DevLoL/devlol.at,DevLoL/devlol.at
devlol/urls.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\nimport shutil\nimport unittest\n\nfrom stash import Stash\n\nclass StashTestCase(unittest.TestCase):\n \"\"\"Base class for test cases that test stash functionality.\n\n This base class makes sure that all unit tests are ex...
python
edit
1
3
bsd-3-clause
6e4e073b4979bbf6099d0054181f13134f8cfe73
ton/stash,ton/stash
stash_test_case.py
rejected_duplicate
Near-duplicate of sample 18522
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.core.management.base import BaseCommand\n\nfrom us_ignite.apps.models import Feature, Domain\n\n\nFEATURE_LIST = (\n 'SDN',\n 'OpenFlow',\n 'Ultra fast',\n 'Speed',\n 'Low-latency',\n 'Local cloud / edge comput...
python
edit
4
5
bsd-3-clause
126d79011221da6692d70f9a9aba1f335155ab58
us-ignite/us_ignite,us-ignite/us_ignite,us-ignite/us_ignite,us-ignite/us_ignite,us-ignite/us_ignite
us_ignite/apps/management/commands/app_load_fixtures.py
rejected_lint
Too many lint violations: 4
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\nimport unittest\nfrom config import Config\n\n\nclass HelperMethodsTest(unittest.TestCase):\n\n def test_that_config_week_is_only_A_or_B(self):\n \"\"\"\n This test ensures that the only value set for 'WEEK'\n ...
python
edit
1
2
mit
102a35d9ce74a4f29be2fc0bb34b80cb7ee4d77d
andela-kanyanwu/food-bot-review
tests/helper_methods_test.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.conf.urls import url, include\nfrom django.contrib import admin\n\nurlpatterns = [\n url(r'^climate/', include('climate.urls')),\n url(r'^herbarium/', include('herbarium.urls')),\n url(r'^api-auth/', include('rest_frame...
python
edit
1
0
apache-2.0
c6b51b82fa0503a2696161374160c47297211c7c
qubs/data-centre,qubs/data-centre,qubs/climate-data-api,qubs/climate-data-api
qubs_data_api/urls.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom custom.uth.utils import create_case, match_case, attach_images_to_case\nfrom custom.uth.models import SonositeUpload, VscanUpload\nfrom celery.task import task\n\n\n@task\ndef async_create_case(upload_id):\n upload_doc = SonositeUpl...
python
edit
1
2
bsd-3-clause
7c9b0ac281d39cbe8b694a4cb7a4dd0c171351e0
qedsoftware/commcare-hq,qedsoftware/commcare-hq,qedsoftware/commcare-hq,puttarajubr/commcare-hq,dimagi/commcare-hq,puttarajubr/commcare-hq,puttarajubr/commcare-hq,dimagi/commcare-hq,SEL-Columbia/commcare-hq,dimagi/commcare-hq,dimagi/commcare-hq,SEL-Columbia/commcare-hq,SEL-Columbia/commcare-hq,puttarajubr/commcare-hq,q...
custom/uth/tasks.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\nimport json\n\n\nclass Struct:\n def __init__(self, **args):\n self.__dict__.update(args)\n\n def get_url(self, key):\n self._dict__.get(key)\n\ntry:\n nar_path = os.environ[\"NARRATIVEDIR\"]\n config_js...
python
edit
1
1
mit
d4de0c4fdf205c1107b08ccba0b428125d81de1a
msneddon/narrative,psnovichkov/narrative,aekazakov/narrative,msneddon/narrative,psnovichkov/narrative,psnovichkov/narrative,jmchandonia/narrative,briehl/narrative,rsutormin/narrative,aekazakov/narrative,psnovichkov/narrative,psnovichkov/narrative,briehl/narrative,nlharris/narrative,msneddon/narrative,scanon/narrative,j...
src/biokbase/narrative/common/url_config.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# -*- coding: utf-8 -*-\n\ndef log_request(self):\n log = self.server.log\n if log:\n if hasattr(log, 'info'):\n log.info(self.format_request() + '\\n')\n else:\n log.write(self.format_request() + '...
python
edit
1
3
mit
ac00ef4ac08c6e47de80c33a6781d00c7b2bc943
clarkduvall/flask-sockets
flask_sockets.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.shortcuts import render\n\nfrom .models import Task\n\ndef index(request):\n\ttasks_list = Task.objects.filter(closed=False)\n\tcontext = {'tasks_list' : tasks_list,}\t\n\treturn render(request, 'taskzilla/index.html', context)\...
python
edit
1
1
mit
b77174948721413de84d6037ef4e4329978978cc
static-code-generators/taskzilla,jailuthra/taskzilla,jailuthra/taskzilla,static-code-generators/taskzilla,static-code-generators/taskzilla,jailuthra/taskzilla
taskzilla/views.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport subprocess\nimport os\nimport mail_handler\nfrom datetime import datetime\nfrom settings_handler import settings\n\ndef execJobs(jobs):\n\ttry:\n\t\tfor job in jobs:\n\t\t\tif not execJob(job):\n\t\t\t\treturn False\n\t\tprint \"Jobs...
python
edit
5
4
apache-2.0
1f13b7734b06e3c9572865734defa0b1afd4db8b
baumartig/paperboy
jobs_executor.py
rejected_lint
Too many lint violations: 5
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os, logging\nfrom flask import Flask\nfrom raven.contrib.flask import Sentry\n\napp = Flask(__name__)\n\napp.config.from_object(os.environ.get('SETTINGS'))\n\napp.logger.debug(\"\\nConfiguration\\n%s\\n\" % app.config)\n\n# Sentry ex...
python
edit
1
0
mit
b0c7e61178a5eb81dc24aab9911baaeccda546ff
LandRegistry/search-api-alpha,LandRegistry/search-api-alpha
searchapi/__init__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport gntp\nimport Growl\n\nclass GNTPRegister(gntp.GNTPRegister):\n\tdef send(self):\n\t\tprint 'Sending Registration'\n\t\tgrowl = Growl.GrowlNotifier(\n\t\t\tapplicationName\t\t\t= self.headers['Application-Name'],\n\t\t\tnotifications\...
python
edit
3
3
mit
2d25e6e70df357d19d9e873d94ac57d25bd7e6aa
kfdm/gntp-regrowl
local.py
rejected_duplicate
Near-duplicate of sample 13196
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"Test client that connects and sends infinite data.\"\"\"\n\nimport sys\n\nfrom tulip import *\n\ndef dprint(*args):\n print('source:', *args, file=sys.stderr)\n\nclass Client(Protocol):\n\n data = b'x'*16*1024\n\n def con...
python
edit
7
2
apache-2.0
00fd8b13e36c5e7020b7769f6dcd1afecfb79fb3
Martiusweb/asyncio,manipopopo/asyncio,jashandeep-sohi/asyncio,manipopopo/asyncio,ajdavis/asyncio,1st1/asyncio,gvanrossum/asyncio,manipopopo/asyncio,1st1/asyncio,fallen/asyncio,vxgmichel/asyncio,haypo/trollius,gvanrossum/asyncio,vxgmichel/asyncio,fallen/asyncio,ajdavis/asyncio,gsb-eng/asyncio,jashandeep-sohi/asyncio,Mar...
examples/source.py
rejected_lint
Too many lint violations: 7
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom sf.lib.orderedattrdict import OrderedAttrDict\n\n\nclass Parameters(OrderedAttrDict):\n pass\n\n\nclass ParameterValues(OrderedAttrDict):\n pass\n\n\nclass Parameter(object):\n\n def __init__(self, default=None, label=None):\n...
python
edit
1
2
mit
4823b42b23580e0a294c1e4ddb3b5b62abf9c7bc
metrasynth/solar-flares
sf/mmck/parameters.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# -*- coding: utf-8 -*-\nfrom django.conf.urls.defaults import patterns, include, url\nfrom django.conf import settings\nfrom views import email_add, email_list, email_delete, \\\n email_send_activation, email_activate, email_mak...
python
edit
4
0
bsd-3-clause
ab83da7b6152dfdc50cf40fa328f3c3d24c13861
un33k/django-emailmgr,un33k/django-emailmgr
emailmgr/urls.py
rejected_lint
Too many lint violations: 4
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\n# list examples\na=['spam','eggs',100,1234]\nlog(a[:2]+['bacon',2*2])\nlog(3*a[:3]+['Boo!'])\nlog(a[:])\na[2]=a[2]+23\nlog(a)\na[0:2]=[1,12]\nlog(a)\na[0:2]=[]\nlog(a)\na[1:1]=['bletch','xyzzy']\nlog(a)\na[:0]=a\nlog(a)\na[:]=[]\nlog(a)\n...
python
edit
12
0
bsd-3-clause
d49118a52c15b2434a43a717476cdc7340dfc8c6
sgzwiz/brython,sgzwiz/brython,sgzwiz/brython
test/test_suite.py
rejected_lint
Too many lint violations: 12
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.contrib.auth.models import User\nfrom django import forms\n\n\nclass SubscribeForm(forms.Form):\n email = forms.EmailField()\n tags = forms.CharField()\n\n def clean_tags(self):\n tags = self.cleaned_data['tags']...
python
edit
1
5
mit
aa15e9195c6e16ec000338e71051f64a692642e0
avinassh/nightreads,avinassh/nightreads
nightreads/user_manager/forms.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# coding: utf-8\n\nfrom __future__ import unicode_literals, print_function\n\nimport datetime\nimport unittest\n\nimport mock\n\nfrom cdek import api, exceptions\n\n\n@mock.patch('cdek.api.urlopen')\nclass CdekApiTest(unittest.TestCase):\n\...
python
edit
3
1
mit
0d3507d5eb9801b38c66fb03804e15b089fb2233
xtelaur/python-cdek,xtelaur/python-cdek
tests/cdek_test.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os, sys\n\n__file__ = os.path.normpath(os.path.abspath(__file__))\n__path__ = os.path.dirname(__file__)\n\n# print(__path__)\n\nif __path__ not in sys.path:\n sys.path.insert(0, __path__)\n\nfrom csharp_element import CSharpElemen...
python
edit
3
1
mit
d3356d42aa083ecebf53bb7792a573ed2289173b
adrianogil/SublimeUnityIntel
unityparser/csharp/csharp_class_body_parser.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nGenerically useful utilities.\n\"\"\"\nimport urlparse\n\ntry: # pragma: no cover\n from cStringIO import StringIO; StringIO\nexcept ImportError:\n from StringIO import StringIO; StringIO\n\n\nclass Constructor(object):\n d...
python
edit
3
2
isc
8f226fffd17b9d89d916ad4a1c42d43afc1f0634
lvh/minitrue
minitrue/utils.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\ndef configuration(parent_package='',top_path=None):\n from numpy.distutils.misc_util import Configuration\n config = Configuration('nipype', parent_package, top_path)\n\n # List all packages to be loaded here\n config.add_subpac...
python
edit
1
1
bsd-3-clause
3f1f666606a0b092c796fab27a67b2dde5a33cb9
christianbrodbeck/nipype,arokem/nipype,carlohamalainen/nipype,pearsonlab/nipype,sgiavasis/nipype,gerddie/nipype,blakedewey/nipype,FredLoney/nipype,fprados/nipype,grlee77/nipype,sgiavasis/nipype,JohnGriffiths/nipype,iglpdc/nipype,gerddie/nipype,iglpdc/nipype,dmordom/nipype,arokem/nipype,FCP-INDI/nipype,mick-d/nipype_sou...
nipype/setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"install_ext\n\nImplement the Distutils \"install_ext\" command to install extension modules.\"\"\"\n\n# created 1999/09/12, Greg Ward\n\n__revision__ = \"$Id$\"\n\nfrom distutils.core import Command\nfrom distutils.util import copy_tr...
python
edit
4
1
mit
d852781fe93c7a37b90387e2b388bf18ed3823d1
pypa/setuptools,pypa/setuptools,pypa/setuptools
command/install_ext.py
rejected_lint
Too many lint violations: 4
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom tilequeue.tile import serialize_coord, deserialize_coord, CoordMessage\nimport threading\n\n\nclass OutputFileQueue(object):\n\n def __init__(self, fp):\n self.fp = fp\n self.lock = threading.RLock()\n\n def enqueue...
python
edit
1
3
mit
4417b3c701e44fbf94fb7375a7a3f148f1ee6112
tilezen/tilequeue,mapzen/tilequeue
tilequeue/queue/file.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport pandas as pd\nimport numpy as np\nimport operator\nfrom sys import argv\nimport os \n\ndef extract( file_name ):\n with open(file_name) as f:\n for i,line in enumerate(f,1):\n if \"SCN\" i...
python
edit
3
3
mit
aace7956091f10af19dfe9eaaf12aef8b0f9f579
NCRA-TIFR/gadpu,NCRA-TIFR/gadpu
new_validity.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import setup, find_packages\n\n\nsetup(\n name=\"django-posgtres-geometry\",\n version=\"0.1.2\",\n packages=find_packages(),\n install_requires=['django', 'psycopg2'],\n description=\"Django ORM field for Pos...
python
edit
1
0
mit
8e0cf99380b284ff4f7b962f622933c243828be7
team23/django-postgres-geometry
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#! /usr/bin/env python\nfrom ez_setup import use_setuptools\nuse_setuptools()\nfrom setuptools import setup, find_packages\n\n\nsetup(name='permamodel',\n version='0.1.0',\n author='Elchin Jafarov and Scott Stewart',\n author...
python
edit
1
0
mit
f0a1555d9767db413d39b08865e2e3aa8f633d2f
permamodel/permamodel,permamodel/permamodel
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# The MIT License (MIT)\r\n# \r\n# Copyright (c) <2011-2014> <Shibzukhov Zaur, szport at gmail dot com>\r\n# \r\n# Permission is hereby granted, free of charge, to any person obtaining a copy\r\n# of this software and associated documentati...
python
edit
6
0
mit
d54854c11094e0ca8598e59de0bc0795dc8143c9
vovanbo/trafaretrecord,vovanbo/trafaretrecord
lib/recordclass/__init__.py
rejected_lint
Too many lint violations: 6
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import setup, find_packages\n\n\nwith open('README.rst') as f:\n readme = f.read()\n\nwith open('LICENSE') as f:\n license = f.read()\n\nwith open('requirements.txt') as f:\n requirements = f.readlines()\n\nsetup(\n...
python
edit
1
0
apache-2.0
ab6393c6b032689417c22d40fdce88807190b672
kevinconway/pycc,kevinconway/pycc
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# Profile the basic test execution\n\nfrom pyresttest import resttest\nfrom pyresttest.benchmarks import Benchmark\nimport cProfile\n\ntest = Benchmark()\ntest.warmup_runs = 0\ntest.benchmark_runs = 1000\ntest.raw_metrics = set()\ntest.metr...
python
edit
3
0
apache-2.0
7c9dac667c47d41c2da52ff993967f27016f6ba9
MorrisJobke/pyresttest,alazaro/pyresttest,suvarnaraju/pyresttest,sunyanhui/pyresttest,wirewit/pyresttest,holdenweb/pyresttest,suvarnaraju/pyresttest,janusnic/pyresttest,MorrisJobke/pyresttest,alazaro/pyresttest,wirewit/pyresttest,sunyanhui/pyresttest,svanoort/pyresttest,netjunki/pyresttest,janusnic/pyresttest,TimYi/pyr...
profile_benchmark.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import setup, find_packages\n\nsetup(\n name='ppci',\n description=\"Pure python compiler infrastructure\",\n scripts=[\"bin/zcc.py\", \"bin/st-flash.py\", 'bin/hexutil.py'],\n version='0.0.1',\n author='Winde...
python
edit
1
0
bsd-2-clause
83b7b66c2558f292ba686583388065b6b2da25cb
windelbouwman/ppci-mirror,windelbouwman/ppci-mirror,windelbouwman/ppci-mirror,windelbouwman/ppci-mirror,windelbouwman/ppci-mirror,windelbouwman/ppci-mirror
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n\nfrom setuptools import setup\n\nsetup(name='l1',\n version='0.1',\n description='L1',\n author='Bugra Akyildiz',\n author_email='<EMAIL>',\n url='bugra.github.io',\n packages=['l1'],\n ...
python
edit
1
0
apache-2.0
1f272ede03be0a9953839b1d19fe8a61ebef488f
bugra/l1
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python3\n\nfrom setuptools import find_packages, setup\n\nsetup(\n name='django-afip',\n description='AFIP integration for django',\n author='Hugo Osvaldo Barrera',\n author_email='<EMAIL>',\n url='https://gitl...
python
edit
1
0
isc
3154a8bd09e8d445de6893862c646c9fb983021d
hobarrera/django-afip,hobarrera/django-afip
setup.py
rejected_duplicate
Near-duplicate of sample 2707
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import setup, find_packages\n\n\nsetup(\n name='validation',\n url='https://github.com/JOIVY/validation',\n version='0.0.1',\n author='Ben Mather',\n author_email='<EMAIL>',\n maintainer='',\n license='B...
python
edit
1
0
apache-2.0
e3fbf8ca10f0ed522bd2e819479bd93243ec4990
JOIVY/validation
setup.py
rejected_duplicate
Near-duplicate of sample 17094
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n\nfrom setuptools import setup\nimport argparse_addons\n\nsetup(name='argparse_addons',\n version=argparse_addons.__version__,\n description=('Additional argparse types and actions.'),\n long_descriptio...
python
edit
1
0
mit
5c53a20363786bdecc4414631ad776abb1dd72d1
eerimoq/argparse_addons
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import setup, find_packages\n\nsetup(\n name=\"vxtwinio\",\n version=\"0.0.1a\",\n url=\"https://github.com/praekelt/vumi-twilio-api\",\n license=\"BSD\",\n description=\"Provides a REST API to Vumi that emula...
python
edit
1
0
bsd-3-clause
92af23a3677d57364ec3d7bf6aaf8d320dd4fe94
praekelt/vumi-twilio-api
setup.py
rejected_duplicate
Near-duplicate of sample 2177
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import setup, find_packages\n\nsetup(\n name='jupyterhub-kubespawner',\n version='0.5.1',\n install_requires=[\n 'jupyterhub',\n 'pyyaml',\n 'kubernetes==2.*',\n 'escapism',\n ],\n ...
python
edit
1
0
bsd-3-clause
4c75f1ecb9a0a6533b02834ec2a0db91472f7f32
jupyterhub/kubespawner,ktong/kubespawner,yuvipanda/jupyterhub-kubernetes-spawner
setup.py
rejected_duplicate
Near-duplicate of sample 12174
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import setup\n\ncli_tools = [\"spritecss = spritecss.main:main\"]\n\nsetup(name=\"spritecss\", version=\"0.5\", url=\"http://yostudios.se/\",\n author=\"Yo Studios AB\", author_email=\"<EMAIL>\",\n description=\"Do...
python
edit
1
0
mit
ae09eb021d6b119a2fdb9a82852ab424acf8f409
wpj-cz/Spritemapper,yostudios/Spritemapper,yostudios/Spritemapper,wpj-cz/Spritemapper,wpj-cz/Spritemapper,wpj-cz/Spritemapper,yostudios/Spritemapper
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import find_packages, setup\nimport sys\n\n\nif 'install' in sys.argv:\n import webbrowser\n webbrowser.open('https://www.youtube.com/watch?v=NMZcwXh7HDA', new=2, autoraise=True)\n\n\nsetup(\n name='rdalal',\n ve...
python
edit
1
0
bsd-3-clause
323d52928fa58196299e1dde0c5b3ef0d1451d9f
willkg/rdalal
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import setup, find_packages\n\nfrom lighthouse import __version__\n\n\nclassifiers = []\nwith open(\"classifiers.txt\") as fd:\n classifiers = fd.readlines()\n\n\nsetup(\n name=\"lighthouse\",\n version=__version__,...
python
edit
1
0
apache-2.0
fe7d10780cd3c98277c64621c07daab0837b6722
wglass/lighthouse
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom distutils.core import setup\nfrom setuptools import setup, find_packages\n\nsetup(\n name = \"django-webmaster-verification\",\n version = \"0.1\",\n author = \"Nicolas Kuttler\",\n author_email = \"<EMAIL>\",\n descript...
python
edit
1
0
bsd-3-clause
e211c9cb76a2f20e8b00a88e148850829ad86ec5
nkuttler/django-webmaster-verification,nkuttler/django-webmaster-verification
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\nfrom setuptools import setup, find_packages\nimport sys\nimport os\nimport glob\n\nsetup(name = \"scilifelab\",\n version = \"0.2.2\",\n author = \"Science for Life Laboratory\",\n author_email = \"<EMA...
python
edit
3
0
mit
f176a726debd870fa2f75bdf7ccf8229bab95da4
senthil10/scilifelab,SciLifeLab/scilifelab,SciLifeLab/scilifelab,SciLifeLab/scilifelab,kate-v-stepanova/scilifelab,jun-wan/scilifelab,senthil10/scilifelab,kate-v-stepanova/scilifelab,jun-wan/scilifelab,SciLifeLab/scilifelab,kate-v-stepanova/scilifelab,jun-wan/scilifelab,senthil10/scilifelab,jun-wan/scilifelab,kate-v-st...
setup.py
rejected_duplicate
Near-duplicate of sample 17860
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n\nfrom setuptools import setup, find_packages\nimport os\n\nhere = os.path.abspath(os.path.dirname(__file__))\nwith open(os.path.join(here, 'README')) as f:\n README = f.read()\n\nrequires = []\n\nsetup(name='pytho...
python
edit
1
0
mit
26e30e7f283a9ffb0a9a9a3f1a6f11f11bbab1e1
petertodd/dust-b-gone
setup.py
rejected_duplicate
Near-duplicate of sample 11235
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\nfrom setuptools import setup\n\nsetup(\n name='exp_sdk',\n packages= ['exp_sdk'],\n version='1.0.0a2',\n description='EXP Python SDK',\n author='Scala',\n author_email='<EMAIL>',\n url='https://github.com/scalainc/exp-python2-sdk',...
python
edit
1
0
mit
9c8289f531abfd75a1c378f53ea58136e29e662c
ScalaInc/exp-python2-sdk,ScalaInc/exp-python2-sdk
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\ntry:\n from collections import OrderedDict\nexcept:\n from ordereddict import OrderedDict\n\ntry:\n from reprlib import recursive_repr\nexcept:\n # don't cope with recursive repr calls in py2\n def recursive_repr(fillvalue='....
python
edit
1
6
unlicense
ebb742165ada521b7d883d3d228d69edc9b1fee7
ajtowns/odictliteral
odictliteral.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport io\nimport os\nimport re\nfrom setuptools import setup, find_packages\n\n\ndef find_version():\n file_dir = os.path.dirname(__file__)\n with io.open(os.path.join(file_dir, 'auth0', '__init__.py')) as f:\n version = re.se...
python
edit
1
2
mit
8a2fa728cc62b61eb83f180fb73784d06482ec2e
auth0/auth0-python,auth0/auth0-python
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import setup, find_packages\n\n\ninstall_requires = [\n 'dill==0.2.5',\n 'easydict==1.6',\n 'h5py==2.6.0',\n 'jsonpickle==0.9.3',\n 'Keras==1.2.0',\n 'nflgame==1.2.20',\n 'numpy==1.11.2',\n 'pandas==0...
python
edit
1
0
mit
8bc2395dd1814f0fa02dc8c48db1cae3f340c6a6
kahnjw/wincast
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport pytest\n\n@pytest.mark.parametrize(\"name\", [\n (\"apt-file\"),\n (\"apt-transport-https\"),\n (\"blktrace\"),\n (\"ca-certificates\"),\n (\"chromium-browser\"),\n (\"cron\"),\n (\"curl\"),\n (\"diod\"),\n (\"docker-ce\"),\...
python
edit
1
1
mit
5a808dfa9ae8661382fbc00641562f2024931b57
wicksy/laptop-build,wicksy/laptop-build,wicksy/laptop-build,wicksy/laptop-build
test/test_packages.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom urlparse import parse_qs\n\nfrom utils import cached_property, MultiDict\n\n\nclass Request(object):\n def __init__(self, event, context):\n self.event = event\n self.context = context\n\n @property\n def method(...
python
edit
1
2
bsd-3-clause
ec7bbe8ac8715ea22142680f0d880a7d0b71c687
funkybob/paws
paws/request.py
rejected_duplicate
Near-duplicate of sample 16952
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom .fixtures import elasticsearch\nimport pytest\n\nimage_flavor = pytest.config.getoption('--image-flavor')\n\n\ndef test_elasticsearch_logs_are_in_docker_logs(elasticsearch):\n elasticsearch.assert_in_docker_log('o.e.n.Node')\n # ...
python
edit
6
1
apache-2.0
f4bc89564828011d2306e16cdc84e053beb7c1d6
jarpy/elasticsearch-docker,jarpy/elasticsearch-docker
tests/test_logging.py
rejected_lint
Too many lint violations: 6
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# basic list functionality\nx = [1, 2, 3 * 4]\nprint(x)\nx[0] = 4\nprint(x)\nx[1] += -4\nprint(x)\nx.append(5)\nprint(x)\nf = x.append\nf(4)\nprint(x)\n\nx.extend([100, 200])\nprint(x)\n\nx += [2, 1]\nprint(x)\n\nprint(x[1:])\nprint(x[:-1])...
python
edit
1
0
mit
51413c8cb63bfdc4fba3f0a144459b0082ce2bf2
pramasoul/micropython,dmazzella/micropython,HenrikSolver/micropython,turbinenreiter/micropython,stonegithubs/micropython,bvernoux/micropython,ernesto-g/micropython,ernesto-g/micropython,blazewicz/micropython,cloudformdesign/micropython,puuu/micropython,slzatz/micropython,omtinez/micropython,SHA2017-badge/micropython-es...
tests/basics/list1.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\nimport time\nprint 'Content-Type: text/javascript'\nprint ''\nprint 'var timeskew = new Date().getTime() - ' + str(time.time()*1000) + ';'\n\n```\n\nApply this change: Disable caching of stale time stamp information."...
python
edit
7
0
apache-2.0
bc65fb47a777c0ef501bb492d8003d01ce22b233
fargly/google-authenticator,google/google-authenticator,fargly/google-authenticator,fargly/google-authenticator,google/google-authenticator
libpam/utc-time/utc-time.py
rejected_lint
Too many lint violations: 7
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport click\n\nfrom flask import Flask, current_app\napp = Flask(__name__)\napp.config.from_object('dad.worker.settings')\n\nimport dad.worker.server # noqa\n\n\n@click.command()\n@click.option('--port', '-p', default=6010)\ndef run(port)...
python
edit
1
1
bsd-3-clause
f0157d9523f09d6a1392685f7b13cfac9f6bf6c0
ionrock/dadd,ionrock/dadd,ionrock/dadd,ionrock/dadd
dad/worker/__init__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom thinglang import run\n\n\ndef test_class_integration():\n assert run(\"\"\"\nthing Person\n has text name\n has number age\n\n created with name\n self.name = name\n self.age = 0\n\n does grow_up\n s...
python
edit
1
2
mit
423d40b8162ff2763346ddf0a115760c6efb4222
ytanay/thinglang,ytanay/thinglang,ytanay/thinglang,ytanay/thinglang
tests/test_classes.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# Copyright 2018 D-Wave Systems Inc.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# ...
python
edit
1
0
apache-2.0
bd30e0596a6310962ea0cf2e83a3ccd6eb9cf4ff
dwavesystems/dimod,dwavesystems/dimod
dimod/package_info.py
rejected_duplicate
Near-duplicate of sample 1547
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/python\n\n\"\"\"Runs the unit test suite for perf dashboard.\"\"\"\n\nimport argparse\nimport dev_appserver\nimport os\nimport sys\nimport unittest\n\n_DASHBOARD_PARENT = os.path.join(os.path.dirname(__file__))\n_DASHBOARD = os.p...
python
edit
3
2
bsd-3-clause
26b1b92d23eddd3496aa77a97d93bc7745047f24
catapult-project/catapult,zeptonaut/catapult,catapult-project/catapult-csm,modulexcite/catapult,catapult-project/catapult-csm,danbeam/catapult,sahiljain/catapult,dstockwell/catapult,SummerLW/Perf-Insight-Report,SummerLW/Perf-Insight-Report,sahiljain/catapult,SummerLW/Perf-Insight-Report,benschmaus/catapult,catapult-pro...
dashboard/run_tests.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\nimport sys\nsys.path.insert(0, os.path.join(os.path.dirname(__file__), '..'))\nimport logging\nimport threading\nimport xmpp2\nfrom xmpp2 import XML\n\nUSERNAME = 'yourusername'\nPASSWORD = 'yourpassword'\nSERVER = 'example.com'\...
python
edit
3
0
mit
aaeabe5d6a987a04b6e78853eb1dfd7d4b85e505
easies/xmpp2
examples/demo2.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# Copyright Least Authority Enterprises.\n# See LICENSE for details.\n\n\"\"\"\nAn in-memory implementation of the Kubernetes client interface.\n\"\"\"\n\nfrom zope.interface import implementer\n\nfrom twisted.python.url import URL\n\nfrom ...
python
edit
1
1
mit
da85cfae848df4cee5ccf2cbbbc370848ea172a7
LeastAuthority/txkube
src/txkube/_memory.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nThe qiprofile Mongodb data model.\n\nThe model field choices are listed in the preferred display order,\nmost common to least common.\n\nThe data capture client has the following responsibility:\n\n* Validate the data upon input as...
python
edit
1
0
bsd-2-clause
135d8da492c4ee763727c2df75b20274c7e17cf0
ohsu-qin/qirest,ohsu-qin/qiprofile-rest
qiprofile_rest/model/__init__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\nimport os\nimport logging\nimport sys\nfrom datetime import datetime\n\nfrom .config import Config\nfrom .submit import submit\n\nc = Config(os.environ)\n\nif c.verbose:\n level=logging.D...
python
edit
1
0
apache-2.0
6d2172a72ca3fc5de628c49bce9c0cbf191a9a61
deconst/submitter,deconst/submitter
submitter/__main__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom .base import *\n\nDATABASES = {\n 'default': {\n 'ENGINE': 'django.db.backends.postgresql_psycopg2',\n 'NAME': 'docs',\n 'USER': 'postgres', # Not used with sqlite3.\n 'PASSWORD': '',...
python
edit
3
0
mit
888fd7120f2a3a1cd5ec73da16705c27cda049fc
asampat3090/readthedocs.org,KamranMackey/readthedocs.org,sils1297/readthedocs.org,kdkeyser/readthedocs.org,LukasBoersma/readthedocs.org,mrshoki/readthedocs.org,Carreau/readthedocs.org,fujita-shintaro/readthedocs.org,sid-kap/readthedocs.org,sunnyzwh/readthedocs.org,kenshinthebattosai/readthedocs.org,sunnyzwh/readthedocs...
readthedocs/settings/postgres.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django import forms\nfrom django_summernote.widgets import SummernoteWidget\nfrom django.core.exceptions import NON_FIELD_ERRORS\n\nfrom .models import Post\n\n\nclass PostForm(forms.ModelForm):\n class Meta:\n model = Post\n...
python
edit
1
3
mit
d0bd57cbdf8ba451e12f7e6b2574cd77132f0f3b
cjh5414/kboard,darjeeling/k-board,cjh5414/kboard,hyesun03/k-board,guswnsxodlf/k-board,kboard/kboard,guswnsxodlf/k-board,kboard/kboard,hyesun03/k-board,cjh5414/kboard,guswnsxodlf/k-board,kboard/kboard,hyesun03/k-board
kboard/board/forms.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nScraper for Massachusetts Appeals Court\nCourtID: massapp\nCourt Short Name: MS\nAuthor: William Palin\nCourt Contact: <EMAIL> (617) 557-1030\nReviewer:\nDate: 2020-01-17\n\"\"\"\n\nfrom juriscraper.opinions.united_states.state impo...
python
edit
1
1
bsd-2-clause
d4de2b2ff0cb7ba6ad4eed7fe2c0b70801e3c057
freelawproject/juriscraper,freelawproject/juriscraper
juriscraper/opinions/united_states/state/massappct128.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\n\nimport pytest\n\nimport setuptools\n\n\n@pytest.fixture\ndef example_source(tmpdir):\n tmpdir.mkdir('foo')\n (tmpdir / 'foo/bar.py').write('')\n (tmpdir / 'readme.txt').write('')\n return tmpdir\n\n\ndef test_findal...
python
edit
1
2
mit
3f4ef89512da6a3e89f27121446ec59773869017
pypa/setuptools,pypa/setuptools,pypa/setuptools
setuptools/tests/test_setuptools.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\ndef sort_by_property(prop):\n def _sort_by_property(items):\n return sorted(items,\n key=lambda item: getattr(item, prop),\n reverse=True)\n\n return _sort_by_property\n\nsort_by_popu...
python
edit
1
1
mit
2f29db7bd30b3db40f6577a4718623f6cd97a5cf
vanng822/geosearch,vanng822/geosearch,vanng822/geosearch
search/sorting.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django import forms\n\n\nclass SubscribeForm(forms.Form):\n email = forms.EmailField()\n tags = forms.CharField()\n\n def clean(self):\n tags = self.cleaned_data['tags'].split(',')\n self.cleaned_data['tags'] = [...
python
edit
1
2
mit
ada3e5dca1e777187a0933bd7b83fcb38c4faf66
avinassh/nightreads,avinassh/nightreads
nightreads/user_manager/forms.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# Copyright 2017 Google Inc. All Rights Reserved.\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n# ...
python
edit
1
0
apache-2.0
7131b2d82a856bfb4f7348567b8795243a24074a
DataBiosphere/dsub,DataBiosphere/dsub
dsub/_dsub_version.py
rejected_duplicate
Near-duplicate of sample 2591
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python3\n\n\"\"\"Get a markdown-formatted list of PRs merged since a certain tag.\"\"\"\n\nimport github_tools\n\nRepo = github_tools.get_repo()\n\n# TODO: implement getting date from repo tag./\ntagname = '0.8.1'\ntags = Rep...
python
edit
1
0
mit
67469ca12b6145eed4051bd85c928f88d4d13791
bilderbuchi/OF_repo_utilities
get_merged_prs_since_tag.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport logging\nimport os\n\nfrom .test_settings import *\n\n\ntry:\n import debug_panel\nexcept ImportError:\n # no debug panel, no use trying to add it to our middleware\n pass\nelse:\n # if debug_panel exists, add it to our I...
python
edit
8
0
mit
b74a95c81958ca567052e27f4df6d211d75f4a90
jayoshih/content-curation,jayoshih/content-curation,DXCanas/content-curation,fle-internal/content-curation,DXCanas/content-curation,DXCanas/content-curation,fle-internal/content-curation,fle-internal/content-curation,jayoshih/content-curation,DXCanas/content-curation,fle-internal/content-curation,jayoshih/content-curat...
contentcuration/contentcuration/dev_settings.py
rejected_lint
Too many lint violations: 8
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport re\n\nfrom django.http import QueryDict\n\nclass HttpMethodOverrideMiddleware:\n \"\"\"\n Facilitate for overriding the HTTP method with the X-HTTP-Method-Override\n header or a '_method' HTTP POST parameter.\n \"\"\"\n\n...
python
edit
1
5
mit
00c5f9b382fd1b060a973a3a3a1db33c280f2dd7
jgorset/django-respite,jgorset/django-respite,jgorset/django-respite
respite/middleware.py
rejected_duplicate
Near-duplicate of sample 20707
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\n__author__ = 'To\\xc3\\xb1o G. Quintela (<EMAIL>)'\n__version__ = '0.0.0'\n\n#from pyCausality.TimeSeries.TS import *\n\n\n#from pyCausality.TimeSeries.automatic_thresholding import *\n#from pyCausality.TimeSeries.distances import *\n#fro...
python
edit
6
1
mit
6b870b6605827472ff86f1d180fe94fa5bb5ea5d
tgquintela/TimeSeriesTools,tgquintela/TimeSeriesTools
TimeSeriesTools/__init__.py
rejected_lint
Too many lint violations: 6
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# This file is part of h5py, a Python interface to the HDF5 library.\n#\n# http://www.h5py.org\n#\n# Copyright 2008-2013 Andrew Collette and contributors\n#\n# License: Standard 3-clause BSD; see \"license.txt\" for full license terms\n# ...
python
edit
1
0
bsd-3-clause
b5db068a5545880d5d66d0be3ce88ccc393adcb0
h5py/h5py,h5py/h5py,h5py/h5py
h5py/_hl/__init__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\nfrom flask import Flask\nfrom flask import render_template\nfrom marvin import client\nimport logging\n\napp = Flask(__name__, static_url_path='/static')\n\n@app.route('/')\ndef home_page():\n # get list of transfered files\n files ...
python
edit
3
1
mit
cfa1b895b5b3e44dd66565add95f636736153536
dou-hackathon-2015-marvin/marvin,dou-hackathon-2015-marvin/marvin,dou-hackathon-2015-marvin/marvin,dou-hackathon-2015-marvin/marvin
marvin/stats/views.py
accepted
null
true