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\"\"\" Convenience functions to load example datasets \"\"\"\n\nimport os\nimport scarplet as sl\n\n\nEXAMPLE_DIRECTORY = os.path.join(os.path.dirname(os.path.abspath(__file__)),\n 'data/')\n\n\ndef load_carr...
python
edit
1
1
mit
6b148e4c98628e9ef60cc3ce70c7cdeb8a215c49
rmsare/scarplet,stgl/scarplet
scarplet/datasets/base.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport jsl\n\n\nclass TargetInfo(jsl.Document):\n docker = jsl.ArrayField(jsl.StringField(), max_items=2)\n rsync = jsl.ArrayField(jsl.StringField(), max_items=2)\n containers = jsl.ArrayField([\n jsl.StringField(),\n ...
python
edit
1
0
apache-2.0
3a74774a42521f4b68e484855d103495438095c3
leapp-to/snactor
examples/schema/targetinfo.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport requests\n\nGITHUB_API_URL = \"https://api.github.com/graphql\"\n\nQUERY = \"\"\"\nquery($repository_owner:String!, $repository_name: String!, $count: Int!) {\n repository(\n owner: $repository_owner,\n name: $repository_name)...
python
edit
3
1
mit
74260bc1b401d9ec500fba1eae72b99c2a2db147
ayushgoel/LongShot
github.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\nimport os\n\n\"\"\"\nPerforms some core NLP operations as a proof of concept for the library.\n\"\"\"\n\nfrom stanford_corenlp_pywrapper import CoreNLP\n\nclass StanfordCoreNLP:\n def __init__(self):\n # I d...
python
edit
1
4
mit
896a9b3d116a6ac2d313c5ea8dbc16345a097138
rigatoni/linguine-python,Pastafarians/linguine-python
linguine/ops/StanfordCoreNLP.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom .misc.lazy_module import LazyModule\nfrom .version import \\\n short_version as __version__, git_revision as __git_version__\n\nADDONS_ENTRY_POINT = 'orange.addons'\n\nfrom Orange import data\n\nfor mod_name in ['classification', 'c...
python
edit
5
0
bsd-2-clause
05e62b96cfa50934d98d78a86307d94239dd7a4b
cheral/orange3,qPCR4vir/orange3,kwikadi/orange3,qusp/orange3,cheral/orange3,cheral/orange3,marinkaz/orange3,kwikadi/orange3,kwikadi/orange3,cheral/orange3,qPCR4vir/orange3,qPCR4vir/orange3,qusp/orange3,kwikadi/orange3,marinkaz/orange3,marinkaz/orange3,kwikadi/orange3,qusp/orange3,marinkaz/orange3,qusp/orange3,qPCR4vir/...
Orange/__init__.py
rejected_lint
Too many lint violations: 5
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom vumi.persist.model import VumiRiakError\nfrom go_api.collections.errors import CollectionUsageError\nfrom go_api.queue import PausingQueueCloseMarker\nfrom twisted.internet.defer import inlineCallbacks, returnValue\n\n\n@inlineCallback...
python
edit
1
5
bsd-3-clause
f473cc24e0f2a41699ed9e684b400cb5cb562ce6
praekelt/go-contacts-api,praekelt/go-contacts-api
go_contacts/backends/utils.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nsentry_heroku.plugin\n~~~~~~~~~~~~~~~~~~~~\n\n:copyright: (c) 2015 by Sentry Team, see AUTHORS for more details.\n:license: Apache 2.0, see LICENSE for more details.\n\"\"\"\nimport sentry_heroku\n\nfrom sentry.plugins import Releas...
python
edit
1
1
apache-2.0
6d018ef0ac8bc020b38dab1dd29dd6e383be2e8e
getsentry/sentry-heroku
src/sentry_heroku/plugin.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nsentry\n~~~~~~\n\n:copyright: (c) 2010 by the Sentry Team, see AUTHORS for more details.\n:license: BSD, see LICENSE for more details.\n\"\"\"\n\n__all__ = ('VERSION', 'Client', 'load')\n\ntry:\n VERSION = __import__('pkg_resourc...
python
edit
7
0
bsd-3-clause
5704912ea9ba866848b6942d6330d30203d90f8b
someonehan/raven-python,smarkets/raven-python,inspirehep/raven-python,jmagnusson/raven-python,ewdurbin/raven-python,inspirehep/raven-python,danriti/raven-python,openlabs/raven,daikeren/opbeat_python,arthurlogilab/raven-python,akalipetis/raven-python,beniwohli/apm-agent-python,Photonomie/raven-python,jmagnusson/raven-py...
raven/__init__.py
rejected_lint
Too many lint violations: 7
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom protobuf3.fields.string import StringField\nfrom protobuf3.message import Message\nfrom unittest import TestCase\n\n\nclass TestStringField(TestCase):\n def setUp(self):\n class StringTestMessage(Message):\n b = St...
python
edit
1
1
mit
389befbf655e6b1608aff79d176365c79c91fe2b
Pr0Ger/protobuf3
tests/fields/test_string.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\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# http://www.apache.org/licenses/LICENSE-2.0\n#\n# U...
python
edit
1
1
apache-2.0
e6ae7fc2c30aa8af087b803408359189ece58f30
rajalokan/keystone,mahak/keystone,rajalokan/keystone,ilay09/keystone,openstack/keystone,rajalokan/keystone,openstack/keystone,openstack/keystone,mahak/keystone,ilay09/keystone,mahak/keystone,ilay09/keystone
keystone/common/policies/revoke_event.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django import template\n\nregister = template.Library()\n\n\n@register.filter\ndef get_range(value):\n return range(value)\n\n\n@register.filter\ndef absolute(value):\n return abs(value)\n\n\n@register.filter\ndef subtract(value,...
python
edit
1
2
apache-2.0
b7b41a160294edd987f73be7817c8b08aa8ed70e
porksmash/swarfarm,PeteAndersen/swarfarm,PeteAndersen/swarfarm,porksmash/swarfarm,PeteAndersen/swarfarm,porksmash/swarfarm,porksmash/swarfarm,PeteAndersen/swarfarm
herders/templatetags/utils.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport httplib2\n\nfrom decorator import decorator\nfrom django.core.urlresolvers import reverse\nfrom django.shortcuts import redirect\nfrom googleapiclient import discovery\nfrom oauth2client.client import OAuth2Credentials\n\n\n@decorato...
python
edit
1
3
mit
400289449e164ff168372d9df286acba35926e61
nihn/map-points,nihn/map-points,nihn/map-points,nihn/map-points
map_points/oauth2/decorators.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom flask import Flask\nfrom flask.ext.mongoengine import MongoEngine\nimport logging\n# configure the logging\nlogging.basicConfig(level='DEBUG', format='%(asctime)s - %(name)s - %(levelname)s - %(message)s')\n\napp = Flask(__name__)\napp...
python
edit
3
1
bsd-3-clause
2502a6c54e4f87d3d344077cce5029e4bbca58d5
taarifa/taarifa_backend,taarifa/taarifa_backend,taarifa/taarifa_backend,taarifa/taarifa_backend
taarifa_backend/__init__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.urls import path, re_path\nfrom django.conf.urls.static import static\nfrom django.conf import settings\n\nfrom . import views\n\n\nurlpatterns = static('/compiled/', document_root=settings.BUILD_ROOT) + [\n path('go/<path:pa...
python
edit
1
0
mit
2d0b44d65a8167a105cbc63e704735b1c360e0c4
citizenlabsgr/voter-engagement,citizenlabsgr/voter-engagement,citizenlabsgr/voter-engagement,citizenlabsgr/voter-engagement,citizenlabsgr/voter-engagement
api/core/urls.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport json\n\nwith open('short_dataset_item.json') as dataset_file:\n dataset = json.load(dataset_file)\n\nfor i in range(len(dataset)):\n if 'Continual' == dataset[i]['frequency']:\n print dataset[i]['name']\n\n\n```\n\nApply...
python
edit
2
0
mit
139b0ae83ff4faa633a628c09f61b33b755b3502
MaxLikelihood/CODE
dataset/print.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom rawkit.libraw import libraw\n\n\nclass Raw(object):\n\n def __init__(self, filename=None):\n self.data = libraw.libraw_init(0)\n libraw.libraw_open_file(self.data, bytes(filename, 'utf-8'))\n\n def __enter__(self):\...
python
edit
1
1
mit
5cb8d2a4187d867111b32491df6e53983f124d73
nagyistoce/rawkit,SamWhited/rawkit,photoshell/rawkit
rawkit/raw.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom rest_framework import viewsets\n\nfrom wafer.kv.models import KeyValue\nfrom wafer.kv.serializers import KeyValueSerializer\nfrom wafer.kv.permissions import KeyValueGroupPermission\n\nclass KeyValueViewSet(viewsets.ModelViewSet):\n ...
python
edit
1
3
isc
6e874375ee1d371a3e6ecb786ade4e1b16d84da5
CTPUG/wafer,CTPUG/wafer,CTPUG/wafer,CTPUG/wafer
wafer/kv/views.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# -*- coding: utf-8 -*-\n# Licensed to the StackStorm, Inc ('StackStorm') under one or more\n# contributor license agreements. See the NOTICE file distributed with\n# this work for additional information regarding copyright ownership.\n# T...
python
edit
1
0
apache-2.0
abd5fcac1fa585daa73910273adf429baf671de3
nzlosh/st2,StackStorm/st2,StackStorm/st2,StackStorm/st2,Plexxi/st2,Plexxi/st2,Plexxi/st2,nzlosh/st2,nzlosh/st2,nzlosh/st2,StackStorm/st2,Plexxi/st2
contrib/runners/windows_runner/windows_runner/__init__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# -*- coding: utf-8 -*-\n# Copyright (c) 2015, Vispy Development Team.\n# Distributed under the (new) BSD License. See LICENSE.txt for more info.\n\nimport numpy as np\n\nfrom vispy.visuals.line.arrow import ARROW_TYPES\nfrom vispy.scene im...
python
edit
4
2
bsd-3-clause
d8872865cc7159ffeeae45a860b97cd241f95c6e
inclement/vispy,michaelaye/vispy,srinathv/vispy,jay3sh/vispy,julienr/vispy,QuLogic/vispy,jay3sh/vispy,julienr/vispy,ghisvail/vispy,drufat/vispy,Eric89GXL/vispy,inclement/vispy,RebeccaWPerry/vispy,michaelaye/vispy,kkuunnddaannkk/vispy,Eric89GXL/vispy,jdreaver/vispy,sbtlaarzc/vispy,srinathv/vispy,Eric89GXL/vispy,drufat/v...
vispy/visuals/tests/test_arrows.py
rejected_lint
Too many lint violations: 4
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
7d271c3f221d5fade656cd94d2a56fab0fc3b928
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\nfrom django.contrib.auth.models import AbstractUser\nfrom django.utils.functional import cached_property\nfrom social.apps.django_app.default.models import UserSocialAuth\n\n\nclass User(AbstractUser):\n\n def save(self, *args, **kwargs)...
python
edit
1
2
mit
c5548840286084f477f689d87539be73751ab784
relekang/accio,relekang/accio,relekang/accio
accio/users/models.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport arrayfire\nimport pytest\n\nbackends = arrayfire.library.get_available_backends()\n# do not use opencl backend, it's kinda broken\n#backends = [x for x in backends if x != 'opencl']\n\n# This will set the different backends before ea...
python
edit
1
1
bsd-2-clause
7b681bfd34a24dc15b219dd355db2557914b7b49
daurer/afnumpy,FilipeMaia/afnumpy
tests/conftest.py
rejected_duplicate
Near-duplicate of sample 12311
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport pytest\n\n\n@pytest.fixture\ndef observe(monkeypatch):\n def patch(module, func):\n original_func = getattr(module, func)\n\n def wrapper(*args, **kwargs):\n result = original_func(*args, **kwargs)\n ...
python
edit
1
1
mit
c5a617db987fda0302cf5963bbc41e8d0887347d
numberoverzero/pyservice
tests/conftest.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport pytest\nfrom utils import *\nfrom pgcli.pgexecute import PGExecute\n\n\n@pytest.yield_fixture(scope=\"function\")\ndef connection():\n create_db('_test_db')\n connection = db_connection('_test_db')\n yield connection\n\n ...
python
edit
1
1
bsd-3-clause
d324b27e41aee52b044e5647a4a13aecc9130c3e
koljonen/pgcli,darikg/pgcli,n-someya/pgcli,thedrow/pgcli,dbcli/vcli,joewalnes/pgcli,zhiyuanshi/pgcli,thedrow/pgcli,darikg/pgcli,janusnic/pgcli,bitemyapp/pgcli,dbcli/pgcli,MattOates/pgcli,suzukaze/pgcli,bitmonk/pgcli,bitmonk/pgcli,johshoff/pgcli,nosun/pgcli,d33tah/pgcli,johshoff/pgcli,koljonen/pgcli,lk1ngaa7/pgcli,zhiyu...
tests/conftest.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport numpy as np\n\nimport skimage.io\nimport skimage.util\n\nimport os\n\n\ndef extract_region_from_image(image, region_bounding_box):\n return image[region_bounding_box[0]:region_bounding_box[2], region_bounding_box[1]:region_boundin...
python
edit
1
8
mit
dec3ec25739e78c465fd5e31a161a674331edbed
SerpentAI/SerpentAI
serpent/cv.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom plumeria.command import commands, channel_only\nfrom plumeria.message import Response\n\n\n@commands.register('roles', category='Discord')\n@channel_only\nasync def roles(message):\n \"\"\"\n Gets the roles in the current server,...
python
edit
1
2
mit
4fda69c972f223354b27b89981751e2ae490a98e
sk89q/Plumeria,sk89q/Plumeria,sk89q/Plumeria
plumeria/plugins/discord.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# file eulfedora/__init__.py\n#\n# Copyright 2010,2011 Emory University Libraries\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...
python
edit
1
0
apache-2.0
99c8024b5568650d4efc9de197b48d93bb099267
bodleian/eulfedora,WSULib/eulfedora
eulfedora/__init__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.conf.urls.defaults import *\n\nfrom motion.feeds import PublicEventsFeed\n\n\nurlpatterns = patterns('',\n url(r'^$', 'makeaface.views.home', name='home'),\n url(r'^$', 'makeaface.views.home', name='group_events'),\n\n ...
python
edit
17
0
mit
7157843c2469fd837cb30df182ad69583790b9eb
markpasc/make-a-face,markpasc/make-a-face
makeaface/makeaface/urls.py
rejected_lint
Too many lint violations: 17
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.core import management\nfrom django.test import TestCase\nfrom django.contrib.contenttypes.models import ContentType\n\nfrom post.models import Post\n\nfrom foundry.models import Member, Listing\n\n\nclass TestCase(TestCase):\n\...
python
edit
1
2
bsd-3-clause
394262effa690eda51ba9ee29aa86d98c683e17d
praekelt/jmbo-foundry,praekelt/jmbo-foundry,praekelt/jmbo-foundry
foundry/tests.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport requests\n\nfrom bs4 import BeautifulSoup\nfrom source.models.rt_rating import RTRating\n\n\nclass OmdbService:\n\n __API_URL = 'http://www.omdbapi.com/?'\n\n def __init__(self, movie_id):\n self.id = movie_id\n\n def...
python
edit
3
1
mit
332452cf7ccd6d3ee583be9a6aac27b14771263f
jeremyrea/caterblu,jeremyrea/caterblu,jeremyrea/caterblu,jeremyrea/caterblu
source/services/omdb_service.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport pytest\n\nfrom boink.dbg_tests import (_test_add_single_kmer,\n _test_add_two_kmers,\n _test_kmer_degree,\n _test_kmer_in_degree,\n ...
python
edit
2
3
mit
fedf1df20418169a377012c22bf81f758e2978e8
camillescott/boink,camillescott/boink,camillescott/boink,camillescott/boink
tests/test_dbg.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom chef import Search\nfrom chef.api import ChefAPI, autoconfigure\nfrom chef.exceptions import ChefError\n\nclass Roledef(object):\n def __init__(self, name, api, hostname_attr):\n self.name = name\n self.api = api\n\tse...
python
edit
null
null
apache-2.0
a1897464b7974589723790f946fed0c1a5bdb475
Scalr/pychef,jarosser06/pychef,cread/pychef,coderanger/pychef,Scalr/pychef,jarosser06/pychef,dipakvwarade/pychef,dipakvwarade/pychef,coderanger/pychef,cread/pychef
chef/fabric.py
rejected_syntax
Syntax error detected by tree-sitter
false
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom flask_wtf import FlaskForm\nfrom wtforms import StringField\nfrom wtforms.validators import DataRequired, Length\n\n\nclass AddSubjectForm(FlaskForm):\n code = StringField('Code', validators=[DataRequired()])\n name = StringField...
python
edit
1
0
mit
cbd0855feb9164182b58b36ee487716fd5a33689
openedoo/module_employee,openedoo/module_employee,openedoo/module_employee
forms/subject.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\nimport logging\nimport types\nimport json\n\nimport six\n\n\nclass JsonFormatter(logging.Formatter):\n\n def format(self, record):\n\n data = {\n \"level\": record.levelno,\n \"levelName\": record....
python
edit
1
5
bsd-3-clause
7ea80522ae56c314b2230fe95d3b5ae939181d40
koenbok/Cactus,koenbok/Cactus,eudicots/Cactus,koenbok/Cactus,eudicots/Cactus,eudicots/Cactus
cactus/logger.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# https://www.hackerrank.com/challenges/ctci-linked-list-cycle\n# Python 3\n\n\"\"\"\nDetect a cycle in a linked list. Note that the head pointer may be 'None' if the list is empty.\n\nA Node is defined as: \n \n class Node(object):\n ...
python
edit
1
3
mit
a27d3f76f194a9767022e37c83d5d18861552cfd
arvinsim/hackerrank-solutions
all-domains/tutorials/cracking-the-coding-interview/linked-lists-detect-a-cycle/solution.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport hypothesis_jsonschema\nfrom hypothesis import HealthCheck, given, settings\nfrom hypothesis import strategies as st\n\nfrom amostra.utils import load_schema\n\nsample_dict = load_schema(\"sample.json\")\n# Pop uuid and revision cause...
python
edit
1
2
bsd-3-clause
0be3b5bf33a3e0254297eda664c85fd249bce2fe
NSLS-II/amostra
amostra/tests/test_jsonschema.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom oeqa.runtime.cases.parselogs import *\n\nrpi_errors = [\n 'bcmgenet fd580000.genet: failed to get enet-eee clock',\n 'bcmgenet fd580000.genet: failed to get enet-wol clock',\n 'bcmgenet fd580000.genet: failed to get enet clock...
python
edit
11
0
mit
4a827bfff24758677e9c1d9d3b186fc14f23e0bb
agherzan/meta-raspberrypi,agherzan/meta-raspberrypi,agherzan/meta-raspberrypi,agherzan/meta-raspberrypi,agherzan/meta-raspberrypi,agherzan/meta-raspberrypi
lib/oeqa/runtime/cases/parselogs_rpi.py
rejected_lint
Too many lint violations: 11
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\nimport os\nimport sys\n\nif __name__ == \"__main__\":\n os.environ.setdefault(\"DJANGO_SETTINGS_MODULE\", \"capomastro.settings\")\n\n from django.core.management import execute_from_command_line\n\n execute_...
python
edit
2
0
mit
6464c3ed7481e347dc6ca93ccfcad6964456e769
timrchavez/capomastro,timrchavez/capomastro
manage.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport sh\nfrom sh import docker\n\n\ndef get_ip():\n \"\"\"Return a string of the IP of the hosts eth0 interface.\"\"\"\n intf = sh.ifconfig.eth0()\n return sh.perl(intf, \"-ne\", 's/dr:(\\S+)/print $1/e')\n\n\ndef cleanup_inside(...
python
edit
1
1
apache-2.0
e9c7b17ccd9709eb90f38bec9d59c48dc6f793b2
robbrockbank/libcalico,tomdee/libnetwork-plugin,TrimBiggs/libcalico,plwhite/libcalico,tomdee/libcalico,projectcalico/libnetwork-plugin,L-MA/libcalico,projectcalico/libcalico,djosborne/libcalico,Symmetric/libcalico,TrimBiggs/libnetwork-plugin,alexhersh/libcalico,insequent/libcalico,caseydavenport/libcalico,TrimBiggs/lib...
calico_containers/tests/st/utils.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport json\nimport uuid\n\nfrom flask_hookserver import Hooks\n\nfrom .db import redis\nfrom .members.models import User\nfrom .projects.tasks import update_project_by_hook\nfrom .tasks import spinach\n\n\nhooks = Hooks()\n\n\n@hooks.hook(...
python
edit
1
5
mit
b1781b8c82979ee3765197084a9c8e372cb68cf8
jazzband/jazzband-site,jazzband/website,jazzband/website,jazzband/website,jazzband/website,jazzband/site,jazzband/jazzband-site,jazzband/site
jazzband/hooks.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom .models import Idea\nfrom .serializers import IdeaSerializer\nfrom rest_framework import status\nfrom rest_framework.decorators import api_view\nfrom rest_framework.response import Response\n\n@api_view(['GET',])\ndef idea_list(request...
python
edit
1
2
mit
b26ce5b5ff778208314bfd21014f88ee24917d7a
neosergio/vote_hackatrix_backend
ideas/views.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\nimport os\nimport sys\n\n\nif __name__ == '__main__':\n os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'base.settings')\n os.environ.setdefault('DJANGO_CONFIGURATION', 'Development')\n\n import dotenv\n d...
python
edit
1
0
apache-2.0
8318bae21bd5cb716a4cbf2cd2dfe46ea8cadbcf
hello-base/web,hello-base/web,hello-base/web,hello-base/web
manage.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.contrib.auth.models import User\nfrom django.db import models\n\n\nclass Token(models.Model):\n fitbit_id = models.CharField(max_length=50)\n refresh_token = models.CharField(max_length=120)\n\n```\n\nApply this change: Ad...
python
edit
3
1
apache-2.0
1ce39741886cdce69e3801a1d0afb25c39a8b844
Bachmann1234/fitbitSlackBot,Bachmann1234/fitbitSlackBot
fitbit/models.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"Handles database connection, and all that fun stuff.\n@package ppbot\n\n\"\"\"\nfrom pymongo import MongoClient\n\nfrom settings import *\n\nclient = MongoClient(MONGO_HOST, MONGO_PORT)\ndb = client[MONGO_DB]\n\n```\n\nApply this chan...
python
edit
9
2
mit
d6461896dec112caad81490e1a6d055a3d4c9a95
billyvg/piebot
db.py
rejected_lint
Too many lint violations: 9
true
[ { "role": "user", "content": "Here is the current file:\n```python\ndef levenshtein(s1, s2):\n if len(s1) < len(s2):\n return levenshtein(s2, s1)\n\n # len(s1) >= len(s2)\n if len(s2) == 0:\n return len(s1)\n\n previous_row = range(len(s2) + 1)\n for i, c1 in enumerate(s1):\n ...
python
edit
1
5
mit
93f9bb4115c4259dd38962229947b87e952a25a7
thatsIch/sublime-rainmeter
completion/levenshtein.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.db import models\n\nclass Animal(models.Model):\n MALE = 'male'\n FEMALE = 'female'\n\n GENDER_CHOICES = ((MALE, 'Male'), (FEMALE, 'Female'))\n\n father = models.ForeignKey(\"self\", null = True, on_delete = models.S...
python
edit
4
1
apache-2.0
6e6c60613180bb3d7e2d019129e57d1a2c33286d
mmlado/animal_pairing,mmlado/animal_pairing
backend/backend/models.py
rejected_lint
Too many lint violations: 4
true
[ { "role": "user", "content": "Here is the current file:\n```python\ndef summarizeECG(instHR, avgHR, brady, tachy):\n \"\"\"Create txt file summarizing ECG analysis\n :param instHR: (int)\n :param avgHR: (int)\n :param brady: (int)\n :param tachy: (int)\n \"\"\"\n #Calls hrdetector() to ...
python
edit
1
1
mit
0420ed666f8a2cd5cd6c2055b13a5d26cc5d3792
raspearsy/bme590hrm
output.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom urllib.request import Request, urlopen\n\nfrom .renderers import XMLRenderer\n\n\nclass Client:\n def __init__(self, hostname, auth_info):\n self.base_url = 'http://{}/MRWEnvio.asmx'.format(hostname)\n self.auth_info =...
python
edit
1
1
mit
9c3514c83404e12b51c6f78cd4472eb1b7bd9fd0
migonzalvar/pysagec
pysagec/client.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nTasks for common project sanity-checking such as linting or type checking.\n\"\"\"\n\nfrom __future__ import unicode_literals\n\nfrom invoke import task\n\n\n@task(name=\"blacken\", iterable=[\"folder\"])\ndef blacken(c, line_length...
python
edit
1
4
bsd-2-clause
e87ac65b42b6390cee835deb180fc6cd2a814082
pyinvoke/invocations
invocations/checks.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport ast\n\nimport click\n\nfrom graphing.graph import FunctionGrapher\nfrom parsing.parser import FileVisitor\n\n\n@click.command()\n@click.argument('code', type=click.File('rb'))\n@click.option('--printed', default=False, is_flag=True, ...
python
edit
1
7
mit
b639c9f1c615ca73fd49c171344effb3718b2b77
LaurEars/codegrapher
script.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport unittest\n\n\nclass TestSpecSet(unittest.TestCase):\n pass\n\n```\n\nApply this change: Add test cases for testing SpecSet." }, { "role": "assistant", "content": "import unittest\nfrom piptools.datastructures import Sp...
python
edit
1
1
bsd-2-clause
8fba76340daef349c45946183757ef463004492b
suutari-ai/prequ,suutari/prequ,suutari/prequ
tests/unit/test_spec_set.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nA Simple example for testing the SimpleServer Class. A simple connectionless\nserver. It is for studying purposes only.\n\"\"\"\n\nfrom simple.server import SimpleServer\n\n\n__author__ = \"Facundo Victor\"\n__license__ = \"MIT\"\n_...
python
edit
1
5
mit
bb42fe14165806caf8a2386c49cb602dbf9ad391
facundovictor/non-blocking-socket-samples
connectionless_service.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom __future__ import print_function\nimport unittest\nimport numpy as np\nimport pydrake\nimport os.path\n\n\nclass TestRBTCoM(unittest.TestCase):\n def testCoM0(self):\n r = pydrake.rbtree.RigidBodyTree(os.path.join(pydrake.get...
python
edit
1
1
bsd-3-clause
2e6445bfda12e470fdc5c0b6aa725fd344c863f1
billhoffman/drake,billhoffman/drake,sheim/drake,sheim/drake,sheim/drake,sheim/drake,billhoffman/drake,billhoffman/drake,billhoffman/drake,sheim/drake,sheim/drake,sheim/drake,billhoffman/drake,billhoffman/drake,sheim/drake,billhoffman/drake
drake/bindings/python/pydrake/test/testRBTCoM.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add a bunch of mostly-empty method stubs." }, { "role": "assistant", "content": "import sublime, sublime_plugin\n\nclass DiffListener(sublime_plugin.EventListener):\n \"\"\"Listens for modifications to the view and gets the di...
python
new_file
5
1
mit
e30629cba2bf09cf83e8e424a203793a5baf9b43
TeamRemote/remote-sublime,TeamRemote/remote-sublime
remote.py
rejected_lint
Too many lint violations: 5
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\nimport sys\nimport os\nimport json\nimport unittest\nimport xmlrunner\n\nfrom flask import Flask, Response\nfrom flask_sqlalchemy import SQLAlchemy\nfrom flask_restful import Api\nfrom flask_script import Manager, Server, prompt_bool\nfro...
python
edit
12
2
apache-2.0
6aa7c86828e230699365b88368070f426a7e2a8c
dang03/son-gkeeper,alfonsoegio/son-gkeeper,felipevicens/son-gkeeper,jbonnet/son-gkeeper,alfonsoegio/son-gkeeper,sonata-nfv/son-gkeeper,jbonnet/son-gkeeper,alfonsoegio/son-gkeeper,jbonnet/son-gkeeper,felipevicens/son-gkeeper,sonata-nfv/son-gkeeper,jbonnet/son-gkeeper,dang03/son-gkeeper,alfonsoegio/son-gkeeper,felipevice...
son-gtklic/app.py
rejected_lint
Too many lint violations: 12
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\nfrom subprocess import Popen, PIPE\n\nLMOD_CMD = os.environ['LMOD_CMD']\nLMOD_SYSTEM_NAME = os.environ.get('LMOD_SYSTEM_NAME', '')\n\ndef module(command, arguments=()):\n cmd = [LMOD_CMD, 'python', '--terse', command]\n cmd...
python
edit
1
4
mit
6bbbc74ea4acda000c115d08801d2f6c677401da
cmd-ntrf/jupyter-lmod,cmd-ntrf/jupyter-lmod,cmd-ntrf/jupyter-lmod
lmod/__init__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nScheduler queues\n\"\"\"\n\nimport marshal\nfrom six.moves import cPickle as pickle\n\nfrom queuelib import queue\n\ndef _serializable_queue(queue_class, serialize, deserialize):\n\n class SerializableQueue(queue_class):\n\n ...
python
edit
1
2
bsd-3-clause
fd99ef86dfca50dbd36b2c1a022cf30a0720dbea
YeelerG/scrapy,wenyu1001/scrapy,GregoryVigoTorres/scrapy,crasker/scrapy,jdemaeyer/scrapy,Parlin-Galanodel/scrapy,arush0311/scrapy,Digenis/scrapy,pablohoffman/scrapy,ArturGaspar/scrapy,kmike/scrapy,crasker/scrapy,eLRuLL/scrapy,wujuguang/scrapy,carlosp420/scrapy,darkrho/scrapy-scrapy,redapple/scrapy,carlosp420/scrapy,bar...
scrapy/squeues.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport bottle\nimport waitress\nimport controller\nimport breathe\nfrom pytz import timezone\nfrom apscheduler.schedulers.background import BackgroundScheduler\n\nbottle_app = bottle.app()\nscheduler = BackgroundScheduler()\nscheduler.confi...
python
edit
1
1
mit
5cb10ce2f8e3b80fc54b5bfd3e60b4240dfed0fd
tipsqueal/duwamish-lighthouse,tipsqueal/duwamish-lighthouse,illumenati/duwamish-lighthouse,illumenati/duwamish-lighthouse,YonasBerhe/duwamish-lighthouse
server.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\nDEFAULT_FILE_STORAGE = 'djangae.storage.BlobstoreStorage'\nFILE_UPLOAD_MAX_MEMORY_SIZE = 1024 * 1024\nFILE_UPLOAD_HANDLERS = (\n 'djangae.storage.BlobstoreFileUploadHandler',\n 'django.core.files.uploadhandler.MemoryFileUploadHandle...
python
edit
1
0
bsd-3-clause
6b4e5c731d4545561bcc1bd5f819e88d5a3eea60
martinogden/djangae,wangjun/djangae,martinogden/djangae,stucox/djangae,SiPiggles/djangae,potatolondon/djangae,trik/djangae,martinogden/djangae,kirberich/djangae,grzes/djangae,kirberich/djangae,armirusco/djangae,pablorecio/djangae,b-cannon/my_djae,armirusco/djangae,leekchan/djangae,trik/djangae,stucox/djangae,jscissr/dj...
djangae/settings_base.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport random\nimport json\nimport time\n\nimport SocketExtend as SockExt\nimport config as conf\nimport parser as p\n\ndef ping(sock):\n\ttry:\n\t\trand = random.randint(1, 99999)\n\t\tdata = {'request':'ping', 'contents': {'value':rand}}\...
python
edit
2
4
bsd-2-clause
14756f5de831832a192a8a453e7e108be7ebcacd
mavroudisv/Crux
components/includes/utilities.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.contrib import admin\n\nfrom .models import User\n\n\n@admin.register(User)\nclass UserAdmin(admin.ModelAdmin):\n # list view\n list_display = (\n 'email',\n 'is_staff',\n 'is_superuser')\n list_fil...
python
edit
1
1
bsd-2-clause
f118d1c3cb4752a20329a32d0d49fd9e46280bc3
jambonrose/DjangoUnleashed-1.8,jambonrose/DjangoUnleashed-1.8
user/admin.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# This file is part of Indico.\n# Copyright (C) 2002 - 2016 European Organization for Nuclear Research (CERN).\n#\n# Indico is free software; you can redistribute it and/or\n# modify it under the terms of the GNU General Public License as\n...
python
edit
1
0
mit
be779b6b7f47750b70afa6f0aeb67b99873e1c98
DirkHoffmann/indico,pferreir/indico,OmeGak/indico,indico/indico,mvidalgarcia/indico,mvidalgarcia/indico,indico/indico,OmeGak/indico,DirkHoffmann/indico,mic4ael/indico,mvidalgarcia/indico,OmeGak/indico,indico/indico,OmeGak/indico,indico/indico,ThiefMaster/indico,pferreir/indico,ThiefMaster/indico,ThiefMaster/indico,pfer...
indico/modules/events/tracks/forms.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.apps import AppConfig\nfrom watson import search as watson\n\n\nclass NotaroConfig(AppConfig):\n name = \"notaro\"\n verbose_name = \"Notizen\"\n\n def ready(self):\n NoteModel = self.get_model(\"Note\")\n ...
python
edit
1
1
bsd-3-clause
e47ede85f2001cc5c514951355ded1253b4c45f7
ugoertz/django-familio,ugoertz/django-familio,ugoertz/django-familio,ugoertz/django-familio
notaro/apps.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nMachine Learning module for NeuroImaging in python\n==================================================\n\nSee http://nisl.github.com for complete documentation.\n\"\"\"\n\"\"\"\ntry:\n import numpy\nexcept ImportError:\n print...
python
edit
2
1
bsd-3-clause
ab191322b245d51df92bed11467512fc92665b1c
abenicho/isvr
nisl/__init__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\nimport ast\n\nfrom .klass import build_method\nfrom .library import Library\n\nregister = Library()\n\n\ndef parse_args(bits):\n '''\n Parse tag bits as if they're function args\n '''\n code = ast.parse('x(%s)' % bits, mode='e...
python
edit
1
1
mit
d17f72112625d66169098d8cb8fb856e7fd93272
funkybob/knights-templater,funkybob/knights-templater
knights/k_tags.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\n:Copyright: 2006-2020 Jochen Kupperschmidt\n:License: Modified BSD, see LICENSE for details.\n\"\"\"\n\nimport pytest\n\nfrom byceps.services.email import service as email_service\nfrom byceps.services.shop.cart.models import Cart\n...
python
edit
1
1
bsd-3-clause
7456080d3f8d598728fe7a9ee96884db9e28a869
homeworkprod/byceps,homeworkprod/byceps,homeworkprod/byceps
tests/services/shop/conftest.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport molwt\n\nM_ATMOS = 5.1352e18 # mass of atmosphere, kg\n\n# Conversion between ppm CO2 and GtC emissions\nppm_gtc = M_ATMOS/1e18*molwt.C/molwt.AIR\n\n```\n\nApply this change: Fix import of molwt in constants" }, { "role":...
python
edit
1
0
apache-2.0
c468b85ff0278a8f398823adcd2893b28f2e8afe
OMS-NetZero/FAIR
fair/constants/general.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom nose.plugins import Plugin\n\n\nclass DjangoNosePlugin(Plugin):\n ''' Adaptor that allows usage of django_nose package plugin from\n the nosetests command line.\n Imports and instantiates django_nose plugin after initializatio...
python
edit
1
2
mit
ea8a78cb7d7cda7b597826a478cce3ab4b0a4b62
jenniferlianne/django_nose_adapter
django_nose_plugin.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# General Settings\ntimerestriction = False\ndebug_mode = True\n\n# Email Settings\n# emailtype = \"Gmail\"\nemailtype = \"Console\"\n\n# SMS Settings\n# outboundsmstype = \"WebService\"\noutboundsmstype = \"Console\"\n\n# Twilio Auth Keys\...
python
edit
1
0
mit
7303afd415cd6867908c6a5108d3604fafb0c8a0
mattstibbs/blockbuster-server,mattstibbs/blockbuster-server
blockbuster/example_config_files/example_config.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!flask/bin/python\n\"\"\"\nAuthor: Swagger.pro\nFile: app.py\nPurpose: runs the app!\n\"\"\"\n\nfrom swagip import app\n\napp.config.from_object('config')\n\n\nif __name__ == \"__main__\":\n app.run(debug=True, host='0.0.0.0')\n\n```\n...
python
edit
1
0
mit
09a96a308c7666defdc1377e207f9632b9bc9c7a
thatarchguy/SwagIP,thatarchguy/SwagIP,thatarchguy/SwagIP
app.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# -*- coding: utf-8 -*-\n#\n# Copyright (C) 2015 Red Hat, 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 Licens...
python
edit
1
5
apache-2.0
c7efd5976f511200162610612fcd5b6f9b013a54
redhat-cip/python-dciclient,redhat-cip/python-dciclient
dciclient/v1/utils.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.conf import settings\nfrom django.core.exceptions import ImproperlyConfigured\n\nfrom cms.utils.compat.dj import is_installed as app_is_installed\n\n\ndef validate_dependencies():\n \"\"\"\n Check for installed apps, their...
python
edit
1
4
bsd-3-clause
0bb7a3d468a70e57bb867678a7649e7ad736d39f
robmagee/django-cms,chmberl/django-cms,astagi/django-cms,sephii/django-cms,philippze/django-cms,dhorelik/django-cms,cyberintruder/django-cms,evildmp/django-cms,cyberintruder/django-cms,takeshineshiro/django-cms,netzkolchose/django-cms,saintbird/django-cms,memnonila/django-cms,wuzhihui1123/django-cms,AlexProfi/django-cm...
cms/utils/setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.contrib.auth.models import AnonymousUser\nfrom django.test import TestCase, RequestFactory\n\n\nclass DummyStorage:\n def __init__(self):\n self.store = set()\n\n def add(self, level, message, extra_tags=''):\n ...
python
edit
1
4
bsd-2-clause
7fb7a4f68be4ce23da23914cffc1c5b76fe5fd06
incuna/incuna-test-utils,incuna/incuna-test-utils
incuna_test_utils/testcases/request.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n# -*- coding: utf-8 -*- #\nfrom __future__ import unicode_literals\n\n# This file is only used if you use `make publish` or\n# explicitly specify it as your config file.\n\nimport os\nimport sys\nsys.path.append(os.cu...
python
edit
2
0
mit
7a66b9fb3482778cd0efab692cbc535260bcad25
gustavofoa/dicasdejava.com.br,gustavofoa/dicasdejava.com.br,gustavofoa/dicasdejava.com.br,gustavofoa/dicasdejava.com.br,gustavofoa/dicasdejava.com.br
publishconf.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom flask import Flask\napp = Flask(__name__)\n\n@app.route('/')\ndef index():\n\treturn '<H1>Measure Anything</H1>'\n\nif __name__ == '__main__':\n\tapp.run(debug=True)\n```\n\nApply this change: Use flask-script so command line parameter...
python
edit
1
1
mit
c6ffb39cc730809781e8dabff4458fd167e60123
rahimnathwani/measure-anything
app.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\nimport mxnet as mx\nimport numpy as np\n\ndef same(a, b):\n return np.sum(a != b) == 0\n\ndef check_with_device(device):\n with mx.Context(device):\n a, b = -10, 10\n mu, sigma = 10, 2\n for i in range(...
python
edit
3
1
apache-2.0
8bc9d9dd548cb2e19a51fb33336695ca3925ba64
sxjscience/mxnet,sxjscience/mxnet,sxjscience/mxnet,sxjscience/mxnet,sxjscience/mxnet,sxjscience/mxnet,sxjscience/mxnet,sxjscience/mxnet,sxjscience/mxnet
tests/python/unittest/test_random.py
rejected_duplicate
Near-duplicate of sample 5680
true
[ { "role": "user", "content": "Here is the current file:\n```python\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# http://www.apache.org/licenses/LICENSE-2.0\n#\n# U...
python
edit
1
2
apache-2.0
0e66044b3949255be2653c0cffee53b003ea3929
ed-/solum,stackforge/solum,ed-/solum,devdattakulkarni/test-solum,gilbertpilz/solum,ed-/solum,openstack/solum,gilbertpilz/solum,ed-/solum,devdattakulkarni/test-solum,openstack/solum,gilbertpilz/solum,stackforge/solum,gilbertpilz/solum
solum/api/controllers/v1/pub/trigger.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n# Copyright 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\nfrom mock_file_system import MockFileSystem\nfrom ...
python
edit
1
1
bsd-3-clause
2add55f78d6b5efb097f8a4d089b2eced80d0882
dednal/chromium.src,markYoungH/chromium.src,axinging/chromium-crosswalk,M4sse/chromium.src,PeterWangIntel/chromium-crosswalk,Fireblend/chromium-crosswalk,krieger-od/nwjs_chromium.src,hgl888/chromium-crosswalk-efl,fujunwei/chromium-crosswalk,ondra-novak/chromium.src,ondra-novak/chromium.src,dushu1203/chromium.src,TheTyp...
chrome/common/extensions/docs/server2/fake_host_file_system_provider.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom roku import __version__\nfrom setuptools import setup, find_packages\nimport os\n\nf = open(os.path.join(os.path.dirname(__file__), 'README.rst'))\nreadme = f.read()\nf.close()\n\nsetup(\n name='python-roku',\n version=__version_...
python
edit
1
0
bsd-3-clause
2e95e3b9badf9c860b98bca6a4edb1d4fac358a9
jcarbaugh/python-roku
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport argparse\n\nimport PIL\nfrom PIL import Image\nimport subprocess\nimport os\nimport glob\n\ndef get_image(filename):\n p = Image.open(filename)\n docker_image = p.info['im2sim_image']\n return subprocess.call('docker pull {}...
python
edit
1
2
mit
d08d78460d0f7143b90a5157c4f5450bb062ec75
IanHawke/im2sim
im2sim.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n\n\"\"\"\nSummarize dataset.\n\nExamples:\n\n\tc2s info data.pck\n\"\"\"\n\nimport sys\n\nfrom argparse import ArgumentParser\nfrom pickle import dump\nfrom scipy.io import savemat\nfrom numpy import corrcoef, mean\nf...
python
edit
5
7
mit
48b6bb91537d9daecca2bc112f5e06dc9b530f09
lucastheis/c2s,jonasrauber/c2s
scripts/c2s-info.py
rejected_lint
Too many lint violations: 5
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import setup,find_packages\n\nsetup (\n name = 'pymatgen',\n version = '1.0.2',\n packages = find_packages(),\n\n # Declare your packages' dependencies here, for eg:\n\n install_requires = ['numpy','scipy','matplotlib',...
python
edit
1
0
mit
7fd7ce41e388a2014cd30a641f1fb3b35661af40
mbkumar/pymatgen,davidwaroquiers/pymatgen,Bismarrck/pymatgen,Bismarrck/pymatgen,richardtran415/pymatgen,gpetretto/pymatgen,gVallverdu/pymatgen,johnson1228/pymatgen,czhengsci/pymatgen,xhqu1981/pymatgen,johnson1228/pymatgen,vorwerkc/pymatgen,montoyjh/pymatgen,setten/pymatgen,setten/pymatgen,blondegeek/pymatgen,richardtra...
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n# coding: utf-8\n\"\"\"\n setup.py\n ~~~~~~~~\n\n Installs marvin as a package.\n\n\"\"\"\n\nfrom setuptools import setup, find_packages\n\nsetup(\n name='marvin',\n version='0.1.0',\n author='Tarjei...
python
edit
1
0
mit
03a5c3ce6c3c5c3238068f7e52d7f482eeebf7fb
streamr/marvin,streamr/marvin,streamr/marvin
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom enum import Enum\n\nfrom .base import Item\n\n\nclass KeepDirectories(Enum):\n NONE = 'none'\n SUFFIX = 'suffix'\n FULL = 'full'\n\n @classmethod\n def cast(cls, value):\n if not value:\n return KeepDir...
python
edit
1
3
mit
9bb48f43c5b7b026d74710860e5427c4e0ec71dd
valohai/valohai-yaml
valohai_yaml/objs/input.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\nfrom os.path import relpath, join\nfrom setuptools import setup\n\ndef read(fname):\n return open(os.path.join(os.path.dirname(__file__), fname)).read()\n\ndef find_package_data(data_root, package_root):\n files = []\n f...
python
edit
1
3
mit
7cc2a54dff4dc801306f5f41633ea7edbcc061c5
openforcefield/openff-toolkit,open-forcefield-group/openforcefield,open-forcefield-group/openforcefield,open-forcefield-group/openforcefield,openforcefield/openff-toolkit
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import setup, find_packages\nimport sys, os\n\nfrom applib import __version__\n\nsetup(name='applib',\n version=__version__,\n description=\"Cross-platform application utilities\",\n long_description=\"\"\"\\\...
python
edit
4
0
mit
5da6d00d040e7e4567956492ed955f9bd4e6cfa7
ActiveState/applib
setup.py
rejected_lint
Too many lint violations: 4
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# coding=utf-8\n\nfrom setuptools import setup, find_packages\nfrom sii import __LIBRARY_VERSION__\n\nINSTALL_REQUIRES = [line for line in open('requirements.txt')]\n\nTESTS_REQUIRE = [line for line in open('requirements-dev.txt')]\n\nPACKA...
python
edit
1
0
mit
d1e75df724fd3627b3fd83ab374dd9770d1acada
gisce/sii
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n\ntry:\n from setuptools import setup, find_packages\nexcept ImportError:\n from ez_setup import use_setuptools\n use_setuptools()\n from setuptools import setup, find_packages\nfrom config import get_vers...
python
edit
4
0
bsd-3-clause
cd9a5d62a7d13b8526a68394508c48cbfc443bba
AniruddhaSAtre/dd-agent,oneandoneis2/dd-agent,a20012251/dd-agent,joelvanvelden/dd-agent,packetloop/dd-agent,huhongbo/dd-agent,AniruddhaSAtre/dd-agent,manolama/dd-agent,joelvanvelden/dd-agent,jamesandariese/dd-agent,eeroniemi/dd-agent,manolama/dd-agent,eeroniemi/dd-agent,AntoCard/powerdns-recursor_check,AntoCard/powerdn...
setup.py
rejected_lint
Too many lint violations: 4
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom distutils.core import setup\n\nimport sisdb\n\nsetup (\n name='sisdb',\n version=sisdb.VERSION,\n description='SIS ORM like library',\n packages=['sisdb'],\n install_requires=['sis >= 0.3.0']\n)\n\n```\n\nApply this chan...
python
edit
1
0
bsd-3-clause
9fbfaac74b3213601ce48c73cd49a02344ba580b
sis-cmdb/sis-db-python
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python3\n\nfrom setuptools import setup\n\nsetup(\n name='todoman',\n description='A simple CalDav-based todo manager.',\n author='Hugo Osvaldo Barrera',\n author_email='<EMAIL>',\n url='https://gitlab.com/hoba...
python
edit
1
0
isc
7da8c97530d25d4f471f7927825382c0cea9524d
pimutils/todoman,rimshaakhan/todoman,Sakshisaraswat/todoman,asalminen/todoman,AnubhaAgrawal/todoman,hobarrera/todoman
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"Config for PyPI.\"\"\"\n\nfrom setuptools import find_packages\nfrom setuptools import setup\n\n\nsetup(\n author='Kyle P. Johnson',\n author_email='<EMAIL>',\n classifiers=[\n 'Intended Audience :: Education',\n ...
python
edit
1
0
mit
703e659ee2705b509b105a9b2a4f09d29c129643
kylepjohnson/cltk,TylerKirby/cltk,TylerKirby/cltk,D-K-E/cltk,LBenzahia/cltk,diyclassics/cltk,cltk/cltk,LBenzahia/cltk
setup.py
rejected_duplicate
Near-duplicate of sample 4589
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python3\n# coding: utf-8\n\n\"\"\"A setuptools based setup module.\n\nSee:\nhttps://packaging.python.org/en/latest/distributing.html\nhttps://github.com/pypa/sampleproject\n\"\"\"\n\nfrom setuptools import setup, find_package...
python
edit
1
0
bsd-3-clause
cf496e0f18811dd61caea822a8cc3e5769bbdc04
dmtucker/keysmith
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\nfrom setuptools import setup\n\nwith open(os.path.join(os.path.dirname(__file__), 'README.rst')) as readme:\n README = readme.read()\n\n# allow setup.py to be run from any path\nos.chdir(os.path.normpath(os.path.join(os.path.a...
python
edit
1
0
mit
3f7c6e468f420198f83e090efc155efe8fb18660
ministryofjustice/django-zendesk-tickets,ministryofjustice/django-zendesk-tickets
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\n\ndef read(filename):\n return open(filename).read()\n\nsetup(name=\"lzo-indexer\",\n version=\"0.0.1\",\n description=\"Library for indexing LZO compressed files\",\n lon...
python
edit
1
1
apache-2.0
2c41039669b9f8b423209c04f1d032584a86721e
duedil-ltd/python-lzo-indexer
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import setup, find_packages\n\n\nwith open(\"README.rst\", \"rt\") as f: readme = f.read()\n\n\nsetup(\n name='gimei',\n version=\"0.1.5\",\n description=\"generates the name and the address at random.\",\n long...
python
edit
1
0
mit
83410be53dfd4ddba5c3d5fff4c8cea022fc08d2
nabetama/gimei
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# -*- coding: utf-8 -*-\nimport os\nfrom setuptools import setup\n\ndef read(fname):\n try:\n return open(os.path.join(os.path.dirname(__file__), fname)).read()\n except:\n return ''\n\nsetup(\n name='todoist-python',...
python
edit
1
2
mit
f78f5b467ffe722e04317396622b5b81e40bb6bd
Doist/todoist-python
setup.py
rejected_duplicate
Near-duplicate of sample 2235
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n# -*- coding: utf-8 -*-\n\nimport os\nimport sys\n\ntry:\n from setuptools import setup\nexcept ImportError:\n from distutils.core import setup\n\nsettings = dict()\n\n# Publish\nif sys.argv[-1] == 'publish':\n ...
python
edit
1
0
bsd-3-clause
7ef952010f1bbfb9f78de923caa1112121328324
dirn/When.py
setup.py
rejected_duplicate
Near-duplicate of sample 12104
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n\nfrom setuptools import setup, find_packages\n\nsetup(\n name='django-validate-model-attribute-assignment',\n\n url=\"https://chris-lamb.co.uk/projects/django-validate-model-attribute-assignment\",\n version...
python
edit
1
0
bsd-3-clause
cb998c88d385d42f13e2e39fb86e8df73610a275
lamby/django-validate-model-attribute-assignment
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom .terms import *\nfrom .parser import *\n\n\n__all__ = [\n 'Alt',\n 'And',\n 'Any',\n 'AnyChar',\n 'AnyInst',\n 'Bind',\n 'Content',\n 'End',\n 'Expect',\n 'ForwardRef',\n 'InfixLeft',\n 'InfixRight',...
python
edit
46
0
mit
ea860743e0ba4538714d9fe5476b4807cf75ed35
jvs/sourcer
sourcer/__init__.py
rejected_lint
Too many lint violations: 46
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom __future__ import unicode_literals\n\nfrom itertools import chain\n\nfrom django import forms\nfrom django.utils.encoding import force_text\nfrom django.utils.html import format_html\nfrom django.utils.safestring import mark_safe\n\n\n...
python
edit
1
2
bsd-3-clause
0ebf51994a73fdc7c4f13b274fc41bef541eea52
jbittel/django-deflect
deflect/widgets.py
rejected_duplicate
Near-duplicate of sample 5078
true