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\nfrom datetime import datetime\n\nfrom django.db import models\nfrom django.utils.translation import ugettext_lazy as _\n\n\nclass Report(models.Model):\n addressed_to = models.TextField()\n reported_from = models.ForeignKey('members.U...
python
edit
1
2
mit
d5c296197c7f5b422f44e58f8e58ead5fdc5c2ad
Hackfmi/Diaphanum,Hackfmi/Diaphanum
reports/models.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/python -tt\n# Copyright 2010 Google Inc.\n# Licensed under the Apache License, Version 2.0\n# http://www.apache.org/licenses/LICENSE-2.0\n\n# Google's Python Class\n# http://code.google.com/edu/languages/google-python-class/\n\n\...
python
edit
3
2
apache-2.0
62f3368eabc54c2cb2a78308fac639e65f55e989
beepscore/google-python-exercises,beepscore/google-python-exercises
hello.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#\n# linter.py\n# Markdown Linter for SublimeLinter, a code checking framework\n# for Sublime Text 3\n#\n# Written by Jon LaBelle\n# Copyright (c) 2018 Jon LaBelle\n#\n# License: MIT\n#\n\n\"\"\"This module exports the Markdownlint plugin c...
python
edit
1
0
mit
b211306824db0a10a79cdab4153c457813b44bca
jonlabelle/SublimeLinter-contrib-markdownlint,jonlabelle/SublimeLinter-contrib-markdownlint
linter.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\n\nclass MalformedFileError(Exception):\n \"\"\"Error raised when the file is not well formatted\"\"\"\n\n\nclass MalformedCaptionError(Exception):\n \"\"\"Error raised when a caption is not well formatted\"\"\"\n\n```\n\nApply this ...
python
edit
1
0
mit
fa2d26f6c7652f1c4964ff5df076bf9dcdd3a493
sampattuzzi/webvtt-py,glut23/webvtt-py
webvtt/exceptions.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport requests\n\ndef can_access(url):\n try:\n current_page = (requests.get(url).text, 'lxml')\n answer = \"SL\"\n except requests.exceptions.ConnectionError:\n answer = \"PL\"\n return answer\n```\n\nApply t...
python
edit
3
2
bsd-2-clause
a542cfe1462869c2b64b2202d7316a0af1e3a613
mjkim610/phishing-detection,jaeyung1001/phishing_site_detection
core/modules/can_access.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nWelcome to the Resin Python SDK documentation.\nThis document aims to describe all the functions supported by the SDK, as well as\nshowing examples of their expected usage.\n\nInstall the Resin SDK:\n\nFrom Pip:\n```\npip install re...
python
edit
3
1
apache-2.0
bb14d53e8db76686a3a93a814b1258933083dc0b
resin-io/resin-sdk-python,resin-io/resin-sdk-python
resin/__init__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nHere is where we configure which AMQP hub implementation we are going to use.\n\"\"\"\n\nfrom qpid010 import QpidAMQPHub\nAMQPHub = QpidAMQPHub\n\n#from pyamqplib import AMQPLibHub\n#AMQPHub = AMQPLibHub\n\n```\n\nApply this change:...
python
edit
2
0
apache-2.0
5c116f4559520083d65848b3bde8bb95621a1633
mokshaproject/moksha,mokshaproject/moksha,pombredanne/moksha,pombredanne/moksha,ralphbean/moksha,mokshaproject/moksha,lmacken/moksha,lmacken/moksha,ralphbean/moksha,ralphbean/moksha,lmacken/moksha,mokshaproject/moksha,pombredanne/moksha,pombredanne/moksha
moksha/hub/amqp/__init__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport logging\nfrom contextlib import contextmanager\nfrom sqlalchemy import create_engine\nfrom sqlalchemy.orm import sessionmaker\nfrom sqlalchemy.exc import SQLAlchemyError\nfrom rtrss import OperationInterruptedException\nfrom rtrss im...
python
edit
1
4
apache-2.0
1bfc91af9d3ef59e39e6b4693457e00e2877f321
notapresent/rtrss,notapresent/rtrss,notapresent/rtrss,notapresent/rtrss
rtrss/database.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom .CIP_EditorWidget import CIP_EditorWidget\nfrom .CIP_EditBox import *\nfrom .CaseReportsWidget import *\nfrom .PreProcessingWidget import *\nfrom .MIPViewerWidget import *\nfrom .CollapsibleMultilineText import *\nfrom .PdfReporter imp...
python
edit
6
0
bsd-3-clause
e2ffc3d09157a0bfba4a0bcaca98691d99d04d77
acil-bwh/SlicerCIP,acil-bwh/SlicerCIP,acil-bwh/SlicerCIP,acil-bwh/SlicerCIP
Scripted/CIP_/CIP/ui/__init__.py
rejected_lint
Too many lint violations: 6
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# websocket_server -- WebSocket server library\n# https://github.com/CylonicRaider/websocket-server\n\n\"\"\"\nwebsocket_server -- WebSocket server library\n\nThis is a little stand-alone library for WebSocket servers.\nIt integrates neatly...
python
edit
10
0
mit
eff9c3865f06eb0fe2100b48274c88db63c2cf4c
CylonicRaider/websocket-server,CylonicRaider/websocket-server
websocket_server/__init__.py
rejected_lint
Too many lint violations: 10
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport unittest\n\nfrom mock import Mock, patch\n\nfrom tools import create_mock_json\nfrom twilio.rest.resources import Account\n\nclass AccountTest(unittest.TestCase):\n\n @patch(\"twilio.rest.resources.base.make_twilio_request\")\n ...
python
edit
1
1
mit
f3617d42b5ac9234f2c245dedbba87cf39c816dc
Stackdriver/twilio-python,cinemapub/bright-response,tysonholub/twilio-python,Mobii/twilio-python,supermanheng21/twilio-python,cinemapub/bright-response,bcorwin/twilio-python,johannakate/twilio-python,clearcare/twilio-python,Stackdriver/twilio-python,YeelerG/twilio-python,Rosy-S/twilio-python,twilio/twilio-python
tests/test_accounts.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport sys\n\ndef format_cols(cols):\n widths = [0] * len(cols[0])\n\n for i in cols:\n for idx, val in enumerate(i):\n widths[idx] = max(len(val), widths[idx])\n\n f = \"\"\n\n t = []\n for i in widths:\n ...
python
edit
6
5
mit
189f62b93382a1db0f2780678bbd4ad9c7769623
lightcrest/kahu-api-demo
util.py
rejected_lint
Too many lint violations: 6
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport couchdb\nfrom been.couch import CouchStore\n\nfrom flask import Flask, render_template\napp = Flask(__name__)\napp.jinja_env.trim_blocks = True\n\nstore = CouchStore()\nstore.load()\n\n@app.route('/')\ndef wake():\n return render_...
python
edit
1
1
bsd-3-clause
9195060fa66b2a068bca4680716a0d5b7be9b13d
chromakode/wake
wake.py
rejected_duplicate
Near-duplicate of sample 11625
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n\nimport sys,requests\n\nREDDIT=sys.argv[1]\nCHANNEL=sys.argv[2]\nFEED=sys.argv[3]\n\nSTATEFILE=\"/home/ircbot/state/reddit-%s-%s-storyids\"%(CHANNEL,REDDIT)\nseen = set(open(STATEFILE).read().split(\"\\n\"))\n\ndata ...
python
edit
4
0
unlicense
17e80f746fd634f84f3050b8ef613537a62c1f73
iibot-irc/irc-reddit,iibot-irc/irc-reddit
reddit.py
rejected_lint
Too many lint violations: 4
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\nif random:\n numbers = 1\n print_numbers(numbers)\nelse:\n numbers = 1, 2, 3\n print_numbers(numbers)\n\ndef print_numbers(numbers):\n for n in numbers:\n print(n)\n\n\n\n```\n\nApply this change: Make function exist...
python
edit
2
2
unlicense
83db8d5eb376304b1482b3f46f0b6a800571f50c
markshannon/buggy_code
non_iterable_example/_5_context.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport random\nimport unittest\n\nfrom aioes.pool import RandomSelector\n\n\nclass TestRandomSelector(unittest.TestCase):\n\n def setUp(self):\n random.seed(123456)\n\n def tearDown(self):\n random.seed(None)\n\n def ...
python
edit
1
1
apache-2.0
8161ec1fc511ba948451ce121c863ca878ef482d
aio-libs/aioes
tests/test_pool.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom flask.ext.script import Manager, Shell\nfrom app import create_app, db\nfrom settings import DevConfig, ProdConfig\nimport os\n\nif os.environ.get(\"ENV\") == 'prod':\n app = create_app(ProdConfig)\nelse:\n app = create_app(DevCo...
python
edit
1
1
mit
abcd2bd21a9033353e04514edd78a2a0a06292de
jawrainey/atc,jawrainey/atc
manage.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\nimport unittest\n\nfrom flask.ext.script import Manager\n\nfrom server import app\nfrom server.models import db\n\nmanager = Manager(app)\n\n\n@manager.command\ndef init_db():\n \"\"\" Initialize database: drop and create all ...
python
edit
1
1
mit
9f8a8321fbed1008f0eec608ba7bce9b08897e40
MACSIFS/IFS,MACSIFS/IFS,MACSIFS/IFS,MACSIFS/IFS
manage.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n\nimport os\n\nfrom app import create_app\nfrom flask.ext.script import Manager, Server\nfrom flask.ext.script.commands import ShowUrls, Clean\nfrom waitress import serve\n\n# default to dev config because no one shou...
python
edit
1
0
mit
43002f30c23f0a5d739a096ec8e9c445a9502f97
doomspork/seancallan.com,doomspork/seancallan.com,doomspork/seancallan.com
manage.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nIn this module we define the interface between the cli input provided\nby the user and the analytics required by the user\n\"\"\"\nfrom edx_data_research import parsing\nfrom edx_data_research import reporting\n\ndef cmd_report_basi...
python
edit
1
1
mit
084a923d928996022936e5c942e69876dc409b5e
McGillX/edx_data_research,McGillX/edx_data_research,McGillX/edx_data_research
edx_data_research/cli/commands.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python3\n\nimport os\nimport re\nimport sys\n\nfrom yuno.core import cli, config\nfrom yuno.core.util import working_dir\n\n\ndef main(argv=None):\n # Figure out where Yuno lives so plugins can cd correctly if they need to...
python
edit
3
5
mit
db960486f223e04fe08a8f2b9619aa887dcafeda
bulatb/yuno,bulatb/yuno
yuno.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\nfrom flask_script import Manager\nfrom flask_migrate import Migrate, MigrateCommand\n\nfrom app import create_app, db\n\napp = create_app(os.getenv(\"FLASK_CONFIG\") or \"default\")\n\nmigrate = Migrate(app, db)\n\nmanager = Mana...
python
edit
1
0
mit
7fe3eae251f3b0b4d433cf2d14f619306159ae43
Encrylize/MyDictionary,Encrylize/MyDictionary,Encrylize/MyDictionary
manage.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"ArgumentParser with Italian translation.\"\"\"\n\nimport argparse\nimport sys\n\n\ndef _callable(obj):\n return hasattr(obj, '__call__') or hasattr(obj, '__bases__')\n\n\nclass ArgParser(argparse.ArgumentParser):\n def __init__(...
python
edit
1
9
mit
395d35eafba14b52a301cb2cf0e7345ae7e0430c
claudio-unipv/pvcheck,claudio-unipv/pvcheck
src/argparser.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nTests run against live mail providers.\n\nThese aren't generally run as part of the test suite.\n\"\"\"\nimport os\n\nimport pytest\n\nfrom aiosmtplib import SMTP, SMTPAuthenticationError, SMTPStatus\n\n\npytestmark = [\n pytest....
python
edit
1
1
mit
de7219dd9d40f316dc0dd6f6c2cad68e66898762
cole/aiosmtplib
tests/test_live.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport dis\nimport time\n\nimport pyte\n\n# Create a new consts value.\nconsts = pyte.create_consts(None, \"Hello, world!\")\n# New varnames values\nvarnames = pyte.create_varnames()\n# Create names (for globals)\nnames = pyte.create_names(...
python
edit
1
0
mit
12096f2961f72e250e16b168c053e89277e442a5
SunDwarf/Pyte
test.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"A Pelican plugin which minifies HTML pages.\"\"\"\n\n\nfrom logging import getLogger\nfrom os import walk\nfrom os.path import join\n\nfrom htmlmin.minify import html_minify as min\nfrom pelican import signals\n\n\nlogger = getLogger(...
python
edit
4
4
unlicense
0adc28fffafbce685dc74009891ced9333b76eb9
rdegges/pelican-minify
minify.py
rejected_lint
Too many lint violations: 4
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom math import sin, cos, asin, sqrt\n\ndef hav(lona, lonb, lata, latb):\n\t# ported from latlontools\n\t# assume latitude and longitudes are in radians\n\tdiff_lat = lata - latb\n\tdiff_lon = lona - lonb\n\n\ta = sin(diff_lat/2)**2 + cos(...
python
edit
1
1
bsd-3-clause
0bd1865730106d2573acb04d95b23290e935f4c4
LemonPi/Pathtreker,LemonPi/Pathtreker,LemonPi/Pathtreker
util.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom __future__ import absolute_import\nfrom __future__ import unicode_literals\nimport simplejson\nfrom django_redis.cache import RedisCache\nfrom . import CACHE_DOCS, key_doc_id, rcache\nfrom corehq.util.soft_assert import soft_assert\n\n...
python
edit
1
3
bsd-3-clause
36d98f499316d4695c20544701dd1d4300aca600
dimagi/commcare-hq,dimagi/commcare-hq,dimagi/commcare-hq,dimagi/commcare-hq,dimagi/commcare-hq
corehq/ex-submodules/dimagi/utils/couch/cache/cache_core/lib.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom __future__ import absolute_import\n\nfrom functools import wraps\n\nfrom django.dispatch import Signal\n\n\nclass BetterSignal(Signal):\n def connect(self, receiver=None, **kwargs):\n \"\"\"\n Support decorator syntax:...
python
edit
1
2
bsd-3-clause
94475ea2ed73e57870e8947a5b3ed474a70447e4
jean/sentry,mitsuhiko/sentry,ifduyue/sentry,zenefits/sentry,JamesMura/sentry,mvaled/sentry,beeftornado/sentry,fotinakis/sentry,JamesMura/sentry,jean/sentry,mitsuhiko/sentry,gencer/sentry,jean/sentry,zenefits/sentry,BuildingLink/sentry,JackDanger/sentry,looker/sentry,looker/sentry,zenefits/sentry,beeftornado/sentry,mval...
src/sentry/signals.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\nexcept ImportError:\n from distutils.core import setup\n\nwith open('README.rst') as file_readme:\n readme = file_readme.read()\n\nsetup(name='json-sempai',\n versi...
python
edit
1
0
mit
affc6d644a5a259b1237df419b32b7001431ea6f
kragniz/json-sempai
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport sys\nfrom PyQt5.QtWidgets import QApplication, QMainWindow\nfrom PyQt5.uic import loadUi\n\nclass MainWindow(QMainWindow):\n\tdef __init__(self, *args):\n\t\tsuper(MainWindow, self).__init__(*args)\n\n\t\tloadUi(\"ui_files/main.ui\",...
python
edit
1
3
bsd-2-clause
a66ba9970675cbc0a79ec683d8db6046865d022e
neelchauhan/OnionLauncher
OnionLauncher/main.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#! /usr/bin/env python\n\nfrom optparse import OptionParser\nfrom compiler import convert_py2js\n\ndef main():\n parser = OptionParser(usage=\"%prog [options] filename\",\n description=\"Python to JavaScript compiler.\")\n pars...
python
edit
3
3
mit
8ce70e6b1af50f59102ccc33086a47fb36037fec
buchuki/pyjaco,buchuki/pyjaco,qsnake/py2js,chrivers/pyjaco,qsnake/py2js,buchuki/pyjaco,chrivers/pyjaco,chrivers/pyjaco
py2js.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# Copyright 2014 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# pylint: disable=W0401,W0614\n\n\nfrom telemetry import story\nfrom teleme...
python
edit
1
2
bsd-3-clause
430fd5393668249f01a2b941eef62569d758c6cf
google/skia,aosp-mirror/platform_external_skia,aosp-mirror/platform_external_skia,google/skia,google/skia,google/skia,aosp-mirror/platform_external_skia,aosp-mirror/platform_external_skia,google/skia,aosp-mirror/platform_external_skia,google/skia,aosp-mirror/platform_external_skia,google/skia,google/skia,aosp-mirror/pl...
tools/skp/page_sets/skia_intelwiki_desktop.py
rejected_duplicate
Near-duplicate of sample 14799
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# encoding: utf8\nfrom __future__ import unicode_literals\n\nfrom django.db import models, migrations\nfrom django.conf import settings\n\n\nclass Migration(migrations.Migration):\n\n dependencies = [\n migrations.swappable_depend...
python
edit
1
0
mit
91165642fb40165987ab0ff734959f88712e514c
vladimiroff/humble-media,vladimiroff/humble-media
humblemedia/resources/migrations/0001_initial.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import setup\nimport sys\n\nsetup(\n # Basic package information.\n name = 'zdesk',\n author = 'Brent Woodruff',\n version = '2.4.0',\n author_email = '<EMAIL>',\n packages = ['zdesk'],\n include_package...
python
edit
3
0
mit
101de91508d918b90c6254dc0b1cc5e0744bbd71
fprimex/zdesk,blade2005/zdesk,fprimex/zdgen
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#! /usr/bin/env python3\nfrom setuptools import setup\n\nfrom hsluv import __version__\n\nsetup(\n name='hsluv',\n version=__version__,\n description='Human-friendly HSL',\n long_description=open('README.md').read(),\n long_d...
python
edit
1
0
mit
618138eaac7463b9e2afd6e8d28c2e27cf294f87
hsluv/hsluv-python,husl-colors/husl.py
setup.py
rejected_duplicate
Near-duplicate of sample 20442
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# -*- coding: utf-8 -*-\n\"\"\"Setup file for basecrm library.\"\"\"\nimport os\nfrom setuptools import setup\n\nREADME = open(os.path.join(os.path.dirname(__file__), 'README.rst')).read()\n\n# allow setup.py to be run from any path\nos.chd...
python
edit
1
0
mit
24773383448698c71c5e83810b767e3a7c0900fb
yunojuno/django-basecrm
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\ntry:\n from setuptools import setup\nexcept:\n from distutils.core import setup\n\nimport os\n\n\ndef parse_requirements(requirements_filename='requirements.txt'):\n requirements = []\n if os.path.exists(requirements_filename):\...
python
edit
1
3
apache-2.0
bfeccfd7c6d926e760f938f6073827fc0c2d3dfa
cloudenvy/cloudenvy
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport sys\r\n\r\nimport setuptools\r\n\r\ndef read_long_description():\r\n with open('README.rst') as f:\r\n data = f.read()\r\n with open('CHANGES.rst') as f:\r\n data += '\\n\\n' + f.read()\r\n return data\r\n\r\ni...
python
edit
1
1
mit
b4ff3790fcefe070d13efed01247e94cbe87bd43
jaraco/irc
setup.py
rejected_duplicate
Near-duplicate of sample 12177
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nDistutils script for building cython .c and .so files. Call it with:\npython setup.py build_ext --inplace\n\"\"\"\n\nfrom distutils.core import setup\nfrom Cython.Build import cythonize\n\n#from Cython.Compiler.Options import direct...
python
edit
1
0
mit
902e4500b57d54a80a586b0843ff3a68706a5c58
cropleyb/pentai,cropleyb/pentai,cropleyb/pentai
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\nfrom setuptools import setup, find_packages\nfrom os import path\nimport sys\n\ninstall_requires = [\n 'itsdangerous',\n 'msgpack-python',\n 'pysha3',\n 'six',\n]\n\nextras_requi...
python
edit
3
0
mit
d78bcc4391f74c86eee927d9c30b58bb211d1cfe
thusoy/nuts-auth,thusoy/nuts-auth
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import setup\nimport sys\n\ntry:\n from PyQt4.QtCore import QT_VERSION_STR\nexcept ImportError:\n sys.exit(\"PyQt4 is required to install this package (see README.md for installation instructions)\")\n\nsetup(\n name = \"...
python
edit
2
0
mit
76dc4637d41b7c32f00a0cc1ab0a8af9b463524d
alexpeattie/wethepeopletoolkit
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import setup\nimport backlog\n\nPACKAGE = 'TracBacklog'\n\nsetup(name=PACKAGE,\n version=backlog.get_version(),\n packages=['backlog'],\n package_data={\n 'backlog': [\n 'htdocs/css/*.css',\n...
python
edit
1
0
bsd-3-clause
6459acb1b96f28e43346677b6e14173e7f30b91e
jszakmeister/trac-backlog,jszakmeister/trac-backlog
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom distutils.core import setup\n\nsetup(\n name='Logentries',\n version='0.7',\n author='Mark Lacomber',\n author_email='<EMAIL>',\n packages=['logentries'],\n scripts=[],\n url='http://pypi.python.org/pypi/Logentries...
python
edit
1
0
mit
0dd97c8154cb73d709656fbee99b8539d73a3ea6
logentries/le_python,jcftang/le_python,drgarcia1986/le_python
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport ez_setup\nez_setup.use_setuptools()\n\nfrom setuptools import setup, find_packages\n\nsetup(\n name = \"mobile-city-history\",\n version = 0.1,\n author = \"Jan-Christopher Pien\",\n author_email = \"<EMAIL>\",\n url =...
python
edit
1
0
mit
e093b77da3f914d15ace4d916cbe0ae9543c1327
fraunhoferfokus/mobile-city-memory,jessepeng/coburg-city-memory,fraunhoferfokus/mobile-city-memory,jessepeng/coburg-city-memory
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\ntry:\n from setuptools import setup\nexcept ImportError:\n from distutils.core import setup\n\n\ndef readme():\n with open('README.rst') as f:\n return f.read()\n\n\nsetup(na...
python
edit
1
1
mit
8682d4fe70571e6ad06357cd7d1f30559ed177ce
ptpt/ptwit
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# (c) 2017 Continuum Analytics, Inc. / http://continuum.io\n# All Rights Reserved\nfrom setuptools import setup\nimport sys\n\nfrom conda_verify import __version__\n\n\nif sys.version_info.major == 2:\n requirements = ['backports.functoo...
python
edit
1
0
bsd-3-clause
5b7b410d49f82d90b5846edaa523cd8b0a703b07
mandeep/conda-verify
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import find_packages, setup\n\n\nsetup(\n name=\"redshift-etl\",\n version=\"0.27.0\",\n author=\"Harry's Data Engineering and Contributors\",\n description=\"ETL code to ferry data from PostgreSQL databases (or ...
python
edit
1
0
mit
75c10d885c89cd763a065e4eb599ea5032b31fdd
harrystech/arthur-redshift-etl,harrystech/arthur-redshift-etl,harrystech/arthur-redshift-etl,harrystech/arthur-redshift-etl,harrystech/arthur-redshift-etl
setup.py
rejected_duplicate
Near-duplicate of sample 11238
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom setuptools import setup, find_packages\n\nsetup(\n name='django-timepiece',\n version=__import__('timepiece').__version__,\n author='Caktus Consulting Group',\n author_email='<EMAIL>',\n packages=find_packages(exclude=['...
python
edit
1
0
mit
5d5d55c80b6067e6e785a5b4578124a6759a1cfd
dannybrowne86/django-timepiece,BocuStudio/django-timepiece,gaga3966/django-timepiece,caktus/django-timepiece,dannybrowne86/django-timepiece,BocuStudio/django-timepiece,arbitrahj/django-timepiece,josesanch/django-timepiece,dannybrowne86/django-timepiece,caktus/django-timepiece,caktus/django-timepiece,gaga3966/django-tim...
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\n\nfrom setuptools import find_packages, setup\n\nfrom great import __url__\n\n\nwith open(os.path.join(os.path.dirname(__file__), \"README.rst\")) as readme:\n long_description = readme.read()\n\nclassifiers = [\n \"Develop...
python
edit
1
0
mit
67cb72b37ce0e68ceee7943295934f1d1fda179e
Julian/Great,Julian/Great,Julian/Great
setup.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/python2.4\n#\n# Copyright 2014 Google Inc. All Rights Reserved.\n\n\"\"\"WebRTC Test\n\nThis module serves the WebRTC Test Page.\n\"\"\"\n\nimport cgi\nimport logging\nimport os\nimport jinja2\nimport webapp2\n\njinja_environment...
python
edit
5
1
bsd-3-clause
b69f69b0e89a49b427292ec179e12bdee6fb4743
xdumaine/adapter,mulyoved/samples,ralic/testrtc,82488059/apprtc,mauricionr/samples,smayoorans/samples,shelsonjava/testrtc,4lejandrito/adapter,TribeMedia/testrtc,YouthAndra/apprtc,JiYou/apprtc,fetterov/samples,82488059/apprtc,webrtc/samples,TribeMedia/samples,dengshaodong/docker-apprtc,4lejandrito/adapter,diddie06/webrt...
samples/web/content/testrtc/testrtc.py
rejected_lint
Too many lint violations: 5
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# Settings used for running tests in Travis\n#\n\n# Load default settings\n# noinspection PyUnresolvedReferences\nfrom settings import *\n\n# Database\nDATABASES = {\n 'default': {\n 'ENGINE': 'django.db.backends.sqlite3', # 'pos...
python
edit
2
0
bsd-3-clause
c8360831ab2fa4d5af2929a85beca4a1f33ef9d1
Inter-Actief/alexia,Inter-Actief/alexia,Inter-Actief/alexia,Inter-Actief/alexia
travis_settings.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport asyncio\nimport aiozmq.rpc\n\n\nclass Handler(aiozmq.rpc.AttrHandler):\n\n @aiozmq.rpc.method\n def remote_func(self, a: int, b: int):\n pass\n\n\n@asyncio.coroutine\ndef go():\n subscriber = yield from aiozmq.rpc.ser...
python
edit
1
3
bsd-2-clause
33f1cd2950bf1544f4bb481aa0c31326a5c061ab
aio-libs/aiozmq,asteven/aiozmq,claws/aiozmq,MetaMemoryT/aiozmq
examples/rpc_pubsub.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Prepare update of Master to v0.20.0" }, { "role": "assistant", "content": "# This is the only location where the version will be written and changed.\n# Based on https://packaging.python.org/single_source_version/\n__version__ = ...
python
new_file
1
0
mit
17cee8fe32a38f976e8548993fa57857f84943ef
pastas/pastas
pastas/version.py
rejected_duplicate
Near-duplicate of sample 1794
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.apps import AppConfig as BaseAppConfig\nfrom django.utils.translation import ugettext_lazy as _\n\n\nclass AppConfig(BaseAppConfig):\n\n name = \"pinax.messages\"\n label = \"pinax_messages\"\n verbose_name = _(\"Pinax ...
python
edit
1
0
mit
fd5507db05429635200d56d4763fe623dfa6a811
pinax/pinax-messages,pinax/pinax-messages
pinax/messages/apps.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nVERSION = (0, 9, 0, 'beta', 1)\n\n\ndef get_version():\n from django.utils.version import get_version as django_get_version\n return django_get_version(VERSION) # pragma: no cover\n\n```\n\nApply this change: Fix version number report...
python
edit
1
4
bsd-3-clause
99b96d2c0b82e186b9eaa13d2efe8b617c9cf3aa
dinie/django-registration,dinie/django-registration,FundedByMe/django-registration,FundedByMe/django-registration,Avenza/django-registration
registration/__init__.py
rejected_duplicate
Near-duplicate of sample 13080
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom .models import ShiftSlot, weekday_loc\nfrom website.settings import WORKSHOP_OPEN_DAYS\n\ndef get_shift_weekview_rows():\n '''Returns a dictionary of shifts for each timeslot, for each weekday'''\n slots = ShiftSlot.objects.all()...
python
edit
4
5
mit
421e811242b737a7b1bf27814d70f719f345131b
hackerspace-ntnu/website,hackerspace-ntnu/website,hackerspace-ntnu/website
watchlist/utils.py
rejected_lint
Too many lint violations: 4
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom __future__ import absolute_import, division, print_function\n\nfrom virtualenv.__about__ import (\n __author__, __copyright__, __email__, __license__, __summary__, __title__,\n __uri__, __version__\n)\nfrom virtualenv.core import...
python
edit
1
2
mit
3830ef5200f3d1763be5d162f5123cd59ca1da0b
ionelmc/virtualenv,ionelmc/virtualenv,ionelmc/virtualenv
virtualenv/__init__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# vim: fileencoding=utf-8 et sw=4 ts=4 tw=80:\n\n# python-quilt - A Python implementation of the quilt patch system\n#\n# Copyright (C) 2012 Björn Ricks <<EMAIL>>\n#\n# This library is free software; you can redistribute it and/or\n# modif...
python
edit
1
0
mit
9261db252969c69ede633d4a4c02bb87c7bc1434
bjoernricks/python-quilt,vadmium/python-quilt
quilt/__init__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport pkg_resources\n\ntry:\n __version__ = pkg_resources.require('python-dispatch')[0].version\nexcept: # pragma: no cover\n __version__ = 'unknown'\n\nfrom pydispatch.dispatch import Dispatcher\nfrom pydispatch.properties import *\...
python
edit
5
0
mit
a7c1ec51aca74785ac309618f9519d4592953d3f
nocarryr/python-dispatch
pydispatch/__init__.py
rejected_lint
Too many lint violations: 5
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.conf.urls import url\n\nfrom . import views\n\nurlpatterns = [\n url(r'^projects/approve/$', views.approve_projects, name='approve_projects_overview'),\n url(r'^projects/approve/(?P<project_id>\\d+)/$', views.approve_proje...
python
edit
1
0
mit
8db252d2980451a3c2107df64c4438de44781eea
frigg/frigg-hq,frigg/frigg-hq,frigg/frigg-hq
frigg/projects/urls.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python -u\nfrom __future__ import absolute_import, division, print_function, unicode_literals\n\nimport csv, os, requests\n\nurl = 'https://api.balancedpayments.com/debits/{}/refunds'\nbalanced_api_secret = os.environ['BALANC...
python
edit
1
2
mit
3c4a9c08858378624600a3f64616f03e29d21f31
gratipay/gratipay.com,gratipay/gratipay.com,gratipay/gratipay.com,gratipay/gratipay.com
actually-do-refunds.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom enum import Enum\n\nclass WechatMessageType(Enum):\n\tTEXT = 1\n\tSYSTEM_MESSAGE = 10000\n\tVOICE = 34\n\tEMOTION = 47\n\tVIDEO = 62\n\tCALL = 50\n\tPICTURE = 3\n\tPOSITION = 48\n\tCARD = 42\n\tLINK = 49\n\n\tUNHANDLED = -999\n```\n\nA...
python
edit
1
0
apache-2.0
17b3ea3fb2af48aa7680b339bb83cba15f842a83
jambus/wechat-analysis
classes/wechatMessageType.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport doseresponse as dr\nimport numpy as np\nimport itertools as it\nimport os\nimport argparse\nimport sys\n\nparser = argparse.ArgumentParser()\n\nrequiredNamed = parser.add_argument_group('required arguments')\nrequiredNamed.add_argume...
python
edit
3
0
bsd-3-clause
0cb87e52f91c85ec99b58f2795c7762354531e7c
mirams/PyHillFit,mirams/PyHillFit,mirams/PyHillFit
python/assemble_BFs.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nCreated on Dec 24, 2016\n\n@author: john papa\n\nCopyright 2016 John Papa. All rights reserved.\nThis work is licensed under the MIT License.\n\"\"\"\nimport logging\n\nfrom .card import Card\n\nclass BjCard(Card):\n\n def __ini...
python
edit
1
4
mit
dbf0fb82263005d90a84ff9011da9849d0a3d0f3
johnpapa2/twenty-one,johnpapa2/twenty-one
cards/bjcard.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport support\nfrom html5lib import html5parser\nfrom html5lib.treebuilders import dom\n\nimport unittest\n\n# tests that aren't autogenerated from text files\nclass MoreParserTests(unittest.TestCase):\n\n def test_assertDoctypeCloneable(...
python
edit
3
1
mit
eea8b5622ced613cde54e6d09cd98f6483543dfd
alex/html5lib-python,html5lib/html5lib-python,mgilson/html5lib-python,mindw/html5lib-python,ordbogen/html5lib-python,mgilson/html5lib-python,mindw/html5lib-python,html5lib/html5lib-python,dstufft/html5lib-python,alex/html5lib-python,ordbogen/html5lib-python,mindw/html5lib-python,dstufft/html5lib-python,html5lib/html5li...
tests/test_parser2.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Add search method to find the movies/series home url" }, { "role": "assistant", "content": "import urllib.parse;\nimport urllib.request;\nfrom bs4 import BeautifulSoup;\n\n\ndef searchLink(search):\n\n\tBASE_URL = \"http://www.99...
python
new_file
1
3
mit
70808dfd53c5a5760a13252a72caf229793e8225
raztechs/py-video-crawler
crawl.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport re\nimport textwrap\n\nimport html2text\n\ntext_maker = html2text.HTML2Text()\ntext_maker.body_width = 0\n\n\ndef strip_html_tags(text):\n text = re.sub(r'<a.*?</a>', '', text)\n return re.sub('<[^<]+?>', '', text)\n\n\ndef htm...
python
edit
1
4
mit
e03bc2013adb21154a1fc2b4737d92f649325154
avinassh/Laozi,avinassh/Laozi
utils.py
rejected_duplicate
Near-duplicate of sample 17127
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.conf.urls import url\r\n\r\nfrom . import views\r\n\r\nurlpatterns = [\r\n url(r'^update/(?P<pk>[0-9]+)$',\r\n views.AmbulanceUpdateView.as_view(),\r\n name=\"ambulance_update\"),\r\n\r\n url(r'^info/(?P<pk>[...
python
edit
1
0
bsd-3-clause
7d362cfc37398a22440173fa7209224a2542778e
EMSTrack/WebServerAndClient,EMSTrack/WebServerAndClient,EMSTrack/WebServerAndClient
eng100l/ambulances/urls.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nclass Room(object):\n def __init__(self, room_name, room_type, max_persons):\n self.room_name = room_name\n self.room_type = room_type\n self.max_persons = max_persons\n self.persons = []\n\n\n def add_occu...
python
edit
1
2
mit
9fba993ea52df48de8d812c1ad0128d48c8ab4cf
peterpaints/room-allocator
classes/room.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\ntry:\n import asyncio\n loop = asyncio.get_event_loop()\nexcept ImportError:\n asyncio = None\n\nimport pexpect\nimport unittest\n\n@unittest.skipIf(asyncio is None, \"Requires asyncio\")\nclass AsyncTests(unittest.TestCase):\n ...
python
edit
21
1
isc
d9fc2cfdcfaf13f2e8491ace60680f3c94ad5c83
dongguangming/pexpect,quatanium/pexpect,crdoconnor/pexpect,Depado/pexpect,crdoconnor/pexpect,dongguangming/pexpect,crdoconnor/pexpect,Wakeupbuddy/pexpect,nodish/pexpect,Wakeupbuddy/pexpect,blink1073/pexpect,nodish/pexpect,quatanium/pexpect,bangi123/pexpect,dongguangming/pexpect,bangi123/pexpect,quatanium/pexpect,Depado...
tests/test_async.py
rejected_lint
Too many lint violations: 21
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom argparse import RawDescriptionHelpFormatter\nfrom copy import copy\n\nimport yaml\n\nfrom conda.cli import common\nfrom conda.cli import main_list\nfrom conda import install\n\ndescription = \"\"\"\nExport a given environment\n\"\"\"\n...
python
edit
1
3
bsd-3-clause
bff2488c184e142bfbf31e945b593e18db707dcc
isaac-kit/conda-env,conda/conda-env,nicoddemus/conda-env,isaac-kit/conda-env,phobson/conda-env,phobson/conda-env,mikecroucher/conda-env,asmeurer/conda-env,dan-blanchard/conda-env,conda/conda-env,ESSS/conda-env,dan-blanchard/conda-env,nicoddemus/conda-env,ESSS/conda-env,mikecroucher/conda-env,asmeurer/conda-env
conda_env/cli/main_export.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom hypothesis_auto import auto_pytest_magic\n\nfrom isort import parse\nfrom isort.settings import default\n\nTEST_CONTENTS = \"\"\"\nimport xyz\nimport abc\n\n\ndef function():\n pass\n\"\"\"\n\n\ndef test_file_contents():\n (\n ...
python
edit
1
1
mit
aaac1ae0667dabe6fd038c9f5a42c157b9457ef1
PyCQA/isort,PyCQA/isort
tests/test_parse.py
rejected_duplicate
Near-duplicate of sample 18594
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom os import chmod, unlink, stat, makedirs\nfrom os.path import isfile, split, exists\nfrom shutil import copyfile\n\ndef move_verify_delete(in_file, out_file):\n '''\n Moves in_file to out_file, verifies that the filesizes are the ...
python
edit
3
6
unlicense
5503a615db51a6ae0461cc0417c61ba508a43eae
timeartist/ufyr
ufyr/storage/utils.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport pytest\n\nfrom bonsai.utils import escape_filter_exp\nfrom bonsai.utils import escape_attribute_value\n\n\ndef test_escape_attribute_value():\n \"\"\" Test escaping special characters in attribute values. \"\"\"\n assert (\n ...
python
edit
1
1
mit
254ecc95cdd0c2809328634e50882ea42fb32105
Noirello/PyLDAP,Noirello/bonsai,Noirello/PyLDAP,Noirello/PyLDAP,Noirello/bonsai,Noirello/bonsai
tests/test_utils.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport operator\nfrom datashape import dshape\nfrom .core import Scalar, BinOp, UnaryOp\n\n\nclass BooleanInterface(Scalar):\n def __not__(self):\n return Not(self)\n\n def __and__(self, other):\n return And(self, other)...
python
edit
1
1
bsd-3-clause
f55f965c4102e2d7230ace39a0eecdaf585538ea
LiaoPan/blaze,caseyclements/blaze,cpcloud/blaze,cowlicks/blaze,caseyclements/blaze,jdmcbr/blaze,dwillmer/blaze,nkhuyu/blaze,scls19fr/blaze,mrocklin/blaze,cowlicks/blaze,dwillmer/blaze,cpcloud/blaze,xlhtc007/blaze,jcrist/blaze,maxalbert/blaze,jdmcbr/blaze,ChinaQuants/blaze,ContinuumIO/blaze,maxalbert/blaze,mrocklin/blaz...
blaze/expr/scalar/boolean.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport unittest\n\nfrom conans.errors import ConanException\n\nfrom cpt.config import ConfigManager\nfrom cpt.printer import Printer\nfrom cpt.test.integration.base import BaseTest\nfrom cpt.test.unit.packager_test import MockConanAPI\n\n\n...
python
edit
1
2
mit
4d55b1bde81c9f426da97f474d759ba8b0a94650
conan-io/conan-package-tools
cpt/test/unit/config_test.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\nfrom django.db import models\nfrom core.models import PlCoreBase\nfrom core.models.plcorebase import StrippedCharField\nfrom core.models import Site, SiteDeployment, SitePrivilege\nfrom core.models import Tag\nfrom django.contrib...
python
edit
4
3
apache-2.0
367d5d6196c3c21e2d1353b258801e6d5e14e602
jermowery/xos,cboling/xos,cboling/xos,cboling/xos,jermowery/xos,cboling/xos,xmaruto/mcord,jermowery/xos,xmaruto/mcord,xmaruto/mcord,cboling/xos,jermowery/xos,xmaruto/mcord
xos/core/models/node.py
rejected_lint
Too many lint violations: 4
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nbyceps.util.sentry\n~~~~~~~~~~~~~~~~~~\n\nSentry_ integration\n\n.. _Sentry: https://sentry.io/\n\n:Copyright: 2006-2020 Jochen Kupperschmidt\n:License: Modified BSD, see LICENSE for details.\n\"\"\"\n\nfrom flask import Flask\n\n\n...
python
edit
1
2
bsd-3-clause
f8ff675f8c9a4ef2b370e5254d33b97261a9d8ca
homeworkprod/byceps,homeworkprod/byceps,homeworkprod/byceps
byceps/util/sentry.py
accepted
null
true
[ { "role": "user", "content": "Write python code for the following: Fix version preparation to 2.0.3" }, { "role": "assistant", "content": "__author__ = 'Luiz Menezes'\n__title__ = 'simple-model'\n__version__ = '2.0.3'\n" } ]
python
new_file
1
0
mit
7a5d11229ff68735c16993c61c3a44e6b5ece7a8
lamenezes/simple-model
simple_model/__version__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nk-mer count and presence\n\"\"\"\n\nfrom galaxy.datatypes.binary import Binary\n\nimport os\nimport logging\n\nlog = logging.getLogger(__name__)\n\n\nclass Count(Binary):\n\n def __init__(self, **kwd):\n Binary.__init__(se...
python
edit
1
1
bsd-3-clause
1b7d84526ac7650f18851610ebef47bdfef828ea
Winterflower/khmer,kdmurray91/khmer,souravsingh/khmer,jas14/khmer,kdmurray91/khmer,Winterflower/khmer,F1000Research/khmer,jas14/khmer,ged-lab/khmer,kdmurray91/khmer,ged-lab/khmer,F1000Research/khmer,ged-lab/khmer,F1000Research/khmer,jas14/khmer,Winterflower/khmer,souravsingh/khmer,souravsingh/khmer
scripts/galaxy/gedlab.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django import http\nfrom django.core.exceptions import ObjectDoesNotExist\nfrom django_databrowse.datastructures import EasyModel\nfrom django_databrowse.sites import DatabrowsePlugin\nfrom django.shortcuts import render_to_response\ni...
python
edit
5
4
bsd-3-clause
b706c31fe24e4e940108882f420c0509cce94970
Alir3z4/django-databrowse,Alir3z4/django-databrowse
django_databrowse/plugins/objects.py
rejected_lint
Too many lint violations: 5
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\nimport os, sys, re, shutil\nos.environ['DJANGO_SETTINGS_MODULE'] = 'tests.settings'\n\nimport django\nfrom django.core.management import call_command\n\nnames = next((a for a in sys.argv[1:] if not a.startswith('-')),...
python
edit
1
0
bsd-3-clause
6b4f4f07c442705f76294b9ec9a37d3d02ca1551
rutube/django-cacheops,Suor/django-cacheops,LPgenerator/django-cacheops,ErwinJunge/django-cacheops,bourivouh/django-cacheops
run_tests.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\n\n Geotrek startup script.\n\n This is executed only once at startup.\n\n\"\"\"\nfrom south.signals import post_migrate\nfrom django.conf import settings\n\nfrom mapentity.helpers import api_bbox\n\nfrom geotrek.common.utils.p...
python
edit
1
1
bsd-2-clause
04b0f21bee9cfef54f4c1138296f86c9694dba95
makinacorpus/Geotrek,makinacorpus/Geotrek,mabhub/Geotrek,GeotrekCE/Geotrek-admin,Anaethelion/Geotrek,makinacorpus/Geotrek,johan--/Geotrek,mabhub/Geotrek,camillemonchicourt/Geotrek,mabhub/Geotrek,GeotrekCE/Geotrek-admin,mabhub/Geotrek,Anaethelion/Geotrek,johan--/Geotrek,camillemonchicourt/Geotrek,johan--/Geotrek,makinac...
geotrek/common/__init__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom conan.packager import ConanMultiPackager\n\nif __name__ == \"__main__\":\n builder = ConanMultiPackager()\n builder.add_common_builds(pure_c=False)\n builder.run()\n\n```\n\nApply this change: CI: Use std 14 in CI" }, { ...
python
edit
1
0
mit
5d2f585779bef5e8bd82e7f4e7b46818153af711
zhuhaow/libnekit,zhuhaow/libnekit,zhuhaow/libnekit,zhuhaow/libnekit
build.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom plugin import plugin\n\n\n@plugin('enable sound')\ndef enable_sound(jarvis, s):\n \"\"\"Let Jarvis use his voice.\"\"\"\n jarvis.enable_voice()\n\n\n@plugin('disable sound')\ndef disable_sound(jarvis, s):\n \"\"\"Deny Jarvis h...
python
edit
1
3
mit
90284fabbbbb1f6e7bda1cf33bdc39a1d76a25d4
sukeesh/Jarvis,sukeesh/Jarvis,sukeesh/Jarvis,sukeesh/Jarvis
jarviscli/plugins/voice.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\n\ntry: # 2.7\n # pylint: disable = E0611,F0401\n from unittest.case import SkipTest\n # pylint: enable = E0611,F0401\nexcept ImportError:\n try: # Nose\n from nose.plugins.skip import SkipTest\n except Impor...
python
edit
2
2
apache-2.0
2f1d32ba80816e3880a464a63d8f3f549a2be9e2
bencevans/mopidy,diandiankan/mopidy,ZenithDK/mopidy,vrs01/mopidy,liamw9534/mopidy,dbrgn/mopidy,swak/mopidy,jodal/mopidy,SuperStarPL/mopidy,jmarsik/mopidy,bacontext/mopidy,woutervanwijk/mopidy,ali/mopidy,pacificIT/mopidy,woutervanwijk/mopidy,quartz55/mopidy,jmarsik/mopidy,dbrgn/mopidy,mokieyue/mopidy,bencevans/mopidy,mo...
tests/__init__.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport pytest\n\nfrom tests.utils import PYTEST_6\n\npytest_plugins = \"pytester\"\n\n\ndef pytest_generate_tests(metafunc):\n if \"pytest_params\" in metafunc.fixturenames:\n if PYTEST_6:\n parametrizations = [\n ...
python
edit
1
3
mit
cbabdf4210313f934ae90d9a853834d9494b3ad5
pytest-dev/pytest-bdd
tests/conftest.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/env python\n'''\nDiscover all instances of unittest.TestCase in this directory.\n'''\n# Import python libs\nimport os\n# Import salt libs\nimport saltunittest\nfrom integration import TestDaemon\n\nTEST_DIR = os.path.dirname(os.p...
python
edit
13
1
apache-2.0
fdd75e81f6d71a8f82abdd79cff6ecd20cbfdb6d
saltstack/salt,saltstack/salt,saltstack/salt,saltstack/salt,saltstack/salt
tests/runtests.py
rejected_lint
Too many lint violations: 13
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.shortcuts import render\nimport logging\nfrom homeful.hud_helper import getSeattleFairMarketRents, getSeattleMultiFamilyProperties\n\nlogger = logging.getLogger(__name__)\n\ndef index(request):\n context = {}\n return rend...
python
edit
3
3
mit
cf9012ff2f6bf745d46f35923f95b6ce0b9d91e1
happyhousing/happyhousing
homeful/views.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport os\n\nimport pytest\nfrom pytest_django.lazy_django import skip_if_no_django\n\n\n@pytest.fixture(scope='session')\ndef casper_js(request):\n skip_if_no_django()\n\n from pytest_django_casperjs.helper import CasperJSLiveServer\...
python
edit
1
3
bsd-3-clause
621c69b22c6364020cf1ed66e4563bd7b43263fc
EnTeQuAk/pytest-django-casperjs
src/pytest_django_casperjs/fixtures.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# pylint: disable=missing-docstring\nfrom cleverhans.future.torch.attacks.fast_gradient_method import fast_gradient_method\nfrom cleverhans.future.torch.attacks.projected_gradient_descent import projected_gradient_descent\nfrom cleverhans.f...
python
edit
7
0
mit
a3c768ab90d1354441d90699049f7dd946e683c2
cleverhans-lab/cleverhans,cleverhans-lab/cleverhans,cleverhans-lab/cleverhans
cleverhans/future/torch/attacks/__init__.py
rejected_lint
Too many lint violations: 7
true
[ { "role": "user", "content": "Here is the current file:\n```python\nimport logging\nimport requests\n\nfrom .base import Notifier\n\nlog = logging.getLogger(__name__)\n\n\nclass HTTPNotifier(Notifier):\n ''' A Notifier that sends http post request to a given url '''\n def __init__(self, auth=None, **k...
python
edit
2
4
mit
e572dcb08e9c89d11c4702927561ef9c2ebc3cb1
fact-project/pycustos
custos/notify/http.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n#!/usr/bin/python\nimport config, store, os\nstandalone_py = os.path.join(os.path.dirname(__file__), 'standalone.py')\nc = config.Config(\"config.ini\")\ns = store.Store(c)\ncursor = s.get_cursor()\ncursor.execute(\"lock table sshkeys in ex...
python
edit
1
0
bsd-3-clause
a5ce33cf60deb5a1045a0bf693b58eb20dbad8d2
pydotorg/pypi,pydotorg/pypi,pydotorg/pypi,pydotorg/pypi
sshkeys_update.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"\nForms\n=====\n\nThese three form subclasses will automatically add limitation by tenant\nto all form fields with a ``queryset`` attribute.\n\n.. warning::\n\n If you customized the dropdown using ``choices`` you have to limit the...
python
edit
1
3
bsd-3-clause
c47c334eb10c331266a2469c0975698722c2cbb4
matthiask/towel,matthiask/towel,matthiask/towel,matthiask/towel
towel/mt/forms.py
rejected_duplicate
Near-duplicate of sample 4878
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"Codewars: Find the unique number\n6 kyu\n\nURL: https://www.codewars.com/kata/find-the-unique-number-1/\n\nThere is an array with some numbers. All numbers are equal except for one.\nTry to find it!\n\nfind_uniq([ 1, 1, 1, 2, 1, 1 ]) ...
python
edit
3
4
bsd-2-clause
e43c03fbb04de6ef067a22b62ce5c8049020831a
bowen0701/algorithms_data_structures
cw_find_the_unique_number.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n# Copyright 2014 Cloudera 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# http://www.apache.or...
python
edit
8
2
apache-2.0
b748de5c965219688562819b3cabad1b7ee357d1
mariusvniekerk/ibis,koverholt/ibis,shaunstanislaus/ibis,deepfield/ibis,Supermem/ibis,o0neup/ibis,ibis-project/ibis,ashhher3/ibis,fivejjs/ibis,Supermem/ibis,koverholt/ibis,cloudera/ibis,laserson/ibis,mahantheshhv/ibis,cloudera/ibis,korotkyn/ibis,Winterflower/ibis,ibis-project/ibis,fivejjs/ibis,adamobeng/ibis,dboyliao/ib...
ibis/__init__.py
rejected_lint
Too many lint violations: 8
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom bluesky.plans import scan\nfrom bluesky.simulators import print_summary, print_summary_wrapper\n\n\ndef test_print_summary(motor_det):\n motor, det = motor_det\n print_summary(scan([det], motor, -1, 1, 10))\n list(print_summar...
python
edit
1
1
bsd-3-clause
70ee0532f68a08fa12ba7bbfb217273ca8ef7a48
ericdill/bluesky,ericdill/bluesky
bluesky/tests/test_simulators.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\nfrom django.contrib.auth.mixins import PermissionRequiredMixin\nfrom django.core.urlresolvers import reverse_lazy\nfrom django.views.generic import ListView, UpdateView\n\nfrom admin.subjects.forms import SubjectForm\nfrom osf.models.subjec...
python
edit
1
2
apache-2.0
86a26fb8a2f9754a27763cb04292735bc31d0fe7
felliott/osf.io,sloria/osf.io,Johnetordoff/osf.io,Johnetordoff/osf.io,Johnetordoff/osf.io,baylee-d/osf.io,TomBaxter/osf.io,felliott/osf.io,icereval/osf.io,crcresearch/osf.io,icereval/osf.io,caneruguz/osf.io,aaxelb/osf.io,chennan47/osf.io,aaxelb/osf.io,brianjgeiger/osf.io,pattisdr/osf.io,HalcyonChimera/osf.io,adlius/osf...
admin/subjects/views.py
accepted
null
true
[ { "role": "user", "content": "Here is the current file:\n```python\n\"\"\"Core XML support for Python.\n\nThis package contains three sub-packages:\n\ndom -- The W3C Document Object Model. This supports DOM Level 1 +\n Namespaces.\n\nparsers -- Python wrappers for XML parsers (currently only supports...
python
edit
4
0
mit
9ca11ae97ac21d6525da853c9ec3e8007939d187
sk-/python2.7-type-annotator,sk-/python2.7-type-annotator,sk-/python2.7-type-annotator
Lib/xml/__init__.py
rejected_lint
Too many lint violations: 4
true