commit stringlengths 40 40 | old_file stringlengths 4 118 | new_file stringlengths 4 118 | old_contents stringlengths 0 2.94k | new_contents stringlengths 1 4.43k | subject stringlengths 15 444 | message stringlengths 16 3.45k | lang stringclasses 1
value | license stringclasses 13
values | repos stringlengths 5 43.2k | prompt stringlengths 17 4.58k | response stringlengths 1 4.43k | prompt_tagged stringlengths 58 4.62k | response_tagged stringlengths 1 4.43k | text stringlengths 132 7.29k | text_tagged stringlengths 173 7.33k |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
9549f70bf6c276f2124682e3f297caeb9c866770 | setup.py | setup.py | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Setup file for easy installation."""
from setuptools import setup
import glob
from spec_cleaner import __version__
setup(
name='spec_cleaner',
description='RPM .spec files cleaner',
long_description='Command-line tool for cleaning various formatting' +
... | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Setup file for easy installation."""
from setuptools import setup
import glob
from spec_cleaner import __version__
setup(
name='spec_cleaner',
description='RPM .spec files cleaner',
long_description='Command-line tool for cleaning various formatting ' +
... | Fix typo in longdesc of the package | Fix typo in longdesc of the package
| Python | bsd-3-clause | plusky/spec-cleaner,plusky/spec-cleaner,plusky/spec-cleaner,plusky/spec-cleaner,plusky/spec-cleaner | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Setup file for easy installation."""
from setuptools import setup
import glob
from spec_cleaner import __version__
setup(
name='spec_cleaner',
description='RPM .spec files cleaner',
long_description='Command-line tool for cleaning various formatting' +
... | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Setup file for easy installation."""
from setuptools import setup
import glob
from spec_cleaner import __version__
setup(
name='spec_cleaner',
description='RPM .spec files cleaner',
long_description='Command-line tool for cleaning various formatting ' +
... | <commit_before>#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Setup file for easy installation."""
from setuptools import setup
import glob
from spec_cleaner import __version__
setup(
name='spec_cleaner',
description='RPM .spec files cleaner',
long_description='Command-line tool for cleaning various for... | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Setup file for easy installation."""
from setuptools import setup
import glob
from spec_cleaner import __version__
setup(
name='spec_cleaner',
description='RPM .spec files cleaner',
long_description='Command-line tool for cleaning various formatting ' +
... | #!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Setup file for easy installation."""
from setuptools import setup
import glob
from spec_cleaner import __version__
setup(
name='spec_cleaner',
description='RPM .spec files cleaner',
long_description='Command-line tool for cleaning various formatting' +
... | <commit_before>#!/usr/bin/env python
# -*- coding: utf-8 -*-
"""Setup file for easy installation."""
from setuptools import setup
import glob
from spec_cleaner import __version__
setup(
name='spec_cleaner',
description='RPM .spec files cleaner',
long_description='Command-line tool for cleaning various for... |
0d1ec7d24e3b6272ccde8a2b02af35a29db145ab | setup.py | setup.py | import os
import setuptools
setuptools.setup(
name='lmj.sim',
version='0.0.2',
namespace_packages=['lmj'],
packages=setuptools.find_packages(),
author='Leif Johnson',
author_email='leif@leifjohnson.net',
description='Yet another OpenGL-with-physics simulation framework',
long_descriptio... | import os
import setuptools
setuptools.setup(
name='lmj.sim',
version='0.0.2',
namespace_packages=['lmj'],
packages=setuptools.find_packages(),
author='Leif Johnson',
author_email='leif@leifjohnson.net',
description='Yet another OpenGL-with-physics simulation framework',
long_descriptio... | Change dependency from PyODE to bindings included with ODE source. | Change dependency from PyODE to bindings included with ODE source.
| Python | mit | EmbodiedCognition/pagoda,EmbodiedCognition/pagoda | import os
import setuptools
setuptools.setup(
name='lmj.sim',
version='0.0.2',
namespace_packages=['lmj'],
packages=setuptools.find_packages(),
author='Leif Johnson',
author_email='leif@leifjohnson.net',
description='Yet another OpenGL-with-physics simulation framework',
long_descriptio... | import os
import setuptools
setuptools.setup(
name='lmj.sim',
version='0.0.2',
namespace_packages=['lmj'],
packages=setuptools.find_packages(),
author='Leif Johnson',
author_email='leif@leifjohnson.net',
description='Yet another OpenGL-with-physics simulation framework',
long_descriptio... | <commit_before>import os
import setuptools
setuptools.setup(
name='lmj.sim',
version='0.0.2',
namespace_packages=['lmj'],
packages=setuptools.find_packages(),
author='Leif Johnson',
author_email='leif@leifjohnson.net',
description='Yet another OpenGL-with-physics simulation framework',
... | import os
import setuptools
setuptools.setup(
name='lmj.sim',
version='0.0.2',
namespace_packages=['lmj'],
packages=setuptools.find_packages(),
author='Leif Johnson',
author_email='leif@leifjohnson.net',
description='Yet another OpenGL-with-physics simulation framework',
long_descriptio... | import os
import setuptools
setuptools.setup(
name='lmj.sim',
version='0.0.2',
namespace_packages=['lmj'],
packages=setuptools.find_packages(),
author='Leif Johnson',
author_email='leif@leifjohnson.net',
description='Yet another OpenGL-with-physics simulation framework',
long_descriptio... | <commit_before>import os
import setuptools
setuptools.setup(
name='lmj.sim',
version='0.0.2',
namespace_packages=['lmj'],
packages=setuptools.find_packages(),
author='Leif Johnson',
author_email='leif@leifjohnson.net',
description='Yet another OpenGL-with-physics simulation framework',
... |
eea8431d5f63fa6245ade4f66f787e62b8ea8b85 | setup.py | setup.py | import sys
from setuptools import setup, find_packages, Command
from distutils import log
setup(
name='diffenator',
version='0.1.0',
author="Google Fonts Project Authors",
description="Font regression tester for Google Fonts",
url="https://github.com/googlefonts/diffenator",
license="Apache Sof... | import sys
from setuptools import setup, find_packages, Command
from distutils import log
setup(
name='fontdiffenator',
version='0.1.0',
author="Google Fonts Project Authors",
description="Font regression tester for Google Fonts",
url="https://github.com/googlefonts/diffenator",
license="Apache... | Change package name to fontdiffenator | Change package name to fontdiffenator
| Python | apache-2.0 | googlefonts/fontdiffenator,googlefonts/fontdiffenator | import sys
from setuptools import setup, find_packages, Command
from distutils import log
setup(
name='diffenator',
version='0.1.0',
author="Google Fonts Project Authors",
description="Font regression tester for Google Fonts",
url="https://github.com/googlefonts/diffenator",
license="Apache Sof... | import sys
from setuptools import setup, find_packages, Command
from distutils import log
setup(
name='fontdiffenator',
version='0.1.0',
author="Google Fonts Project Authors",
description="Font regression tester for Google Fonts",
url="https://github.com/googlefonts/diffenator",
license="Apache... | <commit_before>import sys
from setuptools import setup, find_packages, Command
from distutils import log
setup(
name='diffenator',
version='0.1.0',
author="Google Fonts Project Authors",
description="Font regression tester for Google Fonts",
url="https://github.com/googlefonts/diffenator",
lice... | import sys
from setuptools import setup, find_packages, Command
from distutils import log
setup(
name='fontdiffenator',
version='0.1.0',
author="Google Fonts Project Authors",
description="Font regression tester for Google Fonts",
url="https://github.com/googlefonts/diffenator",
license="Apache... | import sys
from setuptools import setup, find_packages, Command
from distutils import log
setup(
name='diffenator',
version='0.1.0',
author="Google Fonts Project Authors",
description="Font regression tester for Google Fonts",
url="https://github.com/googlefonts/diffenator",
license="Apache Sof... | <commit_before>import sys
from setuptools import setup, find_packages, Command
from distutils import log
setup(
name='diffenator',
version='0.1.0',
author="Google Fonts Project Authors",
description="Font regression tester for Google Fonts",
url="https://github.com/googlefonts/diffenator",
lice... |
eeace4d8c5c787a25c67b2b6bb2916582666ef82 | setup.py | setup.py | #!/usr/bin/env python
import chevron.metadata
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
try:
import pypandoc
readme = pypandoc.convert('README.md', 'rest')
except (ImportError, RuntimeError):
print('\n\n!!!\npypandoc not loaded\n!!!\n')
readme = ''... | #!/usr/bin/env python
import chevron.metadata
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
with open('README.md') as f:
readme = f.read()
setup(name='chevron',
version=chevron.metadata.version,
license='MIT',
description='Mustache templating ... | Remove pandoc, PyPi accepts markdown now | Remove pandoc, PyPi accepts markdown now
| Python | mit | noahmorrison/chevron,noahmorrison/chevron | #!/usr/bin/env python
import chevron.metadata
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
try:
import pypandoc
readme = pypandoc.convert('README.md', 'rest')
except (ImportError, RuntimeError):
print('\n\n!!!\npypandoc not loaded\n!!!\n')
readme = ''... | #!/usr/bin/env python
import chevron.metadata
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
with open('README.md') as f:
readme = f.read()
setup(name='chevron',
version=chevron.metadata.version,
license='MIT',
description='Mustache templating ... | <commit_before>#!/usr/bin/env python
import chevron.metadata
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
try:
import pypandoc
readme = pypandoc.convert('README.md', 'rest')
except (ImportError, RuntimeError):
print('\n\n!!!\npypandoc not loaded\n!!!\n')
... | #!/usr/bin/env python
import chevron.metadata
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
with open('README.md') as f:
readme = f.read()
setup(name='chevron',
version=chevron.metadata.version,
license='MIT',
description='Mustache templating ... | #!/usr/bin/env python
import chevron.metadata
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
try:
import pypandoc
readme = pypandoc.convert('README.md', 'rest')
except (ImportError, RuntimeError):
print('\n\n!!!\npypandoc not loaded\n!!!\n')
readme = ''... | <commit_before>#!/usr/bin/env python
import chevron.metadata
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
try:
import pypandoc
readme = pypandoc.convert('README.md', 'rest')
except (ImportError, RuntimeError):
print('\n\n!!!\npypandoc not loaded\n!!!\n')
... |
73de4216c697ff79cb256a1b8c3be464e6355370 | examples/flask_app/src/backend/main.py | examples/flask_app/src/backend/main.py | from threading import Thread, Lock
import logging
import webview
from time import sleep
from server import run_server
server_lock = Lock()
logger = logging.getLogger(__name__)
def url_ok(url, port):
# Use httplib on Python 2
try:
from http.client import HTTPConnection
except ImportError:
... | import logging
import webview
from contextlib import redirect_stdout
from io import StringIO
from threading import Thread, Lock
from time import sleep
from server import run_server
server_lock = Lock()
logger = logging.getLogger(__name__)
def url_ok(url, port):
# Use httplib on Python 2
try:
from h... | Fix Flask example to allow freezing | Fix Flask example to allow freezing
| Python | bsd-3-clause | r0x0r/pywebview,r0x0r/pywebview,r0x0r/pywebview,r0x0r/pywebview,r0x0r/pywebview | from threading import Thread, Lock
import logging
import webview
from time import sleep
from server import run_server
server_lock = Lock()
logger = logging.getLogger(__name__)
def url_ok(url, port):
# Use httplib on Python 2
try:
from http.client import HTTPConnection
except ImportError:
... | import logging
import webview
from contextlib import redirect_stdout
from io import StringIO
from threading import Thread, Lock
from time import sleep
from server import run_server
server_lock = Lock()
logger = logging.getLogger(__name__)
def url_ok(url, port):
# Use httplib on Python 2
try:
from h... | <commit_before>from threading import Thread, Lock
import logging
import webview
from time import sleep
from server import run_server
server_lock = Lock()
logger = logging.getLogger(__name__)
def url_ok(url, port):
# Use httplib on Python 2
try:
from http.client import HTTPConnection
except Impor... | import logging
import webview
from contextlib import redirect_stdout
from io import StringIO
from threading import Thread, Lock
from time import sleep
from server import run_server
server_lock = Lock()
logger = logging.getLogger(__name__)
def url_ok(url, port):
# Use httplib on Python 2
try:
from h... | from threading import Thread, Lock
import logging
import webview
from time import sleep
from server import run_server
server_lock = Lock()
logger = logging.getLogger(__name__)
def url_ok(url, port):
# Use httplib on Python 2
try:
from http.client import HTTPConnection
except ImportError:
... | <commit_before>from threading import Thread, Lock
import logging
import webview
from time import sleep
from server import run_server
server_lock = Lock()
logger = logging.getLogger(__name__)
def url_ok(url, port):
# Use httplib on Python 2
try:
from http.client import HTTPConnection
except Impor... |
dea503e03a7c18c256d902b0b6ad3cb66a7ce9a2 | examples/flexure/example_point_load.py | examples/flexure/example_point_load.py | #! /usr/bin/env python
"""
"""
from landlab import RasterModelGrid
from landlab.components.flexure import Flexure
def add_load_to_middle_of_grid(grid, load):
shape = grid.shape
load_array = grid.field_values(
"node", "lithosphere__overlying_pressure_increment"
).view()
load_array.shape = s... | #! /usr/bin/env python
"""
"""
from landlab import RasterModelGrid
from landlab.components.flexure import Flexure
def add_load_to_middle_of_grid(grid, load):
shape = grid.shape
load_array = grid.field_values(
"node", "lithosphere__overlying_pressure_increment"
).view()
load_array.shape = s... | Fix F841: local variable is assigned to but never used. | Fix F841: local variable is assigned to but never used.
| Python | mit | amandersillinois/landlab,cmshobe/landlab,landlab/landlab,cmshobe/landlab,amandersillinois/landlab,cmshobe/landlab,landlab/landlab,landlab/landlab | #! /usr/bin/env python
"""
"""
from landlab import RasterModelGrid
from landlab.components.flexure import Flexure
def add_load_to_middle_of_grid(grid, load):
shape = grid.shape
load_array = grid.field_values(
"node", "lithosphere__overlying_pressure_increment"
).view()
load_array.shape = s... | #! /usr/bin/env python
"""
"""
from landlab import RasterModelGrid
from landlab.components.flexure import Flexure
def add_load_to_middle_of_grid(grid, load):
shape = grid.shape
load_array = grid.field_values(
"node", "lithosphere__overlying_pressure_increment"
).view()
load_array.shape = s... | <commit_before>#! /usr/bin/env python
"""
"""
from landlab import RasterModelGrid
from landlab.components.flexure import Flexure
def add_load_to_middle_of_grid(grid, load):
shape = grid.shape
load_array = grid.field_values(
"node", "lithosphere__overlying_pressure_increment"
).view()
load_... | #! /usr/bin/env python
"""
"""
from landlab import RasterModelGrid
from landlab.components.flexure import Flexure
def add_load_to_middle_of_grid(grid, load):
shape = grid.shape
load_array = grid.field_values(
"node", "lithosphere__overlying_pressure_increment"
).view()
load_array.shape = s... | #! /usr/bin/env python
"""
"""
from landlab import RasterModelGrid
from landlab.components.flexure import Flexure
def add_load_to_middle_of_grid(grid, load):
shape = grid.shape
load_array = grid.field_values(
"node", "lithosphere__overlying_pressure_increment"
).view()
load_array.shape = s... | <commit_before>#! /usr/bin/env python
"""
"""
from landlab import RasterModelGrid
from landlab.components.flexure import Flexure
def add_load_to_middle_of_grid(grid, load):
shape = grid.shape
load_array = grid.field_values(
"node", "lithosphere__overlying_pressure_increment"
).view()
load_... |
584956dce7cd607c6cb0d24d360d65d1c0be7005 | lib/pylprof/dump-stats.py | lib/pylprof/dump-stats.py | import json
stats = lp.get_stats()
unit = stats.unit
results = {}
for function, timings in stats.timings.iteritems():
module, line, fname = function
results[module] = {}
for sample in timings:
linenumber, ncalls, timing = sample
if not results[module].get(linenumber):
results[mod... | import json
import sys
from collections import defaultdict
stats = lp.get_stats()
unit = stats.unit
results = {}
for loc, timings in stats.timings.iteritems():
module, line, fname = loc
if not results.get(module):
results[module] = defaultdict(list)
for sample in timings:
linenumber, ncalls... | Fix bug when profiling multiple fcts per module | [pylprof] Fix bug when profiling multiple fcts per module
| Python | mit | iddl/pprofile,iddl/pprofile | import json
stats = lp.get_stats()
unit = stats.unit
results = {}
for function, timings in stats.timings.iteritems():
module, line, fname = function
results[module] = {}
for sample in timings:
linenumber, ncalls, timing = sample
if not results[module].get(linenumber):
results[mod... | import json
import sys
from collections import defaultdict
stats = lp.get_stats()
unit = stats.unit
results = {}
for loc, timings in stats.timings.iteritems():
module, line, fname = loc
if not results.get(module):
results[module] = defaultdict(list)
for sample in timings:
linenumber, ncalls... | <commit_before>import json
stats = lp.get_stats()
unit = stats.unit
results = {}
for function, timings in stats.timings.iteritems():
module, line, fname = function
results[module] = {}
for sample in timings:
linenumber, ncalls, timing = sample
if not results[module].get(linenumber):
... | import json
import sys
from collections import defaultdict
stats = lp.get_stats()
unit = stats.unit
results = {}
for loc, timings in stats.timings.iteritems():
module, line, fname = loc
if not results.get(module):
results[module] = defaultdict(list)
for sample in timings:
linenumber, ncalls... | import json
stats = lp.get_stats()
unit = stats.unit
results = {}
for function, timings in stats.timings.iteritems():
module, line, fname = function
results[module] = {}
for sample in timings:
linenumber, ncalls, timing = sample
if not results[module].get(linenumber):
results[mod... | <commit_before>import json
stats = lp.get_stats()
unit = stats.unit
results = {}
for function, timings in stats.timings.iteritems():
module, line, fname = function
results[module] = {}
for sample in timings:
linenumber, ncalls, timing = sample
if not results[module].get(linenumber):
... |
1c011be6d217ab8a62ed2f5c7f920d543519be2f | app/api_v1/__init__.py | app/api_v1/__init__.py | """This module creates the api BluePrint."""
from flask import BluePrint
api = BluePrint('api', __name__)
| """This module creates the api BluePrint."""
from flask import Blueprint
api = Blueprint('api', __name__)
| Fix typo in import message. | [Bug] Fix typo in import message.
| Python | mit | andela-akiura/bucketlist | """This module creates the api BluePrint."""
from flask import BluePrint
api = BluePrint('api', __name__)
[Bug] Fix typo in import message. | """This module creates the api BluePrint."""
from flask import Blueprint
api = Blueprint('api', __name__)
| <commit_before>"""This module creates the api BluePrint."""
from flask import BluePrint
api = BluePrint('api', __name__)
<commit_msg>[Bug] Fix typo in import message.<commit_after> | """This module creates the api BluePrint."""
from flask import Blueprint
api = Blueprint('api', __name__)
| """This module creates the api BluePrint."""
from flask import BluePrint
api = BluePrint('api', __name__)
[Bug] Fix typo in import message."""This module creates the api BluePrint."""
from flask import Blueprint
api = Blueprint('api', __name__)
| <commit_before>"""This module creates the api BluePrint."""
from flask import BluePrint
api = BluePrint('api', __name__)
<commit_msg>[Bug] Fix typo in import message.<commit_after>"""This module creates the api BluePrint."""
from flask import Blueprint
api = Blueprint('api', __name__)
|
2b58374504242d4019fde208296802fe4fb1c4b3 | Lib/__init__.py | Lib/__init__.py | """\
SciPy --- A scientific computing package for Python
===================================================
You can support the development of SciPy by purchasing documentation
at
http://www.trelgol.com
It is being distributed for a fee for a limited time to try and raise
money for development.
Documentation is ... | """\
SciPy --- A scientific computing package for Python
===================================================
You can support the development of SciPy by purchasing documentation
at
http://www.trelgol.com
It is being distributed for a fee for a limited time to try and raise
money for development.
Documentation is ... | Remove auto include of numpy namespace. | Remove auto include of numpy namespace.
git-svn-id: 003f22d385e25de9cff933a5ea4efd77cb5e7b28@1522 d6536bca-fef9-0310-8506-e4c0a848fbcf
| Python | bsd-3-clause | scipy/scipy-svn,jasonmccampbell/scipy-refactor,jasonmccampbell/scipy-refactor,lesserwhirls/scipy-cwt,jasonmccampbell/scipy-refactor,lesserwhirls/scipy-cwt,scipy/scipy-svn,lesserwhirls/scipy-cwt,lesserwhirls/scipy-cwt,scipy/scipy-svn,scipy/scipy-svn,jasonmccampbell/scipy-refactor | """\
SciPy --- A scientific computing package for Python
===================================================
You can support the development of SciPy by purchasing documentation
at
http://www.trelgol.com
It is being distributed for a fee for a limited time to try and raise
money for development.
Documentation is ... | """\
SciPy --- A scientific computing package for Python
===================================================
You can support the development of SciPy by purchasing documentation
at
http://www.trelgol.com
It is being distributed for a fee for a limited time to try and raise
money for development.
Documentation is ... | <commit_before>"""\
SciPy --- A scientific computing package for Python
===================================================
You can support the development of SciPy by purchasing documentation
at
http://www.trelgol.com
It is being distributed for a fee for a limited time to try and raise
money for development.
Do... | """\
SciPy --- A scientific computing package for Python
===================================================
You can support the development of SciPy by purchasing documentation
at
http://www.trelgol.com
It is being distributed for a fee for a limited time to try and raise
money for development.
Documentation is ... | """\
SciPy --- A scientific computing package for Python
===================================================
You can support the development of SciPy by purchasing documentation
at
http://www.trelgol.com
It is being distributed for a fee for a limited time to try and raise
money for development.
Documentation is ... | <commit_before>"""\
SciPy --- A scientific computing package for Python
===================================================
You can support the development of SciPy by purchasing documentation
at
http://www.trelgol.com
It is being distributed for a fee for a limited time to try and raise
money for development.
Do... |
bdfb9f519de343a8802a66074f9c0af058c42978 | scripts/master/factory/dart/channels.py | scripts/master/factory/dart/channels.py | # Copyright 2013 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
class Channel(object):
def __init__(self, name, branch, position, category_postfix, priority):
self.branch = branch
self.builder_postfix = '-' + na... | # Copyright 2013 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
class Channel(object):
def __init__(self, name, branch, position, category_postfix, priority):
self.branch = branch
self.builder_postfix = '-' + na... | Make stable builders pull from the 1.9 branch | Make stable builders pull from the 1.9 branch
TBR=kasperl@google.com
BUG=
Review URL: https://codereview.chromium.org/1029093006
git-svn-id: 239fca9b83025a0b6f823aeeca02ba5be3d9fd76@294541 0039d316-1c4b-4281-b951-d872f2087c98
| Python | bsd-3-clause | eunchong/build,eunchong/build,eunchong/build,eunchong/build | # Copyright 2013 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
class Channel(object):
def __init__(self, name, branch, position, category_postfix, priority):
self.branch = branch
self.builder_postfix = '-' + na... | # Copyright 2013 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
class Channel(object):
def __init__(self, name, branch, position, category_postfix, priority):
self.branch = branch
self.builder_postfix = '-' + na... | <commit_before># Copyright 2013 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
class Channel(object):
def __init__(self, name, branch, position, category_postfix, priority):
self.branch = branch
self.builder_pos... | # Copyright 2013 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
class Channel(object):
def __init__(self, name, branch, position, category_postfix, priority):
self.branch = branch
self.builder_postfix = '-' + na... | # Copyright 2013 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
class Channel(object):
def __init__(self, name, branch, position, category_postfix, priority):
self.branch = branch
self.builder_postfix = '-' + na... | <commit_before># Copyright 2013 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
class Channel(object):
def __init__(self, name, branch, position, category_postfix, priority):
self.branch = branch
self.builder_pos... |
97529500f335ee1f75a6229c1c313bc7ff2d68ef | satchmo/apps/satchmo_store/shop/management/commands/satchmo_copy_static.py | satchmo/apps/satchmo_store/shop/management/commands/satchmo_copy_static.py | from django.core.management.base import NoArgsCommand
import os
import shutil
class Command(NoArgsCommand):
help = "Copy the satchmo static directory and files to the local project."
def handle_noargs(self, **options):
import satchmo_store
static_src = os.path.join(satchmo_store.__path__[0],'s... | from django.core.management.base import NoArgsCommand
import os
import shutil
class Command(NoArgsCommand):
help = "Copy the satchmo static directory and files to the local project."
def handle_noargs(self, **options):
import satchmo_store
static_src = os.path.join(satchmo_store.__path__[0],'.... | Change the static copy command so it works with new layout. | Change the static copy command so it works with new layout.
--HG--
extra : convert_revision : svn%3Aa38d40e9-c014-0410-b785-c606c0c8e7de/satchmo/trunk%401887
| Python | bsd-3-clause | dokterbob/satchmo,Ryati/satchmo,twidi/satchmo,ringemup/satchmo,ringemup/satchmo,Ryati/satchmo,twidi/satchmo,dokterbob/satchmo | from django.core.management.base import NoArgsCommand
import os
import shutil
class Command(NoArgsCommand):
help = "Copy the satchmo static directory and files to the local project."
def handle_noargs(self, **options):
import satchmo_store
static_src = os.path.join(satchmo_store.__path__[0],'s... | from django.core.management.base import NoArgsCommand
import os
import shutil
class Command(NoArgsCommand):
help = "Copy the satchmo static directory and files to the local project."
def handle_noargs(self, **options):
import satchmo_store
static_src = os.path.join(satchmo_store.__path__[0],'.... | <commit_before>from django.core.management.base import NoArgsCommand
import os
import shutil
class Command(NoArgsCommand):
help = "Copy the satchmo static directory and files to the local project."
def handle_noargs(self, **options):
import satchmo_store
static_src = os.path.join(satchmo_store... | from django.core.management.base import NoArgsCommand
import os
import shutil
class Command(NoArgsCommand):
help = "Copy the satchmo static directory and files to the local project."
def handle_noargs(self, **options):
import satchmo_store
static_src = os.path.join(satchmo_store.__path__[0],'.... | from django.core.management.base import NoArgsCommand
import os
import shutil
class Command(NoArgsCommand):
help = "Copy the satchmo static directory and files to the local project."
def handle_noargs(self, **options):
import satchmo_store
static_src = os.path.join(satchmo_store.__path__[0],'s... | <commit_before>from django.core.management.base import NoArgsCommand
import os
import shutil
class Command(NoArgsCommand):
help = "Copy the satchmo static directory and files to the local project."
def handle_noargs(self, **options):
import satchmo_store
static_src = os.path.join(satchmo_store... |
3c58a84a7eda661d48be72abda9001649ebe3ab0 | app_server/clparser.py | app_server/clparser.py | """This module contains all the logic required to parse the app
server's command line."""
#-------------------------------------------------------------------------------
import re
import logging
import optparse
import clparserutil
#-------------------------------------------------------------------------------
cl... | """This module contains all the logic required to parse the app
server's command line."""
#-------------------------------------------------------------------------------
import re
import logging
import optparse
import clparserutil
#-------------------------------------------------------------------------------
cl... | Improve help docs for app server's command line parser. Dave. | Improve help docs for app server's command line parser. Dave.
| Python | mit | simonsdave/yar,simonsdave/yar,simonsdave/yar,simonsdave/yar | """This module contains all the logic required to parse the app
server's command line."""
#-------------------------------------------------------------------------------
import re
import logging
import optparse
import clparserutil
#-------------------------------------------------------------------------------
cl... | """This module contains all the logic required to parse the app
server's command line."""
#-------------------------------------------------------------------------------
import re
import logging
import optparse
import clparserutil
#-------------------------------------------------------------------------------
cl... | <commit_before>"""This module contains all the logic required to parse the app
server's command line."""
#-------------------------------------------------------------------------------
import re
import logging
import optparse
import clparserutil
#--------------------------------------------------------------------... | """This module contains all the logic required to parse the app
server's command line."""
#-------------------------------------------------------------------------------
import re
import logging
import optparse
import clparserutil
#-------------------------------------------------------------------------------
cl... | """This module contains all the logic required to parse the app
server's command line."""
#-------------------------------------------------------------------------------
import re
import logging
import optparse
import clparserutil
#-------------------------------------------------------------------------------
cl... | <commit_before>"""This module contains all the logic required to parse the app
server's command line."""
#-------------------------------------------------------------------------------
import re
import logging
import optparse
import clparserutil
#--------------------------------------------------------------------... |
e9c4881ee29ba104caf9fc8330583c254fe52c06 | scripts/examples/Arduino/Portenta-H7/19-Low-Power/deep_sleep.py | scripts/examples/Arduino/Portenta-H7/19-Low-Power/deep_sleep.py | # Deep Sleep Mode Example
# This example demonstrates the low-power deep sleep mode plus sensor shutdown.
# Note the camera will reset after wake-up from deep sleep. To find out if the cause of reset
# is deep sleep, call the machine.reset_cause() function and test for machine.DEEPSLEEP_RESET
import pyb, machine, senso... | # Deep Sleep Mode Example
# This example demonstrates the low-power deep sleep mode plus sensor shutdown.
# Note the camera will reset after wake-up from deep sleep. To find out if the cause of reset
# is deep sleep, call the machine.reset_cause() function and test for machine.DEEPSLEEP_RESET
import pyb, machine, senso... | Remove sensor setting from deep sleep example | Remove sensor setting from deep sleep example
| Python | mit | iabdalkader/openmv,openmv/openmv,kwagyeman/openmv,iabdalkader/openmv,openmv/openmv,kwagyeman/openmv,openmv/openmv,iabdalkader/openmv,kwagyeman/openmv,iabdalkader/openmv,kwagyeman/openmv,openmv/openmv | # Deep Sleep Mode Example
# This example demonstrates the low-power deep sleep mode plus sensor shutdown.
# Note the camera will reset after wake-up from deep sleep. To find out if the cause of reset
# is deep sleep, call the machine.reset_cause() function and test for machine.DEEPSLEEP_RESET
import pyb, machine, senso... | # Deep Sleep Mode Example
# This example demonstrates the low-power deep sleep mode plus sensor shutdown.
# Note the camera will reset after wake-up from deep sleep. To find out if the cause of reset
# is deep sleep, call the machine.reset_cause() function and test for machine.DEEPSLEEP_RESET
import pyb, machine, senso... | <commit_before># Deep Sleep Mode Example
# This example demonstrates the low-power deep sleep mode plus sensor shutdown.
# Note the camera will reset after wake-up from deep sleep. To find out if the cause of reset
# is deep sleep, call the machine.reset_cause() function and test for machine.DEEPSLEEP_RESET
import pyb,... | # Deep Sleep Mode Example
# This example demonstrates the low-power deep sleep mode plus sensor shutdown.
# Note the camera will reset after wake-up from deep sleep. To find out if the cause of reset
# is deep sleep, call the machine.reset_cause() function and test for machine.DEEPSLEEP_RESET
import pyb, machine, senso... | # Deep Sleep Mode Example
# This example demonstrates the low-power deep sleep mode plus sensor shutdown.
# Note the camera will reset after wake-up from deep sleep. To find out if the cause of reset
# is deep sleep, call the machine.reset_cause() function and test for machine.DEEPSLEEP_RESET
import pyb, machine, senso... | <commit_before># Deep Sleep Mode Example
# This example demonstrates the low-power deep sleep mode plus sensor shutdown.
# Note the camera will reset after wake-up from deep sleep. To find out if the cause of reset
# is deep sleep, call the machine.reset_cause() function and test for machine.DEEPSLEEP_RESET
import pyb,... |
ae8273f86fc3cc7fdacadf495aa148dda796f11b | printcli.py | printcli.py | #!/usr/bin/env python2
import argparse
import os
from labelprinter import Labelprinter
if os.path.isfile('labelprinterServeConf_local.py'):
import labelprinterServeConf_local as conf
else:
import labelprinterServeConf as conf
def text(args, labelprinter):
bold = 'on' if args.bold else 'off'
labelpri... | #!/usr/bin/env python2
import argparse
import os
from labelprinter import Labelprinter
import labelprinterServeConf as conf
def text(args, labelprinter):
bold = 'on' if args.bold else 'off'
labelprinter.printText(args.text,
charSize=args.char_size,
font=args.font,
... | Make the CLI use the new config (see e4054fb). | Make the CLI use the new config (see e4054fb).
| Python | mit | chaosdorf/labello,chaosdorf/labello,chaosdorf/labello | #!/usr/bin/env python2
import argparse
import os
from labelprinter import Labelprinter
if os.path.isfile('labelprinterServeConf_local.py'):
import labelprinterServeConf_local as conf
else:
import labelprinterServeConf as conf
def text(args, labelprinter):
bold = 'on' if args.bold else 'off'
labelpri... | #!/usr/bin/env python2
import argparse
import os
from labelprinter import Labelprinter
import labelprinterServeConf as conf
def text(args, labelprinter):
bold = 'on' if args.bold else 'off'
labelprinter.printText(args.text,
charSize=args.char_size,
font=args.font,
... | <commit_before>#!/usr/bin/env python2
import argparse
import os
from labelprinter import Labelprinter
if os.path.isfile('labelprinterServeConf_local.py'):
import labelprinterServeConf_local as conf
else:
import labelprinterServeConf as conf
def text(args, labelprinter):
bold = 'on' if args.bold else 'of... | #!/usr/bin/env python2
import argparse
import os
from labelprinter import Labelprinter
import labelprinterServeConf as conf
def text(args, labelprinter):
bold = 'on' if args.bold else 'off'
labelprinter.printText(args.text,
charSize=args.char_size,
font=args.font,
... | #!/usr/bin/env python2
import argparse
import os
from labelprinter import Labelprinter
if os.path.isfile('labelprinterServeConf_local.py'):
import labelprinterServeConf_local as conf
else:
import labelprinterServeConf as conf
def text(args, labelprinter):
bold = 'on' if args.bold else 'off'
labelpri... | <commit_before>#!/usr/bin/env python2
import argparse
import os
from labelprinter import Labelprinter
if os.path.isfile('labelprinterServeConf_local.py'):
import labelprinterServeConf_local as conf
else:
import labelprinterServeConf as conf
def text(args, labelprinter):
bold = 'on' if args.bold else 'of... |
68e6321113c249508dad89688e58860ef5728d64 | microscopes/lda/runner.py | microscopes/lda/runner.py | """Implements the Runner interface fo LDA
"""
from microscopes.common import validator
from microscopes.common.rng import rng
from microscopes.lda.kernels import lda_crp_gibbs
from microscopes.lda.kernels import lda_sample_dispersion
class runner(object):
"""The LDA runner
Parameters
----------
defn... | """Implements the Runner interface fo LDA
"""
from microscopes.common import validator
from microscopes.common.rng import rng
from microscopes.lda.kernels import lda_crp_gibbs
from microscopes.lda.kernels import sample_gamma, sample_alpha
class runner(object):
"""The LDA runner
Parameters
----------
... | Use C++ implementations of hp sampling | Use C++ implementations of hp sampling
| Python | bsd-3-clause | datamicroscopes/lda,datamicroscopes/lda,datamicroscopes/lda | """Implements the Runner interface fo LDA
"""
from microscopes.common import validator
from microscopes.common.rng import rng
from microscopes.lda.kernels import lda_crp_gibbs
from microscopes.lda.kernels import lda_sample_dispersion
class runner(object):
"""The LDA runner
Parameters
----------
defn... | """Implements the Runner interface fo LDA
"""
from microscopes.common import validator
from microscopes.common.rng import rng
from microscopes.lda.kernels import lda_crp_gibbs
from microscopes.lda.kernels import sample_gamma, sample_alpha
class runner(object):
"""The LDA runner
Parameters
----------
... | <commit_before>"""Implements the Runner interface fo LDA
"""
from microscopes.common import validator
from microscopes.common.rng import rng
from microscopes.lda.kernels import lda_crp_gibbs
from microscopes.lda.kernels import lda_sample_dispersion
class runner(object):
"""The LDA runner
Parameters
----... | """Implements the Runner interface fo LDA
"""
from microscopes.common import validator
from microscopes.common.rng import rng
from microscopes.lda.kernels import lda_crp_gibbs
from microscopes.lda.kernels import sample_gamma, sample_alpha
class runner(object):
"""The LDA runner
Parameters
----------
... | """Implements the Runner interface fo LDA
"""
from microscopes.common import validator
from microscopes.common.rng import rng
from microscopes.lda.kernels import lda_crp_gibbs
from microscopes.lda.kernels import lda_sample_dispersion
class runner(object):
"""The LDA runner
Parameters
----------
defn... | <commit_before>"""Implements the Runner interface fo LDA
"""
from microscopes.common import validator
from microscopes.common.rng import rng
from microscopes.lda.kernels import lda_crp_gibbs
from microscopes.lda.kernels import lda_sample_dispersion
class runner(object):
"""The LDA runner
Parameters
----... |
a32e61e9cdf2eababb568659766688a731b121cb | warlock/__init__.py | warlock/__init__.py | # Copyright 2012 Brian Waldon
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,... | # Copyright 2012 Brian Waldon
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,... | Apply 'no blanket NOQA statements' fixes enforced by pre-commit hook | Apply 'no blanket NOQA statements' fixes enforced by pre-commit hook
| Python | apache-2.0 | bcwaldon/warlock | # Copyright 2012 Brian Waldon
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,... | # Copyright 2012 Brian Waldon
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,... | <commit_before># Copyright 2012 Brian Waldon
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed... | # Copyright 2012 Brian Waldon
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,... | # Copyright 2012 Brian Waldon
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,... | <commit_before># Copyright 2012 Brian Waldon
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed... |
3dae7f461d34efceb2e8b0194306d85236fea1fc | src/main/python/piglatin.py | src/main/python/piglatin.py | import sys
def parseCommandLine(argv):
print 'Inside parser'
return argv[1] if len(argv) > 1 else ""
if __name__ == "__main__":
latin = parseCommandLine(sys.argv)
print(latin)
print("igpay atinlay")
| import sys
def parseCommandLine(argv):
return argv[1] if len(argv) > 1 else ""
if __name__ == "__main__":
latin = parseCommandLine(sys.argv)
print(latin)
print("igpay atinlay")
| Test case failing for python3 removed | Test case failing for python3 removed
| Python | mit | oneyoke/sw_asgmt_2 | import sys
def parseCommandLine(argv):
print 'Inside parser'
return argv[1] if len(argv) > 1 else ""
if __name__ == "__main__":
latin = parseCommandLine(sys.argv)
print(latin)
print("igpay atinlay")
Test case failing for python3 removed | import sys
def parseCommandLine(argv):
return argv[1] if len(argv) > 1 else ""
if __name__ == "__main__":
latin = parseCommandLine(sys.argv)
print(latin)
print("igpay atinlay")
| <commit_before>import sys
def parseCommandLine(argv):
print 'Inside parser'
return argv[1] if len(argv) > 1 else ""
if __name__ == "__main__":
latin = parseCommandLine(sys.argv)
print(latin)
print("igpay atinlay")
<commit_msg>Test case failing for python3 removed<commit_after> | import sys
def parseCommandLine(argv):
return argv[1] if len(argv) > 1 else ""
if __name__ == "__main__":
latin = parseCommandLine(sys.argv)
print(latin)
print("igpay atinlay")
| import sys
def parseCommandLine(argv):
print 'Inside parser'
return argv[1] if len(argv) > 1 else ""
if __name__ == "__main__":
latin = parseCommandLine(sys.argv)
print(latin)
print("igpay atinlay")
Test case failing for python3 removedimport sys
def parseCommandLine(argv):
return argv[1] if... | <commit_before>import sys
def parseCommandLine(argv):
print 'Inside parser'
return argv[1] if len(argv) > 1 else ""
if __name__ == "__main__":
latin = parseCommandLine(sys.argv)
print(latin)
print("igpay atinlay")
<commit_msg>Test case failing for python3 removed<commit_after>import sys
def pars... |
cdbe3f5ed5e65a14c1f40cc5daa84a9103e4322d | tests/test_boto_store.py | tests/test_boto_store.py | #!/usr/bin/env python
import os
from tempdir import TempDir
import pytest
boto = pytest.importorskip('boto')
from simplekv.net.botostore import BotoStore
from basic_store import BasicStore
from url_store import UrlStore
from bucket_manager import boto_credentials, boto_bucket
@pytest.fixture(params=boto_credentia... | #!/usr/bin/env python
import os
from tempdir import TempDir
import pytest
boto = pytest.importorskip('boto')
from simplekv.net.botostore import BotoStore
from basic_store import BasicStore
from url_store import UrlStore
from bucket_manager import boto_credentials, boto_bucket
@pytest.fixture(params=boto_credentia... | Use key fixture in boto tests. | Use key fixture in boto tests.
| Python | mit | fmarczin/simplekv,fmarczin/simplekv,karteek/simplekv,mbr/simplekv,karteek/simplekv,mbr/simplekv | #!/usr/bin/env python
import os
from tempdir import TempDir
import pytest
boto = pytest.importorskip('boto')
from simplekv.net.botostore import BotoStore
from basic_store import BasicStore
from url_store import UrlStore
from bucket_manager import boto_credentials, boto_bucket
@pytest.fixture(params=boto_credentia... | #!/usr/bin/env python
import os
from tempdir import TempDir
import pytest
boto = pytest.importorskip('boto')
from simplekv.net.botostore import BotoStore
from basic_store import BasicStore
from url_store import UrlStore
from bucket_manager import boto_credentials, boto_bucket
@pytest.fixture(params=boto_credentia... | <commit_before>#!/usr/bin/env python
import os
from tempdir import TempDir
import pytest
boto = pytest.importorskip('boto')
from simplekv.net.botostore import BotoStore
from basic_store import BasicStore
from url_store import UrlStore
from bucket_manager import boto_credentials, boto_bucket
@pytest.fixture(params... | #!/usr/bin/env python
import os
from tempdir import TempDir
import pytest
boto = pytest.importorskip('boto')
from simplekv.net.botostore import BotoStore
from basic_store import BasicStore
from url_store import UrlStore
from bucket_manager import boto_credentials, boto_bucket
@pytest.fixture(params=boto_credentia... | #!/usr/bin/env python
import os
from tempdir import TempDir
import pytest
boto = pytest.importorskip('boto')
from simplekv.net.botostore import BotoStore
from basic_store import BasicStore
from url_store import UrlStore
from bucket_manager import boto_credentials, boto_bucket
@pytest.fixture(params=boto_credentia... | <commit_before>#!/usr/bin/env python
import os
from tempdir import TempDir
import pytest
boto = pytest.importorskip('boto')
from simplekv.net.botostore import BotoStore
from basic_store import BasicStore
from url_store import UrlStore
from bucket_manager import boto_credentials, boto_bucket
@pytest.fixture(params... |
d65f39d85e98be8651863bcf617fb218e266d0bb | mpfmc/uix/relative_animation.py | mpfmc/uix/relative_animation.py | from kivy.animation import Animation
class RelativeAnimation(Animation):
"""Class that extends the Kivy Animation base class to add relative animation
property target values that are calculated when the animation starts."""
def _initialize(self, widget):
"""Initializes the animation and calculat... | from kivy.animation import Animation
class RelativeAnimation(Animation):
"""Class that extends the Kivy Animation base class to add relative animation
property target values that are calculated when the animation starts."""
def _initialize(self, widget):
"""Initializes the animation and calculat... | Fix relative animation of list values | Fix relative animation of list values
| Python | mit | missionpinball/mpf-mc,missionpinball/mpf-mc,missionpinball/mpf-mc | from kivy.animation import Animation
class RelativeAnimation(Animation):
"""Class that extends the Kivy Animation base class to add relative animation
property target values that are calculated when the animation starts."""
def _initialize(self, widget):
"""Initializes the animation and calculat... | from kivy.animation import Animation
class RelativeAnimation(Animation):
"""Class that extends the Kivy Animation base class to add relative animation
property target values that are calculated when the animation starts."""
def _initialize(self, widget):
"""Initializes the animation and calculat... | <commit_before>from kivy.animation import Animation
class RelativeAnimation(Animation):
"""Class that extends the Kivy Animation base class to add relative animation
property target values that are calculated when the animation starts."""
def _initialize(self, widget):
"""Initializes the animati... | from kivy.animation import Animation
class RelativeAnimation(Animation):
"""Class that extends the Kivy Animation base class to add relative animation
property target values that are calculated when the animation starts."""
def _initialize(self, widget):
"""Initializes the animation and calculat... | from kivy.animation import Animation
class RelativeAnimation(Animation):
"""Class that extends the Kivy Animation base class to add relative animation
property target values that are calculated when the animation starts."""
def _initialize(self, widget):
"""Initializes the animation and calculat... | <commit_before>from kivy.animation import Animation
class RelativeAnimation(Animation):
"""Class that extends the Kivy Animation base class to add relative animation
property target values that are calculated when the animation starts."""
def _initialize(self, widget):
"""Initializes the animati... |
12585ce38fc3ec7a0ddcf448cc398f694c7e29fb | dakis/api/views.py | dakis/api/views.py | from rest_framework import serializers, viewsets
from rest_framework import filters
from django.contrib.auth.models import User
from dakis.core.models import Experiment, Task
class ExperimentSerializer(serializers.HyperlinkedModelSerializer):
id = serializers.IntegerField(label='ID', read_only=True)
class ... | from rest_framework import serializers, viewsets
from rest_framework import filters
from django.contrib.auth.models import User
from dakis.core.models import Experiment, Task
class ExperimentSerializer(serializers.HyperlinkedModelSerializer):
id = serializers.IntegerField(label='ID', read_only=True)
class ... | Exclude details field from editable through API | Exclude details field from editable through API
| Python | agpl-3.0 | niekas/dakis,niekas/dakis,niekas/dakis | from rest_framework import serializers, viewsets
from rest_framework import filters
from django.contrib.auth.models import User
from dakis.core.models import Experiment, Task
class ExperimentSerializer(serializers.HyperlinkedModelSerializer):
id = serializers.IntegerField(label='ID', read_only=True)
class ... | from rest_framework import serializers, viewsets
from rest_framework import filters
from django.contrib.auth.models import User
from dakis.core.models import Experiment, Task
class ExperimentSerializer(serializers.HyperlinkedModelSerializer):
id = serializers.IntegerField(label='ID', read_only=True)
class ... | <commit_before>from rest_framework import serializers, viewsets
from rest_framework import filters
from django.contrib.auth.models import User
from dakis.core.models import Experiment, Task
class ExperimentSerializer(serializers.HyperlinkedModelSerializer):
id = serializers.IntegerField(label='ID', read_only=Tr... | from rest_framework import serializers, viewsets
from rest_framework import filters
from django.contrib.auth.models import User
from dakis.core.models import Experiment, Task
class ExperimentSerializer(serializers.HyperlinkedModelSerializer):
id = serializers.IntegerField(label='ID', read_only=True)
class ... | from rest_framework import serializers, viewsets
from rest_framework import filters
from django.contrib.auth.models import User
from dakis.core.models import Experiment, Task
class ExperimentSerializer(serializers.HyperlinkedModelSerializer):
id = serializers.IntegerField(label='ID', read_only=True)
class ... | <commit_before>from rest_framework import serializers, viewsets
from rest_framework import filters
from django.contrib.auth.models import User
from dakis.core.models import Experiment, Task
class ExperimentSerializer(serializers.HyperlinkedModelSerializer):
id = serializers.IntegerField(label='ID', read_only=Tr... |
cfb50f4ff62770c397634897e09497b74b396067 | notifications/level_starting.py | notifications/level_starting.py | from consts.notification_type import NotificationType
from notifications.base_notification import BaseNotification
class CompLevelStartingNotification(BaseNotification):
def __init__(self, match, event):
self.match = match
self.event = event
def _build_dict(self):
data = {}
d... | from consts.notification_type import NotificationType
from notifications.base_notification import BaseNotification
class CompLevelStartingNotification(BaseNotification):
def __init__(self, match, event):
self.match = match
self.event = event
def _build_dict(self):
data = {}
d... | Add event key to comp level starting notification | Add event key to comp level starting notification
| Python | mit | josephbisch/the-blue-alliance,synth3tk/the-blue-alliance,phil-lopreiato/the-blue-alliance,phil-lopreiato/the-blue-alliance,fangeugene/the-blue-alliance,bvisness/the-blue-alliance,nwalters512/the-blue-alliance,nwalters512/the-blue-alliance,josephbisch/the-blue-alliance,the-blue-alliance/the-blue-alliance,verycumbersome/... | from consts.notification_type import NotificationType
from notifications.base_notification import BaseNotification
class CompLevelStartingNotification(BaseNotification):
def __init__(self, match, event):
self.match = match
self.event = event
def _build_dict(self):
data = {}
d... | from consts.notification_type import NotificationType
from notifications.base_notification import BaseNotification
class CompLevelStartingNotification(BaseNotification):
def __init__(self, match, event):
self.match = match
self.event = event
def _build_dict(self):
data = {}
d... | <commit_before>from consts.notification_type import NotificationType
from notifications.base_notification import BaseNotification
class CompLevelStartingNotification(BaseNotification):
def __init__(self, match, event):
self.match = match
self.event = event
def _build_dict(self):
data... | from consts.notification_type import NotificationType
from notifications.base_notification import BaseNotification
class CompLevelStartingNotification(BaseNotification):
def __init__(self, match, event):
self.match = match
self.event = event
def _build_dict(self):
data = {}
d... | from consts.notification_type import NotificationType
from notifications.base_notification import BaseNotification
class CompLevelStartingNotification(BaseNotification):
def __init__(self, match, event):
self.match = match
self.event = event
def _build_dict(self):
data = {}
d... | <commit_before>from consts.notification_type import NotificationType
from notifications.base_notification import BaseNotification
class CompLevelStartingNotification(BaseNotification):
def __init__(self, match, event):
self.match = match
self.event = event
def _build_dict(self):
data... |
0177066012b3373753cba8baf86f00a365d7147b | findaconf/tests/config.py | findaconf/tests/config.py | # coding: utf-8
from decouple import config
from findaconf.tests.fake_data import fake_conference, seed
def set_app(app, db=False):
unset_app(db)
app.config['TESTING'] = True
app.config['WTF_CSRF_ENABLED'] = False
if db:
app.config['SQLALCHEMY_DATABASE_URI'] = config(
'DATABASE_UR... | # coding: utf-8
from decouple import config
from findaconf.tests.fake_data import fake_conference, seed
def set_app(app, db=False):
# set test vars
app.config['TESTING'] = True
app.config['WTF_CSRF_ENABLED'] = False
# set test db
if db:
app.config['SQLALCHEMY_DATABASE_URI'] = co... | Fix bug that used dev db instead of test db | Fix bug that used dev db instead of test db
| Python | mit | cuducos/findaconf,koorukuroo/findaconf,cuducos/findaconf,koorukuroo/findaconf,koorukuroo/findaconf,cuducos/findaconf | # coding: utf-8
from decouple import config
from findaconf.tests.fake_data import fake_conference, seed
def set_app(app, db=False):
unset_app(db)
app.config['TESTING'] = True
app.config['WTF_CSRF_ENABLED'] = False
if db:
app.config['SQLALCHEMY_DATABASE_URI'] = config(
'DATABASE_UR... | # coding: utf-8
from decouple import config
from findaconf.tests.fake_data import fake_conference, seed
def set_app(app, db=False):
# set test vars
app.config['TESTING'] = True
app.config['WTF_CSRF_ENABLED'] = False
# set test db
if db:
app.config['SQLALCHEMY_DATABASE_URI'] = co... | <commit_before># coding: utf-8
from decouple import config
from findaconf.tests.fake_data import fake_conference, seed
def set_app(app, db=False):
unset_app(db)
app.config['TESTING'] = True
app.config['WTF_CSRF_ENABLED'] = False
if db:
app.config['SQLALCHEMY_DATABASE_URI'] = config(
... | # coding: utf-8
from decouple import config
from findaconf.tests.fake_data import fake_conference, seed
def set_app(app, db=False):
# set test vars
app.config['TESTING'] = True
app.config['WTF_CSRF_ENABLED'] = False
# set test db
if db:
app.config['SQLALCHEMY_DATABASE_URI'] = co... | # coding: utf-8
from decouple import config
from findaconf.tests.fake_data import fake_conference, seed
def set_app(app, db=False):
unset_app(db)
app.config['TESTING'] = True
app.config['WTF_CSRF_ENABLED'] = False
if db:
app.config['SQLALCHEMY_DATABASE_URI'] = config(
'DATABASE_UR... | <commit_before># coding: utf-8
from decouple import config
from findaconf.tests.fake_data import fake_conference, seed
def set_app(app, db=False):
unset_app(db)
app.config['TESTING'] = True
app.config['WTF_CSRF_ENABLED'] = False
if db:
app.config['SQLALCHEMY_DATABASE_URI'] = config(
... |
592df76f77c3450ba56b249ab0cd4404c8dd99e2 | bundle_graph.py | bundle_graph.py | #!/usr/bin/python3
from random import randint
class Student:
def __init__(self, id):
self.id = id
self.papers = []
def assign_paper(self, paper):
self.papers.append(paper)
def __str__(self):
return str(self.id) + ": " + str(self.papers)
class Paper:
def __init__(self, ... | #!/usr/bin/python3
from random import randint
class Student:
def __init__(self, id):
self.id = id
self.papers = []
def assign_paper(self, paper):
self.papers.append(paper)
def __str__(self):
return str(self.id) + ": " + str(self.papers)
class Paper:
def __init__(self, ... | Update validation check for paper bundles. | Update validation check for paper bundles.
| Python | mit | haoyueping/peer-grading-for-MOOCs | #!/usr/bin/python3
from random import randint
class Student:
def __init__(self, id):
self.id = id
self.papers = []
def assign_paper(self, paper):
self.papers.append(paper)
def __str__(self):
return str(self.id) + ": " + str(self.papers)
class Paper:
def __init__(self, ... | #!/usr/bin/python3
from random import randint
class Student:
def __init__(self, id):
self.id = id
self.papers = []
def assign_paper(self, paper):
self.papers.append(paper)
def __str__(self):
return str(self.id) + ": " + str(self.papers)
class Paper:
def __init__(self, ... | <commit_before>#!/usr/bin/python3
from random import randint
class Student:
def __init__(self, id):
self.id = id
self.papers = []
def assign_paper(self, paper):
self.papers.append(paper)
def __str__(self):
return str(self.id) + ": " + str(self.papers)
class Paper:
def ... | #!/usr/bin/python3
from random import randint
class Student:
def __init__(self, id):
self.id = id
self.papers = []
def assign_paper(self, paper):
self.papers.append(paper)
def __str__(self):
return str(self.id) + ": " + str(self.papers)
class Paper:
def __init__(self, ... | #!/usr/bin/python3
from random import randint
class Student:
def __init__(self, id):
self.id = id
self.papers = []
def assign_paper(self, paper):
self.papers.append(paper)
def __str__(self):
return str(self.id) + ": " + str(self.papers)
class Paper:
def __init__(self, ... | <commit_before>#!/usr/bin/python3
from random import randint
class Student:
def __init__(self, id):
self.id = id
self.papers = []
def assign_paper(self, paper):
self.papers.append(paper)
def __str__(self):
return str(self.id) + ": " + str(self.papers)
class Paper:
def ... |
86cfa4e3b60962fa04185efb6500fa6a6c0f4880 | infosystem/subsystem/route/resource.py | infosystem/subsystem/route/resource.py | from sqlalchemy import UniqueConstraint
from infosystem.common.subsystem import entity
from infosystem.database import db
class Route(entity.Entity, db.Model):
# TODO(samueldmq): recheck string lengths for below attributes
# TODO(samueldmq): add an 'active' attribute
attributes = ['id', 'name', 'url', 'm... | from sqlalchemy import UniqueConstraint
from infosystem.common.subsystem import entity
from infosystem.database import db
class Route(entity.Entity, db.Model):
# TODO(samueldmq): recheck string lengths for below attributes
# TODO(samueldmq): add an 'active' attribute
attributes = ['id', 'name', 'url', 'm... | Change admin attribute to sysadmin | Change admin attribute to sysadmin
| Python | apache-2.0 | samueldmq/infosystem | from sqlalchemy import UniqueConstraint
from infosystem.common.subsystem import entity
from infosystem.database import db
class Route(entity.Entity, db.Model):
# TODO(samueldmq): recheck string lengths for below attributes
# TODO(samueldmq): add an 'active' attribute
attributes = ['id', 'name', 'url', 'm... | from sqlalchemy import UniqueConstraint
from infosystem.common.subsystem import entity
from infosystem.database import db
class Route(entity.Entity, db.Model):
# TODO(samueldmq): recheck string lengths for below attributes
# TODO(samueldmq): add an 'active' attribute
attributes = ['id', 'name', 'url', 'm... | <commit_before>from sqlalchemy import UniqueConstraint
from infosystem.common.subsystem import entity
from infosystem.database import db
class Route(entity.Entity, db.Model):
# TODO(samueldmq): recheck string lengths for below attributes
# TODO(samueldmq): add an 'active' attribute
attributes = ['id', 'n... | from sqlalchemy import UniqueConstraint
from infosystem.common.subsystem import entity
from infosystem.database import db
class Route(entity.Entity, db.Model):
# TODO(samueldmq): recheck string lengths for below attributes
# TODO(samueldmq): add an 'active' attribute
attributes = ['id', 'name', 'url', 'm... | from sqlalchemy import UniqueConstraint
from infosystem.common.subsystem import entity
from infosystem.database import db
class Route(entity.Entity, db.Model):
# TODO(samueldmq): recheck string lengths for below attributes
# TODO(samueldmq): add an 'active' attribute
attributes = ['id', 'name', 'url', 'm... | <commit_before>from sqlalchemy import UniqueConstraint
from infosystem.common.subsystem import entity
from infosystem.database import db
class Route(entity.Entity, db.Model):
# TODO(samueldmq): recheck string lengths for below attributes
# TODO(samueldmq): add an 'active' attribute
attributes = ['id', 'n... |
4ec8f09736113630208325cb08f1ffe07e8acc26 | go_cli/tests/test_main.py | go_cli/tests/test_main.py | """ Tests fir go_cli.main. """
from unittest import TestCase
from click.testing import CliRunner
from go_cli.main import cli
class TestCli(TestCase):
def test_help(self):
runner = CliRunner()
result = runner.invoke(cli, ['--help'])
self.assertEqual(result.exit_code, 0)
self.asse... | """ Tests for go_cli.main. """
from unittest import TestCase
from click.testing import CliRunner
from go_cli.main import cli
class TestCli(TestCase):
def test_help(self):
runner = CliRunner()
result = runner.invoke(cli, ['--help'])
self.assertEqual(result.exit_code, 0)
self.asse... | Fix typo in module docstring. | Fix typo in module docstring.
| Python | bsd-3-clause | praekelt/go-cli,praekelt/go-cli | """ Tests fir go_cli.main. """
from unittest import TestCase
from click.testing import CliRunner
from go_cli.main import cli
class TestCli(TestCase):
def test_help(self):
runner = CliRunner()
result = runner.invoke(cli, ['--help'])
self.assertEqual(result.exit_code, 0)
self.asse... | """ Tests for go_cli.main. """
from unittest import TestCase
from click.testing import CliRunner
from go_cli.main import cli
class TestCli(TestCase):
def test_help(self):
runner = CliRunner()
result = runner.invoke(cli, ['--help'])
self.assertEqual(result.exit_code, 0)
self.asse... | <commit_before>""" Tests fir go_cli.main. """
from unittest import TestCase
from click.testing import CliRunner
from go_cli.main import cli
class TestCli(TestCase):
def test_help(self):
runner = CliRunner()
result = runner.invoke(cli, ['--help'])
self.assertEqual(result.exit_code, 0)
... | """ Tests for go_cli.main. """
from unittest import TestCase
from click.testing import CliRunner
from go_cli.main import cli
class TestCli(TestCase):
def test_help(self):
runner = CliRunner()
result = runner.invoke(cli, ['--help'])
self.assertEqual(result.exit_code, 0)
self.asse... | """ Tests fir go_cli.main. """
from unittest import TestCase
from click.testing import CliRunner
from go_cli.main import cli
class TestCli(TestCase):
def test_help(self):
runner = CliRunner()
result = runner.invoke(cli, ['--help'])
self.assertEqual(result.exit_code, 0)
self.asse... | <commit_before>""" Tests fir go_cli.main. """
from unittest import TestCase
from click.testing import CliRunner
from go_cli.main import cli
class TestCli(TestCase):
def test_help(self):
runner = CliRunner()
result = runner.invoke(cli, ['--help'])
self.assertEqual(result.exit_code, 0)
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.