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
|
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
bce9b8aa663a6a87f6a0d03902fbc21a8452ab0d
|
setup.py
|
setup.py
|
#-*- coding: utf-8 -*-
from setuptools import setup, find_packages
import YaDiskClient
setup(
name='YaDiskClient',
version=YaDiskClient.__version__,
include_package_data=True,
py_modules=['YaDiskClient'],
url='https://github.com/TyVik/YaDiskClient',
license='MIT',
author='TyVik',
author_email='tyvik8@gmail.com',
description='Clent for Yandex.Disk',
long_description=open('README.rst').read(),
install_requires=['requests'],
packages=find_packages(),
keywords='Yandex.Disk, webdav, client, python, Yandex',
# test_suite='YaDiskClient.test_YaDiskClient' # this line is commented because tests needs Yandex login and password
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Utilities',
'Topic :: System :: Archiving :: Backup',
],
)
|
#-*- coding: utf-8 -*-
from setuptools import setup, find_packages
import YaDiskClient
setup(
name='YaDiskClient',
version=YaDiskClient.__version__,
include_package_data=True,
py_modules=['YaDiskClient'],
url='https://github.com/TyVik/YaDiskClient',
license='MIT',
author='TyVik',
author_email='tyvik8@gmail.com',
description='Clent for Yandex.Disk',
long_description=open('README.rst').read(),
install_requires=['requests'],
packages=find_packages(),
keywords='Yandex.Disk, webdav, client, python, Yandex',
# test_suite='YaDiskClient.test_YaDiskClient' # this line is commented because tests needs Yandex login and password
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Utilities',
'Topic :: System :: Archiving :: Backup',
],
)
|
Support python 3.7, 3.8, 3.9, 3.10
|
Support python 3.7, 3.8, 3.9, 3.10
|
Python
|
mit
|
TyVik/YaDiskClient
|
#-*- coding: utf-8 -*-
from setuptools import setup, find_packages
import YaDiskClient
setup(
name='YaDiskClient',
version=YaDiskClient.__version__,
include_package_data=True,
py_modules=['YaDiskClient'],
url='https://github.com/TyVik/YaDiskClient',
license='MIT',
author='TyVik',
author_email='tyvik8@gmail.com',
description='Clent for Yandex.Disk',
long_description=open('README.rst').read(),
install_requires=['requests'],
packages=find_packages(),
keywords='Yandex.Disk, webdav, client, python, Yandex',
# test_suite='YaDiskClient.test_YaDiskClient' # this line is commented because tests needs Yandex login and password
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Utilities',
'Topic :: System :: Archiving :: Backup',
],
)
Support python 3.7, 3.8, 3.9, 3.10
|
#-*- coding: utf-8 -*-
from setuptools import setup, find_packages
import YaDiskClient
setup(
name='YaDiskClient',
version=YaDiskClient.__version__,
include_package_data=True,
py_modules=['YaDiskClient'],
url='https://github.com/TyVik/YaDiskClient',
license='MIT',
author='TyVik',
author_email='tyvik8@gmail.com',
description='Clent for Yandex.Disk',
long_description=open('README.rst').read(),
install_requires=['requests'],
packages=find_packages(),
keywords='Yandex.Disk, webdav, client, python, Yandex',
# test_suite='YaDiskClient.test_YaDiskClient' # this line is commented because tests needs Yandex login and password
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Utilities',
'Topic :: System :: Archiving :: Backup',
],
)
|
<commit_before>#-*- coding: utf-8 -*-
from setuptools import setup, find_packages
import YaDiskClient
setup(
name='YaDiskClient',
version=YaDiskClient.__version__,
include_package_data=True,
py_modules=['YaDiskClient'],
url='https://github.com/TyVik/YaDiskClient',
license='MIT',
author='TyVik',
author_email='tyvik8@gmail.com',
description='Clent for Yandex.Disk',
long_description=open('README.rst').read(),
install_requires=['requests'],
packages=find_packages(),
keywords='Yandex.Disk, webdav, client, python, Yandex',
# test_suite='YaDiskClient.test_YaDiskClient' # this line is commented because tests needs Yandex login and password
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Utilities',
'Topic :: System :: Archiving :: Backup',
],
)
<commit_msg>Support python 3.7, 3.8, 3.9, 3.10<commit_after>
|
#-*- coding: utf-8 -*-
from setuptools import setup, find_packages
import YaDiskClient
setup(
name='YaDiskClient',
version=YaDiskClient.__version__,
include_package_data=True,
py_modules=['YaDiskClient'],
url='https://github.com/TyVik/YaDiskClient',
license='MIT',
author='TyVik',
author_email='tyvik8@gmail.com',
description='Clent for Yandex.Disk',
long_description=open('README.rst').read(),
install_requires=['requests'],
packages=find_packages(),
keywords='Yandex.Disk, webdav, client, python, Yandex',
# test_suite='YaDiskClient.test_YaDiskClient' # this line is commented because tests needs Yandex login and password
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Utilities',
'Topic :: System :: Archiving :: Backup',
],
)
|
#-*- coding: utf-8 -*-
from setuptools import setup, find_packages
import YaDiskClient
setup(
name='YaDiskClient',
version=YaDiskClient.__version__,
include_package_data=True,
py_modules=['YaDiskClient'],
url='https://github.com/TyVik/YaDiskClient',
license='MIT',
author='TyVik',
author_email='tyvik8@gmail.com',
description='Clent for Yandex.Disk',
long_description=open('README.rst').read(),
install_requires=['requests'],
packages=find_packages(),
keywords='Yandex.Disk, webdav, client, python, Yandex',
# test_suite='YaDiskClient.test_YaDiskClient' # this line is commented because tests needs Yandex login and password
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Utilities',
'Topic :: System :: Archiving :: Backup',
],
)
Support python 3.7, 3.8, 3.9, 3.10#-*- coding: utf-8 -*-
from setuptools import setup, find_packages
import YaDiskClient
setup(
name='YaDiskClient',
version=YaDiskClient.__version__,
include_package_data=True,
py_modules=['YaDiskClient'],
url='https://github.com/TyVik/YaDiskClient',
license='MIT',
author='TyVik',
author_email='tyvik8@gmail.com',
description='Clent for Yandex.Disk',
long_description=open('README.rst').read(),
install_requires=['requests'],
packages=find_packages(),
keywords='Yandex.Disk, webdav, client, python, Yandex',
# test_suite='YaDiskClient.test_YaDiskClient' # this line is commented because tests needs Yandex login and password
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Utilities',
'Topic :: System :: Archiving :: Backup',
],
)
|
<commit_before>#-*- coding: utf-8 -*-
from setuptools import setup, find_packages
import YaDiskClient
setup(
name='YaDiskClient',
version=YaDiskClient.__version__,
include_package_data=True,
py_modules=['YaDiskClient'],
url='https://github.com/TyVik/YaDiskClient',
license='MIT',
author='TyVik',
author_email='tyvik8@gmail.com',
description='Clent for Yandex.Disk',
long_description=open('README.rst').read(),
install_requires=['requests'],
packages=find_packages(),
keywords='Yandex.Disk, webdav, client, python, Yandex',
# test_suite='YaDiskClient.test_YaDiskClient' # this line is commented because tests needs Yandex login and password
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Utilities',
'Topic :: System :: Archiving :: Backup',
],
)
<commit_msg>Support python 3.7, 3.8, 3.9, 3.10<commit_after>#-*- coding: utf-8 -*-
from setuptools import setup, find_packages
import YaDiskClient
setup(
name='YaDiskClient',
version=YaDiskClient.__version__,
include_package_data=True,
py_modules=['YaDiskClient'],
url='https://github.com/TyVik/YaDiskClient',
license='MIT',
author='TyVik',
author_email='tyvik8@gmail.com',
description='Clent for Yandex.Disk',
long_description=open('README.rst').read(),
install_requires=['requests'],
packages=find_packages(),
keywords='Yandex.Disk, webdav, client, python, Yandex',
# test_suite='YaDiskClient.test_YaDiskClient' # this line is commented because tests needs Yandex login and password
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Programming Language :: Python :: 3.8',
'Programming Language :: Python :: 3.9',
'Programming Language :: Python :: 3.10',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Utilities',
'Topic :: System :: Archiving :: Backup',
],
)
|
d59cb35568a0a16d803c7a899ad0ab74b9b7256a
|
setup.py
|
setup.py
|
from setuptools import setup, PEP420PackageFinder
setup(
name='tangled',
version='1.0a13.dev0',
description='Tangled namespace and utilities',
long_description=open('README.rst').read(),
url='https://tangledframework.org/',
download_url='https://github.com/TangledWeb/tangled/tags',
author='Wyatt Baldwin',
author_email='self@wyattbaldwin.com',
packages=PEP420PackageFinder.find(include=['tangled*']),
install_requires=[
'runcommands>=1.0a27',
],
extras_require={
'dev': [
'coverage>=4.4.2',
'flake8>=3.5.0',
'Sphinx>=1.6.5',
'sphinx_rtd_theme>=0.2.4',
],
},
entry_points="""
[console_scripts]
tangled = tangled.__main__:main
[tangled.scripts]
release = tangled.scripts:ReleaseCommand
scaffold = tangled.scripts:ScaffoldCommand
python = tangled.scripts:ShellCommand
""",
classifiers=[
'Development Status :: 3 - Alpha',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
)
|
from setuptools import setup, PEP420PackageFinder
setup(
name='tangled',
version='1.0a13.dev0',
description='Tangled namespace and utilities',
long_description=open('README.rst').read(),
url='https://tangledframework.org/',
download_url='https://github.com/TangledWeb/tangled/tags',
author='Wyatt Baldwin',
author_email='self@wyattbaldwin.com',
packages=PEP420PackageFinder.find(include=['tangled*']),
install_requires=[
'runcommands>=1.0a27',
],
extras_require={
'dev': [
'coverage>=4.4.2',
'flake8>=3.5.0',
'Sphinx>=1.6.5',
'sphinx_rtd_theme>=0.2.4',
],
},
entry_points="""
[console_scripts]
tangled = tangled.__main__:main
[tangled.scripts]
release = tangled.scripts:ReleaseCommand
scaffold = tangled.scripts:ScaffoldCommand
""",
classifiers=[
'Development Status :: 3 - Alpha',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
)
|
Remove shell console script from entry points
|
Remove shell console script from entry points
Amends f06fecca161bca2360ce076e9cc15458cbda0de5
|
Python
|
mit
|
TangledWeb/tangled
|
from setuptools import setup, PEP420PackageFinder
setup(
name='tangled',
version='1.0a13.dev0',
description='Tangled namespace and utilities',
long_description=open('README.rst').read(),
url='https://tangledframework.org/',
download_url='https://github.com/TangledWeb/tangled/tags',
author='Wyatt Baldwin',
author_email='self@wyattbaldwin.com',
packages=PEP420PackageFinder.find(include=['tangled*']),
install_requires=[
'runcommands>=1.0a27',
],
extras_require={
'dev': [
'coverage>=4.4.2',
'flake8>=3.5.0',
'Sphinx>=1.6.5',
'sphinx_rtd_theme>=0.2.4',
],
},
entry_points="""
[console_scripts]
tangled = tangled.__main__:main
[tangled.scripts]
release = tangled.scripts:ReleaseCommand
scaffold = tangled.scripts:ScaffoldCommand
python = tangled.scripts:ShellCommand
""",
classifiers=[
'Development Status :: 3 - Alpha',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
)
Remove shell console script from entry points
Amends f06fecca161bca2360ce076e9cc15458cbda0de5
|
from setuptools import setup, PEP420PackageFinder
setup(
name='tangled',
version='1.0a13.dev0',
description='Tangled namespace and utilities',
long_description=open('README.rst').read(),
url='https://tangledframework.org/',
download_url='https://github.com/TangledWeb/tangled/tags',
author='Wyatt Baldwin',
author_email='self@wyattbaldwin.com',
packages=PEP420PackageFinder.find(include=['tangled*']),
install_requires=[
'runcommands>=1.0a27',
],
extras_require={
'dev': [
'coverage>=4.4.2',
'flake8>=3.5.0',
'Sphinx>=1.6.5',
'sphinx_rtd_theme>=0.2.4',
],
},
entry_points="""
[console_scripts]
tangled = tangled.__main__:main
[tangled.scripts]
release = tangled.scripts:ReleaseCommand
scaffold = tangled.scripts:ScaffoldCommand
""",
classifiers=[
'Development Status :: 3 - Alpha',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
)
|
<commit_before>from setuptools import setup, PEP420PackageFinder
setup(
name='tangled',
version='1.0a13.dev0',
description='Tangled namespace and utilities',
long_description=open('README.rst').read(),
url='https://tangledframework.org/',
download_url='https://github.com/TangledWeb/tangled/tags',
author='Wyatt Baldwin',
author_email='self@wyattbaldwin.com',
packages=PEP420PackageFinder.find(include=['tangled*']),
install_requires=[
'runcommands>=1.0a27',
],
extras_require={
'dev': [
'coverage>=4.4.2',
'flake8>=3.5.0',
'Sphinx>=1.6.5',
'sphinx_rtd_theme>=0.2.4',
],
},
entry_points="""
[console_scripts]
tangled = tangled.__main__:main
[tangled.scripts]
release = tangled.scripts:ReleaseCommand
scaffold = tangled.scripts:ScaffoldCommand
python = tangled.scripts:ShellCommand
""",
classifiers=[
'Development Status :: 3 - Alpha',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
)
<commit_msg>Remove shell console script from entry points
Amends f06fecca161bca2360ce076e9cc15458cbda0de5<commit_after>
|
from setuptools import setup, PEP420PackageFinder
setup(
name='tangled',
version='1.0a13.dev0',
description='Tangled namespace and utilities',
long_description=open('README.rst').read(),
url='https://tangledframework.org/',
download_url='https://github.com/TangledWeb/tangled/tags',
author='Wyatt Baldwin',
author_email='self@wyattbaldwin.com',
packages=PEP420PackageFinder.find(include=['tangled*']),
install_requires=[
'runcommands>=1.0a27',
],
extras_require={
'dev': [
'coverage>=4.4.2',
'flake8>=3.5.0',
'Sphinx>=1.6.5',
'sphinx_rtd_theme>=0.2.4',
],
},
entry_points="""
[console_scripts]
tangled = tangled.__main__:main
[tangled.scripts]
release = tangled.scripts:ReleaseCommand
scaffold = tangled.scripts:ScaffoldCommand
""",
classifiers=[
'Development Status :: 3 - Alpha',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
)
|
from setuptools import setup, PEP420PackageFinder
setup(
name='tangled',
version='1.0a13.dev0',
description='Tangled namespace and utilities',
long_description=open('README.rst').read(),
url='https://tangledframework.org/',
download_url='https://github.com/TangledWeb/tangled/tags',
author='Wyatt Baldwin',
author_email='self@wyattbaldwin.com',
packages=PEP420PackageFinder.find(include=['tangled*']),
install_requires=[
'runcommands>=1.0a27',
],
extras_require={
'dev': [
'coverage>=4.4.2',
'flake8>=3.5.0',
'Sphinx>=1.6.5',
'sphinx_rtd_theme>=0.2.4',
],
},
entry_points="""
[console_scripts]
tangled = tangled.__main__:main
[tangled.scripts]
release = tangled.scripts:ReleaseCommand
scaffold = tangled.scripts:ScaffoldCommand
python = tangled.scripts:ShellCommand
""",
classifiers=[
'Development Status :: 3 - Alpha',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
)
Remove shell console script from entry points
Amends f06fecca161bca2360ce076e9cc15458cbda0de5from setuptools import setup, PEP420PackageFinder
setup(
name='tangled',
version='1.0a13.dev0',
description='Tangled namespace and utilities',
long_description=open('README.rst').read(),
url='https://tangledframework.org/',
download_url='https://github.com/TangledWeb/tangled/tags',
author='Wyatt Baldwin',
author_email='self@wyattbaldwin.com',
packages=PEP420PackageFinder.find(include=['tangled*']),
install_requires=[
'runcommands>=1.0a27',
],
extras_require={
'dev': [
'coverage>=4.4.2',
'flake8>=3.5.0',
'Sphinx>=1.6.5',
'sphinx_rtd_theme>=0.2.4',
],
},
entry_points="""
[console_scripts]
tangled = tangled.__main__:main
[tangled.scripts]
release = tangled.scripts:ReleaseCommand
scaffold = tangled.scripts:ScaffoldCommand
""",
classifiers=[
'Development Status :: 3 - Alpha',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
)
|
<commit_before>from setuptools import setup, PEP420PackageFinder
setup(
name='tangled',
version='1.0a13.dev0',
description='Tangled namespace and utilities',
long_description=open('README.rst').read(),
url='https://tangledframework.org/',
download_url='https://github.com/TangledWeb/tangled/tags',
author='Wyatt Baldwin',
author_email='self@wyattbaldwin.com',
packages=PEP420PackageFinder.find(include=['tangled*']),
install_requires=[
'runcommands>=1.0a27',
],
extras_require={
'dev': [
'coverage>=4.4.2',
'flake8>=3.5.0',
'Sphinx>=1.6.5',
'sphinx_rtd_theme>=0.2.4',
],
},
entry_points="""
[console_scripts]
tangled = tangled.__main__:main
[tangled.scripts]
release = tangled.scripts:ReleaseCommand
scaffold = tangled.scripts:ScaffoldCommand
python = tangled.scripts:ShellCommand
""",
classifiers=[
'Development Status :: 3 - Alpha',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
)
<commit_msg>Remove shell console script from entry points
Amends f06fecca161bca2360ce076e9cc15458cbda0de5<commit_after>from setuptools import setup, PEP420PackageFinder
setup(
name='tangled',
version='1.0a13.dev0',
description='Tangled namespace and utilities',
long_description=open('README.rst').read(),
url='https://tangledframework.org/',
download_url='https://github.com/TangledWeb/tangled/tags',
author='Wyatt Baldwin',
author_email='self@wyattbaldwin.com',
packages=PEP420PackageFinder.find(include=['tangled*']),
install_requires=[
'runcommands>=1.0a27',
],
extras_require={
'dev': [
'coverage>=4.4.2',
'flake8>=3.5.0',
'Sphinx>=1.6.5',
'sphinx_rtd_theme>=0.2.4',
],
},
entry_points="""
[console_scripts]
tangled = tangled.__main__:main
[tangled.scripts]
release = tangled.scripts:ReleaseCommand
scaffold = tangled.scripts:ScaffoldCommand
""",
classifiers=[
'Development Status :: 3 - Alpha',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
)
|
1e0f2d65ad5a22b1ae945f7a707a2d31bca50744
|
setup.py
|
setup.py
|
from __future__ import print_function
from setuptools import setup
setup_kwargs = dict(
name = 'mod_wsgi-metrics',
version = '1.1.0',
description = 'Metrics package for Apache/mod_wsgi.',
author = 'Graham Dumpleton',
author_email = 'Graham.Dumpleton@gmail.com',
maintainer = 'Graham Dumpleton',
maintainer_email = 'Graham.Dumpleton@gmail.com',
url = 'http://www.modwsgi.org/',
license = 'Apache License, Version 2.0',
platforms = [],
download_url = None,
classifiers= [
'Development Status :: 6 - Mature',
'License :: OSI Approved :: Apache Software License',
'Operating System :: MacOS :: MacOS X',
'Operating System :: POSIX',
'Operating System :: POSIX :: BSD',
'Operating System :: POSIX :: Linux',
'Operating System :: POSIX :: SunOS/Solaris',
'Programming Language :: Python',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Topic :: Internet :: WWW/HTTP :: WSGI',
],
packages = ['mod_wsgi', 'mod_wsgi.metrics', 'mod_wsgi.metrics.newrelic'],
package_dir = {'mod_wsgi': 'src'},
)
setup(**setup_kwargs)
|
from __future__ import print_function
from setuptools import setup
setup_kwargs = dict(
name = 'mod_wsgi-metrics',
version = '1.1.0',
description = 'Metrics package for Apache/mod_wsgi.',
author = 'Graham Dumpleton',
author_email = 'Graham.Dumpleton@gmail.com',
maintainer = 'Graham Dumpleton',
maintainer_email = 'Graham.Dumpleton@gmail.com',
url = 'http://www.modwsgi.org/',
license = 'Apache License, Version 2.0',
platforms = [],
download_url = None,
classifiers= [
'Development Status :: 6 - Mature',
'License :: OSI Approved :: Apache Software License',
'Operating System :: MacOS :: MacOS X',
'Operating System :: POSIX',
'Operating System :: POSIX :: BSD',
'Operating System :: POSIX :: Linux',
'Operating System :: POSIX :: SunOS/Solaris',
'Programming Language :: Python',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Topic :: Internet :: WWW/HTTP :: WSGI',
],
packages = ['mod_wsgi', 'mod_wsgi.metrics', 'mod_wsgi.metrics.newrelic'],
package_dir = {'mod_wsgi': 'src'},
install_requires=['psutil >= 2.0.0'],
)
setup(**setup_kwargs)
|
Add dependency on having psutil available.
|
Add dependency on having psutil available.
|
Python
|
apache-2.0
|
GrahamDumpleton/mod_wsgi-metrics
|
from __future__ import print_function
from setuptools import setup
setup_kwargs = dict(
name = 'mod_wsgi-metrics',
version = '1.1.0',
description = 'Metrics package for Apache/mod_wsgi.',
author = 'Graham Dumpleton',
author_email = 'Graham.Dumpleton@gmail.com',
maintainer = 'Graham Dumpleton',
maintainer_email = 'Graham.Dumpleton@gmail.com',
url = 'http://www.modwsgi.org/',
license = 'Apache License, Version 2.0',
platforms = [],
download_url = None,
classifiers= [
'Development Status :: 6 - Mature',
'License :: OSI Approved :: Apache Software License',
'Operating System :: MacOS :: MacOS X',
'Operating System :: POSIX',
'Operating System :: POSIX :: BSD',
'Operating System :: POSIX :: Linux',
'Operating System :: POSIX :: SunOS/Solaris',
'Programming Language :: Python',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Topic :: Internet :: WWW/HTTP :: WSGI',
],
packages = ['mod_wsgi', 'mod_wsgi.metrics', 'mod_wsgi.metrics.newrelic'],
package_dir = {'mod_wsgi': 'src'},
)
setup(**setup_kwargs)
Add dependency on having psutil available.
|
from __future__ import print_function
from setuptools import setup
setup_kwargs = dict(
name = 'mod_wsgi-metrics',
version = '1.1.0',
description = 'Metrics package for Apache/mod_wsgi.',
author = 'Graham Dumpleton',
author_email = 'Graham.Dumpleton@gmail.com',
maintainer = 'Graham Dumpleton',
maintainer_email = 'Graham.Dumpleton@gmail.com',
url = 'http://www.modwsgi.org/',
license = 'Apache License, Version 2.0',
platforms = [],
download_url = None,
classifiers= [
'Development Status :: 6 - Mature',
'License :: OSI Approved :: Apache Software License',
'Operating System :: MacOS :: MacOS X',
'Operating System :: POSIX',
'Operating System :: POSIX :: BSD',
'Operating System :: POSIX :: Linux',
'Operating System :: POSIX :: SunOS/Solaris',
'Programming Language :: Python',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Topic :: Internet :: WWW/HTTP :: WSGI',
],
packages = ['mod_wsgi', 'mod_wsgi.metrics', 'mod_wsgi.metrics.newrelic'],
package_dir = {'mod_wsgi': 'src'},
install_requires=['psutil >= 2.0.0'],
)
setup(**setup_kwargs)
|
<commit_before>from __future__ import print_function
from setuptools import setup
setup_kwargs = dict(
name = 'mod_wsgi-metrics',
version = '1.1.0',
description = 'Metrics package for Apache/mod_wsgi.',
author = 'Graham Dumpleton',
author_email = 'Graham.Dumpleton@gmail.com',
maintainer = 'Graham Dumpleton',
maintainer_email = 'Graham.Dumpleton@gmail.com',
url = 'http://www.modwsgi.org/',
license = 'Apache License, Version 2.0',
platforms = [],
download_url = None,
classifiers= [
'Development Status :: 6 - Mature',
'License :: OSI Approved :: Apache Software License',
'Operating System :: MacOS :: MacOS X',
'Operating System :: POSIX',
'Operating System :: POSIX :: BSD',
'Operating System :: POSIX :: Linux',
'Operating System :: POSIX :: SunOS/Solaris',
'Programming Language :: Python',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Topic :: Internet :: WWW/HTTP :: WSGI',
],
packages = ['mod_wsgi', 'mod_wsgi.metrics', 'mod_wsgi.metrics.newrelic'],
package_dir = {'mod_wsgi': 'src'},
)
setup(**setup_kwargs)
<commit_msg>Add dependency on having psutil available.<commit_after>
|
from __future__ import print_function
from setuptools import setup
setup_kwargs = dict(
name = 'mod_wsgi-metrics',
version = '1.1.0',
description = 'Metrics package for Apache/mod_wsgi.',
author = 'Graham Dumpleton',
author_email = 'Graham.Dumpleton@gmail.com',
maintainer = 'Graham Dumpleton',
maintainer_email = 'Graham.Dumpleton@gmail.com',
url = 'http://www.modwsgi.org/',
license = 'Apache License, Version 2.0',
platforms = [],
download_url = None,
classifiers= [
'Development Status :: 6 - Mature',
'License :: OSI Approved :: Apache Software License',
'Operating System :: MacOS :: MacOS X',
'Operating System :: POSIX',
'Operating System :: POSIX :: BSD',
'Operating System :: POSIX :: Linux',
'Operating System :: POSIX :: SunOS/Solaris',
'Programming Language :: Python',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Topic :: Internet :: WWW/HTTP :: WSGI',
],
packages = ['mod_wsgi', 'mod_wsgi.metrics', 'mod_wsgi.metrics.newrelic'],
package_dir = {'mod_wsgi': 'src'},
install_requires=['psutil >= 2.0.0'],
)
setup(**setup_kwargs)
|
from __future__ import print_function
from setuptools import setup
setup_kwargs = dict(
name = 'mod_wsgi-metrics',
version = '1.1.0',
description = 'Metrics package for Apache/mod_wsgi.',
author = 'Graham Dumpleton',
author_email = 'Graham.Dumpleton@gmail.com',
maintainer = 'Graham Dumpleton',
maintainer_email = 'Graham.Dumpleton@gmail.com',
url = 'http://www.modwsgi.org/',
license = 'Apache License, Version 2.0',
platforms = [],
download_url = None,
classifiers= [
'Development Status :: 6 - Mature',
'License :: OSI Approved :: Apache Software License',
'Operating System :: MacOS :: MacOS X',
'Operating System :: POSIX',
'Operating System :: POSIX :: BSD',
'Operating System :: POSIX :: Linux',
'Operating System :: POSIX :: SunOS/Solaris',
'Programming Language :: Python',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Topic :: Internet :: WWW/HTTP :: WSGI',
],
packages = ['mod_wsgi', 'mod_wsgi.metrics', 'mod_wsgi.metrics.newrelic'],
package_dir = {'mod_wsgi': 'src'},
)
setup(**setup_kwargs)
Add dependency on having psutil available.from __future__ import print_function
from setuptools import setup
setup_kwargs = dict(
name = 'mod_wsgi-metrics',
version = '1.1.0',
description = 'Metrics package for Apache/mod_wsgi.',
author = 'Graham Dumpleton',
author_email = 'Graham.Dumpleton@gmail.com',
maintainer = 'Graham Dumpleton',
maintainer_email = 'Graham.Dumpleton@gmail.com',
url = 'http://www.modwsgi.org/',
license = 'Apache License, Version 2.0',
platforms = [],
download_url = None,
classifiers= [
'Development Status :: 6 - Mature',
'License :: OSI Approved :: Apache Software License',
'Operating System :: MacOS :: MacOS X',
'Operating System :: POSIX',
'Operating System :: POSIX :: BSD',
'Operating System :: POSIX :: Linux',
'Operating System :: POSIX :: SunOS/Solaris',
'Programming Language :: Python',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Topic :: Internet :: WWW/HTTP :: WSGI',
],
packages = ['mod_wsgi', 'mod_wsgi.metrics', 'mod_wsgi.metrics.newrelic'],
package_dir = {'mod_wsgi': 'src'},
install_requires=['psutil >= 2.0.0'],
)
setup(**setup_kwargs)
|
<commit_before>from __future__ import print_function
from setuptools import setup
setup_kwargs = dict(
name = 'mod_wsgi-metrics',
version = '1.1.0',
description = 'Metrics package for Apache/mod_wsgi.',
author = 'Graham Dumpleton',
author_email = 'Graham.Dumpleton@gmail.com',
maintainer = 'Graham Dumpleton',
maintainer_email = 'Graham.Dumpleton@gmail.com',
url = 'http://www.modwsgi.org/',
license = 'Apache License, Version 2.0',
platforms = [],
download_url = None,
classifiers= [
'Development Status :: 6 - Mature',
'License :: OSI Approved :: Apache Software License',
'Operating System :: MacOS :: MacOS X',
'Operating System :: POSIX',
'Operating System :: POSIX :: BSD',
'Operating System :: POSIX :: Linux',
'Operating System :: POSIX :: SunOS/Solaris',
'Programming Language :: Python',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Topic :: Internet :: WWW/HTTP :: WSGI',
],
packages = ['mod_wsgi', 'mod_wsgi.metrics', 'mod_wsgi.metrics.newrelic'],
package_dir = {'mod_wsgi': 'src'},
)
setup(**setup_kwargs)
<commit_msg>Add dependency on having psutil available.<commit_after>from __future__ import print_function
from setuptools import setup
setup_kwargs = dict(
name = 'mod_wsgi-metrics',
version = '1.1.0',
description = 'Metrics package for Apache/mod_wsgi.',
author = 'Graham Dumpleton',
author_email = 'Graham.Dumpleton@gmail.com',
maintainer = 'Graham Dumpleton',
maintainer_email = 'Graham.Dumpleton@gmail.com',
url = 'http://www.modwsgi.org/',
license = 'Apache License, Version 2.0',
platforms = [],
download_url = None,
classifiers= [
'Development Status :: 6 - Mature',
'License :: OSI Approved :: Apache Software License',
'Operating System :: MacOS :: MacOS X',
'Operating System :: POSIX',
'Operating System :: POSIX :: BSD',
'Operating System :: POSIX :: Linux',
'Operating System :: POSIX :: SunOS/Solaris',
'Programming Language :: Python',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Topic :: Internet :: WWW/HTTP :: WSGI',
],
packages = ['mod_wsgi', 'mod_wsgi.metrics', 'mod_wsgi.metrics.newrelic'],
package_dir = {'mod_wsgi': 'src'},
install_requires=['psutil >= 2.0.0'],
)
setup(**setup_kwargs)
|
0c7754b2b9c8c101476511709a3e2169eee50407
|
setup.py
|
setup.py
|
from setuptools import setup
setup(
name='whip-neustar',
version='0.1',
packages=['whip_neustar'],
entry_points={
'console_scripts': [
'whip-neustar = whip_neustar.cli:main',
],
}
)
|
from setuptools import setup
setup(
name='whip-neustar',
version='0.1',
packages=['whip_neustar'],
entry_points={
'console_scripts': [
'whip-neustar-cli = whip_neustar.cli:main',
],
}
)
|
Rename cli script to whip-neustar-cli
|
Rename cli script to whip-neustar-cli
|
Python
|
bsd-3-clause
|
wbolster/whip-neustar
|
from setuptools import setup
setup(
name='whip-neustar',
version='0.1',
packages=['whip_neustar'],
entry_points={
'console_scripts': [
'whip-neustar = whip_neustar.cli:main',
],
}
)
Rename cli script to whip-neustar-cli
|
from setuptools import setup
setup(
name='whip-neustar',
version='0.1',
packages=['whip_neustar'],
entry_points={
'console_scripts': [
'whip-neustar-cli = whip_neustar.cli:main',
],
}
)
|
<commit_before>from setuptools import setup
setup(
name='whip-neustar',
version='0.1',
packages=['whip_neustar'],
entry_points={
'console_scripts': [
'whip-neustar = whip_neustar.cli:main',
],
}
)
<commit_msg>Rename cli script to whip-neustar-cli<commit_after>
|
from setuptools import setup
setup(
name='whip-neustar',
version='0.1',
packages=['whip_neustar'],
entry_points={
'console_scripts': [
'whip-neustar-cli = whip_neustar.cli:main',
],
}
)
|
from setuptools import setup
setup(
name='whip-neustar',
version='0.1',
packages=['whip_neustar'],
entry_points={
'console_scripts': [
'whip-neustar = whip_neustar.cli:main',
],
}
)
Rename cli script to whip-neustar-clifrom setuptools import setup
setup(
name='whip-neustar',
version='0.1',
packages=['whip_neustar'],
entry_points={
'console_scripts': [
'whip-neustar-cli = whip_neustar.cli:main',
],
}
)
|
<commit_before>from setuptools import setup
setup(
name='whip-neustar',
version='0.1',
packages=['whip_neustar'],
entry_points={
'console_scripts': [
'whip-neustar = whip_neustar.cli:main',
],
}
)
<commit_msg>Rename cli script to whip-neustar-cli<commit_after>from setuptools import setup
setup(
name='whip-neustar',
version='0.1',
packages=['whip_neustar'],
entry_points={
'console_scripts': [
'whip-neustar-cli = whip_neustar.cli:main',
],
}
)
|
ccd726e43c25c0a4b23d15889c955741f9adc1d3
|
setup.py
|
setup.py
|
from setuptools import find_packages
from setuptools import setup
REQUIRED_PACKAGES = ['distance', 'numpy', 'six', 'pillow']
VERSION = '0.1.1'
try:
import pypandoc
README = pypandoc.convert('README.md', 'rst')
except(IOError, ImportError):
README = open('README.md').read()
setup(
name='aocr',
url='https://github.com/emedvedev/attention-ocr',
download_url='https://github.com/emedvedev/attention-ocr/archive/{}.tar.gz'.format(VERSION),
author='Ed Medvedev',
author_email='edward.medvedev@gmail.com',
version=VERSION,
install_requires=REQUIRED_PACKAGES,
packages=find_packages(),
include_package_data=True,
license='MIT',
description=('''Optical character recognition model '''
'''for Tensorflow based on Visual Attention.'''),
long_description=README,
entry_points={
'console_scripts': ['aocr=aocr.__main__:main'],
}
)
|
from setuptools import find_packages
from setuptools import setup
REQUIRED_PACKAGES = ['distance', 'numpy', 'six', 'pillow']
VERSION = '0.2.0'
try:
import pypandoc
README = pypandoc.convert('README.md', 'rst')
except(IOError, ImportError):
README = open('README.md').read()
setup(
name='aocr',
url='https://github.com/emedvedev/attention-ocr',
download_url='https://github.com/emedvedev/attention-ocr/archive/{}.tar.gz'.format(VERSION),
author='Ed Medvedev',
author_email='edward.medvedev@gmail.com',
version=VERSION,
install_requires=REQUIRED_PACKAGES,
packages=find_packages(),
include_package_data=True,
license='MIT',
description=('''Optical character recognition model '''
'''for Tensorflow based on Visual Attention.'''),
long_description=README,
entry_points={
'console_scripts': ['aocr=aocr.__main__:main'],
}
)
|
Update the version to 0.2.0
|
Update the version to 0.2.0
|
Python
|
mit
|
emedvedev/attention-ocr
|
from setuptools import find_packages
from setuptools import setup
REQUIRED_PACKAGES = ['distance', 'numpy', 'six', 'pillow']
VERSION = '0.1.1'
try:
import pypandoc
README = pypandoc.convert('README.md', 'rst')
except(IOError, ImportError):
README = open('README.md').read()
setup(
name='aocr',
url='https://github.com/emedvedev/attention-ocr',
download_url='https://github.com/emedvedev/attention-ocr/archive/{}.tar.gz'.format(VERSION),
author='Ed Medvedev',
author_email='edward.medvedev@gmail.com',
version=VERSION,
install_requires=REQUIRED_PACKAGES,
packages=find_packages(),
include_package_data=True,
license='MIT',
description=('''Optical character recognition model '''
'''for Tensorflow based on Visual Attention.'''),
long_description=README,
entry_points={
'console_scripts': ['aocr=aocr.__main__:main'],
}
)
Update the version to 0.2.0
|
from setuptools import find_packages
from setuptools import setup
REQUIRED_PACKAGES = ['distance', 'numpy', 'six', 'pillow']
VERSION = '0.2.0'
try:
import pypandoc
README = pypandoc.convert('README.md', 'rst')
except(IOError, ImportError):
README = open('README.md').read()
setup(
name='aocr',
url='https://github.com/emedvedev/attention-ocr',
download_url='https://github.com/emedvedev/attention-ocr/archive/{}.tar.gz'.format(VERSION),
author='Ed Medvedev',
author_email='edward.medvedev@gmail.com',
version=VERSION,
install_requires=REQUIRED_PACKAGES,
packages=find_packages(),
include_package_data=True,
license='MIT',
description=('''Optical character recognition model '''
'''for Tensorflow based on Visual Attention.'''),
long_description=README,
entry_points={
'console_scripts': ['aocr=aocr.__main__:main'],
}
)
|
<commit_before>from setuptools import find_packages
from setuptools import setup
REQUIRED_PACKAGES = ['distance', 'numpy', 'six', 'pillow']
VERSION = '0.1.1'
try:
import pypandoc
README = pypandoc.convert('README.md', 'rst')
except(IOError, ImportError):
README = open('README.md').read()
setup(
name='aocr',
url='https://github.com/emedvedev/attention-ocr',
download_url='https://github.com/emedvedev/attention-ocr/archive/{}.tar.gz'.format(VERSION),
author='Ed Medvedev',
author_email='edward.medvedev@gmail.com',
version=VERSION,
install_requires=REQUIRED_PACKAGES,
packages=find_packages(),
include_package_data=True,
license='MIT',
description=('''Optical character recognition model '''
'''for Tensorflow based on Visual Attention.'''),
long_description=README,
entry_points={
'console_scripts': ['aocr=aocr.__main__:main'],
}
)
<commit_msg>Update the version to 0.2.0<commit_after>
|
from setuptools import find_packages
from setuptools import setup
REQUIRED_PACKAGES = ['distance', 'numpy', 'six', 'pillow']
VERSION = '0.2.0'
try:
import pypandoc
README = pypandoc.convert('README.md', 'rst')
except(IOError, ImportError):
README = open('README.md').read()
setup(
name='aocr',
url='https://github.com/emedvedev/attention-ocr',
download_url='https://github.com/emedvedev/attention-ocr/archive/{}.tar.gz'.format(VERSION),
author='Ed Medvedev',
author_email='edward.medvedev@gmail.com',
version=VERSION,
install_requires=REQUIRED_PACKAGES,
packages=find_packages(),
include_package_data=True,
license='MIT',
description=('''Optical character recognition model '''
'''for Tensorflow based on Visual Attention.'''),
long_description=README,
entry_points={
'console_scripts': ['aocr=aocr.__main__:main'],
}
)
|
from setuptools import find_packages
from setuptools import setup
REQUIRED_PACKAGES = ['distance', 'numpy', 'six', 'pillow']
VERSION = '0.1.1'
try:
import pypandoc
README = pypandoc.convert('README.md', 'rst')
except(IOError, ImportError):
README = open('README.md').read()
setup(
name='aocr',
url='https://github.com/emedvedev/attention-ocr',
download_url='https://github.com/emedvedev/attention-ocr/archive/{}.tar.gz'.format(VERSION),
author='Ed Medvedev',
author_email='edward.medvedev@gmail.com',
version=VERSION,
install_requires=REQUIRED_PACKAGES,
packages=find_packages(),
include_package_data=True,
license='MIT',
description=('''Optical character recognition model '''
'''for Tensorflow based on Visual Attention.'''),
long_description=README,
entry_points={
'console_scripts': ['aocr=aocr.__main__:main'],
}
)
Update the version to 0.2.0from setuptools import find_packages
from setuptools import setup
REQUIRED_PACKAGES = ['distance', 'numpy', 'six', 'pillow']
VERSION = '0.2.0'
try:
import pypandoc
README = pypandoc.convert('README.md', 'rst')
except(IOError, ImportError):
README = open('README.md').read()
setup(
name='aocr',
url='https://github.com/emedvedev/attention-ocr',
download_url='https://github.com/emedvedev/attention-ocr/archive/{}.tar.gz'.format(VERSION),
author='Ed Medvedev',
author_email='edward.medvedev@gmail.com',
version=VERSION,
install_requires=REQUIRED_PACKAGES,
packages=find_packages(),
include_package_data=True,
license='MIT',
description=('''Optical character recognition model '''
'''for Tensorflow based on Visual Attention.'''),
long_description=README,
entry_points={
'console_scripts': ['aocr=aocr.__main__:main'],
}
)
|
<commit_before>from setuptools import find_packages
from setuptools import setup
REQUIRED_PACKAGES = ['distance', 'numpy', 'six', 'pillow']
VERSION = '0.1.1'
try:
import pypandoc
README = pypandoc.convert('README.md', 'rst')
except(IOError, ImportError):
README = open('README.md').read()
setup(
name='aocr',
url='https://github.com/emedvedev/attention-ocr',
download_url='https://github.com/emedvedev/attention-ocr/archive/{}.tar.gz'.format(VERSION),
author='Ed Medvedev',
author_email='edward.medvedev@gmail.com',
version=VERSION,
install_requires=REQUIRED_PACKAGES,
packages=find_packages(),
include_package_data=True,
license='MIT',
description=('''Optical character recognition model '''
'''for Tensorflow based on Visual Attention.'''),
long_description=README,
entry_points={
'console_scripts': ['aocr=aocr.__main__:main'],
}
)
<commit_msg>Update the version to 0.2.0<commit_after>from setuptools import find_packages
from setuptools import setup
REQUIRED_PACKAGES = ['distance', 'numpy', 'six', 'pillow']
VERSION = '0.2.0'
try:
import pypandoc
README = pypandoc.convert('README.md', 'rst')
except(IOError, ImportError):
README = open('README.md').read()
setup(
name='aocr',
url='https://github.com/emedvedev/attention-ocr',
download_url='https://github.com/emedvedev/attention-ocr/archive/{}.tar.gz'.format(VERSION),
author='Ed Medvedev',
author_email='edward.medvedev@gmail.com',
version=VERSION,
install_requires=REQUIRED_PACKAGES,
packages=find_packages(),
include_package_data=True,
license='MIT',
description=('''Optical character recognition model '''
'''for Tensorflow based on Visual Attention.'''),
long_description=README,
entry_points={
'console_scripts': ['aocr=aocr.__main__:main'],
}
)
|
7c50ccc9de67df3b4b9addebddb8234e770f0b22
|
setup.py
|
setup.py
|
from os.path import dirname, join
from setuptools import setup, find_packages
version = '0.3'
def read(fname):
return open(join(dirname(__file__), fname)).read()
setup(name='django-apptemplates',
version=version,
description='Django template loader that allows you to load and'
'override a template from a specific Django application.',
long_description=read('README.rst'),
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Internet :: WWW/HTTP :: WSGI',
'Topic :: Software Development :: Libraries :: Application Frameworks', # noqa
'Topic :: Software Development :: Libraries :: Python Modules',
],
keywords='django templates',
author='Konrad Wojas',
author_email='konrad.wojas@jibecompany.com',
maintainer='Tomas Zulberti',
url='http://bitbucket.org/tzulberti/django-apptemplates/',
license='MIT License',
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=True,
zip_safe=False,
)
|
from os.path import dirname, join
from setuptools import setup, find_packages
version = '0.2.1'
def read(fname):
return open(join(dirname(__file__), fname)).read()
setup(name='django-apptemplates',
version=version,
description='Django template loader that allows you to load and'
'override a template from a specific Django application.',
long_description=read('README.rst'),
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Internet :: WWW/HTTP :: WSGI',
'Topic :: Software Development :: Libraries :: Application Frameworks', # noqa
'Topic :: Software Development :: Libraries :: Python Modules',
],
keywords='django templates',
author='Konrad Wojas',
author_email='konrad.wojas@jibecompany.com',
maintainer='Tomas Zulberti',
url='http://bitbucket.org/tzulberti/django-apptemplates/',
license='MIT License',
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=True,
zip_safe=False,
)
|
Increase only minor in version number
|
Increase only minor in version number
|
Python
|
mit
|
jdotjdot/django-apptemplates,bittner/django-apptemplates
|
from os.path import dirname, join
from setuptools import setup, find_packages
version = '0.3'
def read(fname):
return open(join(dirname(__file__), fname)).read()
setup(name='django-apptemplates',
version=version,
description='Django template loader that allows you to load and'
'override a template from a specific Django application.',
long_description=read('README.rst'),
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Internet :: WWW/HTTP :: WSGI',
'Topic :: Software Development :: Libraries :: Application Frameworks', # noqa
'Topic :: Software Development :: Libraries :: Python Modules',
],
keywords='django templates',
author='Konrad Wojas',
author_email='konrad.wojas@jibecompany.com',
maintainer='Tomas Zulberti',
url='http://bitbucket.org/tzulberti/django-apptemplates/',
license='MIT License',
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=True,
zip_safe=False,
)
Increase only minor in version number
|
from os.path import dirname, join
from setuptools import setup, find_packages
version = '0.2.1'
def read(fname):
return open(join(dirname(__file__), fname)).read()
setup(name='django-apptemplates',
version=version,
description='Django template loader that allows you to load and'
'override a template from a specific Django application.',
long_description=read('README.rst'),
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Internet :: WWW/HTTP :: WSGI',
'Topic :: Software Development :: Libraries :: Application Frameworks', # noqa
'Topic :: Software Development :: Libraries :: Python Modules',
],
keywords='django templates',
author='Konrad Wojas',
author_email='konrad.wojas@jibecompany.com',
maintainer='Tomas Zulberti',
url='http://bitbucket.org/tzulberti/django-apptemplates/',
license='MIT License',
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=True,
zip_safe=False,
)
|
<commit_before>from os.path import dirname, join
from setuptools import setup, find_packages
version = '0.3'
def read(fname):
return open(join(dirname(__file__), fname)).read()
setup(name='django-apptemplates',
version=version,
description='Django template loader that allows you to load and'
'override a template from a specific Django application.',
long_description=read('README.rst'),
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Internet :: WWW/HTTP :: WSGI',
'Topic :: Software Development :: Libraries :: Application Frameworks', # noqa
'Topic :: Software Development :: Libraries :: Python Modules',
],
keywords='django templates',
author='Konrad Wojas',
author_email='konrad.wojas@jibecompany.com',
maintainer='Tomas Zulberti',
url='http://bitbucket.org/tzulberti/django-apptemplates/',
license='MIT License',
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=True,
zip_safe=False,
)
<commit_msg>Increase only minor in version number<commit_after>
|
from os.path import dirname, join
from setuptools import setup, find_packages
version = '0.2.1'
def read(fname):
return open(join(dirname(__file__), fname)).read()
setup(name='django-apptemplates',
version=version,
description='Django template loader that allows you to load and'
'override a template from a specific Django application.',
long_description=read('README.rst'),
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Internet :: WWW/HTTP :: WSGI',
'Topic :: Software Development :: Libraries :: Application Frameworks', # noqa
'Topic :: Software Development :: Libraries :: Python Modules',
],
keywords='django templates',
author='Konrad Wojas',
author_email='konrad.wojas@jibecompany.com',
maintainer='Tomas Zulberti',
url='http://bitbucket.org/tzulberti/django-apptemplates/',
license='MIT License',
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=True,
zip_safe=False,
)
|
from os.path import dirname, join
from setuptools import setup, find_packages
version = '0.3'
def read(fname):
return open(join(dirname(__file__), fname)).read()
setup(name='django-apptemplates',
version=version,
description='Django template loader that allows you to load and'
'override a template from a specific Django application.',
long_description=read('README.rst'),
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Internet :: WWW/HTTP :: WSGI',
'Topic :: Software Development :: Libraries :: Application Frameworks', # noqa
'Topic :: Software Development :: Libraries :: Python Modules',
],
keywords='django templates',
author='Konrad Wojas',
author_email='konrad.wojas@jibecompany.com',
maintainer='Tomas Zulberti',
url='http://bitbucket.org/tzulberti/django-apptemplates/',
license='MIT License',
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=True,
zip_safe=False,
)
Increase only minor in version numberfrom os.path import dirname, join
from setuptools import setup, find_packages
version = '0.2.1'
def read(fname):
return open(join(dirname(__file__), fname)).read()
setup(name='django-apptemplates',
version=version,
description='Django template loader that allows you to load and'
'override a template from a specific Django application.',
long_description=read('README.rst'),
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Internet :: WWW/HTTP :: WSGI',
'Topic :: Software Development :: Libraries :: Application Frameworks', # noqa
'Topic :: Software Development :: Libraries :: Python Modules',
],
keywords='django templates',
author='Konrad Wojas',
author_email='konrad.wojas@jibecompany.com',
maintainer='Tomas Zulberti',
url='http://bitbucket.org/tzulberti/django-apptemplates/',
license='MIT License',
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=True,
zip_safe=False,
)
|
<commit_before>from os.path import dirname, join
from setuptools import setup, find_packages
version = '0.3'
def read(fname):
return open(join(dirname(__file__), fname)).read()
setup(name='django-apptemplates',
version=version,
description='Django template loader that allows you to load and'
'override a template from a specific Django application.',
long_description=read('README.rst'),
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Internet :: WWW/HTTP :: WSGI',
'Topic :: Software Development :: Libraries :: Application Frameworks', # noqa
'Topic :: Software Development :: Libraries :: Python Modules',
],
keywords='django templates',
author='Konrad Wojas',
author_email='konrad.wojas@jibecompany.com',
maintainer='Tomas Zulberti',
url='http://bitbucket.org/tzulberti/django-apptemplates/',
license='MIT License',
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=True,
zip_safe=False,
)
<commit_msg>Increase only minor in version number<commit_after>from os.path import dirname, join
from setuptools import setup, find_packages
version = '0.2.1'
def read(fname):
return open(join(dirname(__file__), fname)).read()
setup(name='django-apptemplates',
version=version,
description='Django template loader that allows you to load and'
'override a template from a specific Django application.',
long_description=read('README.rst'),
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Internet :: WWW/HTTP :: WSGI',
'Topic :: Software Development :: Libraries :: Application Frameworks', # noqa
'Topic :: Software Development :: Libraries :: Python Modules',
],
keywords='django templates',
author='Konrad Wojas',
author_email='konrad.wojas@jibecompany.com',
maintainer='Tomas Zulberti',
url='http://bitbucket.org/tzulberti/django-apptemplates/',
license='MIT License',
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=True,
zip_safe=False,
)
|
d96adde7fbb561719aeb101df01e8809a5a06ea7
|
src/model.py
|
src/model.py
|
from keras.models import Sequential
from keras.layers import Activation, TimeDistributed, Dense, RepeatVector, Embedding
from keras.layers.recurrent import LSTM
def get_model(X_vocab_len, X_max_len, y_vocab_len, y_max_len, hidden_size, num_layers):
model = Sequential()
# encoder
model.add(Embedding(X_vocab_len, 64, input_length=X_max_len, mask_zero=True))
model.add(LSTM(hidden_size))
model.add(RepeatVector(y_max_len))
# decoder
for _ in range(num_layers):
model.add(LSTM(hidden_size, return_sequences=True))
model.add(TimeDistributed(Dense(y_vocab_len)))
model.add(Activation('softmax'))
model.compile(loss='categorical_crossentropy',
optimizer='adam',
metrics=['accuracy'])
return model
|
from keras.models import Sequential
from keras.layers import Activation, TimeDistributed, Dense, RepeatVector, Embedding
from keras.layers.recurrent import LSTM
def get_model(X_vocab_len, X_max_len, y_vocab_len, y_max_len, hidden_size, num_layers):
model = Sequential()
# encoder
model.add(Embedding(X_vocab_len, 64, input_length=X_max_len, mask_zero=True))
model.add(LSTM(hidden_size))
model.add(LSTM(hidden_size))
model.add(RepeatVector(y_max_len))
# decoder
for _ in range(num_layers):
model.add(LSTM(hidden_size, return_sequences=True))
model.add(TimeDistributed(Dense(y_vocab_len)))
model.add(Activation('softmax'))
model.compile(loss='categorical_crossentropy',
optimizer='adam',
metrics=['accuracy'])
return model
|
Add one more lstm layer
|
Add one more lstm layer
|
Python
|
mit
|
vdragan1993/python-coder
|
from keras.models import Sequential
from keras.layers import Activation, TimeDistributed, Dense, RepeatVector, Embedding
from keras.layers.recurrent import LSTM
def get_model(X_vocab_len, X_max_len, y_vocab_len, y_max_len, hidden_size, num_layers):
model = Sequential()
# encoder
model.add(Embedding(X_vocab_len, 64, input_length=X_max_len, mask_zero=True))
model.add(LSTM(hidden_size))
model.add(RepeatVector(y_max_len))
# decoder
for _ in range(num_layers):
model.add(LSTM(hidden_size, return_sequences=True))
model.add(TimeDistributed(Dense(y_vocab_len)))
model.add(Activation('softmax'))
model.compile(loss='categorical_crossentropy',
optimizer='adam',
metrics=['accuracy'])
return model
Add one more lstm layer
|
from keras.models import Sequential
from keras.layers import Activation, TimeDistributed, Dense, RepeatVector, Embedding
from keras.layers.recurrent import LSTM
def get_model(X_vocab_len, X_max_len, y_vocab_len, y_max_len, hidden_size, num_layers):
model = Sequential()
# encoder
model.add(Embedding(X_vocab_len, 64, input_length=X_max_len, mask_zero=True))
model.add(LSTM(hidden_size))
model.add(LSTM(hidden_size))
model.add(RepeatVector(y_max_len))
# decoder
for _ in range(num_layers):
model.add(LSTM(hidden_size, return_sequences=True))
model.add(TimeDistributed(Dense(y_vocab_len)))
model.add(Activation('softmax'))
model.compile(loss='categorical_crossentropy',
optimizer='adam',
metrics=['accuracy'])
return model
|
<commit_before>from keras.models import Sequential
from keras.layers import Activation, TimeDistributed, Dense, RepeatVector, Embedding
from keras.layers.recurrent import LSTM
def get_model(X_vocab_len, X_max_len, y_vocab_len, y_max_len, hidden_size, num_layers):
model = Sequential()
# encoder
model.add(Embedding(X_vocab_len, 64, input_length=X_max_len, mask_zero=True))
model.add(LSTM(hidden_size))
model.add(RepeatVector(y_max_len))
# decoder
for _ in range(num_layers):
model.add(LSTM(hidden_size, return_sequences=True))
model.add(TimeDistributed(Dense(y_vocab_len)))
model.add(Activation('softmax'))
model.compile(loss='categorical_crossentropy',
optimizer='adam',
metrics=['accuracy'])
return model
<commit_msg>Add one more lstm layer<commit_after>
|
from keras.models import Sequential
from keras.layers import Activation, TimeDistributed, Dense, RepeatVector, Embedding
from keras.layers.recurrent import LSTM
def get_model(X_vocab_len, X_max_len, y_vocab_len, y_max_len, hidden_size, num_layers):
model = Sequential()
# encoder
model.add(Embedding(X_vocab_len, 64, input_length=X_max_len, mask_zero=True))
model.add(LSTM(hidden_size))
model.add(LSTM(hidden_size))
model.add(RepeatVector(y_max_len))
# decoder
for _ in range(num_layers):
model.add(LSTM(hidden_size, return_sequences=True))
model.add(TimeDistributed(Dense(y_vocab_len)))
model.add(Activation('softmax'))
model.compile(loss='categorical_crossentropy',
optimizer='adam',
metrics=['accuracy'])
return model
|
from keras.models import Sequential
from keras.layers import Activation, TimeDistributed, Dense, RepeatVector, Embedding
from keras.layers.recurrent import LSTM
def get_model(X_vocab_len, X_max_len, y_vocab_len, y_max_len, hidden_size, num_layers):
model = Sequential()
# encoder
model.add(Embedding(X_vocab_len, 64, input_length=X_max_len, mask_zero=True))
model.add(LSTM(hidden_size))
model.add(RepeatVector(y_max_len))
# decoder
for _ in range(num_layers):
model.add(LSTM(hidden_size, return_sequences=True))
model.add(TimeDistributed(Dense(y_vocab_len)))
model.add(Activation('softmax'))
model.compile(loss='categorical_crossentropy',
optimizer='adam',
metrics=['accuracy'])
return model
Add one more lstm layerfrom keras.models import Sequential
from keras.layers import Activation, TimeDistributed, Dense, RepeatVector, Embedding
from keras.layers.recurrent import LSTM
def get_model(X_vocab_len, X_max_len, y_vocab_len, y_max_len, hidden_size, num_layers):
model = Sequential()
# encoder
model.add(Embedding(X_vocab_len, 64, input_length=X_max_len, mask_zero=True))
model.add(LSTM(hidden_size))
model.add(LSTM(hidden_size))
model.add(RepeatVector(y_max_len))
# decoder
for _ in range(num_layers):
model.add(LSTM(hidden_size, return_sequences=True))
model.add(TimeDistributed(Dense(y_vocab_len)))
model.add(Activation('softmax'))
model.compile(loss='categorical_crossentropy',
optimizer='adam',
metrics=['accuracy'])
return model
|
<commit_before>from keras.models import Sequential
from keras.layers import Activation, TimeDistributed, Dense, RepeatVector, Embedding
from keras.layers.recurrent import LSTM
def get_model(X_vocab_len, X_max_len, y_vocab_len, y_max_len, hidden_size, num_layers):
model = Sequential()
# encoder
model.add(Embedding(X_vocab_len, 64, input_length=X_max_len, mask_zero=True))
model.add(LSTM(hidden_size))
model.add(RepeatVector(y_max_len))
# decoder
for _ in range(num_layers):
model.add(LSTM(hidden_size, return_sequences=True))
model.add(TimeDistributed(Dense(y_vocab_len)))
model.add(Activation('softmax'))
model.compile(loss='categorical_crossentropy',
optimizer='adam',
metrics=['accuracy'])
return model
<commit_msg>Add one more lstm layer<commit_after>from keras.models import Sequential
from keras.layers import Activation, TimeDistributed, Dense, RepeatVector, Embedding
from keras.layers.recurrent import LSTM
def get_model(X_vocab_len, X_max_len, y_vocab_len, y_max_len, hidden_size, num_layers):
model = Sequential()
# encoder
model.add(Embedding(X_vocab_len, 64, input_length=X_max_len, mask_zero=True))
model.add(LSTM(hidden_size))
model.add(LSTM(hidden_size))
model.add(RepeatVector(y_max_len))
# decoder
for _ in range(num_layers):
model.add(LSTM(hidden_size, return_sequences=True))
model.add(TimeDistributed(Dense(y_vocab_len)))
model.add(Activation('softmax'))
model.compile(loss='categorical_crossentropy',
optimizer='adam',
metrics=['accuracy'])
return model
|
e09fe37d78a94bcec284f65672a8892b73bb8a27
|
watchman/management/commands/watchman.py
|
watchman/management/commands/watchman.py
|
from __future__ import absolute_import
import json
from django.core.management.base import BaseCommand, CommandError
from watchman.utils import get_checks
class Command(BaseCommand):
help = 'Runs the default django-watchman checks'
def handle(self, *args, **options):
verbosity = options['verbosity']
print_all_checks = verbosity == '2' or verbosity == '3'
for check in get_checks():
if callable(check):
resp = json.dumps(check())
if '"ok": false' in resp:
raise CommandError(resp)
elif print_all_checks:
print resp
|
from __future__ import absolute_import
import json
from optparse import make_option
from django.core.management.base import BaseCommand, CommandError
from watchman.utils import get_checks
class Command(BaseCommand):
help = 'Runs the default django-watchman checks'
option_list = BaseCommand.option_list + (
make_option(
'-c',
'--checks',
dest='checks',
help='A comma-separated list of watchman checks to run (full python dotted paths)'
),
make_option(
'-s',
'--skips',
dest='skips',
help='A comma-separated list of watchman checks to skip (full python dotted paths)'
),
)
def handle(self, *args, **options):
check_list = None
skip_list = None
verbosity = options['verbosity']
print_all_checks = verbosity == '2' or verbosity == '3'
checks = options['checks']
skips = options['skips']
if checks is not None:
check_list = checks.split(',')
if skips is not None:
skip_list = skips.split(',')
for check in get_checks(check_list=check_list, skip_list=skip_list):
if callable(check):
resp = json.dumps(check())
if '"ok": false' in resp:
raise CommandError(resp)
elif print_all_checks:
print resp
|
Add check / skip ability to management command
|
23: Add check / skip ability to management command
* `-c`, `--checks`, `-s`, `--skips` options take comma-separated list of python paths to run / skip
|
Python
|
bsd-3-clause
|
blag/django-watchman,gerlachry/django-watchman,gerlachry/django-watchman,ulope/django-watchman,ulope/django-watchman,mwarkentin/django-watchman,blag/django-watchman,JBKahn/django-watchman,mwarkentin/django-watchman,JBKahn/django-watchman
|
from __future__ import absolute_import
import json
from django.core.management.base import BaseCommand, CommandError
from watchman.utils import get_checks
class Command(BaseCommand):
help = 'Runs the default django-watchman checks'
def handle(self, *args, **options):
verbosity = options['verbosity']
print_all_checks = verbosity == '2' or verbosity == '3'
for check in get_checks():
if callable(check):
resp = json.dumps(check())
if '"ok": false' in resp:
raise CommandError(resp)
elif print_all_checks:
print resp
23: Add check / skip ability to management command
* `-c`, `--checks`, `-s`, `--skips` options take comma-separated list of python paths to run / skip
|
from __future__ import absolute_import
import json
from optparse import make_option
from django.core.management.base import BaseCommand, CommandError
from watchman.utils import get_checks
class Command(BaseCommand):
help = 'Runs the default django-watchman checks'
option_list = BaseCommand.option_list + (
make_option(
'-c',
'--checks',
dest='checks',
help='A comma-separated list of watchman checks to run (full python dotted paths)'
),
make_option(
'-s',
'--skips',
dest='skips',
help='A comma-separated list of watchman checks to skip (full python dotted paths)'
),
)
def handle(self, *args, **options):
check_list = None
skip_list = None
verbosity = options['verbosity']
print_all_checks = verbosity == '2' or verbosity == '3'
checks = options['checks']
skips = options['skips']
if checks is not None:
check_list = checks.split(',')
if skips is not None:
skip_list = skips.split(',')
for check in get_checks(check_list=check_list, skip_list=skip_list):
if callable(check):
resp = json.dumps(check())
if '"ok": false' in resp:
raise CommandError(resp)
elif print_all_checks:
print resp
|
<commit_before>from __future__ import absolute_import
import json
from django.core.management.base import BaseCommand, CommandError
from watchman.utils import get_checks
class Command(BaseCommand):
help = 'Runs the default django-watchman checks'
def handle(self, *args, **options):
verbosity = options['verbosity']
print_all_checks = verbosity == '2' or verbosity == '3'
for check in get_checks():
if callable(check):
resp = json.dumps(check())
if '"ok": false' in resp:
raise CommandError(resp)
elif print_all_checks:
print resp
<commit_msg>23: Add check / skip ability to management command
* `-c`, `--checks`, `-s`, `--skips` options take comma-separated list of python paths to run / skip<commit_after>
|
from __future__ import absolute_import
import json
from optparse import make_option
from django.core.management.base import BaseCommand, CommandError
from watchman.utils import get_checks
class Command(BaseCommand):
help = 'Runs the default django-watchman checks'
option_list = BaseCommand.option_list + (
make_option(
'-c',
'--checks',
dest='checks',
help='A comma-separated list of watchman checks to run (full python dotted paths)'
),
make_option(
'-s',
'--skips',
dest='skips',
help='A comma-separated list of watchman checks to skip (full python dotted paths)'
),
)
def handle(self, *args, **options):
check_list = None
skip_list = None
verbosity = options['verbosity']
print_all_checks = verbosity == '2' or verbosity == '3'
checks = options['checks']
skips = options['skips']
if checks is not None:
check_list = checks.split(',')
if skips is not None:
skip_list = skips.split(',')
for check in get_checks(check_list=check_list, skip_list=skip_list):
if callable(check):
resp = json.dumps(check())
if '"ok": false' in resp:
raise CommandError(resp)
elif print_all_checks:
print resp
|
from __future__ import absolute_import
import json
from django.core.management.base import BaseCommand, CommandError
from watchman.utils import get_checks
class Command(BaseCommand):
help = 'Runs the default django-watchman checks'
def handle(self, *args, **options):
verbosity = options['verbosity']
print_all_checks = verbosity == '2' or verbosity == '3'
for check in get_checks():
if callable(check):
resp = json.dumps(check())
if '"ok": false' in resp:
raise CommandError(resp)
elif print_all_checks:
print resp
23: Add check / skip ability to management command
* `-c`, `--checks`, `-s`, `--skips` options take comma-separated list of python paths to run / skipfrom __future__ import absolute_import
import json
from optparse import make_option
from django.core.management.base import BaseCommand, CommandError
from watchman.utils import get_checks
class Command(BaseCommand):
help = 'Runs the default django-watchman checks'
option_list = BaseCommand.option_list + (
make_option(
'-c',
'--checks',
dest='checks',
help='A comma-separated list of watchman checks to run (full python dotted paths)'
),
make_option(
'-s',
'--skips',
dest='skips',
help='A comma-separated list of watchman checks to skip (full python dotted paths)'
),
)
def handle(self, *args, **options):
check_list = None
skip_list = None
verbosity = options['verbosity']
print_all_checks = verbosity == '2' or verbosity == '3'
checks = options['checks']
skips = options['skips']
if checks is not None:
check_list = checks.split(',')
if skips is not None:
skip_list = skips.split(',')
for check in get_checks(check_list=check_list, skip_list=skip_list):
if callable(check):
resp = json.dumps(check())
if '"ok": false' in resp:
raise CommandError(resp)
elif print_all_checks:
print resp
|
<commit_before>from __future__ import absolute_import
import json
from django.core.management.base import BaseCommand, CommandError
from watchman.utils import get_checks
class Command(BaseCommand):
help = 'Runs the default django-watchman checks'
def handle(self, *args, **options):
verbosity = options['verbosity']
print_all_checks = verbosity == '2' or verbosity == '3'
for check in get_checks():
if callable(check):
resp = json.dumps(check())
if '"ok": false' in resp:
raise CommandError(resp)
elif print_all_checks:
print resp
<commit_msg>23: Add check / skip ability to management command
* `-c`, `--checks`, `-s`, `--skips` options take comma-separated list of python paths to run / skip<commit_after>from __future__ import absolute_import
import json
from optparse import make_option
from django.core.management.base import BaseCommand, CommandError
from watchman.utils import get_checks
class Command(BaseCommand):
help = 'Runs the default django-watchman checks'
option_list = BaseCommand.option_list + (
make_option(
'-c',
'--checks',
dest='checks',
help='A comma-separated list of watchman checks to run (full python dotted paths)'
),
make_option(
'-s',
'--skips',
dest='skips',
help='A comma-separated list of watchman checks to skip (full python dotted paths)'
),
)
def handle(self, *args, **options):
check_list = None
skip_list = None
verbosity = options['verbosity']
print_all_checks = verbosity == '2' or verbosity == '3'
checks = options['checks']
skips = options['skips']
if checks is not None:
check_list = checks.split(',')
if skips is not None:
skip_list = skips.split(',')
for check in get_checks(check_list=check_list, skip_list=skip_list):
if callable(check):
resp = json.dumps(check())
if '"ok": false' in resp:
raise CommandError(resp)
elif print_all_checks:
print resp
|
0c3529bd264d5512e31d828c65676baff6edefa6
|
pinax/waitinglist/templatetags/pinax_waitinglist_tags.py
|
pinax/waitinglist/templatetags/pinax_waitinglist_tags.py
|
from django import template
from ..forms import WaitingListEntryForm
register = template.Library()
@register.assignment_tag
def waitinglist_entry_form():
"""
Get a (new) form object to post a new comment.
Syntax::
{% waitinglist_entry_form as [varname] %}
"""
return WaitingListEntryForm()
|
from django import template
from ..forms import WaitingListEntryForm
register = template.Library()
@register.simple_tag(takes_context=True)
def waitinglist_entry_form(context):
"""
Get a (new) form object to post a new comment.
Syntax::
{% waitinglist_entry_form as [varname] %}
"""
initial = {}
if "request" in context:
initial.update({
"referrer": context["request"].META.get("HTTP_REFERER", ""),
"campaign": context["request"].GET.get("wlc", "")
})
return WaitingListEntryForm(initial=initial)
|
Update template tag to also take context
|
Update template tag to also take context
|
Python
|
mit
|
pinax/pinax-waitinglist,pinax/pinax-waitinglist
|
from django import template
from ..forms import WaitingListEntryForm
register = template.Library()
@register.assignment_tag
def waitinglist_entry_form():
"""
Get a (new) form object to post a new comment.
Syntax::
{% waitinglist_entry_form as [varname] %}
"""
return WaitingListEntryForm()
Update template tag to also take context
|
from django import template
from ..forms import WaitingListEntryForm
register = template.Library()
@register.simple_tag(takes_context=True)
def waitinglist_entry_form(context):
"""
Get a (new) form object to post a new comment.
Syntax::
{% waitinglist_entry_form as [varname] %}
"""
initial = {}
if "request" in context:
initial.update({
"referrer": context["request"].META.get("HTTP_REFERER", ""),
"campaign": context["request"].GET.get("wlc", "")
})
return WaitingListEntryForm(initial=initial)
|
<commit_before>from django import template
from ..forms import WaitingListEntryForm
register = template.Library()
@register.assignment_tag
def waitinglist_entry_form():
"""
Get a (new) form object to post a new comment.
Syntax::
{% waitinglist_entry_form as [varname] %}
"""
return WaitingListEntryForm()
<commit_msg>Update template tag to also take context<commit_after>
|
from django import template
from ..forms import WaitingListEntryForm
register = template.Library()
@register.simple_tag(takes_context=True)
def waitinglist_entry_form(context):
"""
Get a (new) form object to post a new comment.
Syntax::
{% waitinglist_entry_form as [varname] %}
"""
initial = {}
if "request" in context:
initial.update({
"referrer": context["request"].META.get("HTTP_REFERER", ""),
"campaign": context["request"].GET.get("wlc", "")
})
return WaitingListEntryForm(initial=initial)
|
from django import template
from ..forms import WaitingListEntryForm
register = template.Library()
@register.assignment_tag
def waitinglist_entry_form():
"""
Get a (new) form object to post a new comment.
Syntax::
{% waitinglist_entry_form as [varname] %}
"""
return WaitingListEntryForm()
Update template tag to also take contextfrom django import template
from ..forms import WaitingListEntryForm
register = template.Library()
@register.simple_tag(takes_context=True)
def waitinglist_entry_form(context):
"""
Get a (new) form object to post a new comment.
Syntax::
{% waitinglist_entry_form as [varname] %}
"""
initial = {}
if "request" in context:
initial.update({
"referrer": context["request"].META.get("HTTP_REFERER", ""),
"campaign": context["request"].GET.get("wlc", "")
})
return WaitingListEntryForm(initial=initial)
|
<commit_before>from django import template
from ..forms import WaitingListEntryForm
register = template.Library()
@register.assignment_tag
def waitinglist_entry_form():
"""
Get a (new) form object to post a new comment.
Syntax::
{% waitinglist_entry_form as [varname] %}
"""
return WaitingListEntryForm()
<commit_msg>Update template tag to also take context<commit_after>from django import template
from ..forms import WaitingListEntryForm
register = template.Library()
@register.simple_tag(takes_context=True)
def waitinglist_entry_form(context):
"""
Get a (new) form object to post a new comment.
Syntax::
{% waitinglist_entry_form as [varname] %}
"""
initial = {}
if "request" in context:
initial.update({
"referrer": context["request"].META.get("HTTP_REFERER", ""),
"campaign": context["request"].GET.get("wlc", "")
})
return WaitingListEntryForm(initial=initial)
|
7698a548102fae9d801cf2a5cb94163d8e4a39f2
|
kolla_mesos/tests/base.py
|
kolla_mesos/tests/base.py
|
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
import contextlib
from oslotest import base
import six
import testscenarios
# Python 3, thank you for dropping contextlib.nested
if six.PY3:
@contextlib.contextmanager
def nested(*contexts):
with contextlib.ExitStack() as stack:
yield [stack.enter_context(c) for c in contexts]
else:
nested = contextlib.nested
class BaseTestCase(testscenarios.WithScenarios,
base.BaseTestCase):
"""Test case base class for all unit tests."""
|
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
import contextlib
from oslo_config import cfg
from oslotest import base
import six
import testscenarios
# Python 3, thank you for dropping contextlib.nested
if six.PY3:
@contextlib.contextmanager
def nested(*contexts):
with contextlib.ExitStack() as stack:
yield [stack.enter_context(c) for c in contexts]
else:
nested = contextlib.nested
class BaseTestCase(testscenarios.WithScenarios,
base.BaseTestCase):
"""Test case base class for all unit tests."""
def setUp(self):
super(BaseTestCase, self).setUp()
self.addCleanup(cfg.CONF.reset)
|
Make sure any config overrides are reset
|
Make sure any config overrides are reset
The new deploy unit tests have conf.set_override() but
don't reset these after each test, so depending on the
test order there are failures.
This just addes a generic cleanup in the base class to catch
all of them.
Change-Id: Idb1b4ef158808b08657f34bfe1546fa2ec0dae9f
|
Python
|
apache-2.0
|
asalkeld/kolla-mesos,openstack/kolla-mesos,openstack/kolla-mesos,openstack/kolla-mesos
|
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
import contextlib
from oslotest import base
import six
import testscenarios
# Python 3, thank you for dropping contextlib.nested
if six.PY3:
@contextlib.contextmanager
def nested(*contexts):
with contextlib.ExitStack() as stack:
yield [stack.enter_context(c) for c in contexts]
else:
nested = contextlib.nested
class BaseTestCase(testscenarios.WithScenarios,
base.BaseTestCase):
"""Test case base class for all unit tests."""
Make sure any config overrides are reset
The new deploy unit tests have conf.set_override() but
don't reset these after each test, so depending on the
test order there are failures.
This just addes a generic cleanup in the base class to catch
all of them.
Change-Id: Idb1b4ef158808b08657f34bfe1546fa2ec0dae9f
|
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
import contextlib
from oslo_config import cfg
from oslotest import base
import six
import testscenarios
# Python 3, thank you for dropping contextlib.nested
if six.PY3:
@contextlib.contextmanager
def nested(*contexts):
with contextlib.ExitStack() as stack:
yield [stack.enter_context(c) for c in contexts]
else:
nested = contextlib.nested
class BaseTestCase(testscenarios.WithScenarios,
base.BaseTestCase):
"""Test case base class for all unit tests."""
def setUp(self):
super(BaseTestCase, self).setUp()
self.addCleanup(cfg.CONF.reset)
|
<commit_before># 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, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
import contextlib
from oslotest import base
import six
import testscenarios
# Python 3, thank you for dropping contextlib.nested
if six.PY3:
@contextlib.contextmanager
def nested(*contexts):
with contextlib.ExitStack() as stack:
yield [stack.enter_context(c) for c in contexts]
else:
nested = contextlib.nested
class BaseTestCase(testscenarios.WithScenarios,
base.BaseTestCase):
"""Test case base class for all unit tests."""
<commit_msg>Make sure any config overrides are reset
The new deploy unit tests have conf.set_override() but
don't reset these after each test, so depending on the
test order there are failures.
This just addes a generic cleanup in the base class to catch
all of them.
Change-Id: Idb1b4ef158808b08657f34bfe1546fa2ec0dae9f<commit_after>
|
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
import contextlib
from oslo_config import cfg
from oslotest import base
import six
import testscenarios
# Python 3, thank you for dropping contextlib.nested
if six.PY3:
@contextlib.contextmanager
def nested(*contexts):
with contextlib.ExitStack() as stack:
yield [stack.enter_context(c) for c in contexts]
else:
nested = contextlib.nested
class BaseTestCase(testscenarios.WithScenarios,
base.BaseTestCase):
"""Test case base class for all unit tests."""
def setUp(self):
super(BaseTestCase, self).setUp()
self.addCleanup(cfg.CONF.reset)
|
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
import contextlib
from oslotest import base
import six
import testscenarios
# Python 3, thank you for dropping contextlib.nested
if six.PY3:
@contextlib.contextmanager
def nested(*contexts):
with contextlib.ExitStack() as stack:
yield [stack.enter_context(c) for c in contexts]
else:
nested = contextlib.nested
class BaseTestCase(testscenarios.WithScenarios,
base.BaseTestCase):
"""Test case base class for all unit tests."""
Make sure any config overrides are reset
The new deploy unit tests have conf.set_override() but
don't reset these after each test, so depending on the
test order there are failures.
This just addes a generic cleanup in the base class to catch
all of them.
Change-Id: Idb1b4ef158808b08657f34bfe1546fa2ec0dae9f# 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, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
import contextlib
from oslo_config import cfg
from oslotest import base
import six
import testscenarios
# Python 3, thank you for dropping contextlib.nested
if six.PY3:
@contextlib.contextmanager
def nested(*contexts):
with contextlib.ExitStack() as stack:
yield [stack.enter_context(c) for c in contexts]
else:
nested = contextlib.nested
class BaseTestCase(testscenarios.WithScenarios,
base.BaseTestCase):
"""Test case base class for all unit tests."""
def setUp(self):
super(BaseTestCase, self).setUp()
self.addCleanup(cfg.CONF.reset)
|
<commit_before># 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, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
import contextlib
from oslotest import base
import six
import testscenarios
# Python 3, thank you for dropping contextlib.nested
if six.PY3:
@contextlib.contextmanager
def nested(*contexts):
with contextlib.ExitStack() as stack:
yield [stack.enter_context(c) for c in contexts]
else:
nested = contextlib.nested
class BaseTestCase(testscenarios.WithScenarios,
base.BaseTestCase):
"""Test case base class for all unit tests."""
<commit_msg>Make sure any config overrides are reset
The new deploy unit tests have conf.set_override() but
don't reset these after each test, so depending on the
test order there are failures.
This just addes a generic cleanup in the base class to catch
all of them.
Change-Id: Idb1b4ef158808b08657f34bfe1546fa2ec0dae9f<commit_after># 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, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
import contextlib
from oslo_config import cfg
from oslotest import base
import six
import testscenarios
# Python 3, thank you for dropping contextlib.nested
if six.PY3:
@contextlib.contextmanager
def nested(*contexts):
with contextlib.ExitStack() as stack:
yield [stack.enter_context(c) for c in contexts]
else:
nested = contextlib.nested
class BaseTestCase(testscenarios.WithScenarios,
base.BaseTestCase):
"""Test case base class for all unit tests."""
def setUp(self):
super(BaseTestCase, self).setUp()
self.addCleanup(cfg.CONF.reset)
|
116d9565050ad69888cb38c302f8ae0d9232eec3
|
gameserver/utils.py
|
gameserver/utils.py
|
import random as orig_random
from decorator import decorator
import binascii
import struct
import hashlib
from gameserver.database import db
db_session = db.session
random = orig_random.Random()
random.seed()
def node_to_dict(node):
connections = []
for edge in node.lower_edges:
connections.append(
{"to_id": edge.higher_node.id,
"from_id": node.id,
"weight": "{:.2f}".format(edge.weight),
}
)
data = {"id": node.id,
"name": node.name,
"short_name": node.short_name,
"group": node.group,
"leakage": "{:.2f}".format(node.leak),
"max_amount": "{:.2f}".format(node.max_level),
"activation_amount": "{:.2f}".format(node.activation),
"balance": "{:.2f}".format(node.balance),
"connections": connections
}
return data
def pack_amount(value):
return binascii.hexlify(struct.pack("f", value)).decode('ascii')
def unpack_amount(value):
return struct.unpack("f", binascii.unhexlify(value))[0]
def checksum(seller_id, policy_id, price, salt):
input = "{}{}{}{}".format(seller_id, policy_id, pack_amount(price), salt)
return hashlib.sha1(input).hexdigest()
|
import random as orig_random
from decorator import decorator
import binascii
import struct
import hashlib
from gameserver.database import db
db_session = db.session
random = orig_random.Random()
random.seed()
def node_to_dict(node):
connections = []
for edge in node.lower_edges:
connections.append(
{"to_id": edge.higher_node.id,
"from_id": node.id,
"weight": "{:.2f}".format(edge.weight),
}
)
data = {"id": node.id,
"name": node.name,
"short_name": node.short_name,
"group": node.group,
"leakage": "{:.2f}".format(node.leak),
"max_amount": "{:.2f}".format(node.max_level),
"activation_amount": "{:.2f}".format(node.activation),
"active_level": "{:.2f}".format(node.active_level),
"balance": "{:.2f}".format(node.balance),
"connections": connections
}
return data
def pack_amount(value):
return binascii.hexlify(struct.pack("f", value)).decode('ascii')
def unpack_amount(value):
return struct.unpack("f", binascii.unhexlify(value))[0]
def checksum(seller_id, policy_id, price, salt):
input = "{}{}{}{}".format(seller_id, policy_id, pack_amount(price), salt)
return hashlib.sha1(input).hexdigest()
|
Add in the active level to json output for the mobile game to use
|
Add in the active level to json output for the mobile game to use
|
Python
|
apache-2.0
|
hammertoe/didactic-spork,hammertoe/didactic-spork,hammertoe/didactic-spork,hammertoe/didactic-spork
|
import random as orig_random
from decorator import decorator
import binascii
import struct
import hashlib
from gameserver.database import db
db_session = db.session
random = orig_random.Random()
random.seed()
def node_to_dict(node):
connections = []
for edge in node.lower_edges:
connections.append(
{"to_id": edge.higher_node.id,
"from_id": node.id,
"weight": "{:.2f}".format(edge.weight),
}
)
data = {"id": node.id,
"name": node.name,
"short_name": node.short_name,
"group": node.group,
"leakage": "{:.2f}".format(node.leak),
"max_amount": "{:.2f}".format(node.max_level),
"activation_amount": "{:.2f}".format(node.activation),
"balance": "{:.2f}".format(node.balance),
"connections": connections
}
return data
def pack_amount(value):
return binascii.hexlify(struct.pack("f", value)).decode('ascii')
def unpack_amount(value):
return struct.unpack("f", binascii.unhexlify(value))[0]
def checksum(seller_id, policy_id, price, salt):
input = "{}{}{}{}".format(seller_id, policy_id, pack_amount(price), salt)
return hashlib.sha1(input).hexdigest()
Add in the active level to json output for the mobile game to use
|
import random as orig_random
from decorator import decorator
import binascii
import struct
import hashlib
from gameserver.database import db
db_session = db.session
random = orig_random.Random()
random.seed()
def node_to_dict(node):
connections = []
for edge in node.lower_edges:
connections.append(
{"to_id": edge.higher_node.id,
"from_id": node.id,
"weight": "{:.2f}".format(edge.weight),
}
)
data = {"id": node.id,
"name": node.name,
"short_name": node.short_name,
"group": node.group,
"leakage": "{:.2f}".format(node.leak),
"max_amount": "{:.2f}".format(node.max_level),
"activation_amount": "{:.2f}".format(node.activation),
"active_level": "{:.2f}".format(node.active_level),
"balance": "{:.2f}".format(node.balance),
"connections": connections
}
return data
def pack_amount(value):
return binascii.hexlify(struct.pack("f", value)).decode('ascii')
def unpack_amount(value):
return struct.unpack("f", binascii.unhexlify(value))[0]
def checksum(seller_id, policy_id, price, salt):
input = "{}{}{}{}".format(seller_id, policy_id, pack_amount(price), salt)
return hashlib.sha1(input).hexdigest()
|
<commit_before>import random as orig_random
from decorator import decorator
import binascii
import struct
import hashlib
from gameserver.database import db
db_session = db.session
random = orig_random.Random()
random.seed()
def node_to_dict(node):
connections = []
for edge in node.lower_edges:
connections.append(
{"to_id": edge.higher_node.id,
"from_id": node.id,
"weight": "{:.2f}".format(edge.weight),
}
)
data = {"id": node.id,
"name": node.name,
"short_name": node.short_name,
"group": node.group,
"leakage": "{:.2f}".format(node.leak),
"max_amount": "{:.2f}".format(node.max_level),
"activation_amount": "{:.2f}".format(node.activation),
"balance": "{:.2f}".format(node.balance),
"connections": connections
}
return data
def pack_amount(value):
return binascii.hexlify(struct.pack("f", value)).decode('ascii')
def unpack_amount(value):
return struct.unpack("f", binascii.unhexlify(value))[0]
def checksum(seller_id, policy_id, price, salt):
input = "{}{}{}{}".format(seller_id, policy_id, pack_amount(price), salt)
return hashlib.sha1(input).hexdigest()
<commit_msg>Add in the active level to json output for the mobile game to use<commit_after>
|
import random as orig_random
from decorator import decorator
import binascii
import struct
import hashlib
from gameserver.database import db
db_session = db.session
random = orig_random.Random()
random.seed()
def node_to_dict(node):
connections = []
for edge in node.lower_edges:
connections.append(
{"to_id": edge.higher_node.id,
"from_id": node.id,
"weight": "{:.2f}".format(edge.weight),
}
)
data = {"id": node.id,
"name": node.name,
"short_name": node.short_name,
"group": node.group,
"leakage": "{:.2f}".format(node.leak),
"max_amount": "{:.2f}".format(node.max_level),
"activation_amount": "{:.2f}".format(node.activation),
"active_level": "{:.2f}".format(node.active_level),
"balance": "{:.2f}".format(node.balance),
"connections": connections
}
return data
def pack_amount(value):
return binascii.hexlify(struct.pack("f", value)).decode('ascii')
def unpack_amount(value):
return struct.unpack("f", binascii.unhexlify(value))[0]
def checksum(seller_id, policy_id, price, salt):
input = "{}{}{}{}".format(seller_id, policy_id, pack_amount(price), salt)
return hashlib.sha1(input).hexdigest()
|
import random as orig_random
from decorator import decorator
import binascii
import struct
import hashlib
from gameserver.database import db
db_session = db.session
random = orig_random.Random()
random.seed()
def node_to_dict(node):
connections = []
for edge in node.lower_edges:
connections.append(
{"to_id": edge.higher_node.id,
"from_id": node.id,
"weight": "{:.2f}".format(edge.weight),
}
)
data = {"id": node.id,
"name": node.name,
"short_name": node.short_name,
"group": node.group,
"leakage": "{:.2f}".format(node.leak),
"max_amount": "{:.2f}".format(node.max_level),
"activation_amount": "{:.2f}".format(node.activation),
"balance": "{:.2f}".format(node.balance),
"connections": connections
}
return data
def pack_amount(value):
return binascii.hexlify(struct.pack("f", value)).decode('ascii')
def unpack_amount(value):
return struct.unpack("f", binascii.unhexlify(value))[0]
def checksum(seller_id, policy_id, price, salt):
input = "{}{}{}{}".format(seller_id, policy_id, pack_amount(price), salt)
return hashlib.sha1(input).hexdigest()
Add in the active level to json output for the mobile game to useimport random as orig_random
from decorator import decorator
import binascii
import struct
import hashlib
from gameserver.database import db
db_session = db.session
random = orig_random.Random()
random.seed()
def node_to_dict(node):
connections = []
for edge in node.lower_edges:
connections.append(
{"to_id": edge.higher_node.id,
"from_id": node.id,
"weight": "{:.2f}".format(edge.weight),
}
)
data = {"id": node.id,
"name": node.name,
"short_name": node.short_name,
"group": node.group,
"leakage": "{:.2f}".format(node.leak),
"max_amount": "{:.2f}".format(node.max_level),
"activation_amount": "{:.2f}".format(node.activation),
"active_level": "{:.2f}".format(node.active_level),
"balance": "{:.2f}".format(node.balance),
"connections": connections
}
return data
def pack_amount(value):
return binascii.hexlify(struct.pack("f", value)).decode('ascii')
def unpack_amount(value):
return struct.unpack("f", binascii.unhexlify(value))[0]
def checksum(seller_id, policy_id, price, salt):
input = "{}{}{}{}".format(seller_id, policy_id, pack_amount(price), salt)
return hashlib.sha1(input).hexdigest()
|
<commit_before>import random as orig_random
from decorator import decorator
import binascii
import struct
import hashlib
from gameserver.database import db
db_session = db.session
random = orig_random.Random()
random.seed()
def node_to_dict(node):
connections = []
for edge in node.lower_edges:
connections.append(
{"to_id": edge.higher_node.id,
"from_id": node.id,
"weight": "{:.2f}".format(edge.weight),
}
)
data = {"id": node.id,
"name": node.name,
"short_name": node.short_name,
"group": node.group,
"leakage": "{:.2f}".format(node.leak),
"max_amount": "{:.2f}".format(node.max_level),
"activation_amount": "{:.2f}".format(node.activation),
"balance": "{:.2f}".format(node.balance),
"connections": connections
}
return data
def pack_amount(value):
return binascii.hexlify(struct.pack("f", value)).decode('ascii')
def unpack_amount(value):
return struct.unpack("f", binascii.unhexlify(value))[0]
def checksum(seller_id, policy_id, price, salt):
input = "{}{}{}{}".format(seller_id, policy_id, pack_amount(price), salt)
return hashlib.sha1(input).hexdigest()
<commit_msg>Add in the active level to json output for the mobile game to use<commit_after>import random as orig_random
from decorator import decorator
import binascii
import struct
import hashlib
from gameserver.database import db
db_session = db.session
random = orig_random.Random()
random.seed()
def node_to_dict(node):
connections = []
for edge in node.lower_edges:
connections.append(
{"to_id": edge.higher_node.id,
"from_id": node.id,
"weight": "{:.2f}".format(edge.weight),
}
)
data = {"id": node.id,
"name": node.name,
"short_name": node.short_name,
"group": node.group,
"leakage": "{:.2f}".format(node.leak),
"max_amount": "{:.2f}".format(node.max_level),
"activation_amount": "{:.2f}".format(node.activation),
"active_level": "{:.2f}".format(node.active_level),
"balance": "{:.2f}".format(node.balance),
"connections": connections
}
return data
def pack_amount(value):
return binascii.hexlify(struct.pack("f", value)).decode('ascii')
def unpack_amount(value):
return struct.unpack("f", binascii.unhexlify(value))[0]
def checksum(seller_id, policy_id, price, salt):
input = "{}{}{}{}".format(seller_id, policy_id, pack_amount(price), salt)
return hashlib.sha1(input).hexdigest()
|
a5c0efec6c00118fd4df8163b76e5ecca4355adb
|
setup.py
|
setup.py
|
import sys
from setuptools import setup
from setuptools.command.test import test as TestCommand
class PyTest(TestCommand):
def finalize_options(self):
TestCommand.finalize_options(self)
self.test_args = []
self.test_suite = True
def run_tests(self):
#import here, cause outside the eggs aren't loaded
import pytest
sys.exit(pytest.main(self.test_args))
setup(
name="Flask-Redistore",
version="1.0",
url="",
license="BSD",
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
description="Adds Redis support to your Flask applications",
long_description=open("README.rst").read(),
py_modules=["flask_redistore"],
zip_safe=False,
include_package_data=True,
platforms="any",
install_requires=[
"Flask",
"redis",
],
extras_require={"tests": ["pytest"]},
tests_require=["pytest"],
classifiers=[
'Environment :: Web Environment',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Software Development :: Libraries :: Python Modules'
],
cmdclass={"test": PyTest},
)
|
import sys
from setuptools import setup
from setuptools.command.test import test as TestCommand
class PyTest(TestCommand):
def finalize_options(self):
TestCommand.finalize_options(self)
self.test_args = []
self.test_suite = True
def run_tests(self):
#import here, cause outside the eggs aren't loaded
import pytest
sys.exit(pytest.main(self.test_args))
setup(
name="Flask-Redistore",
version="1.0",
url="",
license="BSD",
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
description="Adds Redis support to your Flask applications",
long_description=open("README.rst").read(),
py_modules=["flask_redistore"],
zip_safe=False,
include_package_data=True,
platforms="any",
install_requires=[
"Flask",
"redis",
],
extras_require={"tests": ["pytest", "pretend"]},
tests_require=["pytest", "pretend"],
classifiers=[
'Environment :: Web Environment',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Software Development :: Libraries :: Python Modules'
],
cmdclass={"test": PyTest},
)
|
Add pretend to the test requirements
|
Add pretend to the test requirements
|
Python
|
bsd-2-clause
|
dstufft/Flask-Redistore
|
import sys
from setuptools import setup
from setuptools.command.test import test as TestCommand
class PyTest(TestCommand):
def finalize_options(self):
TestCommand.finalize_options(self)
self.test_args = []
self.test_suite = True
def run_tests(self):
#import here, cause outside the eggs aren't loaded
import pytest
sys.exit(pytest.main(self.test_args))
setup(
name="Flask-Redistore",
version="1.0",
url="",
license="BSD",
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
description="Adds Redis support to your Flask applications",
long_description=open("README.rst").read(),
py_modules=["flask_redistore"],
zip_safe=False,
include_package_data=True,
platforms="any",
install_requires=[
"Flask",
"redis",
],
extras_require={"tests": ["pytest"]},
tests_require=["pytest"],
classifiers=[
'Environment :: Web Environment',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Software Development :: Libraries :: Python Modules'
],
cmdclass={"test": PyTest},
)
Add pretend to the test requirements
|
import sys
from setuptools import setup
from setuptools.command.test import test as TestCommand
class PyTest(TestCommand):
def finalize_options(self):
TestCommand.finalize_options(self)
self.test_args = []
self.test_suite = True
def run_tests(self):
#import here, cause outside the eggs aren't loaded
import pytest
sys.exit(pytest.main(self.test_args))
setup(
name="Flask-Redistore",
version="1.0",
url="",
license="BSD",
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
description="Adds Redis support to your Flask applications",
long_description=open("README.rst").read(),
py_modules=["flask_redistore"],
zip_safe=False,
include_package_data=True,
platforms="any",
install_requires=[
"Flask",
"redis",
],
extras_require={"tests": ["pytest", "pretend"]},
tests_require=["pytest", "pretend"],
classifiers=[
'Environment :: Web Environment',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Software Development :: Libraries :: Python Modules'
],
cmdclass={"test": PyTest},
)
|
<commit_before>import sys
from setuptools import setup
from setuptools.command.test import test as TestCommand
class PyTest(TestCommand):
def finalize_options(self):
TestCommand.finalize_options(self)
self.test_args = []
self.test_suite = True
def run_tests(self):
#import here, cause outside the eggs aren't loaded
import pytest
sys.exit(pytest.main(self.test_args))
setup(
name="Flask-Redistore",
version="1.0",
url="",
license="BSD",
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
description="Adds Redis support to your Flask applications",
long_description=open("README.rst").read(),
py_modules=["flask_redistore"],
zip_safe=False,
include_package_data=True,
platforms="any",
install_requires=[
"Flask",
"redis",
],
extras_require={"tests": ["pytest"]},
tests_require=["pytest"],
classifiers=[
'Environment :: Web Environment',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Software Development :: Libraries :: Python Modules'
],
cmdclass={"test": PyTest},
)
<commit_msg>Add pretend to the test requirements<commit_after>
|
import sys
from setuptools import setup
from setuptools.command.test import test as TestCommand
class PyTest(TestCommand):
def finalize_options(self):
TestCommand.finalize_options(self)
self.test_args = []
self.test_suite = True
def run_tests(self):
#import here, cause outside the eggs aren't loaded
import pytest
sys.exit(pytest.main(self.test_args))
setup(
name="Flask-Redistore",
version="1.0",
url="",
license="BSD",
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
description="Adds Redis support to your Flask applications",
long_description=open("README.rst").read(),
py_modules=["flask_redistore"],
zip_safe=False,
include_package_data=True,
platforms="any",
install_requires=[
"Flask",
"redis",
],
extras_require={"tests": ["pytest", "pretend"]},
tests_require=["pytest", "pretend"],
classifiers=[
'Environment :: Web Environment',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Software Development :: Libraries :: Python Modules'
],
cmdclass={"test": PyTest},
)
|
import sys
from setuptools import setup
from setuptools.command.test import test as TestCommand
class PyTest(TestCommand):
def finalize_options(self):
TestCommand.finalize_options(self)
self.test_args = []
self.test_suite = True
def run_tests(self):
#import here, cause outside the eggs aren't loaded
import pytest
sys.exit(pytest.main(self.test_args))
setup(
name="Flask-Redistore",
version="1.0",
url="",
license="BSD",
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
description="Adds Redis support to your Flask applications",
long_description=open("README.rst").read(),
py_modules=["flask_redistore"],
zip_safe=False,
include_package_data=True,
platforms="any",
install_requires=[
"Flask",
"redis",
],
extras_require={"tests": ["pytest"]},
tests_require=["pytest"],
classifiers=[
'Environment :: Web Environment',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Software Development :: Libraries :: Python Modules'
],
cmdclass={"test": PyTest},
)
Add pretend to the test requirementsimport sys
from setuptools import setup
from setuptools.command.test import test as TestCommand
class PyTest(TestCommand):
def finalize_options(self):
TestCommand.finalize_options(self)
self.test_args = []
self.test_suite = True
def run_tests(self):
#import here, cause outside the eggs aren't loaded
import pytest
sys.exit(pytest.main(self.test_args))
setup(
name="Flask-Redistore",
version="1.0",
url="",
license="BSD",
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
description="Adds Redis support to your Flask applications",
long_description=open("README.rst").read(),
py_modules=["flask_redistore"],
zip_safe=False,
include_package_data=True,
platforms="any",
install_requires=[
"Flask",
"redis",
],
extras_require={"tests": ["pytest", "pretend"]},
tests_require=["pytest", "pretend"],
classifiers=[
'Environment :: Web Environment',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Software Development :: Libraries :: Python Modules'
],
cmdclass={"test": PyTest},
)
|
<commit_before>import sys
from setuptools import setup
from setuptools.command.test import test as TestCommand
class PyTest(TestCommand):
def finalize_options(self):
TestCommand.finalize_options(self)
self.test_args = []
self.test_suite = True
def run_tests(self):
#import here, cause outside the eggs aren't loaded
import pytest
sys.exit(pytest.main(self.test_args))
setup(
name="Flask-Redistore",
version="1.0",
url="",
license="BSD",
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
description="Adds Redis support to your Flask applications",
long_description=open("README.rst").read(),
py_modules=["flask_redistore"],
zip_safe=False,
include_package_data=True,
platforms="any",
install_requires=[
"Flask",
"redis",
],
extras_require={"tests": ["pytest"]},
tests_require=["pytest"],
classifiers=[
'Environment :: Web Environment',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Software Development :: Libraries :: Python Modules'
],
cmdclass={"test": PyTest},
)
<commit_msg>Add pretend to the test requirements<commit_after>import sys
from setuptools import setup
from setuptools.command.test import test as TestCommand
class PyTest(TestCommand):
def finalize_options(self):
TestCommand.finalize_options(self)
self.test_args = []
self.test_suite = True
def run_tests(self):
#import here, cause outside the eggs aren't loaded
import pytest
sys.exit(pytest.main(self.test_args))
setup(
name="Flask-Redistore",
version="1.0",
url="",
license="BSD",
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
description="Adds Redis support to your Flask applications",
long_description=open("README.rst").read(),
py_modules=["flask_redistore"],
zip_safe=False,
include_package_data=True,
platforms="any",
install_requires=[
"Flask",
"redis",
],
extras_require={"tests": ["pytest", "pretend"]},
tests_require=["pytest", "pretend"],
classifiers=[
'Environment :: Web Environment',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
'Topic :: Software Development :: Libraries :: Python Modules'
],
cmdclass={"test": PyTest},
)
|
6efd95ef46fa92e89185130006922d036ce43043
|
setup.py
|
setup.py
|
import codecs
from os import path
from setuptools import find_packages, setup
def read(*parts):
filename = path.join(path.dirname(__file__), *parts)
with codecs.open(filename, encoding="utf-8") as fp:
return fp.read()
setup(
author="Pinax Team",
author_email="team@pinaxproject.com",
description="a liking app for Django",
name="pinax-likes",
long_description=read("README.rst"),
version="1.3.1",
url="http://pinax-likes.rtfd.org/",
license="MIT",
packages=find_packages(),
install_requires=[
"django-appconf>=0.6",
],
package_data={
"pinax.likes": [
"templates/pinax/likes/*",
]
},
test_suite="runtests.runtests",
tests_require=[
],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 3",
"Topic :: Software Development :: Libraries :: Python Modules",
],
zip_safe=False,
)
|
import codecs
from os import path
from setuptools import find_packages, setup
def read(*parts):
filename = path.join(path.dirname(__file__), *parts)
with codecs.open(filename, encoding="utf-8") as fp:
return fp.read()
setup(
author="Pinax Team",
author_email="team@pinaxproject.com",
description="a liking app for Django",
name="pinax-likes",
long_description=read("README.rst"),
version="1.3.1",
url="http://github.com/pinax/pinax-likes/",
license="MIT",
packages=find_packages(),
install_requires=[
"django-appconf>=0.6",
],
package_data={
"pinax.likes": [
"templates/pinax/likes/*",
]
},
test_suite="runtests.runtests",
tests_require=[
],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 3",
"Topic :: Software Development :: Libraries :: Python Modules",
],
zip_safe=False,
)
|
Use the github repo as the project url
|
Use the github repo as the project url
|
Python
|
mit
|
pinax/pinax-likes,pinax/phileo,pinax/phileo
|
import codecs
from os import path
from setuptools import find_packages, setup
def read(*parts):
filename = path.join(path.dirname(__file__), *parts)
with codecs.open(filename, encoding="utf-8") as fp:
return fp.read()
setup(
author="Pinax Team",
author_email="team@pinaxproject.com",
description="a liking app for Django",
name="pinax-likes",
long_description=read("README.rst"),
version="1.3.1",
url="http://pinax-likes.rtfd.org/",
license="MIT",
packages=find_packages(),
install_requires=[
"django-appconf>=0.6",
],
package_data={
"pinax.likes": [
"templates/pinax/likes/*",
]
},
test_suite="runtests.runtests",
tests_require=[
],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 3",
"Topic :: Software Development :: Libraries :: Python Modules",
],
zip_safe=False,
)
Use the github repo as the project url
|
import codecs
from os import path
from setuptools import find_packages, setup
def read(*parts):
filename = path.join(path.dirname(__file__), *parts)
with codecs.open(filename, encoding="utf-8") as fp:
return fp.read()
setup(
author="Pinax Team",
author_email="team@pinaxproject.com",
description="a liking app for Django",
name="pinax-likes",
long_description=read("README.rst"),
version="1.3.1",
url="http://github.com/pinax/pinax-likes/",
license="MIT",
packages=find_packages(),
install_requires=[
"django-appconf>=0.6",
],
package_data={
"pinax.likes": [
"templates/pinax/likes/*",
]
},
test_suite="runtests.runtests",
tests_require=[
],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 3",
"Topic :: Software Development :: Libraries :: Python Modules",
],
zip_safe=False,
)
|
<commit_before>import codecs
from os import path
from setuptools import find_packages, setup
def read(*parts):
filename = path.join(path.dirname(__file__), *parts)
with codecs.open(filename, encoding="utf-8") as fp:
return fp.read()
setup(
author="Pinax Team",
author_email="team@pinaxproject.com",
description="a liking app for Django",
name="pinax-likes",
long_description=read("README.rst"),
version="1.3.1",
url="http://pinax-likes.rtfd.org/",
license="MIT",
packages=find_packages(),
install_requires=[
"django-appconf>=0.6",
],
package_data={
"pinax.likes": [
"templates/pinax/likes/*",
]
},
test_suite="runtests.runtests",
tests_require=[
],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 3",
"Topic :: Software Development :: Libraries :: Python Modules",
],
zip_safe=False,
)
<commit_msg>Use the github repo as the project url<commit_after>
|
import codecs
from os import path
from setuptools import find_packages, setup
def read(*parts):
filename = path.join(path.dirname(__file__), *parts)
with codecs.open(filename, encoding="utf-8") as fp:
return fp.read()
setup(
author="Pinax Team",
author_email="team@pinaxproject.com",
description="a liking app for Django",
name="pinax-likes",
long_description=read("README.rst"),
version="1.3.1",
url="http://github.com/pinax/pinax-likes/",
license="MIT",
packages=find_packages(),
install_requires=[
"django-appconf>=0.6",
],
package_data={
"pinax.likes": [
"templates/pinax/likes/*",
]
},
test_suite="runtests.runtests",
tests_require=[
],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 3",
"Topic :: Software Development :: Libraries :: Python Modules",
],
zip_safe=False,
)
|
import codecs
from os import path
from setuptools import find_packages, setup
def read(*parts):
filename = path.join(path.dirname(__file__), *parts)
with codecs.open(filename, encoding="utf-8") as fp:
return fp.read()
setup(
author="Pinax Team",
author_email="team@pinaxproject.com",
description="a liking app for Django",
name="pinax-likes",
long_description=read("README.rst"),
version="1.3.1",
url="http://pinax-likes.rtfd.org/",
license="MIT",
packages=find_packages(),
install_requires=[
"django-appconf>=0.6",
],
package_data={
"pinax.likes": [
"templates/pinax/likes/*",
]
},
test_suite="runtests.runtests",
tests_require=[
],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 3",
"Topic :: Software Development :: Libraries :: Python Modules",
],
zip_safe=False,
)
Use the github repo as the project urlimport codecs
from os import path
from setuptools import find_packages, setup
def read(*parts):
filename = path.join(path.dirname(__file__), *parts)
with codecs.open(filename, encoding="utf-8") as fp:
return fp.read()
setup(
author="Pinax Team",
author_email="team@pinaxproject.com",
description="a liking app for Django",
name="pinax-likes",
long_description=read("README.rst"),
version="1.3.1",
url="http://github.com/pinax/pinax-likes/",
license="MIT",
packages=find_packages(),
install_requires=[
"django-appconf>=0.6",
],
package_data={
"pinax.likes": [
"templates/pinax/likes/*",
]
},
test_suite="runtests.runtests",
tests_require=[
],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 3",
"Topic :: Software Development :: Libraries :: Python Modules",
],
zip_safe=False,
)
|
<commit_before>import codecs
from os import path
from setuptools import find_packages, setup
def read(*parts):
filename = path.join(path.dirname(__file__), *parts)
with codecs.open(filename, encoding="utf-8") as fp:
return fp.read()
setup(
author="Pinax Team",
author_email="team@pinaxproject.com",
description="a liking app for Django",
name="pinax-likes",
long_description=read("README.rst"),
version="1.3.1",
url="http://pinax-likes.rtfd.org/",
license="MIT",
packages=find_packages(),
install_requires=[
"django-appconf>=0.6",
],
package_data={
"pinax.likes": [
"templates/pinax/likes/*",
]
},
test_suite="runtests.runtests",
tests_require=[
],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 3",
"Topic :: Software Development :: Libraries :: Python Modules",
],
zip_safe=False,
)
<commit_msg>Use the github repo as the project url<commit_after>import codecs
from os import path
from setuptools import find_packages, setup
def read(*parts):
filename = path.join(path.dirname(__file__), *parts)
with codecs.open(filename, encoding="utf-8") as fp:
return fp.read()
setup(
author="Pinax Team",
author_email="team@pinaxproject.com",
description="a liking app for Django",
name="pinax-likes",
long_description=read("README.rst"),
version="1.3.1",
url="http://github.com/pinax/pinax-likes/",
license="MIT",
packages=find_packages(),
install_requires=[
"django-appconf>=0.6",
],
package_data={
"pinax.likes": [
"templates/pinax/likes/*",
]
},
test_suite="runtests.runtests",
tests_require=[
],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Programming Language :: Python :: 2",
"Programming Language :: Python :: 3",
"Topic :: Software Development :: Libraries :: Python Modules",
],
zip_safe=False,
)
|
cfc8563e731e0712ced2dd58b6eab66275b0c073
|
views.py
|
views.py
|
# Copyright (c) 2014-2015, Doug Kelly
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this
# list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright notice,
# this list of conditions and the following disclaimer in the documentation
# and/or other materials provided with the distribution.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
# ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# Create your views here.
from django.shortcuts import render
from django.views.generic import View
class Register(View):
def get(self, request):
return render(request, 'register.html')
|
# Copyright (c) 2014-2015, Doug Kelly
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this
# list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright notice,
# this list of conditions and the following disclaimer in the documentation
# and/or other materials provided with the distribution.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
# ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# Create your views here.
from django.shortcuts import render
from django.views.generic import View
class Register(View):
def get(self, request):
return render(request, 'register/register.html')
|
Restructure templates to avoid name conflict
|
Restructure templates to avoid name conflict
We were about to get into a lot of confusion with registering for
comments and registering for the con... this should help confusion
somewhat.
|
Python
|
bsd-2-clause
|
vangdfang/conspace-register,vangdfang/conspace-register
|
# Copyright (c) 2014-2015, Doug Kelly
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this
# list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright notice,
# this list of conditions and the following disclaimer in the documentation
# and/or other materials provided with the distribution.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
# ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# Create your views here.
from django.shortcuts import render
from django.views.generic import View
class Register(View):
def get(self, request):
return render(request, 'register.html')Restructure templates to avoid name conflict
We were about to get into a lot of confusion with registering for
comments and registering for the con... this should help confusion
somewhat.
|
# Copyright (c) 2014-2015, Doug Kelly
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this
# list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright notice,
# this list of conditions and the following disclaimer in the documentation
# and/or other materials provided with the distribution.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
# ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# Create your views here.
from django.shortcuts import render
from django.views.generic import View
class Register(View):
def get(self, request):
return render(request, 'register/register.html')
|
<commit_before># Copyright (c) 2014-2015, Doug Kelly
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this
# list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright notice,
# this list of conditions and the following disclaimer in the documentation
# and/or other materials provided with the distribution.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
# ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# Create your views here.
from django.shortcuts import render
from django.views.generic import View
class Register(View):
def get(self, request):
return render(request, 'register.html')<commit_msg>Restructure templates to avoid name conflict
We were about to get into a lot of confusion with registering for
comments and registering for the con... this should help confusion
somewhat.<commit_after>
|
# Copyright (c) 2014-2015, Doug Kelly
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this
# list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright notice,
# this list of conditions and the following disclaimer in the documentation
# and/or other materials provided with the distribution.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
# ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# Create your views here.
from django.shortcuts import render
from django.views.generic import View
class Register(View):
def get(self, request):
return render(request, 'register/register.html')
|
# Copyright (c) 2014-2015, Doug Kelly
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this
# list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright notice,
# this list of conditions and the following disclaimer in the documentation
# and/or other materials provided with the distribution.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
# ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# Create your views here.
from django.shortcuts import render
from django.views.generic import View
class Register(View):
def get(self, request):
return render(request, 'register.html')Restructure templates to avoid name conflict
We were about to get into a lot of confusion with registering for
comments and registering for the con... this should help confusion
somewhat.# Copyright (c) 2014-2015, Doug Kelly
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this
# list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright notice,
# this list of conditions and the following disclaimer in the documentation
# and/or other materials provided with the distribution.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
# ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# Create your views here.
from django.shortcuts import render
from django.views.generic import View
class Register(View):
def get(self, request):
return render(request, 'register/register.html')
|
<commit_before># Copyright (c) 2014-2015, Doug Kelly
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this
# list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright notice,
# this list of conditions and the following disclaimer in the documentation
# and/or other materials provided with the distribution.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
# ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# Create your views here.
from django.shortcuts import render
from django.views.generic import View
class Register(View):
def get(self, request):
return render(request, 'register.html')<commit_msg>Restructure templates to avoid name conflict
We were about to get into a lot of confusion with registering for
comments and registering for the con... this should help confusion
somewhat.<commit_after># Copyright (c) 2014-2015, Doug Kelly
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this
# list of conditions and the following disclaimer.
# 2. Redistributions in binary form must reproduce the above copyright notice,
# this list of conditions and the following disclaimer in the documentation
# and/or other materials provided with the distribution.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
# ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
# (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
# ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# Create your views here.
from django.shortcuts import render
from django.views.generic import View
class Register(View):
def get(self, request):
return render(request, 'register/register.html')
|
b17df9b3442c8dd98cb0fdfe415c1953ca5dc092
|
setup.py
|
setup.py
|
#
# Copyright 2017 Google Inc.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import setuptools
def readme():
return '`pstar` documentation and source code can be found at https://github.com/iansf/pstar.'
def version():
return '0.1.2'
setuptools.setup(
name='pstar',
description='pstar: numpy for arbitrary data',
long_description=readme(),
version=version(),
url='https://github.com/iansf/pstar',
download_url='https://github.com/iansf/pstar/archive/%s.tar.gz' % version(),
author='Ian Fischer, Google',
author_email='iansf@google.com',
packages=['pstar'],
license='Apache 2.0',
install_requires=['qj'],
test_suite='nose.collector',
tests_require=['nose'],
)
|
#
# Copyright 2017 Google Inc.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import setuptools
def readme():
return '`pstar` documentation and source code can be found at https://github.com/iansf/pstar.'
def version():
return '0.1.3'
setuptools.setup(
name='pstar',
description='pstar: numpy for arbitrary data',
long_description=readme(),
version=version(),
url='https://github.com/iansf/pstar',
download_url='https://github.com/iansf/pstar/archive/%s.tar.gz' % version(),
author='Ian Fischer, Google',
author_email='iansf@google.com',
packages=['pstar'],
license='Apache 2.0',
install_requires=['qj'],
test_suite='nose.collector',
tests_require=['nose'],
)
|
Update version number to 0.1.3.
|
Update version number to 0.1.3.
|
Python
|
apache-2.0
|
iansf/pstar
|
#
# Copyright 2017 Google Inc.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import setuptools
def readme():
return '`pstar` documentation and source code can be found at https://github.com/iansf/pstar.'
def version():
return '0.1.2'
setuptools.setup(
name='pstar',
description='pstar: numpy for arbitrary data',
long_description=readme(),
version=version(),
url='https://github.com/iansf/pstar',
download_url='https://github.com/iansf/pstar/archive/%s.tar.gz' % version(),
author='Ian Fischer, Google',
author_email='iansf@google.com',
packages=['pstar'],
license='Apache 2.0',
install_requires=['qj'],
test_suite='nose.collector',
tests_require=['nose'],
)
Update version number to 0.1.3.
|
#
# Copyright 2017 Google Inc.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import setuptools
def readme():
return '`pstar` documentation and source code can be found at https://github.com/iansf/pstar.'
def version():
return '0.1.3'
setuptools.setup(
name='pstar',
description='pstar: numpy for arbitrary data',
long_description=readme(),
version=version(),
url='https://github.com/iansf/pstar',
download_url='https://github.com/iansf/pstar/archive/%s.tar.gz' % version(),
author='Ian Fischer, Google',
author_email='iansf@google.com',
packages=['pstar'],
license='Apache 2.0',
install_requires=['qj'],
test_suite='nose.collector',
tests_require=['nose'],
)
|
<commit_before>#
# Copyright 2017 Google Inc.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import setuptools
def readme():
return '`pstar` documentation and source code can be found at https://github.com/iansf/pstar.'
def version():
return '0.1.2'
setuptools.setup(
name='pstar',
description='pstar: numpy for arbitrary data',
long_description=readme(),
version=version(),
url='https://github.com/iansf/pstar',
download_url='https://github.com/iansf/pstar/archive/%s.tar.gz' % version(),
author='Ian Fischer, Google',
author_email='iansf@google.com',
packages=['pstar'],
license='Apache 2.0',
install_requires=['qj'],
test_suite='nose.collector',
tests_require=['nose'],
)
<commit_msg>Update version number to 0.1.3.<commit_after>
|
#
# Copyright 2017 Google Inc.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import setuptools
def readme():
return '`pstar` documentation and source code can be found at https://github.com/iansf/pstar.'
def version():
return '0.1.3'
setuptools.setup(
name='pstar',
description='pstar: numpy for arbitrary data',
long_description=readme(),
version=version(),
url='https://github.com/iansf/pstar',
download_url='https://github.com/iansf/pstar/archive/%s.tar.gz' % version(),
author='Ian Fischer, Google',
author_email='iansf@google.com',
packages=['pstar'],
license='Apache 2.0',
install_requires=['qj'],
test_suite='nose.collector',
tests_require=['nose'],
)
|
#
# Copyright 2017 Google Inc.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import setuptools
def readme():
return '`pstar` documentation and source code can be found at https://github.com/iansf/pstar.'
def version():
return '0.1.2'
setuptools.setup(
name='pstar',
description='pstar: numpy for arbitrary data',
long_description=readme(),
version=version(),
url='https://github.com/iansf/pstar',
download_url='https://github.com/iansf/pstar/archive/%s.tar.gz' % version(),
author='Ian Fischer, Google',
author_email='iansf@google.com',
packages=['pstar'],
license='Apache 2.0',
install_requires=['qj'],
test_suite='nose.collector',
tests_require=['nose'],
)
Update version number to 0.1.3.#
# Copyright 2017 Google Inc.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import setuptools
def readme():
return '`pstar` documentation and source code can be found at https://github.com/iansf/pstar.'
def version():
return '0.1.3'
setuptools.setup(
name='pstar',
description='pstar: numpy for arbitrary data',
long_description=readme(),
version=version(),
url='https://github.com/iansf/pstar',
download_url='https://github.com/iansf/pstar/archive/%s.tar.gz' % version(),
author='Ian Fischer, Google',
author_email='iansf@google.com',
packages=['pstar'],
license='Apache 2.0',
install_requires=['qj'],
test_suite='nose.collector',
tests_require=['nose'],
)
|
<commit_before>#
# Copyright 2017 Google Inc.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import setuptools
def readme():
return '`pstar` documentation and source code can be found at https://github.com/iansf/pstar.'
def version():
return '0.1.2'
setuptools.setup(
name='pstar',
description='pstar: numpy for arbitrary data',
long_description=readme(),
version=version(),
url='https://github.com/iansf/pstar',
download_url='https://github.com/iansf/pstar/archive/%s.tar.gz' % version(),
author='Ian Fischer, Google',
author_email='iansf@google.com',
packages=['pstar'],
license='Apache 2.0',
install_requires=['qj'],
test_suite='nose.collector',
tests_require=['nose'],
)
<commit_msg>Update version number to 0.1.3.<commit_after>#
# Copyright 2017 Google Inc.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import setuptools
def readme():
return '`pstar` documentation and source code can be found at https://github.com/iansf/pstar.'
def version():
return '0.1.3'
setuptools.setup(
name='pstar',
description='pstar: numpy for arbitrary data',
long_description=readme(),
version=version(),
url='https://github.com/iansf/pstar',
download_url='https://github.com/iansf/pstar/archive/%s.tar.gz' % version(),
author='Ian Fischer, Google',
author_email='iansf@google.com',
packages=['pstar'],
license='Apache 2.0',
install_requires=['qj'],
test_suite='nose.collector',
tests_require=['nose'],
)
|
09496ed494ebe867f31eda00a11cd7ed4c491341
|
setup.py
|
setup.py
|
from setuptools import setup, Extension
import platform
version = '2.1.0'
setup(name='dronekit',
zip_safe=True,
version=version,
description='Python language bindings for the DroneApi',
long_description='Python language bindings for the DroneApi',
url='https://github.com/dronekit/dronekit-python',
author='3D Robotics',
install_requires=[
'pymavlink>=1.1.62',
'requests>=2.5.0,<=2.99999',
],
author_email='tim@3drobotics.com, kevinh@geeksville.com',
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Science/Research',
'License :: OSI Approved :: Apache Software License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Topic :: Scientific/Engineering',
],
license='apache',
packages=[
'dronekit', 'dronekit.cloud', 'dronekit.test'
],
ext_modules=[])
|
from setuptools import setup, Extension
import platform
version = '2.1.0'
setup(name='dronekit',
zip_safe=True,
version=version,
description='Developer Tools for Drones.',
long_description='Python API for communication and control of drones over MAVLink.',
url='https://github.com/dronekit/dronekit-python',
author='3D Robotics',
install_requires=[
'pymavlink>=1.1.62',
'requests>=2.5.0,<=2.99999',
],
author_email='tim@3drobotics.com, kevinh@geeksville.com',
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Science/Research',
'License :: OSI Approved :: Apache Software License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Topic :: Scientific/Engineering',
],
license='apache',
packages=[
'dronekit', 'dronekit.cloud', 'dronekit.test'
],
ext_modules=[])
|
Improve description of dronekit on PyPi
|
Improve description of dronekit on PyPi
|
Python
|
apache-2.0
|
hamishwillee/dronekit-python,dronekit/dronekit-python,dronekit/dronekit-python,diydrones/dronekit-python,hamishwillee/dronekit-python,diydrones/dronekit-python
|
from setuptools import setup, Extension
import platform
version = '2.1.0'
setup(name='dronekit',
zip_safe=True,
version=version,
description='Python language bindings for the DroneApi',
long_description='Python language bindings for the DroneApi',
url='https://github.com/dronekit/dronekit-python',
author='3D Robotics',
install_requires=[
'pymavlink>=1.1.62',
'requests>=2.5.0,<=2.99999',
],
author_email='tim@3drobotics.com, kevinh@geeksville.com',
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Science/Research',
'License :: OSI Approved :: Apache Software License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Topic :: Scientific/Engineering',
],
license='apache',
packages=[
'dronekit', 'dronekit.cloud', 'dronekit.test'
],
ext_modules=[])
Improve description of dronekit on PyPi
|
from setuptools import setup, Extension
import platform
version = '2.1.0'
setup(name='dronekit',
zip_safe=True,
version=version,
description='Developer Tools for Drones.',
long_description='Python API for communication and control of drones over MAVLink.',
url='https://github.com/dronekit/dronekit-python',
author='3D Robotics',
install_requires=[
'pymavlink>=1.1.62',
'requests>=2.5.0,<=2.99999',
],
author_email='tim@3drobotics.com, kevinh@geeksville.com',
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Science/Research',
'License :: OSI Approved :: Apache Software License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Topic :: Scientific/Engineering',
],
license='apache',
packages=[
'dronekit', 'dronekit.cloud', 'dronekit.test'
],
ext_modules=[])
|
<commit_before>from setuptools import setup, Extension
import platform
version = '2.1.0'
setup(name='dronekit',
zip_safe=True,
version=version,
description='Python language bindings for the DroneApi',
long_description='Python language bindings for the DroneApi',
url='https://github.com/dronekit/dronekit-python',
author='3D Robotics',
install_requires=[
'pymavlink>=1.1.62',
'requests>=2.5.0,<=2.99999',
],
author_email='tim@3drobotics.com, kevinh@geeksville.com',
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Science/Research',
'License :: OSI Approved :: Apache Software License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Topic :: Scientific/Engineering',
],
license='apache',
packages=[
'dronekit', 'dronekit.cloud', 'dronekit.test'
],
ext_modules=[])
<commit_msg>Improve description of dronekit on PyPi<commit_after>
|
from setuptools import setup, Extension
import platform
version = '2.1.0'
setup(name='dronekit',
zip_safe=True,
version=version,
description='Developer Tools for Drones.',
long_description='Python API for communication and control of drones over MAVLink.',
url='https://github.com/dronekit/dronekit-python',
author='3D Robotics',
install_requires=[
'pymavlink>=1.1.62',
'requests>=2.5.0,<=2.99999',
],
author_email='tim@3drobotics.com, kevinh@geeksville.com',
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Science/Research',
'License :: OSI Approved :: Apache Software License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Topic :: Scientific/Engineering',
],
license='apache',
packages=[
'dronekit', 'dronekit.cloud', 'dronekit.test'
],
ext_modules=[])
|
from setuptools import setup, Extension
import platform
version = '2.1.0'
setup(name='dronekit',
zip_safe=True,
version=version,
description='Python language bindings for the DroneApi',
long_description='Python language bindings for the DroneApi',
url='https://github.com/dronekit/dronekit-python',
author='3D Robotics',
install_requires=[
'pymavlink>=1.1.62',
'requests>=2.5.0,<=2.99999',
],
author_email='tim@3drobotics.com, kevinh@geeksville.com',
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Science/Research',
'License :: OSI Approved :: Apache Software License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Topic :: Scientific/Engineering',
],
license='apache',
packages=[
'dronekit', 'dronekit.cloud', 'dronekit.test'
],
ext_modules=[])
Improve description of dronekit on PyPifrom setuptools import setup, Extension
import platform
version = '2.1.0'
setup(name='dronekit',
zip_safe=True,
version=version,
description='Developer Tools for Drones.',
long_description='Python API for communication and control of drones over MAVLink.',
url='https://github.com/dronekit/dronekit-python',
author='3D Robotics',
install_requires=[
'pymavlink>=1.1.62',
'requests>=2.5.0,<=2.99999',
],
author_email='tim@3drobotics.com, kevinh@geeksville.com',
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Science/Research',
'License :: OSI Approved :: Apache Software License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Topic :: Scientific/Engineering',
],
license='apache',
packages=[
'dronekit', 'dronekit.cloud', 'dronekit.test'
],
ext_modules=[])
|
<commit_before>from setuptools import setup, Extension
import platform
version = '2.1.0'
setup(name='dronekit',
zip_safe=True,
version=version,
description='Python language bindings for the DroneApi',
long_description='Python language bindings for the DroneApi',
url='https://github.com/dronekit/dronekit-python',
author='3D Robotics',
install_requires=[
'pymavlink>=1.1.62',
'requests>=2.5.0,<=2.99999',
],
author_email='tim@3drobotics.com, kevinh@geeksville.com',
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Science/Research',
'License :: OSI Approved :: Apache Software License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Topic :: Scientific/Engineering',
],
license='apache',
packages=[
'dronekit', 'dronekit.cloud', 'dronekit.test'
],
ext_modules=[])
<commit_msg>Improve description of dronekit on PyPi<commit_after>from setuptools import setup, Extension
import platform
version = '2.1.0'
setup(name='dronekit',
zip_safe=True,
version=version,
description='Developer Tools for Drones.',
long_description='Python API for communication and control of drones over MAVLink.',
url='https://github.com/dronekit/dronekit-python',
author='3D Robotics',
install_requires=[
'pymavlink>=1.1.62',
'requests>=2.5.0,<=2.99999',
],
author_email='tim@3drobotics.com, kevinh@geeksville.com',
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Console',
'Intended Audience :: Science/Research',
'License :: OSI Approved :: Apache Software License',
'Operating System :: OS Independent',
'Programming Language :: Python :: 2.7',
'Topic :: Scientific/Engineering',
],
license='apache',
packages=[
'dronekit', 'dronekit.cloud', 'dronekit.test'
],
ext_modules=[])
|
0fcf47c09402bd49866ace6ddbe584de40800534
|
yahoo.py
|
yahoo.py
|
import time
from yahoo_finance import Share
# Collect 30 mins of Finance data on 5 companies, one value per minute
nyt = Share('NYT')
ibm = Share('IBM')
google = Share('GOOG')
facebook = Share('FB')
linkedin = Share('LNKD')
for minute in range(30):
print "%s minutes" % minute
nyt.refresh()
print "The New York Times' stock price is $%s" % nyt.get_price()
ibm.refresh()
print "IBM's stock price is $%s" % ibm.get_price()
google.refresh()
print "Google's stock price is $%s" % google.get_price()
facebook.refresh()
print "Facebook's stock price is $%s" % facebook.get_price()
linkedin.refresh()
print "Linkedin's stock price is $%s" % linkedin.get_price()
time.sleep(60)
|
import time
from yahoo_finance import Share
# Collect 30 mins of Finance data on 5 companies, one value per minute
for minute in range(30):
nyt = Share('NYT')
ibm = Share('IBM')
google = Share('GOOG')
facebook = Share('FB')
linkedin = Share('LNKD')
print "%s minutes" % minute
print "The New York Times' stock price is $%s" % nyt.get_price()
print "IBM's stock price is $%s" % ibm.get_price()
print "Google's stock price is $%s" % google.get_price()
print "Facebook's stock price is $%s" % facebook.get_price()
print "Linkedin's stock price is $%s" % linkedin.get_price()
time.sleep(60)
|
Remove need for refresh() by putting everything in loop
|
Remove need for refresh() by putting everything in loop
|
Python
|
mit
|
cathyq/yahoo-finance
|
import time
from yahoo_finance import Share
# Collect 30 mins of Finance data on 5 companies, one value per minute
nyt = Share('NYT')
ibm = Share('IBM')
google = Share('GOOG')
facebook = Share('FB')
linkedin = Share('LNKD')
for minute in range(30):
print "%s minutes" % minute
nyt.refresh()
print "The New York Times' stock price is $%s" % nyt.get_price()
ibm.refresh()
print "IBM's stock price is $%s" % ibm.get_price()
google.refresh()
print "Google's stock price is $%s" % google.get_price()
facebook.refresh()
print "Facebook's stock price is $%s" % facebook.get_price()
linkedin.refresh()
print "Linkedin's stock price is $%s" % linkedin.get_price()
time.sleep(60)
Remove need for refresh() by putting everything in loop
|
import time
from yahoo_finance import Share
# Collect 30 mins of Finance data on 5 companies, one value per minute
for minute in range(30):
nyt = Share('NYT')
ibm = Share('IBM')
google = Share('GOOG')
facebook = Share('FB')
linkedin = Share('LNKD')
print "%s minutes" % minute
print "The New York Times' stock price is $%s" % nyt.get_price()
print "IBM's stock price is $%s" % ibm.get_price()
print "Google's stock price is $%s" % google.get_price()
print "Facebook's stock price is $%s" % facebook.get_price()
print "Linkedin's stock price is $%s" % linkedin.get_price()
time.sleep(60)
|
<commit_before>import time
from yahoo_finance import Share
# Collect 30 mins of Finance data on 5 companies, one value per minute
nyt = Share('NYT')
ibm = Share('IBM')
google = Share('GOOG')
facebook = Share('FB')
linkedin = Share('LNKD')
for minute in range(30):
print "%s minutes" % minute
nyt.refresh()
print "The New York Times' stock price is $%s" % nyt.get_price()
ibm.refresh()
print "IBM's stock price is $%s" % ibm.get_price()
google.refresh()
print "Google's stock price is $%s" % google.get_price()
facebook.refresh()
print "Facebook's stock price is $%s" % facebook.get_price()
linkedin.refresh()
print "Linkedin's stock price is $%s" % linkedin.get_price()
time.sleep(60)
<commit_msg>Remove need for refresh() by putting everything in loop<commit_after>
|
import time
from yahoo_finance import Share
# Collect 30 mins of Finance data on 5 companies, one value per minute
for minute in range(30):
nyt = Share('NYT')
ibm = Share('IBM')
google = Share('GOOG')
facebook = Share('FB')
linkedin = Share('LNKD')
print "%s minutes" % minute
print "The New York Times' stock price is $%s" % nyt.get_price()
print "IBM's stock price is $%s" % ibm.get_price()
print "Google's stock price is $%s" % google.get_price()
print "Facebook's stock price is $%s" % facebook.get_price()
print "Linkedin's stock price is $%s" % linkedin.get_price()
time.sleep(60)
|
import time
from yahoo_finance import Share
# Collect 30 mins of Finance data on 5 companies, one value per minute
nyt = Share('NYT')
ibm = Share('IBM')
google = Share('GOOG')
facebook = Share('FB')
linkedin = Share('LNKD')
for minute in range(30):
print "%s minutes" % minute
nyt.refresh()
print "The New York Times' stock price is $%s" % nyt.get_price()
ibm.refresh()
print "IBM's stock price is $%s" % ibm.get_price()
google.refresh()
print "Google's stock price is $%s" % google.get_price()
facebook.refresh()
print "Facebook's stock price is $%s" % facebook.get_price()
linkedin.refresh()
print "Linkedin's stock price is $%s" % linkedin.get_price()
time.sleep(60)
Remove need for refresh() by putting everything in loopimport time
from yahoo_finance import Share
# Collect 30 mins of Finance data on 5 companies, one value per minute
for minute in range(30):
nyt = Share('NYT')
ibm = Share('IBM')
google = Share('GOOG')
facebook = Share('FB')
linkedin = Share('LNKD')
print "%s minutes" % minute
print "The New York Times' stock price is $%s" % nyt.get_price()
print "IBM's stock price is $%s" % ibm.get_price()
print "Google's stock price is $%s" % google.get_price()
print "Facebook's stock price is $%s" % facebook.get_price()
print "Linkedin's stock price is $%s" % linkedin.get_price()
time.sleep(60)
|
<commit_before>import time
from yahoo_finance import Share
# Collect 30 mins of Finance data on 5 companies, one value per minute
nyt = Share('NYT')
ibm = Share('IBM')
google = Share('GOOG')
facebook = Share('FB')
linkedin = Share('LNKD')
for minute in range(30):
print "%s minutes" % minute
nyt.refresh()
print "The New York Times' stock price is $%s" % nyt.get_price()
ibm.refresh()
print "IBM's stock price is $%s" % ibm.get_price()
google.refresh()
print "Google's stock price is $%s" % google.get_price()
facebook.refresh()
print "Facebook's stock price is $%s" % facebook.get_price()
linkedin.refresh()
print "Linkedin's stock price is $%s" % linkedin.get_price()
time.sleep(60)
<commit_msg>Remove need for refresh() by putting everything in loop<commit_after>import time
from yahoo_finance import Share
# Collect 30 mins of Finance data on 5 companies, one value per minute
for minute in range(30):
nyt = Share('NYT')
ibm = Share('IBM')
google = Share('GOOG')
facebook = Share('FB')
linkedin = Share('LNKD')
print "%s minutes" % minute
print "The New York Times' stock price is $%s" % nyt.get_price()
print "IBM's stock price is $%s" % ibm.get_price()
print "Google's stock price is $%s" % google.get_price()
print "Facebook's stock price is $%s" % facebook.get_price()
print "Linkedin's stock price is $%s" % linkedin.get_price()
time.sleep(60)
|
ecd201216562c8b802fada27e2f79cda5b05a4d5
|
cron/__init__.py
|
cron/__init__.py
|
import schedule
import settings
from .poll_pull_requests import poll_pull_requests as poll_pull_requests
from .restart_homepage import restart_homepage as restart_homepage
def schedule_jobs():
schedule.every(settings.PULL_REQUEST_POLLING_INTERVAL_SECONDS).seconds.do(poll_pull_requests)
schedule.every(settings.FALLBACK_WINDOW).hours.do(check_fallback)
schedule.every(120).seconds.do(restart_homepage)
|
import schedule
import settings
from .poll_pull_requests import poll_pull_requests as poll_pull_requests
from .restart_homepage import restart_homepage as restart_homepage
def schedule_jobs():
schedule.every(settings.PULL_REQUEST_POLLING_INTERVAL_SECONDS).seconds.do(poll_pull_requests)
schedule.every(settings.FALLBACK_WINDOW_SECONDS).seconds.do(check_fallback)
schedule.every(120).seconds.do(restart_homepage)
|
Change hours to seconds in cron job
|
Change hours to seconds in cron job
|
Python
|
mit
|
amoffat/Chaos,eukaryote31/chaos,phil-r/chaos,g19fanatic/chaos,phil-r/chaos,botchaos/Chaos,Chaosthebot/Chaos,mark-i-m/Chaos,chaosbot/Chaos,g19fanatic/chaos,phil-r/chaos,hongaar/chaos,rudehn/chaos,rudehn/chaos,Chaosthebot/Chaos,botchaos/Chaos,mpnordland/chaos,amoffat/Chaos,mark-i-m/Chaos,chaosbot/Chaos,amoffat/Chaos,amoffat/Chaos,mpnordland/chaos,eukaryote31/chaos,botchaos/Chaos,amoffat/Chaos,chaosbot/Chaos,mpnordland/chaos,eukaryote31/chaos,Chaosthebot/Chaos,rudehn/chaos,eamanu/Chaos,hongaar/chaos,g19fanatic/chaos,mpnordland/chaos,g19fanatic/chaos,eamanu/Chaos,g19fanatic/chaos,rudehn/chaos,Chaosthebot/Chaos,mark-i-m/Chaos,eukaryote31/chaos,mpnordland/chaos,eamanu/Chaos,eukaryote31/chaos,chaosbot/Chaos,hongaar/chaos,botchaos/Chaos,chaosbot/Chaos,phil-r/chaos,mark-i-m/Chaos,eamanu/Chaos,hongaar/chaos,rudehn/chaos,Chaosthebot/Chaos,hongaar/chaos,mark-i-m/Chaos,eamanu/Chaos,phil-r/chaos,botchaos/Chaos
|
import schedule
import settings
from .poll_pull_requests import poll_pull_requests as poll_pull_requests
from .restart_homepage import restart_homepage as restart_homepage
def schedule_jobs():
schedule.every(settings.PULL_REQUEST_POLLING_INTERVAL_SECONDS).seconds.do(poll_pull_requests)
schedule.every(settings.FALLBACK_WINDOW).hours.do(check_fallback)
schedule.every(120).seconds.do(restart_homepage)
Change hours to seconds in cron job
|
import schedule
import settings
from .poll_pull_requests import poll_pull_requests as poll_pull_requests
from .restart_homepage import restart_homepage as restart_homepage
def schedule_jobs():
schedule.every(settings.PULL_REQUEST_POLLING_INTERVAL_SECONDS).seconds.do(poll_pull_requests)
schedule.every(settings.FALLBACK_WINDOW_SECONDS).seconds.do(check_fallback)
schedule.every(120).seconds.do(restart_homepage)
|
<commit_before>import schedule
import settings
from .poll_pull_requests import poll_pull_requests as poll_pull_requests
from .restart_homepage import restart_homepage as restart_homepage
def schedule_jobs():
schedule.every(settings.PULL_REQUEST_POLLING_INTERVAL_SECONDS).seconds.do(poll_pull_requests)
schedule.every(settings.FALLBACK_WINDOW).hours.do(check_fallback)
schedule.every(120).seconds.do(restart_homepage)
<commit_msg>Change hours to seconds in cron job<commit_after>
|
import schedule
import settings
from .poll_pull_requests import poll_pull_requests as poll_pull_requests
from .restart_homepage import restart_homepage as restart_homepage
def schedule_jobs():
schedule.every(settings.PULL_REQUEST_POLLING_INTERVAL_SECONDS).seconds.do(poll_pull_requests)
schedule.every(settings.FALLBACK_WINDOW_SECONDS).seconds.do(check_fallback)
schedule.every(120).seconds.do(restart_homepage)
|
import schedule
import settings
from .poll_pull_requests import poll_pull_requests as poll_pull_requests
from .restart_homepage import restart_homepage as restart_homepage
def schedule_jobs():
schedule.every(settings.PULL_REQUEST_POLLING_INTERVAL_SECONDS).seconds.do(poll_pull_requests)
schedule.every(settings.FALLBACK_WINDOW).hours.do(check_fallback)
schedule.every(120).seconds.do(restart_homepage)
Change hours to seconds in cron jobimport schedule
import settings
from .poll_pull_requests import poll_pull_requests as poll_pull_requests
from .restart_homepage import restart_homepage as restart_homepage
def schedule_jobs():
schedule.every(settings.PULL_REQUEST_POLLING_INTERVAL_SECONDS).seconds.do(poll_pull_requests)
schedule.every(settings.FALLBACK_WINDOW_SECONDS).seconds.do(check_fallback)
schedule.every(120).seconds.do(restart_homepage)
|
<commit_before>import schedule
import settings
from .poll_pull_requests import poll_pull_requests as poll_pull_requests
from .restart_homepage import restart_homepage as restart_homepage
def schedule_jobs():
schedule.every(settings.PULL_REQUEST_POLLING_INTERVAL_SECONDS).seconds.do(poll_pull_requests)
schedule.every(settings.FALLBACK_WINDOW).hours.do(check_fallback)
schedule.every(120).seconds.do(restart_homepage)
<commit_msg>Change hours to seconds in cron job<commit_after>import schedule
import settings
from .poll_pull_requests import poll_pull_requests as poll_pull_requests
from .restart_homepage import restart_homepage as restart_homepage
def schedule_jobs():
schedule.every(settings.PULL_REQUEST_POLLING_INTERVAL_SECONDS).seconds.do(poll_pull_requests)
schedule.every(settings.FALLBACK_WINDOW_SECONDS).seconds.do(check_fallback)
schedule.every(120).seconds.do(restart_homepage)
|
8b6443022d8f1c080e28d3b83bcae8af7fe302ca
|
setup.py
|
setup.py
|
#!/usr/bin/env python
from setuptools import find_packages, Command
setup_params = dict(
name='bugimporters',
version=0.1,
author='Various contributers to the OpenHatch project, Berry Phillips',
author_email='all@openhatch.org, berryphillips@gmail.com',
packages=find_packages(),
description='Bug importers for the OpenHatch project',
install_requires=[
'gdata',
'lxml',
'cssselect',
'pyopenssl',
'unicodecsv',
'feedparser',
'twisted',
'python-dateutil',
'decorator',
'scrapy>0.9',
'argparse',
'mock',
'PyYAML',
'autoresponse>=0.2',
],
)
### Python 2.7 already has importlib. Because of that,
### we can't put it in install_requires. We test for
### that here; if needed, we add it.
try:
import importlib
except ImportError:
setup_params['install_requires'].append('importlib')
if __name__ == '__main__':
from setuptools import setup
setup(**setup_params)
|
#!/usr/bin/env python
from setuptools import find_packages, Command
setup_params = dict(
name='bugimporters',
version=0.1,
author='Various contributers to the OpenHatch project, Berry Phillips',
author_email='all@openhatch.org, berryphillips@gmail.com',
packages=find_packages(),
description='Bug importers for the OpenHatch project',
install_requires=[
'gdata',
'lxml',
'cssselect',
'pyopenssl',
'unicodecsv',
'feedparser',
'twisted',
'python-dateutil',
'decorator',
'scrapy>0.9',
'argparse',
'mock',
'PyYAML',
'autoresponse>=0.3.1',
],
)
### Python 2.7 already has importlib. Because of that,
### we can't put it in install_requires. We test for
### that here; if needed, we add it.
try:
import importlib
except ImportError:
setup_params['install_requires'].append('importlib')
if __name__ == '__main__':
from setuptools import setup
setup(**setup_params)
|
Upgrade to 0.3.1 to avoid broken 0.3
|
Upgrade to 0.3.1 to avoid broken 0.3
|
Python
|
agpl-3.0
|
openhatch/oh-bugimporters,openhatch/oh-bugimporters,openhatch/oh-bugimporters
|
#!/usr/bin/env python
from setuptools import find_packages, Command
setup_params = dict(
name='bugimporters',
version=0.1,
author='Various contributers to the OpenHatch project, Berry Phillips',
author_email='all@openhatch.org, berryphillips@gmail.com',
packages=find_packages(),
description='Bug importers for the OpenHatch project',
install_requires=[
'gdata',
'lxml',
'cssselect',
'pyopenssl',
'unicodecsv',
'feedparser',
'twisted',
'python-dateutil',
'decorator',
'scrapy>0.9',
'argparse',
'mock',
'PyYAML',
'autoresponse>=0.2',
],
)
### Python 2.7 already has importlib. Because of that,
### we can't put it in install_requires. We test for
### that here; if needed, we add it.
try:
import importlib
except ImportError:
setup_params['install_requires'].append('importlib')
if __name__ == '__main__':
from setuptools import setup
setup(**setup_params)
Upgrade to 0.3.1 to avoid broken 0.3
|
#!/usr/bin/env python
from setuptools import find_packages, Command
setup_params = dict(
name='bugimporters',
version=0.1,
author='Various contributers to the OpenHatch project, Berry Phillips',
author_email='all@openhatch.org, berryphillips@gmail.com',
packages=find_packages(),
description='Bug importers for the OpenHatch project',
install_requires=[
'gdata',
'lxml',
'cssselect',
'pyopenssl',
'unicodecsv',
'feedparser',
'twisted',
'python-dateutil',
'decorator',
'scrapy>0.9',
'argparse',
'mock',
'PyYAML',
'autoresponse>=0.3.1',
],
)
### Python 2.7 already has importlib. Because of that,
### we can't put it in install_requires. We test for
### that here; if needed, we add it.
try:
import importlib
except ImportError:
setup_params['install_requires'].append('importlib')
if __name__ == '__main__':
from setuptools import setup
setup(**setup_params)
|
<commit_before>#!/usr/bin/env python
from setuptools import find_packages, Command
setup_params = dict(
name='bugimporters',
version=0.1,
author='Various contributers to the OpenHatch project, Berry Phillips',
author_email='all@openhatch.org, berryphillips@gmail.com',
packages=find_packages(),
description='Bug importers for the OpenHatch project',
install_requires=[
'gdata',
'lxml',
'cssselect',
'pyopenssl',
'unicodecsv',
'feedparser',
'twisted',
'python-dateutil',
'decorator',
'scrapy>0.9',
'argparse',
'mock',
'PyYAML',
'autoresponse>=0.2',
],
)
### Python 2.7 already has importlib. Because of that,
### we can't put it in install_requires. We test for
### that here; if needed, we add it.
try:
import importlib
except ImportError:
setup_params['install_requires'].append('importlib')
if __name__ == '__main__':
from setuptools import setup
setup(**setup_params)
<commit_msg>Upgrade to 0.3.1 to avoid broken 0.3<commit_after>
|
#!/usr/bin/env python
from setuptools import find_packages, Command
setup_params = dict(
name='bugimporters',
version=0.1,
author='Various contributers to the OpenHatch project, Berry Phillips',
author_email='all@openhatch.org, berryphillips@gmail.com',
packages=find_packages(),
description='Bug importers for the OpenHatch project',
install_requires=[
'gdata',
'lxml',
'cssselect',
'pyopenssl',
'unicodecsv',
'feedparser',
'twisted',
'python-dateutil',
'decorator',
'scrapy>0.9',
'argparse',
'mock',
'PyYAML',
'autoresponse>=0.3.1',
],
)
### Python 2.7 already has importlib. Because of that,
### we can't put it in install_requires. We test for
### that here; if needed, we add it.
try:
import importlib
except ImportError:
setup_params['install_requires'].append('importlib')
if __name__ == '__main__':
from setuptools import setup
setup(**setup_params)
|
#!/usr/bin/env python
from setuptools import find_packages, Command
setup_params = dict(
name='bugimporters',
version=0.1,
author='Various contributers to the OpenHatch project, Berry Phillips',
author_email='all@openhatch.org, berryphillips@gmail.com',
packages=find_packages(),
description='Bug importers for the OpenHatch project',
install_requires=[
'gdata',
'lxml',
'cssselect',
'pyopenssl',
'unicodecsv',
'feedparser',
'twisted',
'python-dateutil',
'decorator',
'scrapy>0.9',
'argparse',
'mock',
'PyYAML',
'autoresponse>=0.2',
],
)
### Python 2.7 already has importlib. Because of that,
### we can't put it in install_requires. We test for
### that here; if needed, we add it.
try:
import importlib
except ImportError:
setup_params['install_requires'].append('importlib')
if __name__ == '__main__':
from setuptools import setup
setup(**setup_params)
Upgrade to 0.3.1 to avoid broken 0.3#!/usr/bin/env python
from setuptools import find_packages, Command
setup_params = dict(
name='bugimporters',
version=0.1,
author='Various contributers to the OpenHatch project, Berry Phillips',
author_email='all@openhatch.org, berryphillips@gmail.com',
packages=find_packages(),
description='Bug importers for the OpenHatch project',
install_requires=[
'gdata',
'lxml',
'cssselect',
'pyopenssl',
'unicodecsv',
'feedparser',
'twisted',
'python-dateutil',
'decorator',
'scrapy>0.9',
'argparse',
'mock',
'PyYAML',
'autoresponse>=0.3.1',
],
)
### Python 2.7 already has importlib. Because of that,
### we can't put it in install_requires. We test for
### that here; if needed, we add it.
try:
import importlib
except ImportError:
setup_params['install_requires'].append('importlib')
if __name__ == '__main__':
from setuptools import setup
setup(**setup_params)
|
<commit_before>#!/usr/bin/env python
from setuptools import find_packages, Command
setup_params = dict(
name='bugimporters',
version=0.1,
author='Various contributers to the OpenHatch project, Berry Phillips',
author_email='all@openhatch.org, berryphillips@gmail.com',
packages=find_packages(),
description='Bug importers for the OpenHatch project',
install_requires=[
'gdata',
'lxml',
'cssselect',
'pyopenssl',
'unicodecsv',
'feedparser',
'twisted',
'python-dateutil',
'decorator',
'scrapy>0.9',
'argparse',
'mock',
'PyYAML',
'autoresponse>=0.2',
],
)
### Python 2.7 already has importlib. Because of that,
### we can't put it in install_requires. We test for
### that here; if needed, we add it.
try:
import importlib
except ImportError:
setup_params['install_requires'].append('importlib')
if __name__ == '__main__':
from setuptools import setup
setup(**setup_params)
<commit_msg>Upgrade to 0.3.1 to avoid broken 0.3<commit_after>#!/usr/bin/env python
from setuptools import find_packages, Command
setup_params = dict(
name='bugimporters',
version=0.1,
author='Various contributers to the OpenHatch project, Berry Phillips',
author_email='all@openhatch.org, berryphillips@gmail.com',
packages=find_packages(),
description='Bug importers for the OpenHatch project',
install_requires=[
'gdata',
'lxml',
'cssselect',
'pyopenssl',
'unicodecsv',
'feedparser',
'twisted',
'python-dateutil',
'decorator',
'scrapy>0.9',
'argparse',
'mock',
'PyYAML',
'autoresponse>=0.3.1',
],
)
### Python 2.7 already has importlib. Because of that,
### we can't put it in install_requires. We test for
### that here; if needed, we add it.
try:
import importlib
except ImportError:
setup_params['install_requires'].append('importlib')
if __name__ == '__main__':
from setuptools import setup
setup(**setup_params)
|
4b4e14830b0407f0bfceb563724ee77efe2b3f73
|
Lib/re.py
|
Lib/re.py
|
#
# Minimal "re" compatibility wrapper
#
# If your regexps don't work well under 2.0b1, you can switch
# to the old engine ("pre") down below.
#
# To help us fix any remaining bugs in the new engine, please
# report what went wrong. You can either use the following web
# page:
#
# http://www.python.org/search/search_bugs.html
#
# or send a mail to SRE's author:
#
# Fredrik Lundh <effbot@telia.com>
#
# Make sure to include the pattern, the string SRE failed to
# match, and what result you expected.
#
# thanks /F
#
engine = "sre"
# engine = "pre"
if engine == "sre":
# New unicode-aware engine
from sre import *
else:
# Old 1.5.2 engine. This one supports 8-bit strings only,
# and will be removed in 2.0 final.
from pre import *
|
#
# Minimal "re" compatibility wrapper
#
# If your regexps don't work well under 2.0b1, you can switch
# to the old engine ("pre") down below.
#
# To help us fix any remaining bugs in the new engine, please
# report what went wrong. You can either use the following web
# page:
#
# http://sourceforge.net/bugs/?group_id=5470
#
# or send a mail to SRE's author:
#
# Fredrik Lundh <effbot@telia.com>
#
# Make sure to include the pattern, the string SRE failed to
# match, and what result you expected.
#
# thanks /F
#
# engine = "sre"
engine = "pre"
if engine == "sre":
# New unicode-aware engine
from sre import *
else:
# Old 1.5.2 engine. This one supports 8-bit strings only,
# and will be removed in 2.0 final.
from pre import *
|
Replace the jitterbug page with the SF Bug Tracker page.
|
Replace the jitterbug page with the SF Bug Tracker page.
|
Python
|
mit
|
sk-/python2.7-type-annotator,sk-/python2.7-type-annotator,sk-/python2.7-type-annotator
|
#
# Minimal "re" compatibility wrapper
#
# If your regexps don't work well under 2.0b1, you can switch
# to the old engine ("pre") down below.
#
# To help us fix any remaining bugs in the new engine, please
# report what went wrong. You can either use the following web
# page:
#
# http://www.python.org/search/search_bugs.html
#
# or send a mail to SRE's author:
#
# Fredrik Lundh <effbot@telia.com>
#
# Make sure to include the pattern, the string SRE failed to
# match, and what result you expected.
#
# thanks /F
#
engine = "sre"
# engine = "pre"
if engine == "sre":
# New unicode-aware engine
from sre import *
else:
# Old 1.5.2 engine. This one supports 8-bit strings only,
# and will be removed in 2.0 final.
from pre import *
Replace the jitterbug page with the SF Bug Tracker page.
|
#
# Minimal "re" compatibility wrapper
#
# If your regexps don't work well under 2.0b1, you can switch
# to the old engine ("pre") down below.
#
# To help us fix any remaining bugs in the new engine, please
# report what went wrong. You can either use the following web
# page:
#
# http://sourceforge.net/bugs/?group_id=5470
#
# or send a mail to SRE's author:
#
# Fredrik Lundh <effbot@telia.com>
#
# Make sure to include the pattern, the string SRE failed to
# match, and what result you expected.
#
# thanks /F
#
# engine = "sre"
engine = "pre"
if engine == "sre":
# New unicode-aware engine
from sre import *
else:
# Old 1.5.2 engine. This one supports 8-bit strings only,
# and will be removed in 2.0 final.
from pre import *
|
<commit_before>#
# Minimal "re" compatibility wrapper
#
# If your regexps don't work well under 2.0b1, you can switch
# to the old engine ("pre") down below.
#
# To help us fix any remaining bugs in the new engine, please
# report what went wrong. You can either use the following web
# page:
#
# http://www.python.org/search/search_bugs.html
#
# or send a mail to SRE's author:
#
# Fredrik Lundh <effbot@telia.com>
#
# Make sure to include the pattern, the string SRE failed to
# match, and what result you expected.
#
# thanks /F
#
engine = "sre"
# engine = "pre"
if engine == "sre":
# New unicode-aware engine
from sre import *
else:
# Old 1.5.2 engine. This one supports 8-bit strings only,
# and will be removed in 2.0 final.
from pre import *
<commit_msg>Replace the jitterbug page with the SF Bug Tracker page.<commit_after>
|
#
# Minimal "re" compatibility wrapper
#
# If your regexps don't work well under 2.0b1, you can switch
# to the old engine ("pre") down below.
#
# To help us fix any remaining bugs in the new engine, please
# report what went wrong. You can either use the following web
# page:
#
# http://sourceforge.net/bugs/?group_id=5470
#
# or send a mail to SRE's author:
#
# Fredrik Lundh <effbot@telia.com>
#
# Make sure to include the pattern, the string SRE failed to
# match, and what result you expected.
#
# thanks /F
#
# engine = "sre"
engine = "pre"
if engine == "sre":
# New unicode-aware engine
from sre import *
else:
# Old 1.5.2 engine. This one supports 8-bit strings only,
# and will be removed in 2.0 final.
from pre import *
|
#
# Minimal "re" compatibility wrapper
#
# If your regexps don't work well under 2.0b1, you can switch
# to the old engine ("pre") down below.
#
# To help us fix any remaining bugs in the new engine, please
# report what went wrong. You can either use the following web
# page:
#
# http://www.python.org/search/search_bugs.html
#
# or send a mail to SRE's author:
#
# Fredrik Lundh <effbot@telia.com>
#
# Make sure to include the pattern, the string SRE failed to
# match, and what result you expected.
#
# thanks /F
#
engine = "sre"
# engine = "pre"
if engine == "sre":
# New unicode-aware engine
from sre import *
else:
# Old 1.5.2 engine. This one supports 8-bit strings only,
# and will be removed in 2.0 final.
from pre import *
Replace the jitterbug page with the SF Bug Tracker page.#
# Minimal "re" compatibility wrapper
#
# If your regexps don't work well under 2.0b1, you can switch
# to the old engine ("pre") down below.
#
# To help us fix any remaining bugs in the new engine, please
# report what went wrong. You can either use the following web
# page:
#
# http://sourceforge.net/bugs/?group_id=5470
#
# or send a mail to SRE's author:
#
# Fredrik Lundh <effbot@telia.com>
#
# Make sure to include the pattern, the string SRE failed to
# match, and what result you expected.
#
# thanks /F
#
# engine = "sre"
engine = "pre"
if engine == "sre":
# New unicode-aware engine
from sre import *
else:
# Old 1.5.2 engine. This one supports 8-bit strings only,
# and will be removed in 2.0 final.
from pre import *
|
<commit_before>#
# Minimal "re" compatibility wrapper
#
# If your regexps don't work well under 2.0b1, you can switch
# to the old engine ("pre") down below.
#
# To help us fix any remaining bugs in the new engine, please
# report what went wrong. You can either use the following web
# page:
#
# http://www.python.org/search/search_bugs.html
#
# or send a mail to SRE's author:
#
# Fredrik Lundh <effbot@telia.com>
#
# Make sure to include the pattern, the string SRE failed to
# match, and what result you expected.
#
# thanks /F
#
engine = "sre"
# engine = "pre"
if engine == "sre":
# New unicode-aware engine
from sre import *
else:
# Old 1.5.2 engine. This one supports 8-bit strings only,
# and will be removed in 2.0 final.
from pre import *
<commit_msg>Replace the jitterbug page with the SF Bug Tracker page.<commit_after>#
# Minimal "re" compatibility wrapper
#
# If your regexps don't work well under 2.0b1, you can switch
# to the old engine ("pre") down below.
#
# To help us fix any remaining bugs in the new engine, please
# report what went wrong. You can either use the following web
# page:
#
# http://sourceforge.net/bugs/?group_id=5470
#
# or send a mail to SRE's author:
#
# Fredrik Lundh <effbot@telia.com>
#
# Make sure to include the pattern, the string SRE failed to
# match, and what result you expected.
#
# thanks /F
#
# engine = "sre"
engine = "pre"
if engine == "sre":
# New unicode-aware engine
from sre import *
else:
# Old 1.5.2 engine. This one supports 8-bit strings only,
# and will be removed in 2.0 final.
from pre import *
|
b59b6b9cd9134b97bea71e491822da16b0256cc8
|
setup.py
|
setup.py
|
from setuptools import setup, find_packages
import sys, os
desc_lines = open('README', 'r').readlines()
PACKAGE = 'mtconvert'
VERSION = open(os.path.join(os.path.dirname(os.path.realpath(__file__)),'oldowan', PACKAGE, 'VERSION')).read().strip()
setup(name='oldowan.%s' % PACKAGE,
version=VERSION,
description=desc_lines[0],
long_description=''.join(desc_lines[2:]),
classifiers=[
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Topic :: Scientific/Engineering :: Bio-Informatics"
],
keywords='bioinformatics',
author='Ryan Raaum',
author_email='code@raaum.org',
url='http://www.raaum.org',
license='MIT',
platforms = ['Any'],
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=False,
install_requires=[
"oldowan.polymorphism >= 1.0.0",
"oldowan.mtdna >= 1.0.0"
],
namespace_packages = ['oldowan'],
data_files=[("oldowan/%s" % PACKAGE, ["oldowan/%s/VERSION" % PACKAGE])],
zip_safe=False,
test_suite = 'nose.collector',
)
|
from setuptools import setup, find_packages
import sys, os
desc_lines = open('README', 'r').readlines()
PACKAGE = 'mtconvert'
VERSION = open(os.path.join(os.path.dirname(os.path.realpath(__file__)),'oldowan', PACKAGE, 'VERSION')).read().strip()
setup(name='oldowan.%s' % PACKAGE,
version=VERSION,
description=desc_lines[0],
long_description=''.join(desc_lines[2:]),
classifiers=[
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Topic :: Scientific/Engineering :: Bio-Informatics"
],
keywords='bioinformatics',
author='Ryan Raaum',
author_email='code@raaum.org',
url='http://www.raaum.org',
license='MIT',
platforms = ['Any'],
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=True,
install_requires=[
"oldowan.polymorphism >= 1.0.0",
"oldowan.mtdna >= 1.0.0"
],
namespace_packages = ['oldowan'],
data_files=[("oldowan/%s" % PACKAGE, ["oldowan/%s/VERSION" % PACKAGE])],
zip_safe=False,
test_suite = 'nose.collector',
)
|
Fix package data so that VERSION file actually gets installed
|
Fix package data so that VERSION file actually gets installed
|
Python
|
mit
|
ryanraaum/oldowan.mtconvert
|
from setuptools import setup, find_packages
import sys, os
desc_lines = open('README', 'r').readlines()
PACKAGE = 'mtconvert'
VERSION = open(os.path.join(os.path.dirname(os.path.realpath(__file__)),'oldowan', PACKAGE, 'VERSION')).read().strip()
setup(name='oldowan.%s' % PACKAGE,
version=VERSION,
description=desc_lines[0],
long_description=''.join(desc_lines[2:]),
classifiers=[
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Topic :: Scientific/Engineering :: Bio-Informatics"
],
keywords='bioinformatics',
author='Ryan Raaum',
author_email='code@raaum.org',
url='http://www.raaum.org',
license='MIT',
platforms = ['Any'],
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=False,
install_requires=[
"oldowan.polymorphism >= 1.0.0",
"oldowan.mtdna >= 1.0.0"
],
namespace_packages = ['oldowan'],
data_files=[("oldowan/%s" % PACKAGE, ["oldowan/%s/VERSION" % PACKAGE])],
zip_safe=False,
test_suite = 'nose.collector',
)
Fix package data so that VERSION file actually gets installed
|
from setuptools import setup, find_packages
import sys, os
desc_lines = open('README', 'r').readlines()
PACKAGE = 'mtconvert'
VERSION = open(os.path.join(os.path.dirname(os.path.realpath(__file__)),'oldowan', PACKAGE, 'VERSION')).read().strip()
setup(name='oldowan.%s' % PACKAGE,
version=VERSION,
description=desc_lines[0],
long_description=''.join(desc_lines[2:]),
classifiers=[
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Topic :: Scientific/Engineering :: Bio-Informatics"
],
keywords='bioinformatics',
author='Ryan Raaum',
author_email='code@raaum.org',
url='http://www.raaum.org',
license='MIT',
platforms = ['Any'],
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=True,
install_requires=[
"oldowan.polymorphism >= 1.0.0",
"oldowan.mtdna >= 1.0.0"
],
namespace_packages = ['oldowan'],
data_files=[("oldowan/%s" % PACKAGE, ["oldowan/%s/VERSION" % PACKAGE])],
zip_safe=False,
test_suite = 'nose.collector',
)
|
<commit_before>from setuptools import setup, find_packages
import sys, os
desc_lines = open('README', 'r').readlines()
PACKAGE = 'mtconvert'
VERSION = open(os.path.join(os.path.dirname(os.path.realpath(__file__)),'oldowan', PACKAGE, 'VERSION')).read().strip()
setup(name='oldowan.%s' % PACKAGE,
version=VERSION,
description=desc_lines[0],
long_description=''.join(desc_lines[2:]),
classifiers=[
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Topic :: Scientific/Engineering :: Bio-Informatics"
],
keywords='bioinformatics',
author='Ryan Raaum',
author_email='code@raaum.org',
url='http://www.raaum.org',
license='MIT',
platforms = ['Any'],
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=False,
install_requires=[
"oldowan.polymorphism >= 1.0.0",
"oldowan.mtdna >= 1.0.0"
],
namespace_packages = ['oldowan'],
data_files=[("oldowan/%s" % PACKAGE, ["oldowan/%s/VERSION" % PACKAGE])],
zip_safe=False,
test_suite = 'nose.collector',
)
<commit_msg>Fix package data so that VERSION file actually gets installed<commit_after>
|
from setuptools import setup, find_packages
import sys, os
desc_lines = open('README', 'r').readlines()
PACKAGE = 'mtconvert'
VERSION = open(os.path.join(os.path.dirname(os.path.realpath(__file__)),'oldowan', PACKAGE, 'VERSION')).read().strip()
setup(name='oldowan.%s' % PACKAGE,
version=VERSION,
description=desc_lines[0],
long_description=''.join(desc_lines[2:]),
classifiers=[
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Topic :: Scientific/Engineering :: Bio-Informatics"
],
keywords='bioinformatics',
author='Ryan Raaum',
author_email='code@raaum.org',
url='http://www.raaum.org',
license='MIT',
platforms = ['Any'],
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=True,
install_requires=[
"oldowan.polymorphism >= 1.0.0",
"oldowan.mtdna >= 1.0.0"
],
namespace_packages = ['oldowan'],
data_files=[("oldowan/%s" % PACKAGE, ["oldowan/%s/VERSION" % PACKAGE])],
zip_safe=False,
test_suite = 'nose.collector',
)
|
from setuptools import setup, find_packages
import sys, os
desc_lines = open('README', 'r').readlines()
PACKAGE = 'mtconvert'
VERSION = open(os.path.join(os.path.dirname(os.path.realpath(__file__)),'oldowan', PACKAGE, 'VERSION')).read().strip()
setup(name='oldowan.%s' % PACKAGE,
version=VERSION,
description=desc_lines[0],
long_description=''.join(desc_lines[2:]),
classifiers=[
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Topic :: Scientific/Engineering :: Bio-Informatics"
],
keywords='bioinformatics',
author='Ryan Raaum',
author_email='code@raaum.org',
url='http://www.raaum.org',
license='MIT',
platforms = ['Any'],
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=False,
install_requires=[
"oldowan.polymorphism >= 1.0.0",
"oldowan.mtdna >= 1.0.0"
],
namespace_packages = ['oldowan'],
data_files=[("oldowan/%s" % PACKAGE, ["oldowan/%s/VERSION" % PACKAGE])],
zip_safe=False,
test_suite = 'nose.collector',
)
Fix package data so that VERSION file actually gets installedfrom setuptools import setup, find_packages
import sys, os
desc_lines = open('README', 'r').readlines()
PACKAGE = 'mtconvert'
VERSION = open(os.path.join(os.path.dirname(os.path.realpath(__file__)),'oldowan', PACKAGE, 'VERSION')).read().strip()
setup(name='oldowan.%s' % PACKAGE,
version=VERSION,
description=desc_lines[0],
long_description=''.join(desc_lines[2:]),
classifiers=[
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Topic :: Scientific/Engineering :: Bio-Informatics"
],
keywords='bioinformatics',
author='Ryan Raaum',
author_email='code@raaum.org',
url='http://www.raaum.org',
license='MIT',
platforms = ['Any'],
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=True,
install_requires=[
"oldowan.polymorphism >= 1.0.0",
"oldowan.mtdna >= 1.0.0"
],
namespace_packages = ['oldowan'],
data_files=[("oldowan/%s" % PACKAGE, ["oldowan/%s/VERSION" % PACKAGE])],
zip_safe=False,
test_suite = 'nose.collector',
)
|
<commit_before>from setuptools import setup, find_packages
import sys, os
desc_lines = open('README', 'r').readlines()
PACKAGE = 'mtconvert'
VERSION = open(os.path.join(os.path.dirname(os.path.realpath(__file__)),'oldowan', PACKAGE, 'VERSION')).read().strip()
setup(name='oldowan.%s' % PACKAGE,
version=VERSION,
description=desc_lines[0],
long_description=''.join(desc_lines[2:]),
classifiers=[
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Topic :: Scientific/Engineering :: Bio-Informatics"
],
keywords='bioinformatics',
author='Ryan Raaum',
author_email='code@raaum.org',
url='http://www.raaum.org',
license='MIT',
platforms = ['Any'],
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=False,
install_requires=[
"oldowan.polymorphism >= 1.0.0",
"oldowan.mtdna >= 1.0.0"
],
namespace_packages = ['oldowan'],
data_files=[("oldowan/%s" % PACKAGE, ["oldowan/%s/VERSION" % PACKAGE])],
zip_safe=False,
test_suite = 'nose.collector',
)
<commit_msg>Fix package data so that VERSION file actually gets installed<commit_after>from setuptools import setup, find_packages
import sys, os
desc_lines = open('README', 'r').readlines()
PACKAGE = 'mtconvert'
VERSION = open(os.path.join(os.path.dirname(os.path.realpath(__file__)),'oldowan', PACKAGE, 'VERSION')).read().strip()
setup(name='oldowan.%s' % PACKAGE,
version=VERSION,
description=desc_lines[0],
long_description=''.join(desc_lines[2:]),
classifiers=[
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python",
"Topic :: Scientific/Engineering :: Bio-Informatics"
],
keywords='bioinformatics',
author='Ryan Raaum',
author_email='code@raaum.org',
url='http://www.raaum.org',
license='MIT',
platforms = ['Any'],
packages=find_packages(exclude=['ez_setup', 'examples', 'tests']),
include_package_data=True,
install_requires=[
"oldowan.polymorphism >= 1.0.0",
"oldowan.mtdna >= 1.0.0"
],
namespace_packages = ['oldowan'],
data_files=[("oldowan/%s" % PACKAGE, ["oldowan/%s/VERSION" % PACKAGE])],
zip_safe=False,
test_suite = 'nose.collector',
)
|
9d8d426c452492fb3d5e255d31f2c5f96f257b8d
|
setup.py
|
setup.py
|
from setuptools import setup, find_packages
def parse_requirements(requirement_file):
with open(requirement_file) as f:
return f.readlines()
setup(
name="swimlane",
author="Swimlane LLC",
author_email="info@swimlane.com",
url="https://github.com/swimlane/swimlane-python",
packages=find_packages(exclude=('tests', 'tests.*')),
description="A Python client for Swimlane.",
install_requires=parse_requirements('./requirements.txt'),
setup_requires=[
'setuptools_scm',
'pytest-runner'
],
use_scm_version=True,
tests_require=parse_requirements('./test-requirements.txt'),
classifiers=[
"License :: OSI Approved :: GNU Affero General Public License v3",
"Development Status :: 4 - Beta",
"Programming Language :: Python",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: Implementation :: PyPy"
]
)
|
from setuptools import setup, find_packages
def parse_requirements(requirement_file):
with open(requirement_file) as f:
return f.readlines()
setup(
name="swimlane",
author="Swimlane LLC",
author_email="info@swimlane.com",
url="https://github.com/swimlane/swimlane-python",
packages=find_packages(exclude=('tests', 'tests.*')),
description="A Python client for Swimlane.",
install_requires=parse_requirements('./requirements.txt'),
setup_requires=[
'setuptools_scm',
'pytest-runner'
],
use_scm_version=True,
tests_require=parse_requirements('./test-requirements.txt'),
classifiers=[
"License :: OSI Approved :: GNU Affero General Public License v3",
"Development Status :: 4 - Beta",
"Programming Language :: Python",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
]
)
|
Remove Pypy from list of supported Python versions
|
Remove Pypy from list of supported Python versions
|
Python
|
mit
|
Swimlane/sw-python-client
|
from setuptools import setup, find_packages
def parse_requirements(requirement_file):
with open(requirement_file) as f:
return f.readlines()
setup(
name="swimlane",
author="Swimlane LLC",
author_email="info@swimlane.com",
url="https://github.com/swimlane/swimlane-python",
packages=find_packages(exclude=('tests', 'tests.*')),
description="A Python client for Swimlane.",
install_requires=parse_requirements('./requirements.txt'),
setup_requires=[
'setuptools_scm',
'pytest-runner'
],
use_scm_version=True,
tests_require=parse_requirements('./test-requirements.txt'),
classifiers=[
"License :: OSI Approved :: GNU Affero General Public License v3",
"Development Status :: 4 - Beta",
"Programming Language :: Python",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: Implementation :: PyPy"
]
)
Remove Pypy from list of supported Python versions
|
from setuptools import setup, find_packages
def parse_requirements(requirement_file):
with open(requirement_file) as f:
return f.readlines()
setup(
name="swimlane",
author="Swimlane LLC",
author_email="info@swimlane.com",
url="https://github.com/swimlane/swimlane-python",
packages=find_packages(exclude=('tests', 'tests.*')),
description="A Python client for Swimlane.",
install_requires=parse_requirements('./requirements.txt'),
setup_requires=[
'setuptools_scm',
'pytest-runner'
],
use_scm_version=True,
tests_require=parse_requirements('./test-requirements.txt'),
classifiers=[
"License :: OSI Approved :: GNU Affero General Public License v3",
"Development Status :: 4 - Beta",
"Programming Language :: Python",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
]
)
|
<commit_before>from setuptools import setup, find_packages
def parse_requirements(requirement_file):
with open(requirement_file) as f:
return f.readlines()
setup(
name="swimlane",
author="Swimlane LLC",
author_email="info@swimlane.com",
url="https://github.com/swimlane/swimlane-python",
packages=find_packages(exclude=('tests', 'tests.*')),
description="A Python client for Swimlane.",
install_requires=parse_requirements('./requirements.txt'),
setup_requires=[
'setuptools_scm',
'pytest-runner'
],
use_scm_version=True,
tests_require=parse_requirements('./test-requirements.txt'),
classifiers=[
"License :: OSI Approved :: GNU Affero General Public License v3",
"Development Status :: 4 - Beta",
"Programming Language :: Python",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: Implementation :: PyPy"
]
)
<commit_msg>Remove Pypy from list of supported Python versions<commit_after>
|
from setuptools import setup, find_packages
def parse_requirements(requirement_file):
with open(requirement_file) as f:
return f.readlines()
setup(
name="swimlane",
author="Swimlane LLC",
author_email="info@swimlane.com",
url="https://github.com/swimlane/swimlane-python",
packages=find_packages(exclude=('tests', 'tests.*')),
description="A Python client for Swimlane.",
install_requires=parse_requirements('./requirements.txt'),
setup_requires=[
'setuptools_scm',
'pytest-runner'
],
use_scm_version=True,
tests_require=parse_requirements('./test-requirements.txt'),
classifiers=[
"License :: OSI Approved :: GNU Affero General Public License v3",
"Development Status :: 4 - Beta",
"Programming Language :: Python",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
]
)
|
from setuptools import setup, find_packages
def parse_requirements(requirement_file):
with open(requirement_file) as f:
return f.readlines()
setup(
name="swimlane",
author="Swimlane LLC",
author_email="info@swimlane.com",
url="https://github.com/swimlane/swimlane-python",
packages=find_packages(exclude=('tests', 'tests.*')),
description="A Python client for Swimlane.",
install_requires=parse_requirements('./requirements.txt'),
setup_requires=[
'setuptools_scm',
'pytest-runner'
],
use_scm_version=True,
tests_require=parse_requirements('./test-requirements.txt'),
classifiers=[
"License :: OSI Approved :: GNU Affero General Public License v3",
"Development Status :: 4 - Beta",
"Programming Language :: Python",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: Implementation :: PyPy"
]
)
Remove Pypy from list of supported Python versionsfrom setuptools import setup, find_packages
def parse_requirements(requirement_file):
with open(requirement_file) as f:
return f.readlines()
setup(
name="swimlane",
author="Swimlane LLC",
author_email="info@swimlane.com",
url="https://github.com/swimlane/swimlane-python",
packages=find_packages(exclude=('tests', 'tests.*')),
description="A Python client for Swimlane.",
install_requires=parse_requirements('./requirements.txt'),
setup_requires=[
'setuptools_scm',
'pytest-runner'
],
use_scm_version=True,
tests_require=parse_requirements('./test-requirements.txt'),
classifiers=[
"License :: OSI Approved :: GNU Affero General Public License v3",
"Development Status :: 4 - Beta",
"Programming Language :: Python",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
]
)
|
<commit_before>from setuptools import setup, find_packages
def parse_requirements(requirement_file):
with open(requirement_file) as f:
return f.readlines()
setup(
name="swimlane",
author="Swimlane LLC",
author_email="info@swimlane.com",
url="https://github.com/swimlane/swimlane-python",
packages=find_packages(exclude=('tests', 'tests.*')),
description="A Python client for Swimlane.",
install_requires=parse_requirements('./requirements.txt'),
setup_requires=[
'setuptools_scm',
'pytest-runner'
],
use_scm_version=True,
tests_require=parse_requirements('./test-requirements.txt'),
classifiers=[
"License :: OSI Approved :: GNU Affero General Public License v3",
"Development Status :: 4 - Beta",
"Programming Language :: Python",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: Implementation :: PyPy"
]
)
<commit_msg>Remove Pypy from list of supported Python versions<commit_after>from setuptools import setup, find_packages
def parse_requirements(requirement_file):
with open(requirement_file) as f:
return f.readlines()
setup(
name="swimlane",
author="Swimlane LLC",
author_email="info@swimlane.com",
url="https://github.com/swimlane/swimlane-python",
packages=find_packages(exclude=('tests', 'tests.*')),
description="A Python client for Swimlane.",
install_requires=parse_requirements('./requirements.txt'),
setup_requires=[
'setuptools_scm',
'pytest-runner'
],
use_scm_version=True,
tests_require=parse_requirements('./test-requirements.txt'),
classifiers=[
"License :: OSI Approved :: GNU Affero General Public License v3",
"Development Status :: 4 - Beta",
"Programming Language :: Python",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6",
]
)
|
43a7652639b4448ee2a6684717eca6c285ea43e9
|
setup.py
|
setup.py
|
#!/usr/bin/env python
from setuptools import setup, find_packages
setup(name='simplecoin_rpc_client',
version='0.2.0',
author='Isaac Cook',
author_email='isaac@simpload.com',
entry_points={
'console_scripts': [
'simplecoin_rpc_scheduler = simplecoin_rpc_client.scheduler:entry',
'simplecoin_rpc = simplecoin_rpc_client.sc_rpc:entry'
]
},
packages=find_packages()
)
|
#!/usr/bin/env python
from setuptools import setup, find_packages
setup(name='simplecoin_rpc_client',
version='0.2.0',
author='Isaac Cook',
author_email='isaac@simpload.com',
entry_points={
'console_scripts': [
'simplecoin_rpc_scheduler = simplecoin_rpc_client.scheduler:entry',
'simplecoin_rpc = simplecoin_rpc_client.manage:entry'
]
},
packages=find_packages()
)
|
Fix incorrect module path in manual management command
|
Fix incorrect module path in manual management command
|
Python
|
isc
|
simplecrypto/simplecoin_rpc_client
|
#!/usr/bin/env python
from setuptools import setup, find_packages
setup(name='simplecoin_rpc_client',
version='0.2.0',
author='Isaac Cook',
author_email='isaac@simpload.com',
entry_points={
'console_scripts': [
'simplecoin_rpc_scheduler = simplecoin_rpc_client.scheduler:entry',
'simplecoin_rpc = simplecoin_rpc_client.sc_rpc:entry'
]
},
packages=find_packages()
)
Fix incorrect module path in manual management command
|
#!/usr/bin/env python
from setuptools import setup, find_packages
setup(name='simplecoin_rpc_client',
version='0.2.0',
author='Isaac Cook',
author_email='isaac@simpload.com',
entry_points={
'console_scripts': [
'simplecoin_rpc_scheduler = simplecoin_rpc_client.scheduler:entry',
'simplecoin_rpc = simplecoin_rpc_client.manage:entry'
]
},
packages=find_packages()
)
|
<commit_before>#!/usr/bin/env python
from setuptools import setup, find_packages
setup(name='simplecoin_rpc_client',
version='0.2.0',
author='Isaac Cook',
author_email='isaac@simpload.com',
entry_points={
'console_scripts': [
'simplecoin_rpc_scheduler = simplecoin_rpc_client.scheduler:entry',
'simplecoin_rpc = simplecoin_rpc_client.sc_rpc:entry'
]
},
packages=find_packages()
)
<commit_msg>Fix incorrect module path in manual management command<commit_after>
|
#!/usr/bin/env python
from setuptools import setup, find_packages
setup(name='simplecoin_rpc_client',
version='0.2.0',
author='Isaac Cook',
author_email='isaac@simpload.com',
entry_points={
'console_scripts': [
'simplecoin_rpc_scheduler = simplecoin_rpc_client.scheduler:entry',
'simplecoin_rpc = simplecoin_rpc_client.manage:entry'
]
},
packages=find_packages()
)
|
#!/usr/bin/env python
from setuptools import setup, find_packages
setup(name='simplecoin_rpc_client',
version='0.2.0',
author='Isaac Cook',
author_email='isaac@simpload.com',
entry_points={
'console_scripts': [
'simplecoin_rpc_scheduler = simplecoin_rpc_client.scheduler:entry',
'simplecoin_rpc = simplecoin_rpc_client.sc_rpc:entry'
]
},
packages=find_packages()
)
Fix incorrect module path in manual management command#!/usr/bin/env python
from setuptools import setup, find_packages
setup(name='simplecoin_rpc_client',
version='0.2.0',
author='Isaac Cook',
author_email='isaac@simpload.com',
entry_points={
'console_scripts': [
'simplecoin_rpc_scheduler = simplecoin_rpc_client.scheduler:entry',
'simplecoin_rpc = simplecoin_rpc_client.manage:entry'
]
},
packages=find_packages()
)
|
<commit_before>#!/usr/bin/env python
from setuptools import setup, find_packages
setup(name='simplecoin_rpc_client',
version='0.2.0',
author='Isaac Cook',
author_email='isaac@simpload.com',
entry_points={
'console_scripts': [
'simplecoin_rpc_scheduler = simplecoin_rpc_client.scheduler:entry',
'simplecoin_rpc = simplecoin_rpc_client.sc_rpc:entry'
]
},
packages=find_packages()
)
<commit_msg>Fix incorrect module path in manual management command<commit_after>#!/usr/bin/env python
from setuptools import setup, find_packages
setup(name='simplecoin_rpc_client',
version='0.2.0',
author='Isaac Cook',
author_email='isaac@simpload.com',
entry_points={
'console_scripts': [
'simplecoin_rpc_scheduler = simplecoin_rpc_client.scheduler:entry',
'simplecoin_rpc = simplecoin_rpc_client.manage:entry'
]
},
packages=find_packages()
)
|
c6da491512bce15e3662a64a7ac4668441b53c5a
|
setup.py
|
setup.py
|
"""Installer for marked
"""
from setuptools import setup, find_packages
setup(
name='marked',
description='',
long_description=open('README.rst').read(),
provides=['marked'],
version='1.0.0',
author='Wes Mason',
author_email='wes@1stvamp.org',
url='https://github.com/1stvamp/marked.py',
install_requires=[
'beautifulsoup4 >= 4.3',
'markgen >= 0.9'
],
packages=find_packages(exclude=['marked_tests']),
package_data={},
include_package_data=True,
license='BSD'
)
|
"""Installer for marked
"""
from setuptools import setup, find_packages
setup(
name='marked',
description='Library/utility that converts HTML to markdown text',
long_description=open('README.rst').read(),
provides=['marked'],
version='1.0.0',
author='Wes Mason',
author_email='wes@1stvamp.org',
url='https://github.com/1stvamp/marked.py',
install_requires=[
'beautifulsoup4 >= 4.3',
'markgen >= 0.9'
],
packages=find_packages(exclude=['marked_tests']),
package_data={},
include_package_data=True,
license='BSD'
)
|
Add short description to egg
|
Add short description to egg
|
Python
|
bsd-3-clause
|
1stvamp/marked
|
"""Installer for marked
"""
from setuptools import setup, find_packages
setup(
name='marked',
description='',
long_description=open('README.rst').read(),
provides=['marked'],
version='1.0.0',
author='Wes Mason',
author_email='wes@1stvamp.org',
url='https://github.com/1stvamp/marked.py',
install_requires=[
'beautifulsoup4 >= 4.3',
'markgen >= 0.9'
],
packages=find_packages(exclude=['marked_tests']),
package_data={},
include_package_data=True,
license='BSD'
)
Add short description to egg
|
"""Installer for marked
"""
from setuptools import setup, find_packages
setup(
name='marked',
description='Library/utility that converts HTML to markdown text',
long_description=open('README.rst').read(),
provides=['marked'],
version='1.0.0',
author='Wes Mason',
author_email='wes@1stvamp.org',
url='https://github.com/1stvamp/marked.py',
install_requires=[
'beautifulsoup4 >= 4.3',
'markgen >= 0.9'
],
packages=find_packages(exclude=['marked_tests']),
package_data={},
include_package_data=True,
license='BSD'
)
|
<commit_before>"""Installer for marked
"""
from setuptools import setup, find_packages
setup(
name='marked',
description='',
long_description=open('README.rst').read(),
provides=['marked'],
version='1.0.0',
author='Wes Mason',
author_email='wes@1stvamp.org',
url='https://github.com/1stvamp/marked.py',
install_requires=[
'beautifulsoup4 >= 4.3',
'markgen >= 0.9'
],
packages=find_packages(exclude=['marked_tests']),
package_data={},
include_package_data=True,
license='BSD'
)
<commit_msg>Add short description to egg<commit_after>
|
"""Installer for marked
"""
from setuptools import setup, find_packages
setup(
name='marked',
description='Library/utility that converts HTML to markdown text',
long_description=open('README.rst').read(),
provides=['marked'],
version='1.0.0',
author='Wes Mason',
author_email='wes@1stvamp.org',
url='https://github.com/1stvamp/marked.py',
install_requires=[
'beautifulsoup4 >= 4.3',
'markgen >= 0.9'
],
packages=find_packages(exclude=['marked_tests']),
package_data={},
include_package_data=True,
license='BSD'
)
|
"""Installer for marked
"""
from setuptools import setup, find_packages
setup(
name='marked',
description='',
long_description=open('README.rst').read(),
provides=['marked'],
version='1.0.0',
author='Wes Mason',
author_email='wes@1stvamp.org',
url='https://github.com/1stvamp/marked.py',
install_requires=[
'beautifulsoup4 >= 4.3',
'markgen >= 0.9'
],
packages=find_packages(exclude=['marked_tests']),
package_data={},
include_package_data=True,
license='BSD'
)
Add short description to egg"""Installer for marked
"""
from setuptools import setup, find_packages
setup(
name='marked',
description='Library/utility that converts HTML to markdown text',
long_description=open('README.rst').read(),
provides=['marked'],
version='1.0.0',
author='Wes Mason',
author_email='wes@1stvamp.org',
url='https://github.com/1stvamp/marked.py',
install_requires=[
'beautifulsoup4 >= 4.3',
'markgen >= 0.9'
],
packages=find_packages(exclude=['marked_tests']),
package_data={},
include_package_data=True,
license='BSD'
)
|
<commit_before>"""Installer for marked
"""
from setuptools import setup, find_packages
setup(
name='marked',
description='',
long_description=open('README.rst').read(),
provides=['marked'],
version='1.0.0',
author='Wes Mason',
author_email='wes@1stvamp.org',
url='https://github.com/1stvamp/marked.py',
install_requires=[
'beautifulsoup4 >= 4.3',
'markgen >= 0.9'
],
packages=find_packages(exclude=['marked_tests']),
package_data={},
include_package_data=True,
license='BSD'
)
<commit_msg>Add short description to egg<commit_after>"""Installer for marked
"""
from setuptools import setup, find_packages
setup(
name='marked',
description='Library/utility that converts HTML to markdown text',
long_description=open('README.rst').read(),
provides=['marked'],
version='1.0.0',
author='Wes Mason',
author_email='wes@1stvamp.org',
url='https://github.com/1stvamp/marked.py',
install_requires=[
'beautifulsoup4 >= 4.3',
'markgen >= 0.9'
],
packages=find_packages(exclude=['marked_tests']),
package_data={},
include_package_data=True,
license='BSD'
)
|
90093b78240abd0b49132c28b82ff43137acdfd0
|
setup.py
|
setup.py
|
# Copyright 2018 Google LLC
#
# 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
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from setuptools import setup, find_packages
global __version__
__version__ = None
with open('jax/version.py') as f:
exec(f.read(), globals())
setup(
name='jax',
version=__version__,
description='Differentiate, compile, and transform Numpy code.',
author='JAX team',
author_email='jax-dev@google.com',
packages=find_packages(exclude=["examples"]),
install_requires=[
'numpy>=1.12', 'six', 'protobuf>=3.6.0', 'absl-py', 'opt_einsum<3',
'fastcache'
],
url='https://github.com/google/jax',
license='Apache-2.0',
)
|
# Copyright 2018 Google LLC
#
# 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
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from setuptools import setup, find_packages
global __version__
__version__ = None
with open('jax/version.py') as f:
exec(f.read(), globals())
setup(
name='jax',
version=__version__,
description='Differentiate, compile, and transform Numpy code.',
author='JAX team',
author_email='jax-dev@google.com',
packages=find_packages(exclude=["examples"]),
install_requires=[
'numpy>=1.12', 'six', 'protobuf>=3.6.0', 'absl-py', 'opt_einsum',
'fastcache'
],
url='https://github.com/google/jax',
license='Apache-2.0',
)
|
Remove version restriction from opt_einsum.
|
Remove version restriction from opt_einsum.
See https://github.com/dgasmith/opt_einsum/issues/98.
|
Python
|
apache-2.0
|
tensorflow/probability,google/jax,tensorflow/probability,google/jax,google/jax,google/jax
|
# Copyright 2018 Google LLC
#
# 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
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from setuptools import setup, find_packages
global __version__
__version__ = None
with open('jax/version.py') as f:
exec(f.read(), globals())
setup(
name='jax',
version=__version__,
description='Differentiate, compile, and transform Numpy code.',
author='JAX team',
author_email='jax-dev@google.com',
packages=find_packages(exclude=["examples"]),
install_requires=[
'numpy>=1.12', 'six', 'protobuf>=3.6.0', 'absl-py', 'opt_einsum<3',
'fastcache'
],
url='https://github.com/google/jax',
license='Apache-2.0',
)
Remove version restriction from opt_einsum.
See https://github.com/dgasmith/opt_einsum/issues/98.
|
# Copyright 2018 Google LLC
#
# 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
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from setuptools import setup, find_packages
global __version__
__version__ = None
with open('jax/version.py') as f:
exec(f.read(), globals())
setup(
name='jax',
version=__version__,
description='Differentiate, compile, and transform Numpy code.',
author='JAX team',
author_email='jax-dev@google.com',
packages=find_packages(exclude=["examples"]),
install_requires=[
'numpy>=1.12', 'six', 'protobuf>=3.6.0', 'absl-py', 'opt_einsum',
'fastcache'
],
url='https://github.com/google/jax',
license='Apache-2.0',
)
|
<commit_before># Copyright 2018 Google LLC
#
# 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
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from setuptools import setup, find_packages
global __version__
__version__ = None
with open('jax/version.py') as f:
exec(f.read(), globals())
setup(
name='jax',
version=__version__,
description='Differentiate, compile, and transform Numpy code.',
author='JAX team',
author_email='jax-dev@google.com',
packages=find_packages(exclude=["examples"]),
install_requires=[
'numpy>=1.12', 'six', 'protobuf>=3.6.0', 'absl-py', 'opt_einsum<3',
'fastcache'
],
url='https://github.com/google/jax',
license='Apache-2.0',
)
<commit_msg>Remove version restriction from opt_einsum.
See https://github.com/dgasmith/opt_einsum/issues/98.<commit_after>
|
# Copyright 2018 Google LLC
#
# 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
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from setuptools import setup, find_packages
global __version__
__version__ = None
with open('jax/version.py') as f:
exec(f.read(), globals())
setup(
name='jax',
version=__version__,
description='Differentiate, compile, and transform Numpy code.',
author='JAX team',
author_email='jax-dev@google.com',
packages=find_packages(exclude=["examples"]),
install_requires=[
'numpy>=1.12', 'six', 'protobuf>=3.6.0', 'absl-py', 'opt_einsum',
'fastcache'
],
url='https://github.com/google/jax',
license='Apache-2.0',
)
|
# Copyright 2018 Google LLC
#
# 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
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from setuptools import setup, find_packages
global __version__
__version__ = None
with open('jax/version.py') as f:
exec(f.read(), globals())
setup(
name='jax',
version=__version__,
description='Differentiate, compile, and transform Numpy code.',
author='JAX team',
author_email='jax-dev@google.com',
packages=find_packages(exclude=["examples"]),
install_requires=[
'numpy>=1.12', 'six', 'protobuf>=3.6.0', 'absl-py', 'opt_einsum<3',
'fastcache'
],
url='https://github.com/google/jax',
license='Apache-2.0',
)
Remove version restriction from opt_einsum.
See https://github.com/dgasmith/opt_einsum/issues/98.# Copyright 2018 Google LLC
#
# 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
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from setuptools import setup, find_packages
global __version__
__version__ = None
with open('jax/version.py') as f:
exec(f.read(), globals())
setup(
name='jax',
version=__version__,
description='Differentiate, compile, and transform Numpy code.',
author='JAX team',
author_email='jax-dev@google.com',
packages=find_packages(exclude=["examples"]),
install_requires=[
'numpy>=1.12', 'six', 'protobuf>=3.6.0', 'absl-py', 'opt_einsum',
'fastcache'
],
url='https://github.com/google/jax',
license='Apache-2.0',
)
|
<commit_before># Copyright 2018 Google LLC
#
# 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
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from setuptools import setup, find_packages
global __version__
__version__ = None
with open('jax/version.py') as f:
exec(f.read(), globals())
setup(
name='jax',
version=__version__,
description='Differentiate, compile, and transform Numpy code.',
author='JAX team',
author_email='jax-dev@google.com',
packages=find_packages(exclude=["examples"]),
install_requires=[
'numpy>=1.12', 'six', 'protobuf>=3.6.0', 'absl-py', 'opt_einsum<3',
'fastcache'
],
url='https://github.com/google/jax',
license='Apache-2.0',
)
<commit_msg>Remove version restriction from opt_einsum.
See https://github.com/dgasmith/opt_einsum/issues/98.<commit_after># Copyright 2018 Google LLC
#
# 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
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from setuptools import setup, find_packages
global __version__
__version__ = None
with open('jax/version.py') as f:
exec(f.read(), globals())
setup(
name='jax',
version=__version__,
description='Differentiate, compile, and transform Numpy code.',
author='JAX team',
author_email='jax-dev@google.com',
packages=find_packages(exclude=["examples"]),
install_requires=[
'numpy>=1.12', 'six', 'protobuf>=3.6.0', 'absl-py', 'opt_einsum',
'fastcache'
],
url='https://github.com/google/jax',
license='Apache-2.0',
)
|
1752df7ad93776635c2ad0ff3871e1a333b85845
|
setup.py
|
setup.py
|
#!/usr/bin/env python
import os
from setuptools import setup, find_packages
import versions
def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read()
setup(
name='versions',
version=versions.__version__,
description='Package version handling library',
long_description=read('README.rst'),
author='Philippe Muller',
url='http://github.com/pmuller/versions',
license='MIT',
packages=find_packages(),
classifiers=(
'Development Status :: 3 - Alpha',
'Environment :: Console',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Topic :: Software Development',
'Topic :: System :: Installation/Setup',
'Topic :: System :: Software Distribution',
),
)
|
#!/usr/bin/env python
import os
from setuptools import setup, find_packages
import versions
def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read()
setup(
name='versions',
version=versions.__version__,
description='Package version handling library',
long_description=read('README.rst'),
author='Philippe Muller',
url='http://github.com/pmuller/versions',
license='MIT',
packages=find_packages(),
classifiers=(
'Development Status :: 3 - Alpha',
'Environment :: Console',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Topic :: Software Development',
'Topic :: System :: Installation/Setup',
'Topic :: System :: Software Distribution',
),
)
|
Add classifiers for Python 3.2 and 3.3
|
Add classifiers for Python 3.2 and 3.3
|
Python
|
mit
|
pmuller/versions,pmuller/versions
|
#!/usr/bin/env python
import os
from setuptools import setup, find_packages
import versions
def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read()
setup(
name='versions',
version=versions.__version__,
description='Package version handling library',
long_description=read('README.rst'),
author='Philippe Muller',
url='http://github.com/pmuller/versions',
license='MIT',
packages=find_packages(),
classifiers=(
'Development Status :: 3 - Alpha',
'Environment :: Console',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Topic :: Software Development',
'Topic :: System :: Installation/Setup',
'Topic :: System :: Software Distribution',
),
)
Add classifiers for Python 3.2 and 3.3
|
#!/usr/bin/env python
import os
from setuptools import setup, find_packages
import versions
def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read()
setup(
name='versions',
version=versions.__version__,
description='Package version handling library',
long_description=read('README.rst'),
author='Philippe Muller',
url='http://github.com/pmuller/versions',
license='MIT',
packages=find_packages(),
classifiers=(
'Development Status :: 3 - Alpha',
'Environment :: Console',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Topic :: Software Development',
'Topic :: System :: Installation/Setup',
'Topic :: System :: Software Distribution',
),
)
|
<commit_before>#!/usr/bin/env python
import os
from setuptools import setup, find_packages
import versions
def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read()
setup(
name='versions',
version=versions.__version__,
description='Package version handling library',
long_description=read('README.rst'),
author='Philippe Muller',
url='http://github.com/pmuller/versions',
license='MIT',
packages=find_packages(),
classifiers=(
'Development Status :: 3 - Alpha',
'Environment :: Console',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Topic :: Software Development',
'Topic :: System :: Installation/Setup',
'Topic :: System :: Software Distribution',
),
)
<commit_msg>Add classifiers for Python 3.2 and 3.3<commit_after>
|
#!/usr/bin/env python
import os
from setuptools import setup, find_packages
import versions
def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read()
setup(
name='versions',
version=versions.__version__,
description='Package version handling library',
long_description=read('README.rst'),
author='Philippe Muller',
url='http://github.com/pmuller/versions',
license='MIT',
packages=find_packages(),
classifiers=(
'Development Status :: 3 - Alpha',
'Environment :: Console',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Topic :: Software Development',
'Topic :: System :: Installation/Setup',
'Topic :: System :: Software Distribution',
),
)
|
#!/usr/bin/env python
import os
from setuptools import setup, find_packages
import versions
def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read()
setup(
name='versions',
version=versions.__version__,
description='Package version handling library',
long_description=read('README.rst'),
author='Philippe Muller',
url='http://github.com/pmuller/versions',
license='MIT',
packages=find_packages(),
classifiers=(
'Development Status :: 3 - Alpha',
'Environment :: Console',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Topic :: Software Development',
'Topic :: System :: Installation/Setup',
'Topic :: System :: Software Distribution',
),
)
Add classifiers for Python 3.2 and 3.3#!/usr/bin/env python
import os
from setuptools import setup, find_packages
import versions
def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read()
setup(
name='versions',
version=versions.__version__,
description='Package version handling library',
long_description=read('README.rst'),
author='Philippe Muller',
url='http://github.com/pmuller/versions',
license='MIT',
packages=find_packages(),
classifiers=(
'Development Status :: 3 - Alpha',
'Environment :: Console',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Topic :: Software Development',
'Topic :: System :: Installation/Setup',
'Topic :: System :: Software Distribution',
),
)
|
<commit_before>#!/usr/bin/env python
import os
from setuptools import setup, find_packages
import versions
def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read()
setup(
name='versions',
version=versions.__version__,
description='Package version handling library',
long_description=read('README.rst'),
author='Philippe Muller',
url='http://github.com/pmuller/versions',
license='MIT',
packages=find_packages(),
classifiers=(
'Development Status :: 3 - Alpha',
'Environment :: Console',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Topic :: Software Development',
'Topic :: System :: Installation/Setup',
'Topic :: System :: Software Distribution',
),
)
<commit_msg>Add classifiers for Python 3.2 and 3.3<commit_after>#!/usr/bin/env python
import os
from setuptools import setup, find_packages
import versions
def read(fname):
return open(os.path.join(os.path.dirname(__file__), fname)).read()
setup(
name='versions',
version=versions.__version__,
description='Package version handling library',
long_description=read('README.rst'),
author='Philippe Muller',
url='http://github.com/pmuller/versions',
license='MIT',
packages=find_packages(),
classifiers=(
'Development Status :: 3 - Alpha',
'Environment :: Console',
'Intended Audience :: Developers',
'License :: OSI Approved :: MIT License',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Topic :: Software Development',
'Topic :: System :: Installation/Setup',
'Topic :: System :: Software Distribution',
),
)
|
3cf5ad70d1dc70f8399b50d7c5ea89209f14d00c
|
setup.py
|
setup.py
|
import sys
IS_PYTHON3 = sys.version_info[0] == 3
if not IS_PYTHON3:
print("Error: signac requires python version >= 3.x.")
sys.exit(1)
from setuptools import setup, find_packages
setup(
name='signac',
version='0.1.7dev5',
packages=find_packages(),
author='Carl Simon Adorf',
author_email='csadorf@umich.edu',
description="Computational Database.",
keywords='simulation tools mc md monte-carlo mongodb '
'jobmanagement materials database',
classifiers=[
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Topic :: Scientific/Engineering :: Physics",
],
extras_require={
'db': ['pymongo>=3.0'],
'mpi': ['mpi4py'],
'conversion': ['networkx>=1.1.0'],
},
)
|
import sys
IS_PYTHON3 = sys.version_info[0] == 3
if not IS_PYTHON3:
print("Error: signac requires python version >= 3.x.")
sys.exit(1)
from setuptools import setup, find_packages
setup(
name='signac',
version='0.1.7dev5',
packages=find_packages(),
author='Carl Simon Adorf',
author_email='csadorf@umich.edu',
description="Computational Database.",
keywords='simulation tools mc md monte-carlo mongodb '
'jobmanagement materials database',
classifiers=[
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Topic :: Scientific/Engineering :: Physics",
],
install_requires=['six'],
extras_require={
'db': ['pymongo>=3.0'],
'mpi': ['mpi4py'],
'conversion': ['networkx>=1.1.0'],
},
)
|
Add requirement 'six', required for configobj.
|
Add requirement 'six', required for configobj.
|
Python
|
bsd-3-clause
|
csadorf/signac,csadorf/signac
|
import sys
IS_PYTHON3 = sys.version_info[0] == 3
if not IS_PYTHON3:
print("Error: signac requires python version >= 3.x.")
sys.exit(1)
from setuptools import setup, find_packages
setup(
name='signac',
version='0.1.7dev5',
packages=find_packages(),
author='Carl Simon Adorf',
author_email='csadorf@umich.edu',
description="Computational Database.",
keywords='simulation tools mc md monte-carlo mongodb '
'jobmanagement materials database',
classifiers=[
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Topic :: Scientific/Engineering :: Physics",
],
extras_require={
'db': ['pymongo>=3.0'],
'mpi': ['mpi4py'],
'conversion': ['networkx>=1.1.0'],
},
)
Add requirement 'six', required for configobj.
|
import sys
IS_PYTHON3 = sys.version_info[0] == 3
if not IS_PYTHON3:
print("Error: signac requires python version >= 3.x.")
sys.exit(1)
from setuptools import setup, find_packages
setup(
name='signac',
version='0.1.7dev5',
packages=find_packages(),
author='Carl Simon Adorf',
author_email='csadorf@umich.edu',
description="Computational Database.",
keywords='simulation tools mc md monte-carlo mongodb '
'jobmanagement materials database',
classifiers=[
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Topic :: Scientific/Engineering :: Physics",
],
install_requires=['six'],
extras_require={
'db': ['pymongo>=3.0'],
'mpi': ['mpi4py'],
'conversion': ['networkx>=1.1.0'],
},
)
|
<commit_before>import sys
IS_PYTHON3 = sys.version_info[0] == 3
if not IS_PYTHON3:
print("Error: signac requires python version >= 3.x.")
sys.exit(1)
from setuptools import setup, find_packages
setup(
name='signac',
version='0.1.7dev5',
packages=find_packages(),
author='Carl Simon Adorf',
author_email='csadorf@umich.edu',
description="Computational Database.",
keywords='simulation tools mc md monte-carlo mongodb '
'jobmanagement materials database',
classifiers=[
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Topic :: Scientific/Engineering :: Physics",
],
extras_require={
'db': ['pymongo>=3.0'],
'mpi': ['mpi4py'],
'conversion': ['networkx>=1.1.0'],
},
)
<commit_msg>Add requirement 'six', required for configobj.<commit_after>
|
import sys
IS_PYTHON3 = sys.version_info[0] == 3
if not IS_PYTHON3:
print("Error: signac requires python version >= 3.x.")
sys.exit(1)
from setuptools import setup, find_packages
setup(
name='signac',
version='0.1.7dev5',
packages=find_packages(),
author='Carl Simon Adorf',
author_email='csadorf@umich.edu',
description="Computational Database.",
keywords='simulation tools mc md monte-carlo mongodb '
'jobmanagement materials database',
classifiers=[
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Topic :: Scientific/Engineering :: Physics",
],
install_requires=['six'],
extras_require={
'db': ['pymongo>=3.0'],
'mpi': ['mpi4py'],
'conversion': ['networkx>=1.1.0'],
},
)
|
import sys
IS_PYTHON3 = sys.version_info[0] == 3
if not IS_PYTHON3:
print("Error: signac requires python version >= 3.x.")
sys.exit(1)
from setuptools import setup, find_packages
setup(
name='signac',
version='0.1.7dev5',
packages=find_packages(),
author='Carl Simon Adorf',
author_email='csadorf@umich.edu',
description="Computational Database.",
keywords='simulation tools mc md monte-carlo mongodb '
'jobmanagement materials database',
classifiers=[
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Topic :: Scientific/Engineering :: Physics",
],
extras_require={
'db': ['pymongo>=3.0'],
'mpi': ['mpi4py'],
'conversion': ['networkx>=1.1.0'],
},
)
Add requirement 'six', required for configobj.import sys
IS_PYTHON3 = sys.version_info[0] == 3
if not IS_PYTHON3:
print("Error: signac requires python version >= 3.x.")
sys.exit(1)
from setuptools import setup, find_packages
setup(
name='signac',
version='0.1.7dev5',
packages=find_packages(),
author='Carl Simon Adorf',
author_email='csadorf@umich.edu',
description="Computational Database.",
keywords='simulation tools mc md monte-carlo mongodb '
'jobmanagement materials database',
classifiers=[
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Topic :: Scientific/Engineering :: Physics",
],
install_requires=['six'],
extras_require={
'db': ['pymongo>=3.0'],
'mpi': ['mpi4py'],
'conversion': ['networkx>=1.1.0'],
},
)
|
<commit_before>import sys
IS_PYTHON3 = sys.version_info[0] == 3
if not IS_PYTHON3:
print("Error: signac requires python version >= 3.x.")
sys.exit(1)
from setuptools import setup, find_packages
setup(
name='signac',
version='0.1.7dev5',
packages=find_packages(),
author='Carl Simon Adorf',
author_email='csadorf@umich.edu',
description="Computational Database.",
keywords='simulation tools mc md monte-carlo mongodb '
'jobmanagement materials database',
classifiers=[
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Topic :: Scientific/Engineering :: Physics",
],
extras_require={
'db': ['pymongo>=3.0'],
'mpi': ['mpi4py'],
'conversion': ['networkx>=1.1.0'],
},
)
<commit_msg>Add requirement 'six', required for configobj.<commit_after>import sys
IS_PYTHON3 = sys.version_info[0] == 3
if not IS_PYTHON3:
print("Error: signac requires python version >= 3.x.")
sys.exit(1)
from setuptools import setup, find_packages
setup(
name='signac',
version='0.1.7dev5',
packages=find_packages(),
author='Carl Simon Adorf',
author_email='csadorf@umich.edu',
description="Computational Database.",
keywords='simulation tools mc md monte-carlo mongodb '
'jobmanagement materials database',
classifiers=[
"Development Status :: 3 - Alpha",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Topic :: Scientific/Engineering :: Physics",
],
install_requires=['six'],
extras_require={
'db': ['pymongo>=3.0'],
'mpi': ['mpi4py'],
'conversion': ['networkx>=1.1.0'],
},
)
|
919819a9226d49893a677a3578b7efb9c02f00bf
|
setup.py
|
setup.py
|
#!/usr/bin/env python
from distutils.core import setup
import sys
import os
version = '1.1.5'
try:
import pypandoc
long_description = pypandoc.convert('README.md', 'rst')
except(IOError, ImportError):
long_description = open('README.md').read()
if sys.argv[-1] == 'publish':
os.system('python setup.py sdist upload')
sys.exit()
setup(
name='africastalking',
version=version,
packages=['africastalking'],
description='Official Africa\'s Talking Python SDK',
long_description=long_description,
data_files=[('', ['README.md'])],
license='MIT',
author='Africa\'s Talking',
install_requires=[
'requests>=v2.18.4',
'schema>=0.6.7'
],
python_requires=">=2.7.10",
author_email='info@africastalking.com',
url='https://github.com/AfricasTalkingLtd/africastalking-python',
download_url='https://codeload.github.com/AfricasTalkingLtd/africastalking-python/tar.gz/' + version,
keywords='ussd voice sms mpesa card bank b2b b2c sender_id payments airtime africastalking',
classifiers=[],
)
|
#!/usr/bin/env python
from setuptools import setup
import sys
import os
version = '1.1.6'
with open('README.md', encoding='utf-8') as f:
long_description = f.read()
if sys.argv[-1] == 'publish':
os.system('python setup.py sdist upload')
sys.exit()
setup(
name='africastalking',
version=version,
packages=['africastalking'],
description='Official Africa\'s Talking Python SDK',
data_files=[('', ['README.md'])],
license='MIT',
author='Africa\'s Talking',
install_requires=[
'requests>=v2.18.4',
'schema>=0.6.7'
],
python_requires=">=2.7.10",
author_email='info@africastalking.com',
url='https://github.com/AfricasTalkingLtd/africastalking-python',
download_url='https://codeload.github.com/AfricasTalkingLtd/africastalking-python/tar.gz/' + version,
keywords='ussd voice sms mpesa card bank b2b b2c sender_id payments airtime africastalking',
classifiers=[],
long_description=long_description,
long_description_content_type='text/markdown'
)
|
Write long description as git flavoured markdown
|
Write long description as git flavoured markdown
|
Python
|
mit
|
AfricasTalkingLtd/africastalking-python,AfricasTalkingLtd/africastalking-python,AfricasTalkingLtd/africastalking-python
|
#!/usr/bin/env python
from distutils.core import setup
import sys
import os
version = '1.1.5'
try:
import pypandoc
long_description = pypandoc.convert('README.md', 'rst')
except(IOError, ImportError):
long_description = open('README.md').read()
if sys.argv[-1] == 'publish':
os.system('python setup.py sdist upload')
sys.exit()
setup(
name='africastalking',
version=version,
packages=['africastalking'],
description='Official Africa\'s Talking Python SDK',
long_description=long_description,
data_files=[('', ['README.md'])],
license='MIT',
author='Africa\'s Talking',
install_requires=[
'requests>=v2.18.4',
'schema>=0.6.7'
],
python_requires=">=2.7.10",
author_email='info@africastalking.com',
url='https://github.com/AfricasTalkingLtd/africastalking-python',
download_url='https://codeload.github.com/AfricasTalkingLtd/africastalking-python/tar.gz/' + version,
keywords='ussd voice sms mpesa card bank b2b b2c sender_id payments airtime africastalking',
classifiers=[],
)
Write long description as git flavoured markdown
|
#!/usr/bin/env python
from setuptools import setup
import sys
import os
version = '1.1.6'
with open('README.md', encoding='utf-8') as f:
long_description = f.read()
if sys.argv[-1] == 'publish':
os.system('python setup.py sdist upload')
sys.exit()
setup(
name='africastalking',
version=version,
packages=['africastalking'],
description='Official Africa\'s Talking Python SDK',
data_files=[('', ['README.md'])],
license='MIT',
author='Africa\'s Talking',
install_requires=[
'requests>=v2.18.4',
'schema>=0.6.7'
],
python_requires=">=2.7.10",
author_email='info@africastalking.com',
url='https://github.com/AfricasTalkingLtd/africastalking-python',
download_url='https://codeload.github.com/AfricasTalkingLtd/africastalking-python/tar.gz/' + version,
keywords='ussd voice sms mpesa card bank b2b b2c sender_id payments airtime africastalking',
classifiers=[],
long_description=long_description,
long_description_content_type='text/markdown'
)
|
<commit_before>#!/usr/bin/env python
from distutils.core import setup
import sys
import os
version = '1.1.5'
try:
import pypandoc
long_description = pypandoc.convert('README.md', 'rst')
except(IOError, ImportError):
long_description = open('README.md').read()
if sys.argv[-1] == 'publish':
os.system('python setup.py sdist upload')
sys.exit()
setup(
name='africastalking',
version=version,
packages=['africastalking'],
description='Official Africa\'s Talking Python SDK',
long_description=long_description,
data_files=[('', ['README.md'])],
license='MIT',
author='Africa\'s Talking',
install_requires=[
'requests>=v2.18.4',
'schema>=0.6.7'
],
python_requires=">=2.7.10",
author_email='info@africastalking.com',
url='https://github.com/AfricasTalkingLtd/africastalking-python',
download_url='https://codeload.github.com/AfricasTalkingLtd/africastalking-python/tar.gz/' + version,
keywords='ussd voice sms mpesa card bank b2b b2c sender_id payments airtime africastalking',
classifiers=[],
)
<commit_msg>Write long description as git flavoured markdown<commit_after>
|
#!/usr/bin/env python
from setuptools import setup
import sys
import os
version = '1.1.6'
with open('README.md', encoding='utf-8') as f:
long_description = f.read()
if sys.argv[-1] == 'publish':
os.system('python setup.py sdist upload')
sys.exit()
setup(
name='africastalking',
version=version,
packages=['africastalking'],
description='Official Africa\'s Talking Python SDK',
data_files=[('', ['README.md'])],
license='MIT',
author='Africa\'s Talking',
install_requires=[
'requests>=v2.18.4',
'schema>=0.6.7'
],
python_requires=">=2.7.10",
author_email='info@africastalking.com',
url='https://github.com/AfricasTalkingLtd/africastalking-python',
download_url='https://codeload.github.com/AfricasTalkingLtd/africastalking-python/tar.gz/' + version,
keywords='ussd voice sms mpesa card bank b2b b2c sender_id payments airtime africastalking',
classifiers=[],
long_description=long_description,
long_description_content_type='text/markdown'
)
|
#!/usr/bin/env python
from distutils.core import setup
import sys
import os
version = '1.1.5'
try:
import pypandoc
long_description = pypandoc.convert('README.md', 'rst')
except(IOError, ImportError):
long_description = open('README.md').read()
if sys.argv[-1] == 'publish':
os.system('python setup.py sdist upload')
sys.exit()
setup(
name='africastalking',
version=version,
packages=['africastalking'],
description='Official Africa\'s Talking Python SDK',
long_description=long_description,
data_files=[('', ['README.md'])],
license='MIT',
author='Africa\'s Talking',
install_requires=[
'requests>=v2.18.4',
'schema>=0.6.7'
],
python_requires=">=2.7.10",
author_email='info@africastalking.com',
url='https://github.com/AfricasTalkingLtd/africastalking-python',
download_url='https://codeload.github.com/AfricasTalkingLtd/africastalking-python/tar.gz/' + version,
keywords='ussd voice sms mpesa card bank b2b b2c sender_id payments airtime africastalking',
classifiers=[],
)
Write long description as git flavoured markdown#!/usr/bin/env python
from setuptools import setup
import sys
import os
version = '1.1.6'
with open('README.md', encoding='utf-8') as f:
long_description = f.read()
if sys.argv[-1] == 'publish':
os.system('python setup.py sdist upload')
sys.exit()
setup(
name='africastalking',
version=version,
packages=['africastalking'],
description='Official Africa\'s Talking Python SDK',
data_files=[('', ['README.md'])],
license='MIT',
author='Africa\'s Talking',
install_requires=[
'requests>=v2.18.4',
'schema>=0.6.7'
],
python_requires=">=2.7.10",
author_email='info@africastalking.com',
url='https://github.com/AfricasTalkingLtd/africastalking-python',
download_url='https://codeload.github.com/AfricasTalkingLtd/africastalking-python/tar.gz/' + version,
keywords='ussd voice sms mpesa card bank b2b b2c sender_id payments airtime africastalking',
classifiers=[],
long_description=long_description,
long_description_content_type='text/markdown'
)
|
<commit_before>#!/usr/bin/env python
from distutils.core import setup
import sys
import os
version = '1.1.5'
try:
import pypandoc
long_description = pypandoc.convert('README.md', 'rst')
except(IOError, ImportError):
long_description = open('README.md').read()
if sys.argv[-1] == 'publish':
os.system('python setup.py sdist upload')
sys.exit()
setup(
name='africastalking',
version=version,
packages=['africastalking'],
description='Official Africa\'s Talking Python SDK',
long_description=long_description,
data_files=[('', ['README.md'])],
license='MIT',
author='Africa\'s Talking',
install_requires=[
'requests>=v2.18.4',
'schema>=0.6.7'
],
python_requires=">=2.7.10",
author_email='info@africastalking.com',
url='https://github.com/AfricasTalkingLtd/africastalking-python',
download_url='https://codeload.github.com/AfricasTalkingLtd/africastalking-python/tar.gz/' + version,
keywords='ussd voice sms mpesa card bank b2b b2c sender_id payments airtime africastalking',
classifiers=[],
)
<commit_msg>Write long description as git flavoured markdown<commit_after>#!/usr/bin/env python
from setuptools import setup
import sys
import os
version = '1.1.6'
with open('README.md', encoding='utf-8') as f:
long_description = f.read()
if sys.argv[-1] == 'publish':
os.system('python setup.py sdist upload')
sys.exit()
setup(
name='africastalking',
version=version,
packages=['africastalking'],
description='Official Africa\'s Talking Python SDK',
data_files=[('', ['README.md'])],
license='MIT',
author='Africa\'s Talking',
install_requires=[
'requests>=v2.18.4',
'schema>=0.6.7'
],
python_requires=">=2.7.10",
author_email='info@africastalking.com',
url='https://github.com/AfricasTalkingLtd/africastalking-python',
download_url='https://codeload.github.com/AfricasTalkingLtd/africastalking-python/tar.gz/' + version,
keywords='ussd voice sms mpesa card bank b2b b2c sender_id payments airtime africastalking',
classifiers=[],
long_description=long_description,
long_description_content_type='text/markdown'
)
|
9f3de0529b2f6d78e97f395c3751cd060fd36248
|
setup.py
|
setup.py
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import websitepoller
from setuptools import setup
description = "Polls specified websites and alerts using system notifications."
try:
from pypandoc import convert
long_description = convert('README.md', 'rst')
except (ImportError, IOError, OSError):
print 'check that you have installed pandoc properly and that ' + \
'README.md exists!'
long_description = description
setup(
name="website-poller",
version=websitepoller.__version__,
url='http://koodilehto.github.com/website-poller',
license='MIT',
description=description,
long_description=long_description,
author=websitepoller.__author__,
author_email='info@koodilehto.fi',
packages=['websitepoller', ],
package_dir={'websitepoller': 'websitepoller', },
install_requires=['setuptools', ],
data_files=['README.md'],
entry_points="""
[console_scripts]
websitepoller = websitepoller:run
""",
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: POSIX',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Internet :: WWW/HTTP',
'Topic :: System :: Networking :: Monitoring',
],
)
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import websitepoller
from setuptools import setup
description = "Polls specified websites and alerts using system notifications."
try:
from pypandoc import convert
long_description = convert('README.md', 'rst')
except (ImportError, IOError, OSError):
print 'check that you have installed pandoc properly and that ' + \
'README.md exists!'
long_description = description
setup(
name="website-poller",
version=websitepoller.__version__,
url='http://koodilehto.github.com/website-poller',
license='MIT',
description=description,
long_description=long_description,
author=websitepoller.__author__,
author_email='info@koodilehto.fi',
packages=['websitepoller', ],
package_dir={'websitepoller': 'websitepoller', },
install_requires=['setuptools', ],
data_files=[('', ['README.md'])],
entry_points="""
[console_scripts]
websitepoller = websitepoller:run
""",
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: POSIX',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Internet :: WWW/HTTP',
'Topic :: System :: Networking :: Monitoring',
],
)
|
Include README to data_files properly
|
Include README to data_files properly
|
Python
|
mit
|
koodilehto/website-poller,koodilehto/website-poller
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import websitepoller
from setuptools import setup
description = "Polls specified websites and alerts using system notifications."
try:
from pypandoc import convert
long_description = convert('README.md', 'rst')
except (ImportError, IOError, OSError):
print 'check that you have installed pandoc properly and that ' + \
'README.md exists!'
long_description = description
setup(
name="website-poller",
version=websitepoller.__version__,
url='http://koodilehto.github.com/website-poller',
license='MIT',
description=description,
long_description=long_description,
author=websitepoller.__author__,
author_email='info@koodilehto.fi',
packages=['websitepoller', ],
package_dir={'websitepoller': 'websitepoller', },
install_requires=['setuptools', ],
data_files=['README.md'],
entry_points="""
[console_scripts]
websitepoller = websitepoller:run
""",
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: POSIX',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Internet :: WWW/HTTP',
'Topic :: System :: Networking :: Monitoring',
],
)
Include README to data_files properly
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import websitepoller
from setuptools import setup
description = "Polls specified websites and alerts using system notifications."
try:
from pypandoc import convert
long_description = convert('README.md', 'rst')
except (ImportError, IOError, OSError):
print 'check that you have installed pandoc properly and that ' + \
'README.md exists!'
long_description = description
setup(
name="website-poller",
version=websitepoller.__version__,
url='http://koodilehto.github.com/website-poller',
license='MIT',
description=description,
long_description=long_description,
author=websitepoller.__author__,
author_email='info@koodilehto.fi',
packages=['websitepoller', ],
package_dir={'websitepoller': 'websitepoller', },
install_requires=['setuptools', ],
data_files=[('', ['README.md'])],
entry_points="""
[console_scripts]
websitepoller = websitepoller:run
""",
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: POSIX',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Internet :: WWW/HTTP',
'Topic :: System :: Networking :: Monitoring',
],
)
|
<commit_before>#!/usr/bin/env python
# -*- coding: utf-8 -*-
import websitepoller
from setuptools import setup
description = "Polls specified websites and alerts using system notifications."
try:
from pypandoc import convert
long_description = convert('README.md', 'rst')
except (ImportError, IOError, OSError):
print 'check that you have installed pandoc properly and that ' + \
'README.md exists!'
long_description = description
setup(
name="website-poller",
version=websitepoller.__version__,
url='http://koodilehto.github.com/website-poller',
license='MIT',
description=description,
long_description=long_description,
author=websitepoller.__author__,
author_email='info@koodilehto.fi',
packages=['websitepoller', ],
package_dir={'websitepoller': 'websitepoller', },
install_requires=['setuptools', ],
data_files=['README.md'],
entry_points="""
[console_scripts]
websitepoller = websitepoller:run
""",
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: POSIX',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Internet :: WWW/HTTP',
'Topic :: System :: Networking :: Monitoring',
],
)
<commit_msg>Include README to data_files properly<commit_after>
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import websitepoller
from setuptools import setup
description = "Polls specified websites and alerts using system notifications."
try:
from pypandoc import convert
long_description = convert('README.md', 'rst')
except (ImportError, IOError, OSError):
print 'check that you have installed pandoc properly and that ' + \
'README.md exists!'
long_description = description
setup(
name="website-poller",
version=websitepoller.__version__,
url='http://koodilehto.github.com/website-poller',
license='MIT',
description=description,
long_description=long_description,
author=websitepoller.__author__,
author_email='info@koodilehto.fi',
packages=['websitepoller', ],
package_dir={'websitepoller': 'websitepoller', },
install_requires=['setuptools', ],
data_files=[('', ['README.md'])],
entry_points="""
[console_scripts]
websitepoller = websitepoller:run
""",
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: POSIX',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Internet :: WWW/HTTP',
'Topic :: System :: Networking :: Monitoring',
],
)
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
import websitepoller
from setuptools import setup
description = "Polls specified websites and alerts using system notifications."
try:
from pypandoc import convert
long_description = convert('README.md', 'rst')
except (ImportError, IOError, OSError):
print 'check that you have installed pandoc properly and that ' + \
'README.md exists!'
long_description = description
setup(
name="website-poller",
version=websitepoller.__version__,
url='http://koodilehto.github.com/website-poller',
license='MIT',
description=description,
long_description=long_description,
author=websitepoller.__author__,
author_email='info@koodilehto.fi',
packages=['websitepoller', ],
package_dir={'websitepoller': 'websitepoller', },
install_requires=['setuptools', ],
data_files=['README.md'],
entry_points="""
[console_scripts]
websitepoller = websitepoller:run
""",
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: POSIX',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Internet :: WWW/HTTP',
'Topic :: System :: Networking :: Monitoring',
],
)
Include README to data_files properly#!/usr/bin/env python
# -*- coding: utf-8 -*-
import websitepoller
from setuptools import setup
description = "Polls specified websites and alerts using system notifications."
try:
from pypandoc import convert
long_description = convert('README.md', 'rst')
except (ImportError, IOError, OSError):
print 'check that you have installed pandoc properly and that ' + \
'README.md exists!'
long_description = description
setup(
name="website-poller",
version=websitepoller.__version__,
url='http://koodilehto.github.com/website-poller',
license='MIT',
description=description,
long_description=long_description,
author=websitepoller.__author__,
author_email='info@koodilehto.fi',
packages=['websitepoller', ],
package_dir={'websitepoller': 'websitepoller', },
install_requires=['setuptools', ],
data_files=[('', ['README.md'])],
entry_points="""
[console_scripts]
websitepoller = websitepoller:run
""",
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: POSIX',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Internet :: WWW/HTTP',
'Topic :: System :: Networking :: Monitoring',
],
)
|
<commit_before>#!/usr/bin/env python
# -*- coding: utf-8 -*-
import websitepoller
from setuptools import setup
description = "Polls specified websites and alerts using system notifications."
try:
from pypandoc import convert
long_description = convert('README.md', 'rst')
except (ImportError, IOError, OSError):
print 'check that you have installed pandoc properly and that ' + \
'README.md exists!'
long_description = description
setup(
name="website-poller",
version=websitepoller.__version__,
url='http://koodilehto.github.com/website-poller',
license='MIT',
description=description,
long_description=long_description,
author=websitepoller.__author__,
author_email='info@koodilehto.fi',
packages=['websitepoller', ],
package_dir={'websitepoller': 'websitepoller', },
install_requires=['setuptools', ],
data_files=['README.md'],
entry_points="""
[console_scripts]
websitepoller = websitepoller:run
""",
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: POSIX',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Internet :: WWW/HTTP',
'Topic :: System :: Networking :: Monitoring',
],
)
<commit_msg>Include README to data_files properly<commit_after>#!/usr/bin/env python
# -*- coding: utf-8 -*-
import websitepoller
from setuptools import setup
description = "Polls specified websites and alerts using system notifications."
try:
from pypandoc import convert
long_description = convert('README.md', 'rst')
except (ImportError, IOError, OSError):
print 'check that you have installed pandoc properly and that ' + \
'README.md exists!'
long_description = description
setup(
name="website-poller",
version=websitepoller.__version__,
url='http://koodilehto.github.com/website-poller',
license='MIT',
description=description,
long_description=long_description,
author=websitepoller.__author__,
author_email='info@koodilehto.fi',
packages=['websitepoller', ],
package_dir={'websitepoller': 'websitepoller', },
install_requires=['setuptools', ],
data_files=[('', ['README.md'])],
entry_points="""
[console_scripts]
websitepoller = websitepoller:run
""",
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Console',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: POSIX',
'Programming Language :: Python',
'Topic :: Internet',
'Topic :: Internet :: WWW/HTTP',
'Topic :: System :: Networking :: Monitoring',
],
)
|
e9494cce4ded69dbf8f7be7d77e4feed3121edb9
|
setup.py
|
setup.py
|
# -*- coding: utf-8 -*-
import os
from setuptools import setup
with open(os.path.join(os.path.dirname(__file__), 'README.rst')) as readme:
README = readme.read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-sb-admin',
version='0.1.1',
packages=['django_sb_admin'],
include_package_data=True,
license='Apache License version 2.0', # example license
description='SB Admin dashboard Bootstrap 3 theme packaged as Django app.',
long_description=README,
url='https://github.com/bluszcz/django-smb-admin',
author='Rafał Zawadzki',
author_email='bluszcz@bluszcz.net',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License', # example license
'Operating System :: OS Independent',
'Programming Language :: Python',
# Replace these appropriately if you are stuck on Python 2.
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)
|
# -*- coding: utf-8 -*-
import os
from setuptools import setup
with open(os.path.join(os.path.dirname(__file__), 'README.rst')) as readme:
README = readme.read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-sb-admin',
version='0.1.1',
packages=['django_sb_admin'],
include_package_data=True,
license='Apache License version 2.0',
description='SB Admin dashboard Bootstrap 3 theme packaged as Django app.',
long_description=README,
url='https://github.com/bluszcz/django-sb-admin',
author='Rafał Zawadzki',
author_email='bluszcz@bluszcz.net',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)
|
Remove template's text and fix url to github
|
Remove template's text and fix url to github
|
Python
|
apache-2.0
|
bluszcz/django-sb-admin,bluszcz/django-sb-admin,bluszcz/django-sb-admin
|
# -*- coding: utf-8 -*-
import os
from setuptools import setup
with open(os.path.join(os.path.dirname(__file__), 'README.rst')) as readme:
README = readme.read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-sb-admin',
version='0.1.1',
packages=['django_sb_admin'],
include_package_data=True,
license='Apache License version 2.0', # example license
description='SB Admin dashboard Bootstrap 3 theme packaged as Django app.',
long_description=README,
url='https://github.com/bluszcz/django-smb-admin',
author='Rafał Zawadzki',
author_email='bluszcz@bluszcz.net',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License', # example license
'Operating System :: OS Independent',
'Programming Language :: Python',
# Replace these appropriately if you are stuck on Python 2.
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)
Remove template's text and fix url to github
|
# -*- coding: utf-8 -*-
import os
from setuptools import setup
with open(os.path.join(os.path.dirname(__file__), 'README.rst')) as readme:
README = readme.read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-sb-admin',
version='0.1.1',
packages=['django_sb_admin'],
include_package_data=True,
license='Apache License version 2.0',
description='SB Admin dashboard Bootstrap 3 theme packaged as Django app.',
long_description=README,
url='https://github.com/bluszcz/django-sb-admin',
author='Rafał Zawadzki',
author_email='bluszcz@bluszcz.net',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)
|
<commit_before># -*- coding: utf-8 -*-
import os
from setuptools import setup
with open(os.path.join(os.path.dirname(__file__), 'README.rst')) as readme:
README = readme.read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-sb-admin',
version='0.1.1',
packages=['django_sb_admin'],
include_package_data=True,
license='Apache License version 2.0', # example license
description='SB Admin dashboard Bootstrap 3 theme packaged as Django app.',
long_description=README,
url='https://github.com/bluszcz/django-smb-admin',
author='Rafał Zawadzki',
author_email='bluszcz@bluszcz.net',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License', # example license
'Operating System :: OS Independent',
'Programming Language :: Python',
# Replace these appropriately if you are stuck on Python 2.
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)
<commit_msg>Remove template's text and fix url to github<commit_after>
|
# -*- coding: utf-8 -*-
import os
from setuptools import setup
with open(os.path.join(os.path.dirname(__file__), 'README.rst')) as readme:
README = readme.read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-sb-admin',
version='0.1.1',
packages=['django_sb_admin'],
include_package_data=True,
license='Apache License version 2.0',
description='SB Admin dashboard Bootstrap 3 theme packaged as Django app.',
long_description=README,
url='https://github.com/bluszcz/django-sb-admin',
author='Rafał Zawadzki',
author_email='bluszcz@bluszcz.net',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)
|
# -*- coding: utf-8 -*-
import os
from setuptools import setup
with open(os.path.join(os.path.dirname(__file__), 'README.rst')) as readme:
README = readme.read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-sb-admin',
version='0.1.1',
packages=['django_sb_admin'],
include_package_data=True,
license='Apache License version 2.0', # example license
description='SB Admin dashboard Bootstrap 3 theme packaged as Django app.',
long_description=README,
url='https://github.com/bluszcz/django-smb-admin',
author='Rafał Zawadzki',
author_email='bluszcz@bluszcz.net',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License', # example license
'Operating System :: OS Independent',
'Programming Language :: Python',
# Replace these appropriately if you are stuck on Python 2.
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)
Remove template's text and fix url to github# -*- coding: utf-8 -*-
import os
from setuptools import setup
with open(os.path.join(os.path.dirname(__file__), 'README.rst')) as readme:
README = readme.read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-sb-admin',
version='0.1.1',
packages=['django_sb_admin'],
include_package_data=True,
license='Apache License version 2.0',
description='SB Admin dashboard Bootstrap 3 theme packaged as Django app.',
long_description=README,
url='https://github.com/bluszcz/django-sb-admin',
author='Rafał Zawadzki',
author_email='bluszcz@bluszcz.net',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)
|
<commit_before># -*- coding: utf-8 -*-
import os
from setuptools import setup
with open(os.path.join(os.path.dirname(__file__), 'README.rst')) as readme:
README = readme.read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-sb-admin',
version='0.1.1',
packages=['django_sb_admin'],
include_package_data=True,
license='Apache License version 2.0', # example license
description='SB Admin dashboard Bootstrap 3 theme packaged as Django app.',
long_description=README,
url='https://github.com/bluszcz/django-smb-admin',
author='Rafał Zawadzki',
author_email='bluszcz@bluszcz.net',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License', # example license
'Operating System :: OS Independent',
'Programming Language :: Python',
# Replace these appropriately if you are stuck on Python 2.
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)
<commit_msg>Remove template's text and fix url to github<commit_after># -*- coding: utf-8 -*-
import os
from setuptools import setup
with open(os.path.join(os.path.dirname(__file__), 'README.rst')) as readme:
README = readme.read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='django-sb-admin',
version='0.1.1',
packages=['django_sb_admin'],
include_package_data=True,
license='Apache License version 2.0',
description='SB Admin dashboard Bootstrap 3 theme packaged as Django app.',
long_description=README,
url='https://github.com/bluszcz/django-sb-admin',
author='Rafał Zawadzki',
author_email='bluszcz@bluszcz.net',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)
|
e6da3d784dd391681b5677029bf7400dc659759e
|
setup.py
|
setup.py
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
from pytube import __version__
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
with open('README.rst') as readme_file:
readme = readme_file.read()
with open('LICENSE') as readme_file:
license = readme_file.read()
setup(
name="pytube",
version=__version__,
author="Nick Ficano",
author_email="nficano@gmail.com",
packages=['pytube'],
url="https://github.com/nficano/pytube",
license=license,
scripts=['scripts/pytube'],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Console",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Natural Language :: English",
"Operating System :: MacOS",
"Operating System :: Microsoft",
"Operating System :: POSIX",
"Operating System :: Unix",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python",
"Topic :: Internet",
"Topic :: Multimedia :: Video",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Terminals",
"Topic :: Utilities",
],
description=("A Python library for downloading YouTube videos."),
long_description=readme,
zip_safe=True,
)
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
from pytube import __version__
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
with open('README.rst') as readme_file:
readme = readme_file.read()
with open('LICENSE.txt') as readme_file:
license = readme_file.read()
setup(
name="pytube",
version=__version__,
author="Nick Ficano",
author_email="nficano@gmail.com",
packages=['pytube'],
url="https://github.com/nficano/pytube",
license=license,
scripts=['scripts/pytube'],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Console",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Natural Language :: English",
"Operating System :: MacOS",
"Operating System :: Microsoft",
"Operating System :: POSIX",
"Operating System :: Unix",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python",
"Topic :: Internet",
"Topic :: Multimedia :: Video",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Terminals",
"Topic :: Utilities",
],
description=("A Python library for downloading YouTube videos."),
long_description=readme,
zip_safe=True,
)
|
Fix open call for LICENSE.txt
|
Fix open call for LICENSE.txt
Closes #76
|
Python
|
unlicense
|
pytube/pytube
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
from pytube import __version__
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
with open('README.rst') as readme_file:
readme = readme_file.read()
with open('LICENSE') as readme_file:
license = readme_file.read()
setup(
name="pytube",
version=__version__,
author="Nick Ficano",
author_email="nficano@gmail.com",
packages=['pytube'],
url="https://github.com/nficano/pytube",
license=license,
scripts=['scripts/pytube'],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Console",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Natural Language :: English",
"Operating System :: MacOS",
"Operating System :: Microsoft",
"Operating System :: POSIX",
"Operating System :: Unix",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python",
"Topic :: Internet",
"Topic :: Multimedia :: Video",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Terminals",
"Topic :: Utilities",
],
description=("A Python library for downloading YouTube videos."),
long_description=readme,
zip_safe=True,
)
Fix open call for LICENSE.txt
Closes #76
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
from pytube import __version__
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
with open('README.rst') as readme_file:
readme = readme_file.read()
with open('LICENSE.txt') as readme_file:
license = readme_file.read()
setup(
name="pytube",
version=__version__,
author="Nick Ficano",
author_email="nficano@gmail.com",
packages=['pytube'],
url="https://github.com/nficano/pytube",
license=license,
scripts=['scripts/pytube'],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Console",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Natural Language :: English",
"Operating System :: MacOS",
"Operating System :: Microsoft",
"Operating System :: POSIX",
"Operating System :: Unix",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python",
"Topic :: Internet",
"Topic :: Multimedia :: Video",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Terminals",
"Topic :: Utilities",
],
description=("A Python library for downloading YouTube videos."),
long_description=readme,
zip_safe=True,
)
|
<commit_before>#!/usr/bin/env python
# -*- coding: utf-8 -*-
from pytube import __version__
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
with open('README.rst') as readme_file:
readme = readme_file.read()
with open('LICENSE') as readme_file:
license = readme_file.read()
setup(
name="pytube",
version=__version__,
author="Nick Ficano",
author_email="nficano@gmail.com",
packages=['pytube'],
url="https://github.com/nficano/pytube",
license=license,
scripts=['scripts/pytube'],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Console",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Natural Language :: English",
"Operating System :: MacOS",
"Operating System :: Microsoft",
"Operating System :: POSIX",
"Operating System :: Unix",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python",
"Topic :: Internet",
"Topic :: Multimedia :: Video",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Terminals",
"Topic :: Utilities",
],
description=("A Python library for downloading YouTube videos."),
long_description=readme,
zip_safe=True,
)
<commit_msg>Fix open call for LICENSE.txt
Closes #76<commit_after>
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
from pytube import __version__
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
with open('README.rst') as readme_file:
readme = readme_file.read()
with open('LICENSE.txt') as readme_file:
license = readme_file.read()
setup(
name="pytube",
version=__version__,
author="Nick Ficano",
author_email="nficano@gmail.com",
packages=['pytube'],
url="https://github.com/nficano/pytube",
license=license,
scripts=['scripts/pytube'],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Console",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Natural Language :: English",
"Operating System :: MacOS",
"Operating System :: Microsoft",
"Operating System :: POSIX",
"Operating System :: Unix",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python",
"Topic :: Internet",
"Topic :: Multimedia :: Video",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Terminals",
"Topic :: Utilities",
],
description=("A Python library for downloading YouTube videos."),
long_description=readme,
zip_safe=True,
)
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
from pytube import __version__
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
with open('README.rst') as readme_file:
readme = readme_file.read()
with open('LICENSE') as readme_file:
license = readme_file.read()
setup(
name="pytube",
version=__version__,
author="Nick Ficano",
author_email="nficano@gmail.com",
packages=['pytube'],
url="https://github.com/nficano/pytube",
license=license,
scripts=['scripts/pytube'],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Console",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Natural Language :: English",
"Operating System :: MacOS",
"Operating System :: Microsoft",
"Operating System :: POSIX",
"Operating System :: Unix",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python",
"Topic :: Internet",
"Topic :: Multimedia :: Video",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Terminals",
"Topic :: Utilities",
],
description=("A Python library for downloading YouTube videos."),
long_description=readme,
zip_safe=True,
)
Fix open call for LICENSE.txt
Closes #76#!/usr/bin/env python
# -*- coding: utf-8 -*-
from pytube import __version__
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
with open('README.rst') as readme_file:
readme = readme_file.read()
with open('LICENSE.txt') as readme_file:
license = readme_file.read()
setup(
name="pytube",
version=__version__,
author="Nick Ficano",
author_email="nficano@gmail.com",
packages=['pytube'],
url="https://github.com/nficano/pytube",
license=license,
scripts=['scripts/pytube'],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Console",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Natural Language :: English",
"Operating System :: MacOS",
"Operating System :: Microsoft",
"Operating System :: POSIX",
"Operating System :: Unix",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python",
"Topic :: Internet",
"Topic :: Multimedia :: Video",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Terminals",
"Topic :: Utilities",
],
description=("A Python library for downloading YouTube videos."),
long_description=readme,
zip_safe=True,
)
|
<commit_before>#!/usr/bin/env python
# -*- coding: utf-8 -*-
from pytube import __version__
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
with open('README.rst') as readme_file:
readme = readme_file.read()
with open('LICENSE') as readme_file:
license = readme_file.read()
setup(
name="pytube",
version=__version__,
author="Nick Ficano",
author_email="nficano@gmail.com",
packages=['pytube'],
url="https://github.com/nficano/pytube",
license=license,
scripts=['scripts/pytube'],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Console",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Natural Language :: English",
"Operating System :: MacOS",
"Operating System :: Microsoft",
"Operating System :: POSIX",
"Operating System :: Unix",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python",
"Topic :: Internet",
"Topic :: Multimedia :: Video",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Terminals",
"Topic :: Utilities",
],
description=("A Python library for downloading YouTube videos."),
long_description=readme,
zip_safe=True,
)
<commit_msg>Fix open call for LICENSE.txt
Closes #76<commit_after>#!/usr/bin/env python
# -*- coding: utf-8 -*-
from pytube import __version__
try:
from setuptools import setup
except ImportError:
from distutils.core import setup
with open('README.rst') as readme_file:
readme = readme_file.read()
with open('LICENSE.txt') as readme_file:
license = readme_file.read()
setup(
name="pytube",
version=__version__,
author="Nick Ficano",
author_email="nficano@gmail.com",
packages=['pytube'],
url="https://github.com/nficano/pytube",
license=license,
scripts=['scripts/pytube'],
classifiers=[
"Development Status :: 5 - Production/Stable",
"Environment :: Console",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
"Natural Language :: English",
"Operating System :: MacOS",
"Operating System :: Microsoft",
"Operating System :: POSIX",
"Operating System :: Unix",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.3",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5",
"Programming Language :: Python",
"Topic :: Internet",
"Topic :: Multimedia :: Video",
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: Terminals",
"Topic :: Utilities",
],
description=("A Python library for downloading YouTube videos."),
long_description=readme,
zip_safe=True,
)
|
700fbd3df723756857fca30411a430e5ace0f423
|
setup.py
|
setup.py
|
#!/usr/bin/env python
import os
from setuptools import setup
ROOT_DIR = os.path.dirname(__file__)
SOURCE_DIR = os.path.join(ROOT_DIR)
test_requirements = []
with open('./requirements.txt') as requirements_txt:
requirements = [line for line in requirements_txt]
setup(
name="docker-py",
version='0.2.3',
description="Python client for Docker.",
packages=['docker', 'docker.auth', 'docker.unixconn', 'docker.utils'],
install_requires=requirements + test_requirements,
zip_safe=False,
test_suite='tests',
classifiers=['Development Status :: 4 - Beta',
'Environment :: Other Environment',
'Intended Audience :: Developers',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Utilities',
'License :: OSI Approved :: Apache Software License'
],
)
|
#!/usr/bin/env python
import os
from setuptools import setup
ROOT_DIR = os.path.dirname(__file__)
SOURCE_DIR = os.path.join(ROOT_DIR)
test_requirements = []
with open('./requirements.txt') as requirements_txt:
requirements = [line for line in requirements_txt]
setup(
name="docker-py",
version='0.2.3',
description="Python client for Docker.",
packages=['docker', 'docker.auth', 'docker.unixconn', 'docker.utils'],
install_requires=requirements + test_requirements,
zip_safe=False,
test_suite='tests',
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Other Environment',
'Intended Audience :: Developers',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Topic :: Utilities',
'License :: OSI Approved :: Apache Software License',
],
)
|
Declare explicitly supported python versions
|
Declare explicitly supported python versions
|
Python
|
apache-2.0
|
hibooboo2/docker-py,jpopelka/docker-py,vdemeester/docker-py,youhong316/docker-py,tbeadle/docker-py,minzhang28/docker-py,bboreham/docker-py,zwqzhangweiqiang/docker-py,kaiyou/docker-py,rschmidtz/docker-py,stevenewey/docker-py,schu/docker-py,youhong316/docker-py,ibuildthecloud/docker-py,TomasTomecek/docker-py,tristan0x/docker-py,ssanderson/docker-py,kpavel/docker-py,v-boyko/docker-py,dimaspivak/docker-py,rutsky/docker-py,terminalmage/docker-py,rancher/docker-py,bfirsh/docker-py,mangalaman93/docker-py,wlan0/docker-py,uian/docker-py,PierreF/docker-py,jhowardmsft/docker-py,aanand/docker-py,Faylixe/docker-py,vitalyisaev2/docker-py,erikced/docker-py,olsaki/docker-py,vpetersson/docker-py,gamechanger/docker-py,docker/docker-py,shakamunyi/docker-py,delfick/docker-py,rastaman/docker-py,wehkamp/docker-py,ColinHuang/docker-py,Ye-Yong-Chi/docker-py,MohamedAshiqrh/docker-py,rhatdan/docker-py,auready/docker-py,aiden0z/docker-py,funkyfuture/docker-py,tshauck/docker-py,sourcelair/docker-py,mrfuxi/docker-py,a-ba/docker-py,shakamunyi/docker-py,docker/docker-py,minzhang28/docker-py,vpetersson/docker-py,mnowster/docker-py,dimaspivak/docker-py,uggla/docker-py,jamesmarva/docker-py,a-ba/docker-py,ibuildthecloud/docker-py,dnephin/docker-py,Melraidin/docker-py,aiden0z/docker-py,auready/docker-py,mohitsoni/docker-py,rutsky/docker-py,aanand/docker-py,vdemeester/docker-py,Faylixe/docker-py,ticosax/docker-py,funkyfuture/docker-py,bfirsh/docker-py,mark-adams/docker-py,ClusterHQ/docker-py,dlorenc/docker-py,wallrj/docker-py,kaiyou/docker-py,ColinHuang/docker-py,shishir-a412ed/docker-py,paulbellamy/docker-py,clarete/docker-py,leolujuyi/docker-py,mikedougherty/docker-py,runcom/docker-py,tangkun75/docker-py
|
#!/usr/bin/env python
import os
from setuptools import setup
ROOT_DIR = os.path.dirname(__file__)
SOURCE_DIR = os.path.join(ROOT_DIR)
test_requirements = []
with open('./requirements.txt') as requirements_txt:
requirements = [line for line in requirements_txt]
setup(
name="docker-py",
version='0.2.3',
description="Python client for Docker.",
packages=['docker', 'docker.auth', 'docker.unixconn', 'docker.utils'],
install_requires=requirements + test_requirements,
zip_safe=False,
test_suite='tests',
classifiers=['Development Status :: 4 - Beta',
'Environment :: Other Environment',
'Intended Audience :: Developers',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Utilities',
'License :: OSI Approved :: Apache Software License'
],
)
Declare explicitly supported python versions
|
#!/usr/bin/env python
import os
from setuptools import setup
ROOT_DIR = os.path.dirname(__file__)
SOURCE_DIR = os.path.join(ROOT_DIR)
test_requirements = []
with open('./requirements.txt') as requirements_txt:
requirements = [line for line in requirements_txt]
setup(
name="docker-py",
version='0.2.3',
description="Python client for Docker.",
packages=['docker', 'docker.auth', 'docker.unixconn', 'docker.utils'],
install_requires=requirements + test_requirements,
zip_safe=False,
test_suite='tests',
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Other Environment',
'Intended Audience :: Developers',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Topic :: Utilities',
'License :: OSI Approved :: Apache Software License',
],
)
|
<commit_before>#!/usr/bin/env python
import os
from setuptools import setup
ROOT_DIR = os.path.dirname(__file__)
SOURCE_DIR = os.path.join(ROOT_DIR)
test_requirements = []
with open('./requirements.txt') as requirements_txt:
requirements = [line for line in requirements_txt]
setup(
name="docker-py",
version='0.2.3',
description="Python client for Docker.",
packages=['docker', 'docker.auth', 'docker.unixconn', 'docker.utils'],
install_requires=requirements + test_requirements,
zip_safe=False,
test_suite='tests',
classifiers=['Development Status :: 4 - Beta',
'Environment :: Other Environment',
'Intended Audience :: Developers',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Utilities',
'License :: OSI Approved :: Apache Software License'
],
)
<commit_msg>Declare explicitly supported python versions<commit_after>
|
#!/usr/bin/env python
import os
from setuptools import setup
ROOT_DIR = os.path.dirname(__file__)
SOURCE_DIR = os.path.join(ROOT_DIR)
test_requirements = []
with open('./requirements.txt') as requirements_txt:
requirements = [line for line in requirements_txt]
setup(
name="docker-py",
version='0.2.3',
description="Python client for Docker.",
packages=['docker', 'docker.auth', 'docker.unixconn', 'docker.utils'],
install_requires=requirements + test_requirements,
zip_safe=False,
test_suite='tests',
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Other Environment',
'Intended Audience :: Developers',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Topic :: Utilities',
'License :: OSI Approved :: Apache Software License',
],
)
|
#!/usr/bin/env python
import os
from setuptools import setup
ROOT_DIR = os.path.dirname(__file__)
SOURCE_DIR = os.path.join(ROOT_DIR)
test_requirements = []
with open('./requirements.txt') as requirements_txt:
requirements = [line for line in requirements_txt]
setup(
name="docker-py",
version='0.2.3',
description="Python client for Docker.",
packages=['docker', 'docker.auth', 'docker.unixconn', 'docker.utils'],
install_requires=requirements + test_requirements,
zip_safe=False,
test_suite='tests',
classifiers=['Development Status :: 4 - Beta',
'Environment :: Other Environment',
'Intended Audience :: Developers',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Utilities',
'License :: OSI Approved :: Apache Software License'
],
)
Declare explicitly supported python versions#!/usr/bin/env python
import os
from setuptools import setup
ROOT_DIR = os.path.dirname(__file__)
SOURCE_DIR = os.path.join(ROOT_DIR)
test_requirements = []
with open('./requirements.txt') as requirements_txt:
requirements = [line for line in requirements_txt]
setup(
name="docker-py",
version='0.2.3',
description="Python client for Docker.",
packages=['docker', 'docker.auth', 'docker.unixconn', 'docker.utils'],
install_requires=requirements + test_requirements,
zip_safe=False,
test_suite='tests',
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Other Environment',
'Intended Audience :: Developers',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Topic :: Utilities',
'License :: OSI Approved :: Apache Software License',
],
)
|
<commit_before>#!/usr/bin/env python
import os
from setuptools import setup
ROOT_DIR = os.path.dirname(__file__)
SOURCE_DIR = os.path.join(ROOT_DIR)
test_requirements = []
with open('./requirements.txt') as requirements_txt:
requirements = [line for line in requirements_txt]
setup(
name="docker-py",
version='0.2.3',
description="Python client for Docker.",
packages=['docker', 'docker.auth', 'docker.unixconn', 'docker.utils'],
install_requires=requirements + test_requirements,
zip_safe=False,
test_suite='tests',
classifiers=['Development Status :: 4 - Beta',
'Environment :: Other Environment',
'Intended Audience :: Developers',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Utilities',
'License :: OSI Approved :: Apache Software License'
],
)
<commit_msg>Declare explicitly supported python versions<commit_after>#!/usr/bin/env python
import os
from setuptools import setup
ROOT_DIR = os.path.dirname(__file__)
SOURCE_DIR = os.path.join(ROOT_DIR)
test_requirements = []
with open('./requirements.txt') as requirements_txt:
requirements = [line for line in requirements_txt]
setup(
name="docker-py",
version='0.2.3',
description="Python client for Docker.",
packages=['docker', 'docker.auth', 'docker.unixconn', 'docker.utils'],
install_requires=requirements + test_requirements,
zip_safe=False,
test_suite='tests',
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Other Environment',
'Intended Audience :: Developers',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Topic :: Utilities',
'License :: OSI Approved :: Apache Software License',
],
)
|
e89f5e4025c5880788676d6c92224710b041a322
|
setup.py
|
setup.py
|
#!/usr/bin/env python
from setuptools import setup, find_packages
def install():
setup(
name='dogu',
version='1.0',
license='MIT',
description='Dogu server, Implementation of dogu interace',
long_description='Dogu server, Implementation of dogu interace',
author='Luavis Kang',
author_email='luaviskang@gmail.com',
url='https://github.com/SomaSoma/dogu',
classifiers=[
'Development Status :: 1 - Planning',
'License :: Freeware',
'Operating System :: POSIX',
'Operating System :: Microsoft :: Windows',
'Operating System :: MacOS :: MacOS X',
'Topic :: Scientific/Engineering :: Interface Engine/Protocol Translator',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4'],
packages=find_packages(),
install_requires=[
'pytest==2.7.2',
'gevent==1.1b3',
'hpack==1.1.0',
'daemonize==2.3.1',
],
script="dogu-server"
)
if __name__ == "__main__":
install()
|
#!/usr/bin/env python
from setuptools import setup, find_packages
def install():
setup(
name='dogu',
version='1.0',
license='MIT',
description='Dogu server, Implementation of dogu interace',
long_description='Dogu server, Implementation of dogu interace',
author='Luavis Kang',
author_email='luaviskang@gmail.com',
url='https://github.com/SomaSoma/dogu',
classifiers=[
'Development Status :: 2 - Pre-Alpha',
'License :: Freeware',
'Operating System :: POSIX',
'Operating System :: Microsoft :: Windows',
'Operating System :: MacOS :: MacOS X',
'Topic :: Scientific/Engineering :: Interface Engine/Protocol Translator',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4'],
packages=find_packages(),
install_requires=[
'pytest==2.7.2',
'gevent==1.1b3',
'hpack==1.1.0',
'daemonize==2.3.1',
],
scripts=["dogu-server"],
)
if __name__ == "__main__":
install()
|
Change Planning to Pre Alpha
|
Change Planning to Pre Alpha
|
Python
|
mit
|
SomaSoma/dogu
|
#!/usr/bin/env python
from setuptools import setup, find_packages
def install():
setup(
name='dogu',
version='1.0',
license='MIT',
description='Dogu server, Implementation of dogu interace',
long_description='Dogu server, Implementation of dogu interace',
author='Luavis Kang',
author_email='luaviskang@gmail.com',
url='https://github.com/SomaSoma/dogu',
classifiers=[
'Development Status :: 1 - Planning',
'License :: Freeware',
'Operating System :: POSIX',
'Operating System :: Microsoft :: Windows',
'Operating System :: MacOS :: MacOS X',
'Topic :: Scientific/Engineering :: Interface Engine/Protocol Translator',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4'],
packages=find_packages(),
install_requires=[
'pytest==2.7.2',
'gevent==1.1b3',
'hpack==1.1.0',
'daemonize==2.3.1',
],
script="dogu-server"
)
if __name__ == "__main__":
install()
Change Planning to Pre Alpha
|
#!/usr/bin/env python
from setuptools import setup, find_packages
def install():
setup(
name='dogu',
version='1.0',
license='MIT',
description='Dogu server, Implementation of dogu interace',
long_description='Dogu server, Implementation of dogu interace',
author='Luavis Kang',
author_email='luaviskang@gmail.com',
url='https://github.com/SomaSoma/dogu',
classifiers=[
'Development Status :: 2 - Pre-Alpha',
'License :: Freeware',
'Operating System :: POSIX',
'Operating System :: Microsoft :: Windows',
'Operating System :: MacOS :: MacOS X',
'Topic :: Scientific/Engineering :: Interface Engine/Protocol Translator',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4'],
packages=find_packages(),
install_requires=[
'pytest==2.7.2',
'gevent==1.1b3',
'hpack==1.1.0',
'daemonize==2.3.1',
],
scripts=["dogu-server"],
)
if __name__ == "__main__":
install()
|
<commit_before>#!/usr/bin/env python
from setuptools import setup, find_packages
def install():
setup(
name='dogu',
version='1.0',
license='MIT',
description='Dogu server, Implementation of dogu interace',
long_description='Dogu server, Implementation of dogu interace',
author='Luavis Kang',
author_email='luaviskang@gmail.com',
url='https://github.com/SomaSoma/dogu',
classifiers=[
'Development Status :: 1 - Planning',
'License :: Freeware',
'Operating System :: POSIX',
'Operating System :: Microsoft :: Windows',
'Operating System :: MacOS :: MacOS X',
'Topic :: Scientific/Engineering :: Interface Engine/Protocol Translator',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4'],
packages=find_packages(),
install_requires=[
'pytest==2.7.2',
'gevent==1.1b3',
'hpack==1.1.0',
'daemonize==2.3.1',
],
script="dogu-server"
)
if __name__ == "__main__":
install()
<commit_msg>Change Planning to Pre Alpha<commit_after>
|
#!/usr/bin/env python
from setuptools import setup, find_packages
def install():
setup(
name='dogu',
version='1.0',
license='MIT',
description='Dogu server, Implementation of dogu interace',
long_description='Dogu server, Implementation of dogu interace',
author='Luavis Kang',
author_email='luaviskang@gmail.com',
url='https://github.com/SomaSoma/dogu',
classifiers=[
'Development Status :: 2 - Pre-Alpha',
'License :: Freeware',
'Operating System :: POSIX',
'Operating System :: Microsoft :: Windows',
'Operating System :: MacOS :: MacOS X',
'Topic :: Scientific/Engineering :: Interface Engine/Protocol Translator',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4'],
packages=find_packages(),
install_requires=[
'pytest==2.7.2',
'gevent==1.1b3',
'hpack==1.1.0',
'daemonize==2.3.1',
],
scripts=["dogu-server"],
)
if __name__ == "__main__":
install()
|
#!/usr/bin/env python
from setuptools import setup, find_packages
def install():
setup(
name='dogu',
version='1.0',
license='MIT',
description='Dogu server, Implementation of dogu interace',
long_description='Dogu server, Implementation of dogu interace',
author='Luavis Kang',
author_email='luaviskang@gmail.com',
url='https://github.com/SomaSoma/dogu',
classifiers=[
'Development Status :: 1 - Planning',
'License :: Freeware',
'Operating System :: POSIX',
'Operating System :: Microsoft :: Windows',
'Operating System :: MacOS :: MacOS X',
'Topic :: Scientific/Engineering :: Interface Engine/Protocol Translator',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4'],
packages=find_packages(),
install_requires=[
'pytest==2.7.2',
'gevent==1.1b3',
'hpack==1.1.0',
'daemonize==2.3.1',
],
script="dogu-server"
)
if __name__ == "__main__":
install()
Change Planning to Pre Alpha#!/usr/bin/env python
from setuptools import setup, find_packages
def install():
setup(
name='dogu',
version='1.0',
license='MIT',
description='Dogu server, Implementation of dogu interace',
long_description='Dogu server, Implementation of dogu interace',
author='Luavis Kang',
author_email='luaviskang@gmail.com',
url='https://github.com/SomaSoma/dogu',
classifiers=[
'Development Status :: 2 - Pre-Alpha',
'License :: Freeware',
'Operating System :: POSIX',
'Operating System :: Microsoft :: Windows',
'Operating System :: MacOS :: MacOS X',
'Topic :: Scientific/Engineering :: Interface Engine/Protocol Translator',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4'],
packages=find_packages(),
install_requires=[
'pytest==2.7.2',
'gevent==1.1b3',
'hpack==1.1.0',
'daemonize==2.3.1',
],
scripts=["dogu-server"],
)
if __name__ == "__main__":
install()
|
<commit_before>#!/usr/bin/env python
from setuptools import setup, find_packages
def install():
setup(
name='dogu',
version='1.0',
license='MIT',
description='Dogu server, Implementation of dogu interace',
long_description='Dogu server, Implementation of dogu interace',
author='Luavis Kang',
author_email='luaviskang@gmail.com',
url='https://github.com/SomaSoma/dogu',
classifiers=[
'Development Status :: 1 - Planning',
'License :: Freeware',
'Operating System :: POSIX',
'Operating System :: Microsoft :: Windows',
'Operating System :: MacOS :: MacOS X',
'Topic :: Scientific/Engineering :: Interface Engine/Protocol Translator',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4'],
packages=find_packages(),
install_requires=[
'pytest==2.7.2',
'gevent==1.1b3',
'hpack==1.1.0',
'daemonize==2.3.1',
],
script="dogu-server"
)
if __name__ == "__main__":
install()
<commit_msg>Change Planning to Pre Alpha<commit_after>#!/usr/bin/env python
from setuptools import setup, find_packages
def install():
setup(
name='dogu',
version='1.0',
license='MIT',
description='Dogu server, Implementation of dogu interace',
long_description='Dogu server, Implementation of dogu interace',
author='Luavis Kang',
author_email='luaviskang@gmail.com',
url='https://github.com/SomaSoma/dogu',
classifiers=[
'Development Status :: 2 - Pre-Alpha',
'License :: Freeware',
'Operating System :: POSIX',
'Operating System :: Microsoft :: Windows',
'Operating System :: MacOS :: MacOS X',
'Topic :: Scientific/Engineering :: Interface Engine/Protocol Translator',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3.2',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4'],
packages=find_packages(),
install_requires=[
'pytest==2.7.2',
'gevent==1.1b3',
'hpack==1.1.0',
'daemonize==2.3.1',
],
scripts=["dogu-server"],
)
if __name__ == "__main__":
install()
|
dab413f009cd6095142ce20995ab058be97657c8
|
setup.py
|
setup.py
|
from distutils.core import setup
from distutils.extension import Extension
from Cython.Distutils import build_ext
import numpy
import configuration
ext_modules = [Extension("sourceterm.srccython", ["sourceterm/srccython.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("romberg", ["romberg.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("rk4", ["rk4.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
#Extension("cythontesting", ["cythontesting.pyx"],
#extra_compile_args=["-g"],
#extra_link_args=["-g"],
#include_dirs=[numpy.get_include()])
]
setup_args = dict(name=configuration.PROGRAM_NAME,
cmdclass = {'build_ext': build_ext},
ext_modules = ext_modules)
if __name__ == "__main__":
setup(**setup_args)
|
from distutils.core import setup
from distutils.extension import Extension
from Cython.Distutils import build_ext
import numpy
import configuration
ext_modules = [Extension("sourceterm.srccython", ["sourceterm/srccython.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("romberg", ["romberg.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("rk4cython", ["rk4.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
#Extension("cythontesting", ["cythontesting.pyx"],
#extra_compile_args=["-g"],
#extra_link_args=["-g"],
#include_dirs=[numpy.get_include()])
]
setup_args = dict(name=configuration.PROGRAM_NAME,
cmdclass = {'build_ext': build_ext},
ext_modules = ext_modules)
if __name__ == "__main__":
setup(**setup_args)
|
Change name of module made by cython to rk4cython to test.
|
Change name of module made by cython to rk4cython to test.
|
Python
|
bsd-3-clause
|
ihuston/pyflation,ihuston/pyflation
|
from distutils.core import setup
from distutils.extension import Extension
from Cython.Distutils import build_ext
import numpy
import configuration
ext_modules = [Extension("sourceterm.srccython", ["sourceterm/srccython.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("romberg", ["romberg.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("rk4", ["rk4.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
#Extension("cythontesting", ["cythontesting.pyx"],
#extra_compile_args=["-g"],
#extra_link_args=["-g"],
#include_dirs=[numpy.get_include()])
]
setup_args = dict(name=configuration.PROGRAM_NAME,
cmdclass = {'build_ext': build_ext},
ext_modules = ext_modules)
if __name__ == "__main__":
setup(**setup_args)
Change name of module made by cython to rk4cython to test.
|
from distutils.core import setup
from distutils.extension import Extension
from Cython.Distutils import build_ext
import numpy
import configuration
ext_modules = [Extension("sourceterm.srccython", ["sourceterm/srccython.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("romberg", ["romberg.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("rk4cython", ["rk4.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
#Extension("cythontesting", ["cythontesting.pyx"],
#extra_compile_args=["-g"],
#extra_link_args=["-g"],
#include_dirs=[numpy.get_include()])
]
setup_args = dict(name=configuration.PROGRAM_NAME,
cmdclass = {'build_ext': build_ext},
ext_modules = ext_modules)
if __name__ == "__main__":
setup(**setup_args)
|
<commit_before>from distutils.core import setup
from distutils.extension import Extension
from Cython.Distutils import build_ext
import numpy
import configuration
ext_modules = [Extension("sourceterm.srccython", ["sourceterm/srccython.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("romberg", ["romberg.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("rk4", ["rk4.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
#Extension("cythontesting", ["cythontesting.pyx"],
#extra_compile_args=["-g"],
#extra_link_args=["-g"],
#include_dirs=[numpy.get_include()])
]
setup_args = dict(name=configuration.PROGRAM_NAME,
cmdclass = {'build_ext': build_ext},
ext_modules = ext_modules)
if __name__ == "__main__":
setup(**setup_args)
<commit_msg>Change name of module made by cython to rk4cython to test.<commit_after>
|
from distutils.core import setup
from distutils.extension import Extension
from Cython.Distutils import build_ext
import numpy
import configuration
ext_modules = [Extension("sourceterm.srccython", ["sourceterm/srccython.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("romberg", ["romberg.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("rk4cython", ["rk4.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
#Extension("cythontesting", ["cythontesting.pyx"],
#extra_compile_args=["-g"],
#extra_link_args=["-g"],
#include_dirs=[numpy.get_include()])
]
setup_args = dict(name=configuration.PROGRAM_NAME,
cmdclass = {'build_ext': build_ext},
ext_modules = ext_modules)
if __name__ == "__main__":
setup(**setup_args)
|
from distutils.core import setup
from distutils.extension import Extension
from Cython.Distutils import build_ext
import numpy
import configuration
ext_modules = [Extension("sourceterm.srccython", ["sourceterm/srccython.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("romberg", ["romberg.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("rk4", ["rk4.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
#Extension("cythontesting", ["cythontesting.pyx"],
#extra_compile_args=["-g"],
#extra_link_args=["-g"],
#include_dirs=[numpy.get_include()])
]
setup_args = dict(name=configuration.PROGRAM_NAME,
cmdclass = {'build_ext': build_ext},
ext_modules = ext_modules)
if __name__ == "__main__":
setup(**setup_args)
Change name of module made by cython to rk4cython to test.from distutils.core import setup
from distutils.extension import Extension
from Cython.Distutils import build_ext
import numpy
import configuration
ext_modules = [Extension("sourceterm.srccython", ["sourceterm/srccython.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("romberg", ["romberg.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("rk4cython", ["rk4.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
#Extension("cythontesting", ["cythontesting.pyx"],
#extra_compile_args=["-g"],
#extra_link_args=["-g"],
#include_dirs=[numpy.get_include()])
]
setup_args = dict(name=configuration.PROGRAM_NAME,
cmdclass = {'build_ext': build_ext},
ext_modules = ext_modules)
if __name__ == "__main__":
setup(**setup_args)
|
<commit_before>from distutils.core import setup
from distutils.extension import Extension
from Cython.Distutils import build_ext
import numpy
import configuration
ext_modules = [Extension("sourceterm.srccython", ["sourceterm/srccython.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("romberg", ["romberg.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("rk4", ["rk4.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
#Extension("cythontesting", ["cythontesting.pyx"],
#extra_compile_args=["-g"],
#extra_link_args=["-g"],
#include_dirs=[numpy.get_include()])
]
setup_args = dict(name=configuration.PROGRAM_NAME,
cmdclass = {'build_ext': build_ext},
ext_modules = ext_modules)
if __name__ == "__main__":
setup(**setup_args)
<commit_msg>Change name of module made by cython to rk4cython to test.<commit_after>from distutils.core import setup
from distutils.extension import Extension
from Cython.Distutils import build_ext
import numpy
import configuration
ext_modules = [Extension("sourceterm.srccython", ["sourceterm/srccython.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("romberg", ["romberg.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
Extension("rk4cython", ["rk4.pyx"],
extra_compile_args=["-g"],
extra_link_args=["-g"],
include_dirs=[numpy.get_include()]),
#
#Extension("cythontesting", ["cythontesting.pyx"],
#extra_compile_args=["-g"],
#extra_link_args=["-g"],
#include_dirs=[numpy.get_include()])
]
setup_args = dict(name=configuration.PROGRAM_NAME,
cmdclass = {'build_ext': build_ext},
ext_modules = ext_modules)
if __name__ == "__main__":
setup(**setup_args)
|
5bf901933e3b0ced065a9134d75b3653cb9d94d3
|
setup.py
|
setup.py
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
try:
from setuptools import setup
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup
setup(
name='django-compress',
version='1.0.0',
description='A Django app for compressing CSS and JS',
author='Michael Crute',
author_email='mike@finiteloopsoftware.com',
url='http://github.com/finiteloopsoftware/django-compress/',
long_description=open('README.rst', 'r').read(),
packages=[
'compress',
'compress.templatetags',
],
package_data={
'compress': ['templates/compress/*'],
},
zip_safe=False,
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Utilities'
],
)
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
try:
from setuptools import setup
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup
setup(
name='django-compress',
version='2.0.0',
description='A Django app for compressing CSS and JS',
author='Michael Crute',
author_email='mike@finiteloopsoftware.com',
url='http://github.com/finiteloopsoftware/django-compress/',
long_description=open('README.rst', 'r').read(),
packages=[
'compress',
'compress.templatetags',
],
package_data={
'compress': ['templates/compress/*'],
},
zip_safe=False,
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Utilities'
],
)
|
Bump to 2.0 to get past old django-compress
|
Bump to 2.0 to get past old django-compress
|
Python
|
bsd-3-clause
|
finiteloopsoftware/django-compressor
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
try:
from setuptools import setup
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup
setup(
name='django-compress',
version='1.0.0',
description='A Django app for compressing CSS and JS',
author='Michael Crute',
author_email='mike@finiteloopsoftware.com',
url='http://github.com/finiteloopsoftware/django-compress/',
long_description=open('README.rst', 'r').read(),
packages=[
'compress',
'compress.templatetags',
],
package_data={
'compress': ['templates/compress/*'],
},
zip_safe=False,
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Utilities'
],
)
Bump to 2.0 to get past old django-compress
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
try:
from setuptools import setup
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup
setup(
name='django-compress',
version='2.0.0',
description='A Django app for compressing CSS and JS',
author='Michael Crute',
author_email='mike@finiteloopsoftware.com',
url='http://github.com/finiteloopsoftware/django-compress/',
long_description=open('README.rst', 'r').read(),
packages=[
'compress',
'compress.templatetags',
],
package_data={
'compress': ['templates/compress/*'],
},
zip_safe=False,
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Utilities'
],
)
|
<commit_before>#!/usr/bin/env python
# -*- coding: utf-8 -*-
try:
from setuptools import setup
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup
setup(
name='django-compress',
version='1.0.0',
description='A Django app for compressing CSS and JS',
author='Michael Crute',
author_email='mike@finiteloopsoftware.com',
url='http://github.com/finiteloopsoftware/django-compress/',
long_description=open('README.rst', 'r').read(),
packages=[
'compress',
'compress.templatetags',
],
package_data={
'compress': ['templates/compress/*'],
},
zip_safe=False,
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Utilities'
],
)
<commit_msg>Bump to 2.0 to get past old django-compress<commit_after>
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
try:
from setuptools import setup
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup
setup(
name='django-compress',
version='2.0.0',
description='A Django app for compressing CSS and JS',
author='Michael Crute',
author_email='mike@finiteloopsoftware.com',
url='http://github.com/finiteloopsoftware/django-compress/',
long_description=open('README.rst', 'r').read(),
packages=[
'compress',
'compress.templatetags',
],
package_data={
'compress': ['templates/compress/*'],
},
zip_safe=False,
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Utilities'
],
)
|
#!/usr/bin/env python
# -*- coding: utf-8 -*-
try:
from setuptools import setup
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup
setup(
name='django-compress',
version='1.0.0',
description='A Django app for compressing CSS and JS',
author='Michael Crute',
author_email='mike@finiteloopsoftware.com',
url='http://github.com/finiteloopsoftware/django-compress/',
long_description=open('README.rst', 'r').read(),
packages=[
'compress',
'compress.templatetags',
],
package_data={
'compress': ['templates/compress/*'],
},
zip_safe=False,
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Utilities'
],
)
Bump to 2.0 to get past old django-compress#!/usr/bin/env python
# -*- coding: utf-8 -*-
try:
from setuptools import setup
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup
setup(
name='django-compress',
version='2.0.0',
description='A Django app for compressing CSS and JS',
author='Michael Crute',
author_email='mike@finiteloopsoftware.com',
url='http://github.com/finiteloopsoftware/django-compress/',
long_description=open('README.rst', 'r').read(),
packages=[
'compress',
'compress.templatetags',
],
package_data={
'compress': ['templates/compress/*'],
},
zip_safe=False,
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Utilities'
],
)
|
<commit_before>#!/usr/bin/env python
# -*- coding: utf-8 -*-
try:
from setuptools import setup
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup
setup(
name='django-compress',
version='1.0.0',
description='A Django app for compressing CSS and JS',
author='Michael Crute',
author_email='mike@finiteloopsoftware.com',
url='http://github.com/finiteloopsoftware/django-compress/',
long_description=open('README.rst', 'r').read(),
packages=[
'compress',
'compress.templatetags',
],
package_data={
'compress': ['templates/compress/*'],
},
zip_safe=False,
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Utilities'
],
)
<commit_msg>Bump to 2.0 to get past old django-compress<commit_after>#!/usr/bin/env python
# -*- coding: utf-8 -*-
try:
from setuptools import setup
except ImportError:
from ez_setup import use_setuptools
use_setuptools()
from setuptools import setup
setup(
name='django-compress',
version='2.0.0',
description='A Django app for compressing CSS and JS',
author='Michael Crute',
author_email='mike@finiteloopsoftware.com',
url='http://github.com/finiteloopsoftware/django-compress/',
long_description=open('README.rst', 'r').read(),
packages=[
'compress',
'compress.templatetags',
],
package_data={
'compress': ['templates/compress/*'],
},
zip_safe=False,
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Topic :: Utilities'
],
)
|
0ab49537a5ee5cae80d7447e8a787eee734b02cc
|
setup.py
|
setup.py
|
#!/usr/bin/python2.4
from distutils.core import setup
setup(name='mox',
version='0.5.1',
py_modules=['mox', 'stubout'],
url='http://code.google.com/p/pymox/',
maintainer='pymox maintainers',
maintainer_email='mox-discuss@googlegroups.com',
license='Apache License, Version 2.0',
description='Mock object framework',
long_description='''Mox is a mock object framework for Python based on the
Java mock object framework EasyMock.''',
)
|
#!/usr/bin/python2.4
from distutils.core import setup
setup(name='mox',
version='0.5.2',
py_modules=['mox', 'stubout'],
url='http://code.google.com/p/pymox/',
maintainer='pymox maintainers',
maintainer_email='mox-discuss@googlegroups.com',
license='Apache License, Version 2.0',
description='Mock object framework',
long_description='''Mox is a mock object framework for Python based on the
Java mock object framework EasyMock.''',
)
|
Increment version number to 0.5.2 for new release.
|
Increment version number to 0.5.2 for new release.
git-svn-id: 81b94fb54a9ccc5de77f18f0566c533f73bbb9c4@41 b1010a0a-674b-0410-b734-77272b80c875
|
Python
|
apache-2.0
|
gmcquillan/mimic
|
#!/usr/bin/python2.4
from distutils.core import setup
setup(name='mox',
version='0.5.1',
py_modules=['mox', 'stubout'],
url='http://code.google.com/p/pymox/',
maintainer='pymox maintainers',
maintainer_email='mox-discuss@googlegroups.com',
license='Apache License, Version 2.0',
description='Mock object framework',
long_description='''Mox is a mock object framework for Python based on the
Java mock object framework EasyMock.''',
)
Increment version number to 0.5.2 for new release.
git-svn-id: 81b94fb54a9ccc5de77f18f0566c533f73bbb9c4@41 b1010a0a-674b-0410-b734-77272b80c875
|
#!/usr/bin/python2.4
from distutils.core import setup
setup(name='mox',
version='0.5.2',
py_modules=['mox', 'stubout'],
url='http://code.google.com/p/pymox/',
maintainer='pymox maintainers',
maintainer_email='mox-discuss@googlegroups.com',
license='Apache License, Version 2.0',
description='Mock object framework',
long_description='''Mox is a mock object framework for Python based on the
Java mock object framework EasyMock.''',
)
|
<commit_before>#!/usr/bin/python2.4
from distutils.core import setup
setup(name='mox',
version='0.5.1',
py_modules=['mox', 'stubout'],
url='http://code.google.com/p/pymox/',
maintainer='pymox maintainers',
maintainer_email='mox-discuss@googlegroups.com',
license='Apache License, Version 2.0',
description='Mock object framework',
long_description='''Mox is a mock object framework for Python based on the
Java mock object framework EasyMock.''',
)
<commit_msg>Increment version number to 0.5.2 for new release.
git-svn-id: 81b94fb54a9ccc5de77f18f0566c533f73bbb9c4@41 b1010a0a-674b-0410-b734-77272b80c875<commit_after>
|
#!/usr/bin/python2.4
from distutils.core import setup
setup(name='mox',
version='0.5.2',
py_modules=['mox', 'stubout'],
url='http://code.google.com/p/pymox/',
maintainer='pymox maintainers',
maintainer_email='mox-discuss@googlegroups.com',
license='Apache License, Version 2.0',
description='Mock object framework',
long_description='''Mox is a mock object framework for Python based on the
Java mock object framework EasyMock.''',
)
|
#!/usr/bin/python2.4
from distutils.core import setup
setup(name='mox',
version='0.5.1',
py_modules=['mox', 'stubout'],
url='http://code.google.com/p/pymox/',
maintainer='pymox maintainers',
maintainer_email='mox-discuss@googlegroups.com',
license='Apache License, Version 2.0',
description='Mock object framework',
long_description='''Mox is a mock object framework for Python based on the
Java mock object framework EasyMock.''',
)
Increment version number to 0.5.2 for new release.
git-svn-id: 81b94fb54a9ccc5de77f18f0566c533f73bbb9c4@41 b1010a0a-674b-0410-b734-77272b80c875#!/usr/bin/python2.4
from distutils.core import setup
setup(name='mox',
version='0.5.2',
py_modules=['mox', 'stubout'],
url='http://code.google.com/p/pymox/',
maintainer='pymox maintainers',
maintainer_email='mox-discuss@googlegroups.com',
license='Apache License, Version 2.0',
description='Mock object framework',
long_description='''Mox is a mock object framework for Python based on the
Java mock object framework EasyMock.''',
)
|
<commit_before>#!/usr/bin/python2.4
from distutils.core import setup
setup(name='mox',
version='0.5.1',
py_modules=['mox', 'stubout'],
url='http://code.google.com/p/pymox/',
maintainer='pymox maintainers',
maintainer_email='mox-discuss@googlegroups.com',
license='Apache License, Version 2.0',
description='Mock object framework',
long_description='''Mox is a mock object framework for Python based on the
Java mock object framework EasyMock.''',
)
<commit_msg>Increment version number to 0.5.2 for new release.
git-svn-id: 81b94fb54a9ccc5de77f18f0566c533f73bbb9c4@41 b1010a0a-674b-0410-b734-77272b80c875<commit_after>#!/usr/bin/python2.4
from distutils.core import setup
setup(name='mox',
version='0.5.2',
py_modules=['mox', 'stubout'],
url='http://code.google.com/p/pymox/',
maintainer='pymox maintainers',
maintainer_email='mox-discuss@googlegroups.com',
license='Apache License, Version 2.0',
description='Mock object framework',
long_description='''Mox is a mock object framework for Python based on the
Java mock object framework EasyMock.''',
)
|
0540d4c176134f573eeebd3e44e01aecf7291151
|
setup.py
|
setup.py
|
import setuptools
setuptools.setup(
name="Monufacture",
version="2.0.0",
author="Tom Leach",
author_email="tom@gc.io",
description="A lightweight factory framework for easily generating test data in MongoDB",
license="BSD",
keywords="mongo mongodb database testing factory pymongo",
url="http://github.com/gamechanger/monufacture",
packages=["monufacture"],
long_description="Monufacture is a factory framework with an API designed to make " +
"it as easy as possible to generate valid test data in MongoDB. " +
"Inspired by the excellent factory_girl Ruby Gem.",
install_requires=['pymongo>=3.0.0', 'pytz'],
tests_require=['mock', 'nose', 'freezegun']
)
|
import setuptools
setuptools.setup(
name="Monufacture",
version="2.0.0",
author="Tom Leach",
author_email="tom@gc.io",
description="A lightweight factory framework for easily generating test data in MongoDB",
license="BSD",
keywords="mongo mongodb database testing factory pymongo",
url="http://github.com/gamechanger/monufacture",
packages=["monufacture"],
long_description="Monufacture is a factory framework with an API designed to make " +
"it as easy as possible to generate valid test data in MongoDB. " +
"Inspired by the excellent factory_girl Ruby Gem.",
install_requires=['pymongo>=3.0.0,<4.0.0', 'pytz'],
tests_require=['mock', 'nose', 'freezegun']
)
|
Add upper bound on PyMongo version for future compatibility
|
Add upper bound on PyMongo version for future compatibility
|
Python
|
mit
|
gamechanger/monufacture
|
import setuptools
setuptools.setup(
name="Monufacture",
version="2.0.0",
author="Tom Leach",
author_email="tom@gc.io",
description="A lightweight factory framework for easily generating test data in MongoDB",
license="BSD",
keywords="mongo mongodb database testing factory pymongo",
url="http://github.com/gamechanger/monufacture",
packages=["monufacture"],
long_description="Monufacture is a factory framework with an API designed to make " +
"it as easy as possible to generate valid test data in MongoDB. " +
"Inspired by the excellent factory_girl Ruby Gem.",
install_requires=['pymongo>=3.0.0', 'pytz'],
tests_require=['mock', 'nose', 'freezegun']
)
Add upper bound on PyMongo version for future compatibility
|
import setuptools
setuptools.setup(
name="Monufacture",
version="2.0.0",
author="Tom Leach",
author_email="tom@gc.io",
description="A lightweight factory framework for easily generating test data in MongoDB",
license="BSD",
keywords="mongo mongodb database testing factory pymongo",
url="http://github.com/gamechanger/monufacture",
packages=["monufacture"],
long_description="Monufacture is a factory framework with an API designed to make " +
"it as easy as possible to generate valid test data in MongoDB. " +
"Inspired by the excellent factory_girl Ruby Gem.",
install_requires=['pymongo>=3.0.0,<4.0.0', 'pytz'],
tests_require=['mock', 'nose', 'freezegun']
)
|
<commit_before>import setuptools
setuptools.setup(
name="Monufacture",
version="2.0.0",
author="Tom Leach",
author_email="tom@gc.io",
description="A lightweight factory framework for easily generating test data in MongoDB",
license="BSD",
keywords="mongo mongodb database testing factory pymongo",
url="http://github.com/gamechanger/monufacture",
packages=["monufacture"],
long_description="Monufacture is a factory framework with an API designed to make " +
"it as easy as possible to generate valid test data in MongoDB. " +
"Inspired by the excellent factory_girl Ruby Gem.",
install_requires=['pymongo>=3.0.0', 'pytz'],
tests_require=['mock', 'nose', 'freezegun']
)
<commit_msg>Add upper bound on PyMongo version for future compatibility<commit_after>
|
import setuptools
setuptools.setup(
name="Monufacture",
version="2.0.0",
author="Tom Leach",
author_email="tom@gc.io",
description="A lightweight factory framework for easily generating test data in MongoDB",
license="BSD",
keywords="mongo mongodb database testing factory pymongo",
url="http://github.com/gamechanger/monufacture",
packages=["monufacture"],
long_description="Monufacture is a factory framework with an API designed to make " +
"it as easy as possible to generate valid test data in MongoDB. " +
"Inspired by the excellent factory_girl Ruby Gem.",
install_requires=['pymongo>=3.0.0,<4.0.0', 'pytz'],
tests_require=['mock', 'nose', 'freezegun']
)
|
import setuptools
setuptools.setup(
name="Monufacture",
version="2.0.0",
author="Tom Leach",
author_email="tom@gc.io",
description="A lightweight factory framework for easily generating test data in MongoDB",
license="BSD",
keywords="mongo mongodb database testing factory pymongo",
url="http://github.com/gamechanger/monufacture",
packages=["monufacture"],
long_description="Monufacture is a factory framework with an API designed to make " +
"it as easy as possible to generate valid test data in MongoDB. " +
"Inspired by the excellent factory_girl Ruby Gem.",
install_requires=['pymongo>=3.0.0', 'pytz'],
tests_require=['mock', 'nose', 'freezegun']
)
Add upper bound on PyMongo version for future compatibilityimport setuptools
setuptools.setup(
name="Monufacture",
version="2.0.0",
author="Tom Leach",
author_email="tom@gc.io",
description="A lightweight factory framework for easily generating test data in MongoDB",
license="BSD",
keywords="mongo mongodb database testing factory pymongo",
url="http://github.com/gamechanger/monufacture",
packages=["monufacture"],
long_description="Monufacture is a factory framework with an API designed to make " +
"it as easy as possible to generate valid test data in MongoDB. " +
"Inspired by the excellent factory_girl Ruby Gem.",
install_requires=['pymongo>=3.0.0,<4.0.0', 'pytz'],
tests_require=['mock', 'nose', 'freezegun']
)
|
<commit_before>import setuptools
setuptools.setup(
name="Monufacture",
version="2.0.0",
author="Tom Leach",
author_email="tom@gc.io",
description="A lightweight factory framework for easily generating test data in MongoDB",
license="BSD",
keywords="mongo mongodb database testing factory pymongo",
url="http://github.com/gamechanger/monufacture",
packages=["monufacture"],
long_description="Monufacture is a factory framework with an API designed to make " +
"it as easy as possible to generate valid test data in MongoDB. " +
"Inspired by the excellent factory_girl Ruby Gem.",
install_requires=['pymongo>=3.0.0', 'pytz'],
tests_require=['mock', 'nose', 'freezegun']
)
<commit_msg>Add upper bound on PyMongo version for future compatibility<commit_after>import setuptools
setuptools.setup(
name="Monufacture",
version="2.0.0",
author="Tom Leach",
author_email="tom@gc.io",
description="A lightweight factory framework for easily generating test data in MongoDB",
license="BSD",
keywords="mongo mongodb database testing factory pymongo",
url="http://github.com/gamechanger/monufacture",
packages=["monufacture"],
long_description="Monufacture is a factory framework with an API designed to make " +
"it as easy as possible to generate valid test data in MongoDB. " +
"Inspired by the excellent factory_girl Ruby Gem.",
install_requires=['pymongo>=3.0.0,<4.0.0', 'pytz'],
tests_require=['mock', 'nose', 'freezegun']
)
|
d2e5d784b4b1376e294b032e937479a7104a47d0
|
setup.py
|
setup.py
|
import os
from glob import glob
from setuptools import setup, find_packages
def read(fname):
with open(os.path.join(os.path.dirname(__file__), fname)) as f:
return f.read()
def recursive_include(module):
module_path = module.replace(".", "/") + "/"
files = glob(f"{module_path}**", recursive=True)
return [file.replace(module_path, "") for file in files]
setup(
name="kivy-ios",
version="1.3.0.dev0",
description="Kivy for iOS",
long_description=read("README.md"),
long_description_content_type="text/markdown",
author="The Kivy team",
author_email="kivy-dev@googlegroups.com",
url="https://github.com/kivy/kivy-ios",
python_requires=">=3.6.0",
install_requires=["cookiecutter", "pbxproj", "Pillow", "requests", "sh"],
packages=find_packages(),
package_data={
# note this method is a bit excessive as it includes absolutely everything
# make sure you run with from a clean directory
"kivy_ios": recursive_include("kivy_ios"),
},
entry_points={"console_scripts": ["toolchain = kivy_ios.toolchain:main"]},
)
|
import os
from glob import glob
from setuptools import setup, find_packages
def read(fname):
with open(os.path.join(os.path.dirname(__file__), fname)) as f:
return f.read()
def recursive_include(module):
module_path = module.replace(".", "/") + "/"
files = glob(f"{module_path}**", recursive=True)
return [file.replace(module_path, "") for file in files]
setup(
name="kivy-ios",
version="1.3.0.dev0",
description="Kivy for iOS",
license="MIT License",
long_description=read("README.md"),
long_description_content_type="text/markdown",
author="The Kivy team",
author_email="kivy-dev@googlegroups.com",
url="https://github.com/kivy/kivy-ios",
python_requires=">=3.6.0",
install_requires=["cookiecutter", "pbxproj", "Pillow", "requests", "sh"],
packages=find_packages(),
package_data={
# note this method is a bit excessive as it includes absolutely everything
# make sure you run with from a clean directory
"kivy_ios": recursive_include("kivy_ios"),
},
entry_points={"console_scripts": ["toolchain = kivy_ios.toolchain:main"]},
)
|
Add official OSI name in the license metadata
|
Add official OSI name in the license metadata
This makes it easier for automatic license checkers to verify the license of this package.
|
Python
|
mit
|
kivy/kivy-ios,kivy/kivy-ios,kivy/kivy-ios
|
import os
from glob import glob
from setuptools import setup, find_packages
def read(fname):
with open(os.path.join(os.path.dirname(__file__), fname)) as f:
return f.read()
def recursive_include(module):
module_path = module.replace(".", "/") + "/"
files = glob(f"{module_path}**", recursive=True)
return [file.replace(module_path, "") for file in files]
setup(
name="kivy-ios",
version="1.3.0.dev0",
description="Kivy for iOS",
long_description=read("README.md"),
long_description_content_type="text/markdown",
author="The Kivy team",
author_email="kivy-dev@googlegroups.com",
url="https://github.com/kivy/kivy-ios",
python_requires=">=3.6.0",
install_requires=["cookiecutter", "pbxproj", "Pillow", "requests", "sh"],
packages=find_packages(),
package_data={
# note this method is a bit excessive as it includes absolutely everything
# make sure you run with from a clean directory
"kivy_ios": recursive_include("kivy_ios"),
},
entry_points={"console_scripts": ["toolchain = kivy_ios.toolchain:main"]},
)
Add official OSI name in the license metadata
This makes it easier for automatic license checkers to verify the license of this package.
|
import os
from glob import glob
from setuptools import setup, find_packages
def read(fname):
with open(os.path.join(os.path.dirname(__file__), fname)) as f:
return f.read()
def recursive_include(module):
module_path = module.replace(".", "/") + "/"
files = glob(f"{module_path}**", recursive=True)
return [file.replace(module_path, "") for file in files]
setup(
name="kivy-ios",
version="1.3.0.dev0",
description="Kivy for iOS",
license="MIT License",
long_description=read("README.md"),
long_description_content_type="text/markdown",
author="The Kivy team",
author_email="kivy-dev@googlegroups.com",
url="https://github.com/kivy/kivy-ios",
python_requires=">=3.6.0",
install_requires=["cookiecutter", "pbxproj", "Pillow", "requests", "sh"],
packages=find_packages(),
package_data={
# note this method is a bit excessive as it includes absolutely everything
# make sure you run with from a clean directory
"kivy_ios": recursive_include("kivy_ios"),
},
entry_points={"console_scripts": ["toolchain = kivy_ios.toolchain:main"]},
)
|
<commit_before>import os
from glob import glob
from setuptools import setup, find_packages
def read(fname):
with open(os.path.join(os.path.dirname(__file__), fname)) as f:
return f.read()
def recursive_include(module):
module_path = module.replace(".", "/") + "/"
files = glob(f"{module_path}**", recursive=True)
return [file.replace(module_path, "") for file in files]
setup(
name="kivy-ios",
version="1.3.0.dev0",
description="Kivy for iOS",
long_description=read("README.md"),
long_description_content_type="text/markdown",
author="The Kivy team",
author_email="kivy-dev@googlegroups.com",
url="https://github.com/kivy/kivy-ios",
python_requires=">=3.6.0",
install_requires=["cookiecutter", "pbxproj", "Pillow", "requests", "sh"],
packages=find_packages(),
package_data={
# note this method is a bit excessive as it includes absolutely everything
# make sure you run with from a clean directory
"kivy_ios": recursive_include("kivy_ios"),
},
entry_points={"console_scripts": ["toolchain = kivy_ios.toolchain:main"]},
)
<commit_msg>Add official OSI name in the license metadata
This makes it easier for automatic license checkers to verify the license of this package.<commit_after>
|
import os
from glob import glob
from setuptools import setup, find_packages
def read(fname):
with open(os.path.join(os.path.dirname(__file__), fname)) as f:
return f.read()
def recursive_include(module):
module_path = module.replace(".", "/") + "/"
files = glob(f"{module_path}**", recursive=True)
return [file.replace(module_path, "") for file in files]
setup(
name="kivy-ios",
version="1.3.0.dev0",
description="Kivy for iOS",
license="MIT License",
long_description=read("README.md"),
long_description_content_type="text/markdown",
author="The Kivy team",
author_email="kivy-dev@googlegroups.com",
url="https://github.com/kivy/kivy-ios",
python_requires=">=3.6.0",
install_requires=["cookiecutter", "pbxproj", "Pillow", "requests", "sh"],
packages=find_packages(),
package_data={
# note this method is a bit excessive as it includes absolutely everything
# make sure you run with from a clean directory
"kivy_ios": recursive_include("kivy_ios"),
},
entry_points={"console_scripts": ["toolchain = kivy_ios.toolchain:main"]},
)
|
import os
from glob import glob
from setuptools import setup, find_packages
def read(fname):
with open(os.path.join(os.path.dirname(__file__), fname)) as f:
return f.read()
def recursive_include(module):
module_path = module.replace(".", "/") + "/"
files = glob(f"{module_path}**", recursive=True)
return [file.replace(module_path, "") for file in files]
setup(
name="kivy-ios",
version="1.3.0.dev0",
description="Kivy for iOS",
long_description=read("README.md"),
long_description_content_type="text/markdown",
author="The Kivy team",
author_email="kivy-dev@googlegroups.com",
url="https://github.com/kivy/kivy-ios",
python_requires=">=3.6.0",
install_requires=["cookiecutter", "pbxproj", "Pillow", "requests", "sh"],
packages=find_packages(),
package_data={
# note this method is a bit excessive as it includes absolutely everything
# make sure you run with from a clean directory
"kivy_ios": recursive_include("kivy_ios"),
},
entry_points={"console_scripts": ["toolchain = kivy_ios.toolchain:main"]},
)
Add official OSI name in the license metadata
This makes it easier for automatic license checkers to verify the license of this package.import os
from glob import glob
from setuptools import setup, find_packages
def read(fname):
with open(os.path.join(os.path.dirname(__file__), fname)) as f:
return f.read()
def recursive_include(module):
module_path = module.replace(".", "/") + "/"
files = glob(f"{module_path}**", recursive=True)
return [file.replace(module_path, "") for file in files]
setup(
name="kivy-ios",
version="1.3.0.dev0",
description="Kivy for iOS",
license="MIT License",
long_description=read("README.md"),
long_description_content_type="text/markdown",
author="The Kivy team",
author_email="kivy-dev@googlegroups.com",
url="https://github.com/kivy/kivy-ios",
python_requires=">=3.6.0",
install_requires=["cookiecutter", "pbxproj", "Pillow", "requests", "sh"],
packages=find_packages(),
package_data={
# note this method is a bit excessive as it includes absolutely everything
# make sure you run with from a clean directory
"kivy_ios": recursive_include("kivy_ios"),
},
entry_points={"console_scripts": ["toolchain = kivy_ios.toolchain:main"]},
)
|
<commit_before>import os
from glob import glob
from setuptools import setup, find_packages
def read(fname):
with open(os.path.join(os.path.dirname(__file__), fname)) as f:
return f.read()
def recursive_include(module):
module_path = module.replace(".", "/") + "/"
files = glob(f"{module_path}**", recursive=True)
return [file.replace(module_path, "") for file in files]
setup(
name="kivy-ios",
version="1.3.0.dev0",
description="Kivy for iOS",
long_description=read("README.md"),
long_description_content_type="text/markdown",
author="The Kivy team",
author_email="kivy-dev@googlegroups.com",
url="https://github.com/kivy/kivy-ios",
python_requires=">=3.6.0",
install_requires=["cookiecutter", "pbxproj", "Pillow", "requests", "sh"],
packages=find_packages(),
package_data={
# note this method is a bit excessive as it includes absolutely everything
# make sure you run with from a clean directory
"kivy_ios": recursive_include("kivy_ios"),
},
entry_points={"console_scripts": ["toolchain = kivy_ios.toolchain:main"]},
)
<commit_msg>Add official OSI name in the license metadata
This makes it easier for automatic license checkers to verify the license of this package.<commit_after>import os
from glob import glob
from setuptools import setup, find_packages
def read(fname):
with open(os.path.join(os.path.dirname(__file__), fname)) as f:
return f.read()
def recursive_include(module):
module_path = module.replace(".", "/") + "/"
files = glob(f"{module_path}**", recursive=True)
return [file.replace(module_path, "") for file in files]
setup(
name="kivy-ios",
version="1.3.0.dev0",
description="Kivy for iOS",
license="MIT License",
long_description=read("README.md"),
long_description_content_type="text/markdown",
author="The Kivy team",
author_email="kivy-dev@googlegroups.com",
url="https://github.com/kivy/kivy-ios",
python_requires=">=3.6.0",
install_requires=["cookiecutter", "pbxproj", "Pillow", "requests", "sh"],
packages=find_packages(),
package_data={
# note this method is a bit excessive as it includes absolutely everything
# make sure you run with from a clean directory
"kivy_ios": recursive_include("kivy_ios"),
},
entry_points={"console_scripts": ["toolchain = kivy_ios.toolchain:main"]},
)
|
ccdfc8d9d45ccdfd8c525572b655e4ddfb8fe328
|
setup.py
|
setup.py
|
from setuptools import setup, find_packages
from suponoff import __version__ as version
if __name__ == '__main__':
with open("README.rst") as f:
long_description = f.read()
setup(
name="suponoff",
version=version,
author="Gambit Research",
author_email="opensource@gambitresearch.com",
description="An alternative Supervisor web interface.",
long_description=long_description,
license="BSD",
url="",
zip_safe=False,
include_package_data=True,
packages=find_packages(),
scripts=[
'suponoff-monhelper.py'
],
install_requires=[
"Django >= 1.7", # just because I only tested with Django 1.7...
],
classifiers=[
"Development Status :: 4 - Beta",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Operating System :: Linux",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.3",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Internet :: WWW/HTTP :: Dynamic Content",
"Topic :: Internet :: WWW/HTTP :: WSGI",
("Topic :: Software Development :: Libraries :: "
"Application Frameworks"),
"Topic :: Software Development :: Libraries :: Python Modules",
])
|
from setuptools import setup, find_packages
from suponoff import __version__ as version
if __name__ == '__main__':
with open("README.rst") as f:
long_description = f.read()
setup(
name="suponoff",
version=version,
author="Gambit Research",
author_email="opensource@gambitresearch.com",
description="An alternative Supervisor web interface.",
long_description=long_description,
license="BSD",
url="",
zip_safe=False,
include_package_data=True,
packages=find_packages(),
scripts=[
'suponoff-monhelper.py'
],
install_requires=[
"Django >= 1.7", # just because I only tested with Django 1.7...
],
classifiers=[
"Development Status :: 4 - Beta",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Operating System :: Linux",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.3",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Internet :: WWW/HTTP :: Dynamic Content",
"Topic :: Internet :: WWW/HTTP :: WSGI",
("Topic :: Software Development :: Libraries :: "
"Application Frameworks"),
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: System :: Systems Administration",
])
|
Add 'Systems Administration' to the list of project classifiers
|
Add 'Systems Administration' to the list of project classifiers
|
Python
|
bsd-2-clause
|
GambitResearch/suponoff,GambitResearch/suponoff,lciti/suponoff,lciti/suponoff,GambitResearch/suponoff,lciti/suponoff
|
from setuptools import setup, find_packages
from suponoff import __version__ as version
if __name__ == '__main__':
with open("README.rst") as f:
long_description = f.read()
setup(
name="suponoff",
version=version,
author="Gambit Research",
author_email="opensource@gambitresearch.com",
description="An alternative Supervisor web interface.",
long_description=long_description,
license="BSD",
url="",
zip_safe=False,
include_package_data=True,
packages=find_packages(),
scripts=[
'suponoff-monhelper.py'
],
install_requires=[
"Django >= 1.7", # just because I only tested with Django 1.7...
],
classifiers=[
"Development Status :: 4 - Beta",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Operating System :: Linux",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.3",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Internet :: WWW/HTTP :: Dynamic Content",
"Topic :: Internet :: WWW/HTTP :: WSGI",
("Topic :: Software Development :: Libraries :: "
"Application Frameworks"),
"Topic :: Software Development :: Libraries :: Python Modules",
])
Add 'Systems Administration' to the list of project classifiers
|
from setuptools import setup, find_packages
from suponoff import __version__ as version
if __name__ == '__main__':
with open("README.rst") as f:
long_description = f.read()
setup(
name="suponoff",
version=version,
author="Gambit Research",
author_email="opensource@gambitresearch.com",
description="An alternative Supervisor web interface.",
long_description=long_description,
license="BSD",
url="",
zip_safe=False,
include_package_data=True,
packages=find_packages(),
scripts=[
'suponoff-monhelper.py'
],
install_requires=[
"Django >= 1.7", # just because I only tested with Django 1.7...
],
classifiers=[
"Development Status :: 4 - Beta",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Operating System :: Linux",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.3",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Internet :: WWW/HTTP :: Dynamic Content",
"Topic :: Internet :: WWW/HTTP :: WSGI",
("Topic :: Software Development :: Libraries :: "
"Application Frameworks"),
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: System :: Systems Administration",
])
|
<commit_before>from setuptools import setup, find_packages
from suponoff import __version__ as version
if __name__ == '__main__':
with open("README.rst") as f:
long_description = f.read()
setup(
name="suponoff",
version=version,
author="Gambit Research",
author_email="opensource@gambitresearch.com",
description="An alternative Supervisor web interface.",
long_description=long_description,
license="BSD",
url="",
zip_safe=False,
include_package_data=True,
packages=find_packages(),
scripts=[
'suponoff-monhelper.py'
],
install_requires=[
"Django >= 1.7", # just because I only tested with Django 1.7...
],
classifiers=[
"Development Status :: 4 - Beta",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Operating System :: Linux",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.3",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Internet :: WWW/HTTP :: Dynamic Content",
"Topic :: Internet :: WWW/HTTP :: WSGI",
("Topic :: Software Development :: Libraries :: "
"Application Frameworks"),
"Topic :: Software Development :: Libraries :: Python Modules",
])
<commit_msg>Add 'Systems Administration' to the list of project classifiers<commit_after>
|
from setuptools import setup, find_packages
from suponoff import __version__ as version
if __name__ == '__main__':
with open("README.rst") as f:
long_description = f.read()
setup(
name="suponoff",
version=version,
author="Gambit Research",
author_email="opensource@gambitresearch.com",
description="An alternative Supervisor web interface.",
long_description=long_description,
license="BSD",
url="",
zip_safe=False,
include_package_data=True,
packages=find_packages(),
scripts=[
'suponoff-monhelper.py'
],
install_requires=[
"Django >= 1.7", # just because I only tested with Django 1.7...
],
classifiers=[
"Development Status :: 4 - Beta",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Operating System :: Linux",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.3",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Internet :: WWW/HTTP :: Dynamic Content",
"Topic :: Internet :: WWW/HTTP :: WSGI",
("Topic :: Software Development :: Libraries :: "
"Application Frameworks"),
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: System :: Systems Administration",
])
|
from setuptools import setup, find_packages
from suponoff import __version__ as version
if __name__ == '__main__':
with open("README.rst") as f:
long_description = f.read()
setup(
name="suponoff",
version=version,
author="Gambit Research",
author_email="opensource@gambitresearch.com",
description="An alternative Supervisor web interface.",
long_description=long_description,
license="BSD",
url="",
zip_safe=False,
include_package_data=True,
packages=find_packages(),
scripts=[
'suponoff-monhelper.py'
],
install_requires=[
"Django >= 1.7", # just because I only tested with Django 1.7...
],
classifiers=[
"Development Status :: 4 - Beta",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Operating System :: Linux",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.3",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Internet :: WWW/HTTP :: Dynamic Content",
"Topic :: Internet :: WWW/HTTP :: WSGI",
("Topic :: Software Development :: Libraries :: "
"Application Frameworks"),
"Topic :: Software Development :: Libraries :: Python Modules",
])
Add 'Systems Administration' to the list of project classifiersfrom setuptools import setup, find_packages
from suponoff import __version__ as version
if __name__ == '__main__':
with open("README.rst") as f:
long_description = f.read()
setup(
name="suponoff",
version=version,
author="Gambit Research",
author_email="opensource@gambitresearch.com",
description="An alternative Supervisor web interface.",
long_description=long_description,
license="BSD",
url="",
zip_safe=False,
include_package_data=True,
packages=find_packages(),
scripts=[
'suponoff-monhelper.py'
],
install_requires=[
"Django >= 1.7", # just because I only tested with Django 1.7...
],
classifiers=[
"Development Status :: 4 - Beta",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Operating System :: Linux",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.3",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Internet :: WWW/HTTP :: Dynamic Content",
"Topic :: Internet :: WWW/HTTP :: WSGI",
("Topic :: Software Development :: Libraries :: "
"Application Frameworks"),
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: System :: Systems Administration",
])
|
<commit_before>from setuptools import setup, find_packages
from suponoff import __version__ as version
if __name__ == '__main__':
with open("README.rst") as f:
long_description = f.read()
setup(
name="suponoff",
version=version,
author="Gambit Research",
author_email="opensource@gambitresearch.com",
description="An alternative Supervisor web interface.",
long_description=long_description,
license="BSD",
url="",
zip_safe=False,
include_package_data=True,
packages=find_packages(),
scripts=[
'suponoff-monhelper.py'
],
install_requires=[
"Django >= 1.7", # just because I only tested with Django 1.7...
],
classifiers=[
"Development Status :: 4 - Beta",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Operating System :: Linux",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.3",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Internet :: WWW/HTTP :: Dynamic Content",
"Topic :: Internet :: WWW/HTTP :: WSGI",
("Topic :: Software Development :: Libraries :: "
"Application Frameworks"),
"Topic :: Software Development :: Libraries :: Python Modules",
])
<commit_msg>Add 'Systems Administration' to the list of project classifiers<commit_after>from setuptools import setup, find_packages
from suponoff import __version__ as version
if __name__ == '__main__':
with open("README.rst") as f:
long_description = f.read()
setup(
name="suponoff",
version=version,
author="Gambit Research",
author_email="opensource@gambitresearch.com",
description="An alternative Supervisor web interface.",
long_description=long_description,
license="BSD",
url="",
zip_safe=False,
include_package_data=True,
packages=find_packages(),
scripts=[
'suponoff-monhelper.py'
],
install_requires=[
"Django >= 1.7", # just because I only tested with Django 1.7...
],
classifiers=[
"Development Status :: 4 - Beta",
"Environment :: Web Environment",
"Framework :: Django",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Operating System :: Linux",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.3",
"Topic :: Internet :: WWW/HTTP",
"Topic :: Internet :: WWW/HTTP :: Dynamic Content",
"Topic :: Internet :: WWW/HTTP :: WSGI",
("Topic :: Software Development :: Libraries :: "
"Application Frameworks"),
"Topic :: Software Development :: Libraries :: Python Modules",
"Topic :: System :: Systems Administration",
])
|
b26d8903561809bec0224cd0ebec5c3c6bff7ee5
|
setup.py
|
setup.py
|
from setuptools import setup, find_packages
requires = [
'configparser',
'python-dateutil',
'pytz',
'requests',
'simplejson'
]
setup(
name='amaascore',
version='0.1.7',
description='Asset Management as a Service - Core SDK',
license='Apache License 2.0',
url='https://github.com/amaas-fintech/amaas-core-sdk-python',
author='AMaaS',
author_email='tech@amaas.com',
classifiers=[
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
packages=find_packages(exclude=['tests']), # Very annoying that this doesnt work - I have to include a MANIFEST
install_requires=requires,
)
|
from setuptools import setup, find_packages
requires = [
'configparser',
'python-dateutil',
'pytz',
'requests',
'simplejson'
]
setup(
name='amaascore',
version='0.1.8',
description='Asset Management as a Service - Core SDK',
license='Apache License 2.0',
url='https://github.com/amaas-fintech/amaas-core-sdk-python',
author='AMaaS',
author_email='tech@amaas.com',
classifiers=[
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
packages=find_packages(exclude=['tests']), # Very annoying that this doesnt work - I have to include a MANIFEST
install_requires=requires,
)
|
Increment version for deployment to PyPI
|
Increment version for deployment to PyPI
|
Python
|
apache-2.0
|
paul-rs/amaas-core-sdk-python,amaas-fintech/amaas-core-sdk-python,nedlowe/amaas-core-sdk-python,nedlowe/amaas-core-sdk-python,paul-rs/amaas-core-sdk-python,amaas-fintech/amaas-core-sdk-python
|
from setuptools import setup, find_packages
requires = [
'configparser',
'python-dateutil',
'pytz',
'requests',
'simplejson'
]
setup(
name='amaascore',
version='0.1.7',
description='Asset Management as a Service - Core SDK',
license='Apache License 2.0',
url='https://github.com/amaas-fintech/amaas-core-sdk-python',
author='AMaaS',
author_email='tech@amaas.com',
classifiers=[
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
packages=find_packages(exclude=['tests']), # Very annoying that this doesnt work - I have to include a MANIFEST
install_requires=requires,
)
Increment version for deployment to PyPI
|
from setuptools import setup, find_packages
requires = [
'configparser',
'python-dateutil',
'pytz',
'requests',
'simplejson'
]
setup(
name='amaascore',
version='0.1.8',
description='Asset Management as a Service - Core SDK',
license='Apache License 2.0',
url='https://github.com/amaas-fintech/amaas-core-sdk-python',
author='AMaaS',
author_email='tech@amaas.com',
classifiers=[
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
packages=find_packages(exclude=['tests']), # Very annoying that this doesnt work - I have to include a MANIFEST
install_requires=requires,
)
|
<commit_before>from setuptools import setup, find_packages
requires = [
'configparser',
'python-dateutil',
'pytz',
'requests',
'simplejson'
]
setup(
name='amaascore',
version='0.1.7',
description='Asset Management as a Service - Core SDK',
license='Apache License 2.0',
url='https://github.com/amaas-fintech/amaas-core-sdk-python',
author='AMaaS',
author_email='tech@amaas.com',
classifiers=[
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
packages=find_packages(exclude=['tests']), # Very annoying that this doesnt work - I have to include a MANIFEST
install_requires=requires,
)
<commit_msg>Increment version for deployment to PyPI<commit_after>
|
from setuptools import setup, find_packages
requires = [
'configparser',
'python-dateutil',
'pytz',
'requests',
'simplejson'
]
setup(
name='amaascore',
version='0.1.8',
description='Asset Management as a Service - Core SDK',
license='Apache License 2.0',
url='https://github.com/amaas-fintech/amaas-core-sdk-python',
author='AMaaS',
author_email='tech@amaas.com',
classifiers=[
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
packages=find_packages(exclude=['tests']), # Very annoying that this doesnt work - I have to include a MANIFEST
install_requires=requires,
)
|
from setuptools import setup, find_packages
requires = [
'configparser',
'python-dateutil',
'pytz',
'requests',
'simplejson'
]
setup(
name='amaascore',
version='0.1.7',
description='Asset Management as a Service - Core SDK',
license='Apache License 2.0',
url='https://github.com/amaas-fintech/amaas-core-sdk-python',
author='AMaaS',
author_email='tech@amaas.com',
classifiers=[
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
packages=find_packages(exclude=['tests']), # Very annoying that this doesnt work - I have to include a MANIFEST
install_requires=requires,
)
Increment version for deployment to PyPIfrom setuptools import setup, find_packages
requires = [
'configparser',
'python-dateutil',
'pytz',
'requests',
'simplejson'
]
setup(
name='amaascore',
version='0.1.8',
description='Asset Management as a Service - Core SDK',
license='Apache License 2.0',
url='https://github.com/amaas-fintech/amaas-core-sdk-python',
author='AMaaS',
author_email='tech@amaas.com',
classifiers=[
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
packages=find_packages(exclude=['tests']), # Very annoying that this doesnt work - I have to include a MANIFEST
install_requires=requires,
)
|
<commit_before>from setuptools import setup, find_packages
requires = [
'configparser',
'python-dateutil',
'pytz',
'requests',
'simplejson'
]
setup(
name='amaascore',
version='0.1.7',
description='Asset Management as a Service - Core SDK',
license='Apache License 2.0',
url='https://github.com/amaas-fintech/amaas-core-sdk-python',
author='AMaaS',
author_email='tech@amaas.com',
classifiers=[
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
packages=find_packages(exclude=['tests']), # Very annoying that this doesnt work - I have to include a MANIFEST
install_requires=requires,
)
<commit_msg>Increment version for deployment to PyPI<commit_after>from setuptools import setup, find_packages
requires = [
'configparser',
'python-dateutil',
'pytz',
'requests',
'simplejson'
]
setup(
name='amaascore',
version='0.1.8',
description='Asset Management as a Service - Core SDK',
license='Apache License 2.0',
url='https://github.com/amaas-fintech/amaas-core-sdk-python',
author='AMaaS',
author_email='tech@amaas.com',
classifiers=[
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
],
packages=find_packages(exclude=['tests']), # Very annoying that this doesnt work - I have to include a MANIFEST
install_requires=requires,
)
|
adaf3a3d1caadebc773d1153f382953d6a39700e
|
setup.py
|
setup.py
|
import os
from setuptools import setup
README = open(os.path.join(os.path.dirname(__file__), 'README.md')).read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='hybridize',
version='0.1',
packages=['hybridize'],
include_package_data=True,
install_requires = [
'setuptools',
'django',
'django-compressor',
'django_mobileesp',
'libsass',
],
license='Apache License, Version 2.0', # example license
description='Django plugin that allows apps to be consumed in native-hybrid mobile apps.',
long_description=README,
url='http://www.example.com/',
author='Your Name',
author_email='yourname@example.com',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License', # example license
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)
|
import os
from setuptools import setup
README = open(os.path.join(os.path.dirname(__file__), 'README.md')).read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='hybridize',
version='0.1',
packages=['hybridize'],
include_package_data=True,
install_requires = [
'setuptools',
'django',
'django-compressor',
'django_mobileesp',
'pyscss',
],
license='Apache License, Version 2.0', # example license
description='Django plugin that allows apps to be consumed in native-hybrid mobile apps.',
long_description=README,
url='http://www.example.com/',
author='Your Name',
author_email='yourname@example.com',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License', # example license
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)
|
Use pyscss instead of libsass, as it should be able to be successfully installed on our managed servers.
|
Use pyscss instead of libsass, as it should be able to be successfully installed on our managed servers.
|
Python
|
apache-2.0
|
charlon/django-hybridize,charlon/django-hybridize,charlon/django-hybridize
|
import os
from setuptools import setup
README = open(os.path.join(os.path.dirname(__file__), 'README.md')).read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='hybridize',
version='0.1',
packages=['hybridize'],
include_package_data=True,
install_requires = [
'setuptools',
'django',
'django-compressor',
'django_mobileesp',
'libsass',
],
license='Apache License, Version 2.0', # example license
description='Django plugin that allows apps to be consumed in native-hybrid mobile apps.',
long_description=README,
url='http://www.example.com/',
author='Your Name',
author_email='yourname@example.com',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License', # example license
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)Use pyscss instead of libsass, as it should be able to be successfully installed on our managed servers.
|
import os
from setuptools import setup
README = open(os.path.join(os.path.dirname(__file__), 'README.md')).read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='hybridize',
version='0.1',
packages=['hybridize'],
include_package_data=True,
install_requires = [
'setuptools',
'django',
'django-compressor',
'django_mobileesp',
'pyscss',
],
license='Apache License, Version 2.0', # example license
description='Django plugin that allows apps to be consumed in native-hybrid mobile apps.',
long_description=README,
url='http://www.example.com/',
author='Your Name',
author_email='yourname@example.com',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License', # example license
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)
|
<commit_before>import os
from setuptools import setup
README = open(os.path.join(os.path.dirname(__file__), 'README.md')).read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='hybridize',
version='0.1',
packages=['hybridize'],
include_package_data=True,
install_requires = [
'setuptools',
'django',
'django-compressor',
'django_mobileesp',
'libsass',
],
license='Apache License, Version 2.0', # example license
description='Django plugin that allows apps to be consumed in native-hybrid mobile apps.',
long_description=README,
url='http://www.example.com/',
author='Your Name',
author_email='yourname@example.com',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License', # example license
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)<commit_msg>Use pyscss instead of libsass, as it should be able to be successfully installed on our managed servers.<commit_after>
|
import os
from setuptools import setup
README = open(os.path.join(os.path.dirname(__file__), 'README.md')).read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='hybridize',
version='0.1',
packages=['hybridize'],
include_package_data=True,
install_requires = [
'setuptools',
'django',
'django-compressor',
'django_mobileesp',
'pyscss',
],
license='Apache License, Version 2.0', # example license
description='Django plugin that allows apps to be consumed in native-hybrid mobile apps.',
long_description=README,
url='http://www.example.com/',
author='Your Name',
author_email='yourname@example.com',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License', # example license
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)
|
import os
from setuptools import setup
README = open(os.path.join(os.path.dirname(__file__), 'README.md')).read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='hybridize',
version='0.1',
packages=['hybridize'],
include_package_data=True,
install_requires = [
'setuptools',
'django',
'django-compressor',
'django_mobileesp',
'libsass',
],
license='Apache License, Version 2.0', # example license
description='Django plugin that allows apps to be consumed in native-hybrid mobile apps.',
long_description=README,
url='http://www.example.com/',
author='Your Name',
author_email='yourname@example.com',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License', # example license
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)Use pyscss instead of libsass, as it should be able to be successfully installed on our managed servers.import os
from setuptools import setup
README = open(os.path.join(os.path.dirname(__file__), 'README.md')).read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='hybridize',
version='0.1',
packages=['hybridize'],
include_package_data=True,
install_requires = [
'setuptools',
'django',
'django-compressor',
'django_mobileesp',
'pyscss',
],
license='Apache License, Version 2.0', # example license
description='Django plugin that allows apps to be consumed in native-hybrid mobile apps.',
long_description=README,
url='http://www.example.com/',
author='Your Name',
author_email='yourname@example.com',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License', # example license
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)
|
<commit_before>import os
from setuptools import setup
README = open(os.path.join(os.path.dirname(__file__), 'README.md')).read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='hybridize',
version='0.1',
packages=['hybridize'],
include_package_data=True,
install_requires = [
'setuptools',
'django',
'django-compressor',
'django_mobileesp',
'libsass',
],
license='Apache License, Version 2.0', # example license
description='Django plugin that allows apps to be consumed in native-hybrid mobile apps.',
long_description=README,
url='http://www.example.com/',
author='Your Name',
author_email='yourname@example.com',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License', # example license
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)<commit_msg>Use pyscss instead of libsass, as it should be able to be successfully installed on our managed servers.<commit_after>import os
from setuptools import setup
README = open(os.path.join(os.path.dirname(__file__), 'README.md')).read()
# allow setup.py to be run from any path
os.chdir(os.path.normpath(os.path.join(os.path.abspath(__file__), os.pardir)))
setup(
name='hybridize',
version='0.1',
packages=['hybridize'],
include_package_data=True,
install_requires = [
'setuptools',
'django',
'django-compressor',
'django_mobileesp',
'pyscss',
],
license='Apache License, Version 2.0', # example license
description='Django plugin that allows apps to be consumed in native-hybrid mobile apps.',
long_description=README,
url='http://www.example.com/',
author='Your Name',
author_email='yourname@example.com',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: Apache Software License', # example license
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
)
|
fc1be53d3e877ea647c1712705097e36d889d3b7
|
setup.py
|
setup.py
|
#!/usr/bin/env python
import twelve
import twelve.adapters
import twelve.services
try:
from setuptools import setup
# hush pyflakes
setup
except ImportError:
from distutils.core import setup
requires = []
setup(
name="twelve",
version=twelve.__version__,
description="12factor inspired settings for a variety of backing services archetypes.",
long_description=open("README.rst").read() + '\n\n' +
open("CHANGELOG.rst").read(),
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
url="https://github.com/dstufft/twelve/",
packages=[
"twelve",
],
package_data={"": ["LICENSE"]},
include_package_data=True,
install_requires=[],
license=open("LICENSE").read(),
classifiers=(
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Programming Language :: Python",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.0",
"Programming Language :: Python :: 3.1",
),
)
|
#!/usr/bin/env python
import twelve
import twelve.adapters
import twelve.services
try:
from setuptools import setup
# hush pyflakes
setup
except ImportError:
from distutils.core import setup
requires = []
setup(
name="twelve",
version=twelve.__version__,
description="12factor inspired settings for a variety of backing services archetypes.",
long_description=open("README.rst").read() + '\n\n' +
open("CHANGELOG.rst").read(),
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
url="https://crate.io/packages/twelve/",
packages=[
"twelve",
],
package_data={"": ["LICENSE"]},
include_package_data=True,
install_requires=[],
license=open("LICENSE").read(),
classifiers=(
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Programming Language :: Python",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.0",
"Programming Language :: Python :: 3.1",
),
)
|
Switch URL to Crate page
|
Switch URL to Crate page
|
Python
|
bsd-3-clause
|
dstufft/twelve
|
#!/usr/bin/env python
import twelve
import twelve.adapters
import twelve.services
try:
from setuptools import setup
# hush pyflakes
setup
except ImportError:
from distutils.core import setup
requires = []
setup(
name="twelve",
version=twelve.__version__,
description="12factor inspired settings for a variety of backing services archetypes.",
long_description=open("README.rst").read() + '\n\n' +
open("CHANGELOG.rst").read(),
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
url="https://github.com/dstufft/twelve/",
packages=[
"twelve",
],
package_data={"": ["LICENSE"]},
include_package_data=True,
install_requires=[],
license=open("LICENSE").read(),
classifiers=(
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Programming Language :: Python",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.0",
"Programming Language :: Python :: 3.1",
),
)
Switch URL to Crate page
|
#!/usr/bin/env python
import twelve
import twelve.adapters
import twelve.services
try:
from setuptools import setup
# hush pyflakes
setup
except ImportError:
from distutils.core import setup
requires = []
setup(
name="twelve",
version=twelve.__version__,
description="12factor inspired settings for a variety of backing services archetypes.",
long_description=open("README.rst").read() + '\n\n' +
open("CHANGELOG.rst").read(),
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
url="https://crate.io/packages/twelve/",
packages=[
"twelve",
],
package_data={"": ["LICENSE"]},
include_package_data=True,
install_requires=[],
license=open("LICENSE").read(),
classifiers=(
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Programming Language :: Python",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.0",
"Programming Language :: Python :: 3.1",
),
)
|
<commit_before>#!/usr/bin/env python
import twelve
import twelve.adapters
import twelve.services
try:
from setuptools import setup
# hush pyflakes
setup
except ImportError:
from distutils.core import setup
requires = []
setup(
name="twelve",
version=twelve.__version__,
description="12factor inspired settings for a variety of backing services archetypes.",
long_description=open("README.rst").read() + '\n\n' +
open("CHANGELOG.rst").read(),
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
url="https://github.com/dstufft/twelve/",
packages=[
"twelve",
],
package_data={"": ["LICENSE"]},
include_package_data=True,
install_requires=[],
license=open("LICENSE").read(),
classifiers=(
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Programming Language :: Python",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.0",
"Programming Language :: Python :: 3.1",
),
)
<commit_msg>Switch URL to Crate page<commit_after>
|
#!/usr/bin/env python
import twelve
import twelve.adapters
import twelve.services
try:
from setuptools import setup
# hush pyflakes
setup
except ImportError:
from distutils.core import setup
requires = []
setup(
name="twelve",
version=twelve.__version__,
description="12factor inspired settings for a variety of backing services archetypes.",
long_description=open("README.rst").read() + '\n\n' +
open("CHANGELOG.rst").read(),
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
url="https://crate.io/packages/twelve/",
packages=[
"twelve",
],
package_data={"": ["LICENSE"]},
include_package_data=True,
install_requires=[],
license=open("LICENSE").read(),
classifiers=(
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Programming Language :: Python",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.0",
"Programming Language :: Python :: 3.1",
),
)
|
#!/usr/bin/env python
import twelve
import twelve.adapters
import twelve.services
try:
from setuptools import setup
# hush pyflakes
setup
except ImportError:
from distutils.core import setup
requires = []
setup(
name="twelve",
version=twelve.__version__,
description="12factor inspired settings for a variety of backing services archetypes.",
long_description=open("README.rst").read() + '\n\n' +
open("CHANGELOG.rst").read(),
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
url="https://github.com/dstufft/twelve/",
packages=[
"twelve",
],
package_data={"": ["LICENSE"]},
include_package_data=True,
install_requires=[],
license=open("LICENSE").read(),
classifiers=(
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Programming Language :: Python",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.0",
"Programming Language :: Python :: 3.1",
),
)
Switch URL to Crate page#!/usr/bin/env python
import twelve
import twelve.adapters
import twelve.services
try:
from setuptools import setup
# hush pyflakes
setup
except ImportError:
from distutils.core import setup
requires = []
setup(
name="twelve",
version=twelve.__version__,
description="12factor inspired settings for a variety of backing services archetypes.",
long_description=open("README.rst").read() + '\n\n' +
open("CHANGELOG.rst").read(),
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
url="https://crate.io/packages/twelve/",
packages=[
"twelve",
],
package_data={"": ["LICENSE"]},
include_package_data=True,
install_requires=[],
license=open("LICENSE").read(),
classifiers=(
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Programming Language :: Python",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.0",
"Programming Language :: Python :: 3.1",
),
)
|
<commit_before>#!/usr/bin/env python
import twelve
import twelve.adapters
import twelve.services
try:
from setuptools import setup
# hush pyflakes
setup
except ImportError:
from distutils.core import setup
requires = []
setup(
name="twelve",
version=twelve.__version__,
description="12factor inspired settings for a variety of backing services archetypes.",
long_description=open("README.rst").read() + '\n\n' +
open("CHANGELOG.rst").read(),
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
url="https://github.com/dstufft/twelve/",
packages=[
"twelve",
],
package_data={"": ["LICENSE"]},
include_package_data=True,
install_requires=[],
license=open("LICENSE").read(),
classifiers=(
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Programming Language :: Python",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.0",
"Programming Language :: Python :: 3.1",
),
)
<commit_msg>Switch URL to Crate page<commit_after>#!/usr/bin/env python
import twelve
import twelve.adapters
import twelve.services
try:
from setuptools import setup
# hush pyflakes
setup
except ImportError:
from distutils.core import setup
requires = []
setup(
name="twelve",
version=twelve.__version__,
description="12factor inspired settings for a variety of backing services archetypes.",
long_description=open("README.rst").read() + '\n\n' +
open("CHANGELOG.rst").read(),
author="Donald Stufft",
author_email="donald.stufft@gmail.com",
url="https://crate.io/packages/twelve/",
packages=[
"twelve",
],
package_data={"": ["LICENSE"]},
include_package_data=True,
install_requires=[],
license=open("LICENSE").read(),
classifiers=(
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Programming Language :: Python",
"Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.0",
"Programming Language :: Python :: 3.1",
),
)
|
c55e5ed59e8fdfa451227a3ed29fee042a591a6a
|
setup.py
|
setup.py
|
import setuptools
from polymorphic_auth import __version__
setuptools.setup(
name='django-polymorphic-auth',
version=__version__,
packages=setuptools.find_packages(),
install_requires=[
'coverage',
'Django',
'django-dynamic-fixture',
'django-nose',
'django-polymorphic',
'django-webtest',
'nose-progressive',
'WebTest',
],
)
|
import setuptools
from polymorphic_auth import __version__
setuptools.setup(
name='django-polymorphic-auth',
version=__version__,
packages=setuptools.find_packages(),
install_requires=[
'coverage',
'Django',
'django-dynamic-fixture',
'django-nose',
'django-polymorphic',
'django-webtest',
'nose-progressive',
'WebTest',
],
extras_require={
'dev': ['ipdb', 'ipython'],
},
)
|
Add `dev` extras to requirements.
|
Add `dev` extras to requirements.
|
Python
|
mit
|
whembed197923/django-polymorphic-auth,ixc/django-polymorphic-auth
|
import setuptools
from polymorphic_auth import __version__
setuptools.setup(
name='django-polymorphic-auth',
version=__version__,
packages=setuptools.find_packages(),
install_requires=[
'coverage',
'Django',
'django-dynamic-fixture',
'django-nose',
'django-polymorphic',
'django-webtest',
'nose-progressive',
'WebTest',
],
)
Add `dev` extras to requirements.
|
import setuptools
from polymorphic_auth import __version__
setuptools.setup(
name='django-polymorphic-auth',
version=__version__,
packages=setuptools.find_packages(),
install_requires=[
'coverage',
'Django',
'django-dynamic-fixture',
'django-nose',
'django-polymorphic',
'django-webtest',
'nose-progressive',
'WebTest',
],
extras_require={
'dev': ['ipdb', 'ipython'],
},
)
|
<commit_before>import setuptools
from polymorphic_auth import __version__
setuptools.setup(
name='django-polymorphic-auth',
version=__version__,
packages=setuptools.find_packages(),
install_requires=[
'coverage',
'Django',
'django-dynamic-fixture',
'django-nose',
'django-polymorphic',
'django-webtest',
'nose-progressive',
'WebTest',
],
)
<commit_msg>Add `dev` extras to requirements.<commit_after>
|
import setuptools
from polymorphic_auth import __version__
setuptools.setup(
name='django-polymorphic-auth',
version=__version__,
packages=setuptools.find_packages(),
install_requires=[
'coverage',
'Django',
'django-dynamic-fixture',
'django-nose',
'django-polymorphic',
'django-webtest',
'nose-progressive',
'WebTest',
],
extras_require={
'dev': ['ipdb', 'ipython'],
},
)
|
import setuptools
from polymorphic_auth import __version__
setuptools.setup(
name='django-polymorphic-auth',
version=__version__,
packages=setuptools.find_packages(),
install_requires=[
'coverage',
'Django',
'django-dynamic-fixture',
'django-nose',
'django-polymorphic',
'django-webtest',
'nose-progressive',
'WebTest',
],
)
Add `dev` extras to requirements.import setuptools
from polymorphic_auth import __version__
setuptools.setup(
name='django-polymorphic-auth',
version=__version__,
packages=setuptools.find_packages(),
install_requires=[
'coverage',
'Django',
'django-dynamic-fixture',
'django-nose',
'django-polymorphic',
'django-webtest',
'nose-progressive',
'WebTest',
],
extras_require={
'dev': ['ipdb', 'ipython'],
},
)
|
<commit_before>import setuptools
from polymorphic_auth import __version__
setuptools.setup(
name='django-polymorphic-auth',
version=__version__,
packages=setuptools.find_packages(),
install_requires=[
'coverage',
'Django',
'django-dynamic-fixture',
'django-nose',
'django-polymorphic',
'django-webtest',
'nose-progressive',
'WebTest',
],
)
<commit_msg>Add `dev` extras to requirements.<commit_after>import setuptools
from polymorphic_auth import __version__
setuptools.setup(
name='django-polymorphic-auth',
version=__version__,
packages=setuptools.find_packages(),
install_requires=[
'coverage',
'Django',
'django-dynamic-fixture',
'django-nose',
'django-polymorphic',
'django-webtest',
'nose-progressive',
'WebTest',
],
extras_require={
'dev': ['ipdb', 'ipython'],
},
)
|
0fea9c036e77a5c6b4d829a41b8a5770f9c4a9f0
|
setup.py
|
setup.py
|
#!/usr/bin/env python
# Copyright (c) 2013 Hewlett-Packard Development Company, L.P.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import setuptools
setuptools.setup(
setup_requires=['d2to1>=0.2.10,<0.3'],
d2to1=True)
|
#!/usr/bin/env python
# Copyright (c) 2013 Hewlett-Packard Development Company, L.P.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import os
import sys
try:
sys.path += [x for x in os.listdir(".") if x.endswith(".egg")]
import d2to1 # flake8: noqa
except ImportError:
import subprocess
if not subprocess.call(
[sys.executable] +
"-m pip.__init__ install distribute<0.7 d2to1>=0.2.10,<0.3".split()
):
sys.exit(subprocess.call([sys.executable] + sys.argv))
import setuptools
setuptools.setup(
setup_requires=['d2to1>=0.2.10,<0.3'],
d2to1=True)
|
Use pip instead of easy_install for installation.
|
Use pip instead of easy_install for installation.
If we're running the installation of dependencies for installation
ourselves anyway - just use pip and be done with it. This means
that our requirements will get installed consistently regardless of
whether we're using pip, python setup.py install or a tox environment.
Change-Id: If92557a33a76553ad36bd136fa87780857a894b1
|
Python
|
apache-2.0
|
openstack-attic/oslo.version,emonty/oslo.version
|
#!/usr/bin/env python
# Copyright (c) 2013 Hewlett-Packard Development Company, L.P.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import setuptools
setuptools.setup(
setup_requires=['d2to1>=0.2.10,<0.3'],
d2to1=True)
Use pip instead of easy_install for installation.
If we're running the installation of dependencies for installation
ourselves anyway - just use pip and be done with it. This means
that our requirements will get installed consistently regardless of
whether we're using pip, python setup.py install or a tox environment.
Change-Id: If92557a33a76553ad36bd136fa87780857a894b1
|
#!/usr/bin/env python
# Copyright (c) 2013 Hewlett-Packard Development Company, L.P.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import os
import sys
try:
sys.path += [x for x in os.listdir(".") if x.endswith(".egg")]
import d2to1 # flake8: noqa
except ImportError:
import subprocess
if not subprocess.call(
[sys.executable] +
"-m pip.__init__ install distribute<0.7 d2to1>=0.2.10,<0.3".split()
):
sys.exit(subprocess.call([sys.executable] + sys.argv))
import setuptools
setuptools.setup(
setup_requires=['d2to1>=0.2.10,<0.3'],
d2to1=True)
|
<commit_before>#!/usr/bin/env python
# Copyright (c) 2013 Hewlett-Packard Development Company, L.P.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import setuptools
setuptools.setup(
setup_requires=['d2to1>=0.2.10,<0.3'],
d2to1=True)
<commit_msg>Use pip instead of easy_install for installation.
If we're running the installation of dependencies for installation
ourselves anyway - just use pip and be done with it. This means
that our requirements will get installed consistently regardless of
whether we're using pip, python setup.py install or a tox environment.
Change-Id: If92557a33a76553ad36bd136fa87780857a894b1<commit_after>
|
#!/usr/bin/env python
# Copyright (c) 2013 Hewlett-Packard Development Company, L.P.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import os
import sys
try:
sys.path += [x for x in os.listdir(".") if x.endswith(".egg")]
import d2to1 # flake8: noqa
except ImportError:
import subprocess
if not subprocess.call(
[sys.executable] +
"-m pip.__init__ install distribute<0.7 d2to1>=0.2.10,<0.3".split()
):
sys.exit(subprocess.call([sys.executable] + sys.argv))
import setuptools
setuptools.setup(
setup_requires=['d2to1>=0.2.10,<0.3'],
d2to1=True)
|
#!/usr/bin/env python
# Copyright (c) 2013 Hewlett-Packard Development Company, L.P.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import setuptools
setuptools.setup(
setup_requires=['d2to1>=0.2.10,<0.3'],
d2to1=True)
Use pip instead of easy_install for installation.
If we're running the installation of dependencies for installation
ourselves anyway - just use pip and be done with it. This means
that our requirements will get installed consistently regardless of
whether we're using pip, python setup.py install or a tox environment.
Change-Id: If92557a33a76553ad36bd136fa87780857a894b1#!/usr/bin/env python
# Copyright (c) 2013 Hewlett-Packard Development Company, L.P.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import os
import sys
try:
sys.path += [x for x in os.listdir(".") if x.endswith(".egg")]
import d2to1 # flake8: noqa
except ImportError:
import subprocess
if not subprocess.call(
[sys.executable] +
"-m pip.__init__ install distribute<0.7 d2to1>=0.2.10,<0.3".split()
):
sys.exit(subprocess.call([sys.executable] + sys.argv))
import setuptools
setuptools.setup(
setup_requires=['d2to1>=0.2.10,<0.3'],
d2to1=True)
|
<commit_before>#!/usr/bin/env python
# Copyright (c) 2013 Hewlett-Packard Development Company, L.P.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import setuptools
setuptools.setup(
setup_requires=['d2to1>=0.2.10,<0.3'],
d2to1=True)
<commit_msg>Use pip instead of easy_install for installation.
If we're running the installation of dependencies for installation
ourselves anyway - just use pip and be done with it. This means
that our requirements will get installed consistently regardless of
whether we're using pip, python setup.py install or a tox environment.
Change-Id: If92557a33a76553ad36bd136fa87780857a894b1<commit_after>#!/usr/bin/env python
# Copyright (c) 2013 Hewlett-Packard Development Company, L.P.
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
# implied.
# See the License for the specific language governing permissions and
# limitations under the License.
import os
import sys
try:
sys.path += [x for x in os.listdir(".") if x.endswith(".egg")]
import d2to1 # flake8: noqa
except ImportError:
import subprocess
if not subprocess.call(
[sys.executable] +
"-m pip.__init__ install distribute<0.7 d2to1>=0.2.10,<0.3".split()
):
sys.exit(subprocess.call([sys.executable] + sys.argv))
import setuptools
setuptools.setup(
setup_requires=['d2to1>=0.2.10,<0.3'],
d2to1=True)
|
20a4d6b681b2fe174f3ef9f03c0ece9024a7fca5
|
views.py
|
views.py
|
from django.http import HttpResponse
from django.shortcuts import render_to_response
from store.models import FandomHierarchy, Image
from store.itemfilters import ApplyPredicates
def frontpage(request):
tree = FandomHierarchy.objects.filter(parent_id=None).get_root()
return render_to_response('index.html', {'filter': None, 'tree': tree})
def filtered(request, filter):
tree = FandomHierarchy.objects.filter(parent_id=None).get_root()
items = Image.objects.all()
if filter:
items = ApplyPredicates(filter, items)
return render_to_response('index.html', {'filter': filter, 'tree': tree, 'items': items})
|
from django.http import HttpResponse
from django.shortcuts import render_to_response
from store.models import FandomHierarchy, Image
from store.itemfilters import ApplyPredicates
def frontpage(request):
tree = FandomHierarchy.objects.filter(parent=None).get_root()
return render_to_response('index.html', {'filter': None, 'tree': tree})
def filtered(request, filter):
tree = FandomHierarchy.objects.filter(parent=None).get_root()
items = Image.objects.all()
if filter:
items = ApplyPredicates(filter, items)
return render_to_response('index.html', {'filter': filter, 'tree': tree, 'items': items})
|
Use the right field name?
|
Use the right field name?
|
Python
|
bsd-3-clause
|
willmurnane/store
|
from django.http import HttpResponse
from django.shortcuts import render_to_response
from store.models import FandomHierarchy, Image
from store.itemfilters import ApplyPredicates
def frontpage(request):
tree = FandomHierarchy.objects.filter(parent_id=None).get_root()
return render_to_response('index.html', {'filter': None, 'tree': tree})
def filtered(request, filter):
tree = FandomHierarchy.objects.filter(parent_id=None).get_root()
items = Image.objects.all()
if filter:
items = ApplyPredicates(filter, items)
return render_to_response('index.html', {'filter': filter, 'tree': tree, 'items': items})
Use the right field name?
|
from django.http import HttpResponse
from django.shortcuts import render_to_response
from store.models import FandomHierarchy, Image
from store.itemfilters import ApplyPredicates
def frontpage(request):
tree = FandomHierarchy.objects.filter(parent=None).get_root()
return render_to_response('index.html', {'filter': None, 'tree': tree})
def filtered(request, filter):
tree = FandomHierarchy.objects.filter(parent=None).get_root()
items = Image.objects.all()
if filter:
items = ApplyPredicates(filter, items)
return render_to_response('index.html', {'filter': filter, 'tree': tree, 'items': items})
|
<commit_before>from django.http import HttpResponse
from django.shortcuts import render_to_response
from store.models import FandomHierarchy, Image
from store.itemfilters import ApplyPredicates
def frontpage(request):
tree = FandomHierarchy.objects.filter(parent_id=None).get_root()
return render_to_response('index.html', {'filter': None, 'tree': tree})
def filtered(request, filter):
tree = FandomHierarchy.objects.filter(parent_id=None).get_root()
items = Image.objects.all()
if filter:
items = ApplyPredicates(filter, items)
return render_to_response('index.html', {'filter': filter, 'tree': tree, 'items': items})
<commit_msg>Use the right field name?<commit_after>
|
from django.http import HttpResponse
from django.shortcuts import render_to_response
from store.models import FandomHierarchy, Image
from store.itemfilters import ApplyPredicates
def frontpage(request):
tree = FandomHierarchy.objects.filter(parent=None).get_root()
return render_to_response('index.html', {'filter': None, 'tree': tree})
def filtered(request, filter):
tree = FandomHierarchy.objects.filter(parent=None).get_root()
items = Image.objects.all()
if filter:
items = ApplyPredicates(filter, items)
return render_to_response('index.html', {'filter': filter, 'tree': tree, 'items': items})
|
from django.http import HttpResponse
from django.shortcuts import render_to_response
from store.models import FandomHierarchy, Image
from store.itemfilters import ApplyPredicates
def frontpage(request):
tree = FandomHierarchy.objects.filter(parent_id=None).get_root()
return render_to_response('index.html', {'filter': None, 'tree': tree})
def filtered(request, filter):
tree = FandomHierarchy.objects.filter(parent_id=None).get_root()
items = Image.objects.all()
if filter:
items = ApplyPredicates(filter, items)
return render_to_response('index.html', {'filter': filter, 'tree': tree, 'items': items})
Use the right field name?from django.http import HttpResponse
from django.shortcuts import render_to_response
from store.models import FandomHierarchy, Image
from store.itemfilters import ApplyPredicates
def frontpage(request):
tree = FandomHierarchy.objects.filter(parent=None).get_root()
return render_to_response('index.html', {'filter': None, 'tree': tree})
def filtered(request, filter):
tree = FandomHierarchy.objects.filter(parent=None).get_root()
items = Image.objects.all()
if filter:
items = ApplyPredicates(filter, items)
return render_to_response('index.html', {'filter': filter, 'tree': tree, 'items': items})
|
<commit_before>from django.http import HttpResponse
from django.shortcuts import render_to_response
from store.models import FandomHierarchy, Image
from store.itemfilters import ApplyPredicates
def frontpage(request):
tree = FandomHierarchy.objects.filter(parent_id=None).get_root()
return render_to_response('index.html', {'filter': None, 'tree': tree})
def filtered(request, filter):
tree = FandomHierarchy.objects.filter(parent_id=None).get_root()
items = Image.objects.all()
if filter:
items = ApplyPredicates(filter, items)
return render_to_response('index.html', {'filter': filter, 'tree': tree, 'items': items})
<commit_msg>Use the right field name?<commit_after>from django.http import HttpResponse
from django.shortcuts import render_to_response
from store.models import FandomHierarchy, Image
from store.itemfilters import ApplyPredicates
def frontpage(request):
tree = FandomHierarchy.objects.filter(parent=None).get_root()
return render_to_response('index.html', {'filter': None, 'tree': tree})
def filtered(request, filter):
tree = FandomHierarchy.objects.filter(parent=None).get_root()
items = Image.objects.all()
if filter:
items = ApplyPredicates(filter, items)
return render_to_response('index.html', {'filter': filter, 'tree': tree, 'items': items})
|
6270f9b926e741efb86940c9c670e23b397e45de
|
tests/grammar_atomic_tests.py
|
tests/grammar_atomic_tests.py
|
from unittest import TestCase
from pyparsing import ParseException
from regparser.grammar.atomic import *
class GrammarAtomicTests(TestCase):
def test_em_digit_p(self):
result = em_digit_p.parseString('(<E T="03">2</E>)')
self.assertEqual('2', result.p5)
def test_double_alpha(self):
# Match (aa), (bb), etc.
result = lower_p.parseString('(a)')
self.assertEqual('a', result.p1)
result = lower_p.parseString('(aa)')
self.assertEqual('aa', result.p1)
result = lower_p.parseString('(i)')
self.assertEqual('i', result.p1)
# Except for roman numerals
with self.assertRaises(ParseException):
result = lower_p.parseString('(ii)')
with self.assertRaises(ParseException):
result = lower_p.parseString('(iv)')
|
from unittest import TestCase
from pyparsing import ParseException
from regparser.grammar.atomic import *
class GrammarAtomicTests(TestCase):
def test_em_digit_p(self):
result = em_digit_p.parseString('(<E T="03">2</E>)')
self.assertEqual('2', result.p5)
def test_double_alpha(self):
for text, p1 in [('(a)', 'a'),
('(aa)', 'aa'),
('(i)','i')]:
result = lower_p.parseString(text)
self.assertEqual(p1, result.p1)
for text in ['(ii)', '(iv)', '(vi)']:
try:
result = lower_p.parseString(text)
except ParseException:
pass
except e:
self.fail("Unexpected error:", e)
else:
self.fail("Didn't raise ParseException")
|
Refactor test to eliminate assertRaises() error with Python 2.6
|
Refactor test to eliminate assertRaises() error with Python 2.6
|
Python
|
cc0-1.0
|
cmc333333/regulations-parser,eregs/regulations-parser,tadhg-ohiggins/regulations-parser,cmc333333/regulations-parser,eregs/regulations-parser,tadhg-ohiggins/regulations-parser
|
from unittest import TestCase
from pyparsing import ParseException
from regparser.grammar.atomic import *
class GrammarAtomicTests(TestCase):
def test_em_digit_p(self):
result = em_digit_p.parseString('(<E T="03">2</E>)')
self.assertEqual('2', result.p5)
def test_double_alpha(self):
# Match (aa), (bb), etc.
result = lower_p.parseString('(a)')
self.assertEqual('a', result.p1)
result = lower_p.parseString('(aa)')
self.assertEqual('aa', result.p1)
result = lower_p.parseString('(i)')
self.assertEqual('i', result.p1)
# Except for roman numerals
with self.assertRaises(ParseException):
result = lower_p.parseString('(ii)')
with self.assertRaises(ParseException):
result = lower_p.parseString('(iv)')
Refactor test to eliminate assertRaises() error with Python 2.6
|
from unittest import TestCase
from pyparsing import ParseException
from regparser.grammar.atomic import *
class GrammarAtomicTests(TestCase):
def test_em_digit_p(self):
result = em_digit_p.parseString('(<E T="03">2</E>)')
self.assertEqual('2', result.p5)
def test_double_alpha(self):
for text, p1 in [('(a)', 'a'),
('(aa)', 'aa'),
('(i)','i')]:
result = lower_p.parseString(text)
self.assertEqual(p1, result.p1)
for text in ['(ii)', '(iv)', '(vi)']:
try:
result = lower_p.parseString(text)
except ParseException:
pass
except e:
self.fail("Unexpected error:", e)
else:
self.fail("Didn't raise ParseException")
|
<commit_before>from unittest import TestCase
from pyparsing import ParseException
from regparser.grammar.atomic import *
class GrammarAtomicTests(TestCase):
def test_em_digit_p(self):
result = em_digit_p.parseString('(<E T="03">2</E>)')
self.assertEqual('2', result.p5)
def test_double_alpha(self):
# Match (aa), (bb), etc.
result = lower_p.parseString('(a)')
self.assertEqual('a', result.p1)
result = lower_p.parseString('(aa)')
self.assertEqual('aa', result.p1)
result = lower_p.parseString('(i)')
self.assertEqual('i', result.p1)
# Except for roman numerals
with self.assertRaises(ParseException):
result = lower_p.parseString('(ii)')
with self.assertRaises(ParseException):
result = lower_p.parseString('(iv)')
<commit_msg>Refactor test to eliminate assertRaises() error with Python 2.6<commit_after>
|
from unittest import TestCase
from pyparsing import ParseException
from regparser.grammar.atomic import *
class GrammarAtomicTests(TestCase):
def test_em_digit_p(self):
result = em_digit_p.parseString('(<E T="03">2</E>)')
self.assertEqual('2', result.p5)
def test_double_alpha(self):
for text, p1 in [('(a)', 'a'),
('(aa)', 'aa'),
('(i)','i')]:
result = lower_p.parseString(text)
self.assertEqual(p1, result.p1)
for text in ['(ii)', '(iv)', '(vi)']:
try:
result = lower_p.parseString(text)
except ParseException:
pass
except e:
self.fail("Unexpected error:", e)
else:
self.fail("Didn't raise ParseException")
|
from unittest import TestCase
from pyparsing import ParseException
from regparser.grammar.atomic import *
class GrammarAtomicTests(TestCase):
def test_em_digit_p(self):
result = em_digit_p.parseString('(<E T="03">2</E>)')
self.assertEqual('2', result.p5)
def test_double_alpha(self):
# Match (aa), (bb), etc.
result = lower_p.parseString('(a)')
self.assertEqual('a', result.p1)
result = lower_p.parseString('(aa)')
self.assertEqual('aa', result.p1)
result = lower_p.parseString('(i)')
self.assertEqual('i', result.p1)
# Except for roman numerals
with self.assertRaises(ParseException):
result = lower_p.parseString('(ii)')
with self.assertRaises(ParseException):
result = lower_p.parseString('(iv)')
Refactor test to eliminate assertRaises() error with Python 2.6from unittest import TestCase
from pyparsing import ParseException
from regparser.grammar.atomic import *
class GrammarAtomicTests(TestCase):
def test_em_digit_p(self):
result = em_digit_p.parseString('(<E T="03">2</E>)')
self.assertEqual('2', result.p5)
def test_double_alpha(self):
for text, p1 in [('(a)', 'a'),
('(aa)', 'aa'),
('(i)','i')]:
result = lower_p.parseString(text)
self.assertEqual(p1, result.p1)
for text in ['(ii)', '(iv)', '(vi)']:
try:
result = lower_p.parseString(text)
except ParseException:
pass
except e:
self.fail("Unexpected error:", e)
else:
self.fail("Didn't raise ParseException")
|
<commit_before>from unittest import TestCase
from pyparsing import ParseException
from regparser.grammar.atomic import *
class GrammarAtomicTests(TestCase):
def test_em_digit_p(self):
result = em_digit_p.parseString('(<E T="03">2</E>)')
self.assertEqual('2', result.p5)
def test_double_alpha(self):
# Match (aa), (bb), etc.
result = lower_p.parseString('(a)')
self.assertEqual('a', result.p1)
result = lower_p.parseString('(aa)')
self.assertEqual('aa', result.p1)
result = lower_p.parseString('(i)')
self.assertEqual('i', result.p1)
# Except for roman numerals
with self.assertRaises(ParseException):
result = lower_p.parseString('(ii)')
with self.assertRaises(ParseException):
result = lower_p.parseString('(iv)')
<commit_msg>Refactor test to eliminate assertRaises() error with Python 2.6<commit_after>from unittest import TestCase
from pyparsing import ParseException
from regparser.grammar.atomic import *
class GrammarAtomicTests(TestCase):
def test_em_digit_p(self):
result = em_digit_p.parseString('(<E T="03">2</E>)')
self.assertEqual('2', result.p5)
def test_double_alpha(self):
for text, p1 in [('(a)', 'a'),
('(aa)', 'aa'),
('(i)','i')]:
result = lower_p.parseString(text)
self.assertEqual(p1, result.p1)
for text in ['(ii)', '(iv)', '(vi)']:
try:
result = lower_p.parseString(text)
except ParseException:
pass
except e:
self.fail("Unexpected error:", e)
else:
self.fail("Didn't raise ParseException")
|
5a6175f3d5a7d3bb709d55d317e19c804ad0634c
|
captura/views.py
|
captura/views.py
|
from django.contrib.auth.decorators import user_passes_test, login_required
from django.shortcuts import render
from perfiles_usuario.utils import is_capturista
from estudios_socioeconomicos.models import Estudio
@login_required
@user_passes_test(is_capturista)
def capturista_dashboard(request):
"""View to render the capturista control dashboard.
This view shows the list of socio-economic studies that are under review
and the button to add a new socio-economic study.
Also shows the edit and see feedback buttons to each socio-economic study
shown in the list if this exists for the current user (capturist).
"""
estudios = []
iduser = request.user.id
rechazados = Estudio.objects.filter(status='rechazado')
for estudio in rechazados:
if estudio.capturista_id == iduser:
estudios.append(estudio)
return render(request, 'captura/dashboard_capturista.html',
{'estudios': estudios})
|
from django.contrib.auth.decorators import user_passes_test, login_required
from django.shortcuts import render
from perfiles_usuario.utils import is_capturista
from estudios_socioeconomicos.models import Estudio
@login_required
#@user_passes_test(is_capturista)
def capturista_dashboard(request):
"""View to render the capturista control dashboard.
This view shows the list of socio-economic studies that are under review
and the button to add a new socio-economic study.
Also shows the edit and see feedback buttons to each socio-economic study
shown in the list if this exists for the current user (capturist).
"""
user_id = request.user.id
estudios = Estudio.objects.filter(status=Estudio.RECHAZADO, capturista_id=user_id)
return render(request, 'captura/dashboard_capturista.html',
{'estudios': estudios})
|
Correct the view of capturist dashboard
|
Correct the view of capturist dashboard
|
Python
|
mit
|
erikiado/jp2_online,erikiado/jp2_online,erikiado/jp2_online
|
from django.contrib.auth.decorators import user_passes_test, login_required
from django.shortcuts import render
from perfiles_usuario.utils import is_capturista
from estudios_socioeconomicos.models import Estudio
@login_required
@user_passes_test(is_capturista)
def capturista_dashboard(request):
"""View to render the capturista control dashboard.
This view shows the list of socio-economic studies that are under review
and the button to add a new socio-economic study.
Also shows the edit and see feedback buttons to each socio-economic study
shown in the list if this exists for the current user (capturist).
"""
estudios = []
iduser = request.user.id
rechazados = Estudio.objects.filter(status='rechazado')
for estudio in rechazados:
if estudio.capturista_id == iduser:
estudios.append(estudio)
return render(request, 'captura/dashboard_capturista.html',
{'estudios': estudios})
Correct the view of capturist dashboard
|
from django.contrib.auth.decorators import user_passes_test, login_required
from django.shortcuts import render
from perfiles_usuario.utils import is_capturista
from estudios_socioeconomicos.models import Estudio
@login_required
#@user_passes_test(is_capturista)
def capturista_dashboard(request):
"""View to render the capturista control dashboard.
This view shows the list of socio-economic studies that are under review
and the button to add a new socio-economic study.
Also shows the edit and see feedback buttons to each socio-economic study
shown in the list if this exists for the current user (capturist).
"""
user_id = request.user.id
estudios = Estudio.objects.filter(status=Estudio.RECHAZADO, capturista_id=user_id)
return render(request, 'captura/dashboard_capturista.html',
{'estudios': estudios})
|
<commit_before>from django.contrib.auth.decorators import user_passes_test, login_required
from django.shortcuts import render
from perfiles_usuario.utils import is_capturista
from estudios_socioeconomicos.models import Estudio
@login_required
@user_passes_test(is_capturista)
def capturista_dashboard(request):
"""View to render the capturista control dashboard.
This view shows the list of socio-economic studies that are under review
and the button to add a new socio-economic study.
Also shows the edit and see feedback buttons to each socio-economic study
shown in the list if this exists for the current user (capturist).
"""
estudios = []
iduser = request.user.id
rechazados = Estudio.objects.filter(status='rechazado')
for estudio in rechazados:
if estudio.capturista_id == iduser:
estudios.append(estudio)
return render(request, 'captura/dashboard_capturista.html',
{'estudios': estudios})
<commit_msg>Correct the view of capturist dashboard<commit_after>
|
from django.contrib.auth.decorators import user_passes_test, login_required
from django.shortcuts import render
from perfiles_usuario.utils import is_capturista
from estudios_socioeconomicos.models import Estudio
@login_required
#@user_passes_test(is_capturista)
def capturista_dashboard(request):
"""View to render the capturista control dashboard.
This view shows the list of socio-economic studies that are under review
and the button to add a new socio-economic study.
Also shows the edit and see feedback buttons to each socio-economic study
shown in the list if this exists for the current user (capturist).
"""
user_id = request.user.id
estudios = Estudio.objects.filter(status=Estudio.RECHAZADO, capturista_id=user_id)
return render(request, 'captura/dashboard_capturista.html',
{'estudios': estudios})
|
from django.contrib.auth.decorators import user_passes_test, login_required
from django.shortcuts import render
from perfiles_usuario.utils import is_capturista
from estudios_socioeconomicos.models import Estudio
@login_required
@user_passes_test(is_capturista)
def capturista_dashboard(request):
"""View to render the capturista control dashboard.
This view shows the list of socio-economic studies that are under review
and the button to add a new socio-economic study.
Also shows the edit and see feedback buttons to each socio-economic study
shown in the list if this exists for the current user (capturist).
"""
estudios = []
iduser = request.user.id
rechazados = Estudio.objects.filter(status='rechazado')
for estudio in rechazados:
if estudio.capturista_id == iduser:
estudios.append(estudio)
return render(request, 'captura/dashboard_capturista.html',
{'estudios': estudios})
Correct the view of capturist dashboardfrom django.contrib.auth.decorators import user_passes_test, login_required
from django.shortcuts import render
from perfiles_usuario.utils import is_capturista
from estudios_socioeconomicos.models import Estudio
@login_required
#@user_passes_test(is_capturista)
def capturista_dashboard(request):
"""View to render the capturista control dashboard.
This view shows the list of socio-economic studies that are under review
and the button to add a new socio-economic study.
Also shows the edit and see feedback buttons to each socio-economic study
shown in the list if this exists for the current user (capturist).
"""
user_id = request.user.id
estudios = Estudio.objects.filter(status=Estudio.RECHAZADO, capturista_id=user_id)
return render(request, 'captura/dashboard_capturista.html',
{'estudios': estudios})
|
<commit_before>from django.contrib.auth.decorators import user_passes_test, login_required
from django.shortcuts import render
from perfiles_usuario.utils import is_capturista
from estudios_socioeconomicos.models import Estudio
@login_required
@user_passes_test(is_capturista)
def capturista_dashboard(request):
"""View to render the capturista control dashboard.
This view shows the list of socio-economic studies that are under review
and the button to add a new socio-economic study.
Also shows the edit and see feedback buttons to each socio-economic study
shown in the list if this exists for the current user (capturist).
"""
estudios = []
iduser = request.user.id
rechazados = Estudio.objects.filter(status='rechazado')
for estudio in rechazados:
if estudio.capturista_id == iduser:
estudios.append(estudio)
return render(request, 'captura/dashboard_capturista.html',
{'estudios': estudios})
<commit_msg>Correct the view of capturist dashboard<commit_after>from django.contrib.auth.decorators import user_passes_test, login_required
from django.shortcuts import render
from perfiles_usuario.utils import is_capturista
from estudios_socioeconomicos.models import Estudio
@login_required
#@user_passes_test(is_capturista)
def capturista_dashboard(request):
"""View to render the capturista control dashboard.
This view shows the list of socio-economic studies that are under review
and the button to add a new socio-economic study.
Also shows the edit and see feedback buttons to each socio-economic study
shown in the list if this exists for the current user (capturist).
"""
user_id = request.user.id
estudios = Estudio.objects.filter(status=Estudio.RECHAZADO, capturista_id=user_id)
return render(request, 'captura/dashboard_capturista.html',
{'estudios': estudios})
|
5410bdf26ac014066efa9e0770a9d902adcbcc75
|
Python/kraken/core/objects/attributes/integer_attribute.py
|
Python/kraken/core/objects/attributes/integer_attribute.py
|
"""Kraken - objects.Attributes.IntegerAttribute module.
Classes:
IntegerAttribute - Base Attribute.
"""
from number_attribute import NumberAttribute
from kraken.core.kraken_system import ks
class IntegerAttribute(NumberAttribute):
"""Float Attribute. Implemented value type checking and limiting."""
def __init__(self, name, value=0, minValue=None, maxValue=None):
super(IntegerAttribute, self).__init__(name, value, minValue=minValue, maxValue=maxValue)
if minValue is None:
if value < 0:
self.setMin(value)
else:
self.setMin(0)
if maxValue is None:
if value == 0:
self.setMax(10)
else:
self.setMax(value * 3)
assert type(self.value) is int, "Value is not of type 'int'."
def setValue(self, value):
"""Sets the value of the attribute.
Arguments:
value -- Value to set the attribute to.
Return:
True if successful.
"""
if type(value) not in (int):
raise TypeError("Value is not of type 'int'.")
if value < self._min:
raise ValueError("Value is less than attribute minimum.")
elif value > self._max:
raise ValueError("Value is greater than attribute maximum.")
super(IntegerAttribute, self).setValue(value)
return True
def getRTVal(self):
"""Returns and RTVal object for this attribute.
Return:
RTVal
"""
return ks.rtVal('Integer', self._value)
|
"""Kraken - objects.Attributes.IntegerAttribute module.
Classes:
IntegerAttribute - Base Attribute.
"""
from number_attribute import NumberAttribute
from kraken.core.kraken_system import ks
class IntegerAttribute(NumberAttribute):
"""Float Attribute. Implemented value type checking and limiting."""
def __init__(self, name, value=0, minValue=None, maxValue=None):
super(IntegerAttribute, self).__init__(name, value, minValue=minValue, maxValue=maxValue)
if minValue is None:
if value < 0:
self.setMin(value)
else:
self.setMin(0)
if maxValue is None:
if value == 0:
self.setMax(10)
else:
self.setMax(value * 3)
assert type(self._value) is int, "Value is not of type 'int'."
def setValue(self, value):
"""Sets the value of the attribute.
Arguments:
value -- Value to set the attribute to.
Return:
True if successful.
"""
if type(value) not in (int):
raise TypeError("Value is not of type 'int'.")
if value < self._min:
raise ValueError("Value is less than attribute minimum.")
elif value > self._max:
raise ValueError("Value is greater than attribute maximum.")
super(IntegerAttribute, self).setValue(value)
return True
def getRTVal(self):
"""Returns and RTVal object for this attribute.
Return:
RTVal
"""
return ks.rtVal('Integer', self._value)
|
Fix value attribute name to _value
|
Fix value attribute name to _value
|
Python
|
bsd-3-clause
|
goshow-jp/Kraken,goshow-jp/Kraken,goshow-jp/Kraken,oculusstorystudio/kraken,oculusstorystudio/kraken
|
"""Kraken - objects.Attributes.IntegerAttribute module.
Classes:
IntegerAttribute - Base Attribute.
"""
from number_attribute import NumberAttribute
from kraken.core.kraken_system import ks
class IntegerAttribute(NumberAttribute):
"""Float Attribute. Implemented value type checking and limiting."""
def __init__(self, name, value=0, minValue=None, maxValue=None):
super(IntegerAttribute, self).__init__(name, value, minValue=minValue, maxValue=maxValue)
if minValue is None:
if value < 0:
self.setMin(value)
else:
self.setMin(0)
if maxValue is None:
if value == 0:
self.setMax(10)
else:
self.setMax(value * 3)
assert type(self.value) is int, "Value is not of type 'int'."
def setValue(self, value):
"""Sets the value of the attribute.
Arguments:
value -- Value to set the attribute to.
Return:
True if successful.
"""
if type(value) not in (int):
raise TypeError("Value is not of type 'int'.")
if value < self._min:
raise ValueError("Value is less than attribute minimum.")
elif value > self._max:
raise ValueError("Value is greater than attribute maximum.")
super(IntegerAttribute, self).setValue(value)
return True
def getRTVal(self):
"""Returns and RTVal object for this attribute.
Return:
RTVal
"""
return ks.rtVal('Integer', self._value)
Fix value attribute name to _value
|
"""Kraken - objects.Attributes.IntegerAttribute module.
Classes:
IntegerAttribute - Base Attribute.
"""
from number_attribute import NumberAttribute
from kraken.core.kraken_system import ks
class IntegerAttribute(NumberAttribute):
"""Float Attribute. Implemented value type checking and limiting."""
def __init__(self, name, value=0, minValue=None, maxValue=None):
super(IntegerAttribute, self).__init__(name, value, minValue=minValue, maxValue=maxValue)
if minValue is None:
if value < 0:
self.setMin(value)
else:
self.setMin(0)
if maxValue is None:
if value == 0:
self.setMax(10)
else:
self.setMax(value * 3)
assert type(self._value) is int, "Value is not of type 'int'."
def setValue(self, value):
"""Sets the value of the attribute.
Arguments:
value -- Value to set the attribute to.
Return:
True if successful.
"""
if type(value) not in (int):
raise TypeError("Value is not of type 'int'.")
if value < self._min:
raise ValueError("Value is less than attribute minimum.")
elif value > self._max:
raise ValueError("Value is greater than attribute maximum.")
super(IntegerAttribute, self).setValue(value)
return True
def getRTVal(self):
"""Returns and RTVal object for this attribute.
Return:
RTVal
"""
return ks.rtVal('Integer', self._value)
|
<commit_before>"""Kraken - objects.Attributes.IntegerAttribute module.
Classes:
IntegerAttribute - Base Attribute.
"""
from number_attribute import NumberAttribute
from kraken.core.kraken_system import ks
class IntegerAttribute(NumberAttribute):
"""Float Attribute. Implemented value type checking and limiting."""
def __init__(self, name, value=0, minValue=None, maxValue=None):
super(IntegerAttribute, self).__init__(name, value, minValue=minValue, maxValue=maxValue)
if minValue is None:
if value < 0:
self.setMin(value)
else:
self.setMin(0)
if maxValue is None:
if value == 0:
self.setMax(10)
else:
self.setMax(value * 3)
assert type(self.value) is int, "Value is not of type 'int'."
def setValue(self, value):
"""Sets the value of the attribute.
Arguments:
value -- Value to set the attribute to.
Return:
True if successful.
"""
if type(value) not in (int):
raise TypeError("Value is not of type 'int'.")
if value < self._min:
raise ValueError("Value is less than attribute minimum.")
elif value > self._max:
raise ValueError("Value is greater than attribute maximum.")
super(IntegerAttribute, self).setValue(value)
return True
def getRTVal(self):
"""Returns and RTVal object for this attribute.
Return:
RTVal
"""
return ks.rtVal('Integer', self._value)
<commit_msg>Fix value attribute name to _value<commit_after>
|
"""Kraken - objects.Attributes.IntegerAttribute module.
Classes:
IntegerAttribute - Base Attribute.
"""
from number_attribute import NumberAttribute
from kraken.core.kraken_system import ks
class IntegerAttribute(NumberAttribute):
"""Float Attribute. Implemented value type checking and limiting."""
def __init__(self, name, value=0, minValue=None, maxValue=None):
super(IntegerAttribute, self).__init__(name, value, minValue=minValue, maxValue=maxValue)
if minValue is None:
if value < 0:
self.setMin(value)
else:
self.setMin(0)
if maxValue is None:
if value == 0:
self.setMax(10)
else:
self.setMax(value * 3)
assert type(self._value) is int, "Value is not of type 'int'."
def setValue(self, value):
"""Sets the value of the attribute.
Arguments:
value -- Value to set the attribute to.
Return:
True if successful.
"""
if type(value) not in (int):
raise TypeError("Value is not of type 'int'.")
if value < self._min:
raise ValueError("Value is less than attribute minimum.")
elif value > self._max:
raise ValueError("Value is greater than attribute maximum.")
super(IntegerAttribute, self).setValue(value)
return True
def getRTVal(self):
"""Returns and RTVal object for this attribute.
Return:
RTVal
"""
return ks.rtVal('Integer', self._value)
|
"""Kraken - objects.Attributes.IntegerAttribute module.
Classes:
IntegerAttribute - Base Attribute.
"""
from number_attribute import NumberAttribute
from kraken.core.kraken_system import ks
class IntegerAttribute(NumberAttribute):
"""Float Attribute. Implemented value type checking and limiting."""
def __init__(self, name, value=0, minValue=None, maxValue=None):
super(IntegerAttribute, self).__init__(name, value, minValue=minValue, maxValue=maxValue)
if minValue is None:
if value < 0:
self.setMin(value)
else:
self.setMin(0)
if maxValue is None:
if value == 0:
self.setMax(10)
else:
self.setMax(value * 3)
assert type(self.value) is int, "Value is not of type 'int'."
def setValue(self, value):
"""Sets the value of the attribute.
Arguments:
value -- Value to set the attribute to.
Return:
True if successful.
"""
if type(value) not in (int):
raise TypeError("Value is not of type 'int'.")
if value < self._min:
raise ValueError("Value is less than attribute minimum.")
elif value > self._max:
raise ValueError("Value is greater than attribute maximum.")
super(IntegerAttribute, self).setValue(value)
return True
def getRTVal(self):
"""Returns and RTVal object for this attribute.
Return:
RTVal
"""
return ks.rtVal('Integer', self._value)
Fix value attribute name to _value"""Kraken - objects.Attributes.IntegerAttribute module.
Classes:
IntegerAttribute - Base Attribute.
"""
from number_attribute import NumberAttribute
from kraken.core.kraken_system import ks
class IntegerAttribute(NumberAttribute):
"""Float Attribute. Implemented value type checking and limiting."""
def __init__(self, name, value=0, minValue=None, maxValue=None):
super(IntegerAttribute, self).__init__(name, value, minValue=minValue, maxValue=maxValue)
if minValue is None:
if value < 0:
self.setMin(value)
else:
self.setMin(0)
if maxValue is None:
if value == 0:
self.setMax(10)
else:
self.setMax(value * 3)
assert type(self._value) is int, "Value is not of type 'int'."
def setValue(self, value):
"""Sets the value of the attribute.
Arguments:
value -- Value to set the attribute to.
Return:
True if successful.
"""
if type(value) not in (int):
raise TypeError("Value is not of type 'int'.")
if value < self._min:
raise ValueError("Value is less than attribute minimum.")
elif value > self._max:
raise ValueError("Value is greater than attribute maximum.")
super(IntegerAttribute, self).setValue(value)
return True
def getRTVal(self):
"""Returns and RTVal object for this attribute.
Return:
RTVal
"""
return ks.rtVal('Integer', self._value)
|
<commit_before>"""Kraken - objects.Attributes.IntegerAttribute module.
Classes:
IntegerAttribute - Base Attribute.
"""
from number_attribute import NumberAttribute
from kraken.core.kraken_system import ks
class IntegerAttribute(NumberAttribute):
"""Float Attribute. Implemented value type checking and limiting."""
def __init__(self, name, value=0, minValue=None, maxValue=None):
super(IntegerAttribute, self).__init__(name, value, minValue=minValue, maxValue=maxValue)
if minValue is None:
if value < 0:
self.setMin(value)
else:
self.setMin(0)
if maxValue is None:
if value == 0:
self.setMax(10)
else:
self.setMax(value * 3)
assert type(self.value) is int, "Value is not of type 'int'."
def setValue(self, value):
"""Sets the value of the attribute.
Arguments:
value -- Value to set the attribute to.
Return:
True if successful.
"""
if type(value) not in (int):
raise TypeError("Value is not of type 'int'.")
if value < self._min:
raise ValueError("Value is less than attribute minimum.")
elif value > self._max:
raise ValueError("Value is greater than attribute maximum.")
super(IntegerAttribute, self).setValue(value)
return True
def getRTVal(self):
"""Returns and RTVal object for this attribute.
Return:
RTVal
"""
return ks.rtVal('Integer', self._value)
<commit_msg>Fix value attribute name to _value<commit_after>"""Kraken - objects.Attributes.IntegerAttribute module.
Classes:
IntegerAttribute - Base Attribute.
"""
from number_attribute import NumberAttribute
from kraken.core.kraken_system import ks
class IntegerAttribute(NumberAttribute):
"""Float Attribute. Implemented value type checking and limiting."""
def __init__(self, name, value=0, minValue=None, maxValue=None):
super(IntegerAttribute, self).__init__(name, value, minValue=minValue, maxValue=maxValue)
if minValue is None:
if value < 0:
self.setMin(value)
else:
self.setMin(0)
if maxValue is None:
if value == 0:
self.setMax(10)
else:
self.setMax(value * 3)
assert type(self._value) is int, "Value is not of type 'int'."
def setValue(self, value):
"""Sets the value of the attribute.
Arguments:
value -- Value to set the attribute to.
Return:
True if successful.
"""
if type(value) not in (int):
raise TypeError("Value is not of type 'int'.")
if value < self._min:
raise ValueError("Value is less than attribute minimum.")
elif value > self._max:
raise ValueError("Value is greater than attribute maximum.")
super(IntegerAttribute, self).setValue(value)
return True
def getRTVal(self):
"""Returns and RTVal object for this attribute.
Return:
RTVal
"""
return ks.rtVal('Integer', self._value)
|
a79801b4f67f3372231b1df2c73e52a7cc6b35a3
|
perfiles_usuario/models.py
|
perfiles_usuario/models.py
|
from django.db import models
from django.conf import settings
from django.contrib.auth.models import Group
from .utils import CAPTURISTA_GROUP
class Capturista(models.Model):
""" Extension of Django's User Model for Capturistas.
We extend the Django User Model to identify Capturistas since they have relations with
other models and close interaction with the API.
Attributes:
----------
user : django.contrib.auth.models.User
A mock user to use across all tests.
activo : BooleanField
Indicates whether the profile is active or not.
"""
user = models.OneToOneField(settings.AUTH_USER_MODEL)
activo = models.BooleanField(default=True)
def save(self, *args, **kwargs):
""" Override the save method to add the capturista group.
"""
user_group = Group.objects.get_or_create(name=CAPTURISTA_GROUP)[0]
self.user.groups.add(user_group)
return super(Capturista, self).save(*args, **kwargs)
|
from django.db import models
from django.conf import settings
from django.contrib.auth.models import Group
from .utils import CAPTURISTA_GROUP
class Capturista(models.Model):
""" Extension of Django's User Model for Capturistas.
We extend the Django User Model to identify Capturistas since they have relations with
other models and close interaction with the API.
Attributes:
----------
user : django.contrib.auth.models.User
The django User related to Capturista (i.e. contains the actual user information).
activo : BooleanField
Indicates whether the profile is active or not.
"""
user = models.OneToOneField(settings.AUTH_USER_MODEL)
activo = models.BooleanField(default=True)
def save(self, *args, **kwargs):
""" Override the save method to add the capturista group.
"""
user_group = Group.objects.get_or_create(name=CAPTURISTA_GROUP)[0]
self.user.groups.add(user_group)
return super(Capturista, self).save(*args, **kwargs)
|
Fix user documentation in Capturista.
|
Fix user documentation in Capturista.
|
Python
|
mit
|
erikiado/jp2_online,erikiado/jp2_online,erikiado/jp2_online
|
from django.db import models
from django.conf import settings
from django.contrib.auth.models import Group
from .utils import CAPTURISTA_GROUP
class Capturista(models.Model):
""" Extension of Django's User Model for Capturistas.
We extend the Django User Model to identify Capturistas since they have relations with
other models and close interaction with the API.
Attributes:
----------
user : django.contrib.auth.models.User
A mock user to use across all tests.
activo : BooleanField
Indicates whether the profile is active or not.
"""
user = models.OneToOneField(settings.AUTH_USER_MODEL)
activo = models.BooleanField(default=True)
def save(self, *args, **kwargs):
""" Override the save method to add the capturista group.
"""
user_group = Group.objects.get_or_create(name=CAPTURISTA_GROUP)[0]
self.user.groups.add(user_group)
return super(Capturista, self).save(*args, **kwargs)
Fix user documentation in Capturista.
|
from django.db import models
from django.conf import settings
from django.contrib.auth.models import Group
from .utils import CAPTURISTA_GROUP
class Capturista(models.Model):
""" Extension of Django's User Model for Capturistas.
We extend the Django User Model to identify Capturistas since they have relations with
other models and close interaction with the API.
Attributes:
----------
user : django.contrib.auth.models.User
The django User related to Capturista (i.e. contains the actual user information).
activo : BooleanField
Indicates whether the profile is active or not.
"""
user = models.OneToOneField(settings.AUTH_USER_MODEL)
activo = models.BooleanField(default=True)
def save(self, *args, **kwargs):
""" Override the save method to add the capturista group.
"""
user_group = Group.objects.get_or_create(name=CAPTURISTA_GROUP)[0]
self.user.groups.add(user_group)
return super(Capturista, self).save(*args, **kwargs)
|
<commit_before>from django.db import models
from django.conf import settings
from django.contrib.auth.models import Group
from .utils import CAPTURISTA_GROUP
class Capturista(models.Model):
""" Extension of Django's User Model for Capturistas.
We extend the Django User Model to identify Capturistas since they have relations with
other models and close interaction with the API.
Attributes:
----------
user : django.contrib.auth.models.User
A mock user to use across all tests.
activo : BooleanField
Indicates whether the profile is active or not.
"""
user = models.OneToOneField(settings.AUTH_USER_MODEL)
activo = models.BooleanField(default=True)
def save(self, *args, **kwargs):
""" Override the save method to add the capturista group.
"""
user_group = Group.objects.get_or_create(name=CAPTURISTA_GROUP)[0]
self.user.groups.add(user_group)
return super(Capturista, self).save(*args, **kwargs)
<commit_msg>Fix user documentation in Capturista.<commit_after>
|
from django.db import models
from django.conf import settings
from django.contrib.auth.models import Group
from .utils import CAPTURISTA_GROUP
class Capturista(models.Model):
""" Extension of Django's User Model for Capturistas.
We extend the Django User Model to identify Capturistas since they have relations with
other models and close interaction with the API.
Attributes:
----------
user : django.contrib.auth.models.User
The django User related to Capturista (i.e. contains the actual user information).
activo : BooleanField
Indicates whether the profile is active or not.
"""
user = models.OneToOneField(settings.AUTH_USER_MODEL)
activo = models.BooleanField(default=True)
def save(self, *args, **kwargs):
""" Override the save method to add the capturista group.
"""
user_group = Group.objects.get_or_create(name=CAPTURISTA_GROUP)[0]
self.user.groups.add(user_group)
return super(Capturista, self).save(*args, **kwargs)
|
from django.db import models
from django.conf import settings
from django.contrib.auth.models import Group
from .utils import CAPTURISTA_GROUP
class Capturista(models.Model):
""" Extension of Django's User Model for Capturistas.
We extend the Django User Model to identify Capturistas since they have relations with
other models and close interaction with the API.
Attributes:
----------
user : django.contrib.auth.models.User
A mock user to use across all tests.
activo : BooleanField
Indicates whether the profile is active or not.
"""
user = models.OneToOneField(settings.AUTH_USER_MODEL)
activo = models.BooleanField(default=True)
def save(self, *args, **kwargs):
""" Override the save method to add the capturista group.
"""
user_group = Group.objects.get_or_create(name=CAPTURISTA_GROUP)[0]
self.user.groups.add(user_group)
return super(Capturista, self).save(*args, **kwargs)
Fix user documentation in Capturista.from django.db import models
from django.conf import settings
from django.contrib.auth.models import Group
from .utils import CAPTURISTA_GROUP
class Capturista(models.Model):
""" Extension of Django's User Model for Capturistas.
We extend the Django User Model to identify Capturistas since they have relations with
other models and close interaction with the API.
Attributes:
----------
user : django.contrib.auth.models.User
The django User related to Capturista (i.e. contains the actual user information).
activo : BooleanField
Indicates whether the profile is active or not.
"""
user = models.OneToOneField(settings.AUTH_USER_MODEL)
activo = models.BooleanField(default=True)
def save(self, *args, **kwargs):
""" Override the save method to add the capturista group.
"""
user_group = Group.objects.get_or_create(name=CAPTURISTA_GROUP)[0]
self.user.groups.add(user_group)
return super(Capturista, self).save(*args, **kwargs)
|
<commit_before>from django.db import models
from django.conf import settings
from django.contrib.auth.models import Group
from .utils import CAPTURISTA_GROUP
class Capturista(models.Model):
""" Extension of Django's User Model for Capturistas.
We extend the Django User Model to identify Capturistas since they have relations with
other models and close interaction with the API.
Attributes:
----------
user : django.contrib.auth.models.User
A mock user to use across all tests.
activo : BooleanField
Indicates whether the profile is active or not.
"""
user = models.OneToOneField(settings.AUTH_USER_MODEL)
activo = models.BooleanField(default=True)
def save(self, *args, **kwargs):
""" Override the save method to add the capturista group.
"""
user_group = Group.objects.get_or_create(name=CAPTURISTA_GROUP)[0]
self.user.groups.add(user_group)
return super(Capturista, self).save(*args, **kwargs)
<commit_msg>Fix user documentation in Capturista.<commit_after>from django.db import models
from django.conf import settings
from django.contrib.auth.models import Group
from .utils import CAPTURISTA_GROUP
class Capturista(models.Model):
""" Extension of Django's User Model for Capturistas.
We extend the Django User Model to identify Capturistas since they have relations with
other models and close interaction with the API.
Attributes:
----------
user : django.contrib.auth.models.User
The django User related to Capturista (i.e. contains the actual user information).
activo : BooleanField
Indicates whether the profile is active or not.
"""
user = models.OneToOneField(settings.AUTH_USER_MODEL)
activo = models.BooleanField(default=True)
def save(self, *args, **kwargs):
""" Override the save method to add the capturista group.
"""
user_group = Group.objects.get_or_create(name=CAPTURISTA_GROUP)[0]
self.user.groups.add(user_group)
return super(Capturista, self).save(*args, **kwargs)
|
8db0479c6d6d960eda2de2332ea19f3779943294
|
run.py
|
run.py
|
# run.py
#
# Copyright(c) Exequiel Ceasar Navarrete <esnavarrete1@up.edu.ph>
# Licensed under MIT
# Version 0.0.0
from app import app
if __name__ == "__main__":
# run the application
app.run(debug=app.config['DEBUG'])
|
#!/usr/bin/env python
# run.py
#
# Copyright(c) Exequiel Ceasar Navarrete <esnavarrete1@up.edu.ph>
# Licensed under MIT
# Version 0.0.0
from app import app
if __name__ == "__main__":
# run the application
app.run(debug=app.config['DEBUG'])
|
Add python shebang and change file mode to executable
|
Add python shebang and change file mode to executable
|
Python
|
mit
|
ecsnavarretemit/sarai-interactive-maps-backend,ecsnavarretemit/sarai-interactive-maps-backend
|
# run.py
#
# Copyright(c) Exequiel Ceasar Navarrete <esnavarrete1@up.edu.ph>
# Licensed under MIT
# Version 0.0.0
from app import app
if __name__ == "__main__":
# run the application
app.run(debug=app.config['DEBUG'])
Add python shebang and change file mode to executable
|
#!/usr/bin/env python
# run.py
#
# Copyright(c) Exequiel Ceasar Navarrete <esnavarrete1@up.edu.ph>
# Licensed under MIT
# Version 0.0.0
from app import app
if __name__ == "__main__":
# run the application
app.run(debug=app.config['DEBUG'])
|
<commit_before># run.py
#
# Copyright(c) Exequiel Ceasar Navarrete <esnavarrete1@up.edu.ph>
# Licensed under MIT
# Version 0.0.0
from app import app
if __name__ == "__main__":
# run the application
app.run(debug=app.config['DEBUG'])
<commit_msg>Add python shebang and change file mode to executable<commit_after>
|
#!/usr/bin/env python
# run.py
#
# Copyright(c) Exequiel Ceasar Navarrete <esnavarrete1@up.edu.ph>
# Licensed under MIT
# Version 0.0.0
from app import app
if __name__ == "__main__":
# run the application
app.run(debug=app.config['DEBUG'])
|
# run.py
#
# Copyright(c) Exequiel Ceasar Navarrete <esnavarrete1@up.edu.ph>
# Licensed under MIT
# Version 0.0.0
from app import app
if __name__ == "__main__":
# run the application
app.run(debug=app.config['DEBUG'])
Add python shebang and change file mode to executable#!/usr/bin/env python
# run.py
#
# Copyright(c) Exequiel Ceasar Navarrete <esnavarrete1@up.edu.ph>
# Licensed under MIT
# Version 0.0.0
from app import app
if __name__ == "__main__":
# run the application
app.run(debug=app.config['DEBUG'])
|
<commit_before># run.py
#
# Copyright(c) Exequiel Ceasar Navarrete <esnavarrete1@up.edu.ph>
# Licensed under MIT
# Version 0.0.0
from app import app
if __name__ == "__main__":
# run the application
app.run(debug=app.config['DEBUG'])
<commit_msg>Add python shebang and change file mode to executable<commit_after>#!/usr/bin/env python
# run.py
#
# Copyright(c) Exequiel Ceasar Navarrete <esnavarrete1@up.edu.ph>
# Licensed under MIT
# Version 0.0.0
from app import app
if __name__ == "__main__":
# run the application
app.run(debug=app.config['DEBUG'])
|
c8550f68977077347eba7331c882585e9bb945bf
|
cla_backend/apps/cla_eventlog/management/commands/find_and_delete_old_cases.py
|
cla_backend/apps/cla_eventlog/management/commands/find_and_delete_old_cases.py
|
from django.core.management.base import BaseCommand
from dateutil.relativedelta import relativedelta
from legalaid.models import Case
from cla_butler.tasks import DeleteOldData
class FindAndDeleteCasesUsingCreationTime(DeleteOldData):
def get_eligible_cases(self):
super(FindAndDeleteCasesUsingCreationTime, self)._setup()
two_years = self.now - relativedelta(years=2)
return Case.objects.filter(created__lte=two_years).exclude(log__created__gte=two_years)
class Command(BaseCommand):
help = (
"Find or delete cases that are 2 years old or over that were not deleted prior to the task command being fixed"
)
def handle(self, *args, **kwargs):
if args[0] == "find":
cases = FindAndDeleteCasesUsingCreationTime().get_eligible_cases()
print(cases)
print(cases.count())
if args[0] == "delete":
FindAndDeleteCasesUsingCreationTime().run()
|
from django.core.management.base import BaseCommand
from dateutil.relativedelta import relativedelta
from legalaid.models import Case
from cla_butler.tasks import DeleteOldData
class FindAndDeleteCasesUsingCreationTime(DeleteOldData):
def get_eligible_cases(self):
self._setup()
two_years = self.now - relativedelta(years=2)
return Case.objects.filter(created__lte=two_years).exclude(log__created__gte=two_years)
class Command(BaseCommand):
help = (
"Find or delete cases that are 2 years old or over that were not deleted prior to the task command being fixed"
)
def handle(self, *args, **kwargs):
instance = FindAndDeleteCasesUsingCreationTime()
if len(args) == 0:
cases = instance.get_eligible_cases()
print(cases.count())
elif args[0] == "delete":
instance.run()
|
Refactor command to find cases by default
|
Refactor command to find cases by default
|
Python
|
mit
|
ministryofjustice/cla_backend,ministryofjustice/cla_backend,ministryofjustice/cla_backend,ministryofjustice/cla_backend
|
from django.core.management.base import BaseCommand
from dateutil.relativedelta import relativedelta
from legalaid.models import Case
from cla_butler.tasks import DeleteOldData
class FindAndDeleteCasesUsingCreationTime(DeleteOldData):
def get_eligible_cases(self):
super(FindAndDeleteCasesUsingCreationTime, self)._setup()
two_years = self.now - relativedelta(years=2)
return Case.objects.filter(created__lte=two_years).exclude(log__created__gte=two_years)
class Command(BaseCommand):
help = (
"Find or delete cases that are 2 years old or over that were not deleted prior to the task command being fixed"
)
def handle(self, *args, **kwargs):
if args[0] == "find":
cases = FindAndDeleteCasesUsingCreationTime().get_eligible_cases()
print(cases)
print(cases.count())
if args[0] == "delete":
FindAndDeleteCasesUsingCreationTime().run()
Refactor command to find cases by default
|
from django.core.management.base import BaseCommand
from dateutil.relativedelta import relativedelta
from legalaid.models import Case
from cla_butler.tasks import DeleteOldData
class FindAndDeleteCasesUsingCreationTime(DeleteOldData):
def get_eligible_cases(self):
self._setup()
two_years = self.now - relativedelta(years=2)
return Case.objects.filter(created__lte=two_years).exclude(log__created__gte=two_years)
class Command(BaseCommand):
help = (
"Find or delete cases that are 2 years old or over that were not deleted prior to the task command being fixed"
)
def handle(self, *args, **kwargs):
instance = FindAndDeleteCasesUsingCreationTime()
if len(args) == 0:
cases = instance.get_eligible_cases()
print(cases.count())
elif args[0] == "delete":
instance.run()
|
<commit_before>from django.core.management.base import BaseCommand
from dateutil.relativedelta import relativedelta
from legalaid.models import Case
from cla_butler.tasks import DeleteOldData
class FindAndDeleteCasesUsingCreationTime(DeleteOldData):
def get_eligible_cases(self):
super(FindAndDeleteCasesUsingCreationTime, self)._setup()
two_years = self.now - relativedelta(years=2)
return Case.objects.filter(created__lte=two_years).exclude(log__created__gte=two_years)
class Command(BaseCommand):
help = (
"Find or delete cases that are 2 years old or over that were not deleted prior to the task command being fixed"
)
def handle(self, *args, **kwargs):
if args[0] == "find":
cases = FindAndDeleteCasesUsingCreationTime().get_eligible_cases()
print(cases)
print(cases.count())
if args[0] == "delete":
FindAndDeleteCasesUsingCreationTime().run()
<commit_msg>Refactor command to find cases by default<commit_after>
|
from django.core.management.base import BaseCommand
from dateutil.relativedelta import relativedelta
from legalaid.models import Case
from cla_butler.tasks import DeleteOldData
class FindAndDeleteCasesUsingCreationTime(DeleteOldData):
def get_eligible_cases(self):
self._setup()
two_years = self.now - relativedelta(years=2)
return Case.objects.filter(created__lte=two_years).exclude(log__created__gte=two_years)
class Command(BaseCommand):
help = (
"Find or delete cases that are 2 years old or over that were not deleted prior to the task command being fixed"
)
def handle(self, *args, **kwargs):
instance = FindAndDeleteCasesUsingCreationTime()
if len(args) == 0:
cases = instance.get_eligible_cases()
print(cases.count())
elif args[0] == "delete":
instance.run()
|
from django.core.management.base import BaseCommand
from dateutil.relativedelta import relativedelta
from legalaid.models import Case
from cla_butler.tasks import DeleteOldData
class FindAndDeleteCasesUsingCreationTime(DeleteOldData):
def get_eligible_cases(self):
super(FindAndDeleteCasesUsingCreationTime, self)._setup()
two_years = self.now - relativedelta(years=2)
return Case.objects.filter(created__lte=two_years).exclude(log__created__gte=two_years)
class Command(BaseCommand):
help = (
"Find or delete cases that are 2 years old or over that were not deleted prior to the task command being fixed"
)
def handle(self, *args, **kwargs):
if args[0] == "find":
cases = FindAndDeleteCasesUsingCreationTime().get_eligible_cases()
print(cases)
print(cases.count())
if args[0] == "delete":
FindAndDeleteCasesUsingCreationTime().run()
Refactor command to find cases by defaultfrom django.core.management.base import BaseCommand
from dateutil.relativedelta import relativedelta
from legalaid.models import Case
from cla_butler.tasks import DeleteOldData
class FindAndDeleteCasesUsingCreationTime(DeleteOldData):
def get_eligible_cases(self):
self._setup()
two_years = self.now - relativedelta(years=2)
return Case.objects.filter(created__lte=two_years).exclude(log__created__gte=two_years)
class Command(BaseCommand):
help = (
"Find or delete cases that are 2 years old or over that were not deleted prior to the task command being fixed"
)
def handle(self, *args, **kwargs):
instance = FindAndDeleteCasesUsingCreationTime()
if len(args) == 0:
cases = instance.get_eligible_cases()
print(cases.count())
elif args[0] == "delete":
instance.run()
|
<commit_before>from django.core.management.base import BaseCommand
from dateutil.relativedelta import relativedelta
from legalaid.models import Case
from cla_butler.tasks import DeleteOldData
class FindAndDeleteCasesUsingCreationTime(DeleteOldData):
def get_eligible_cases(self):
super(FindAndDeleteCasesUsingCreationTime, self)._setup()
two_years = self.now - relativedelta(years=2)
return Case.objects.filter(created__lte=two_years).exclude(log__created__gte=two_years)
class Command(BaseCommand):
help = (
"Find or delete cases that are 2 years old or over that were not deleted prior to the task command being fixed"
)
def handle(self, *args, **kwargs):
if args[0] == "find":
cases = FindAndDeleteCasesUsingCreationTime().get_eligible_cases()
print(cases)
print(cases.count())
if args[0] == "delete":
FindAndDeleteCasesUsingCreationTime().run()
<commit_msg>Refactor command to find cases by default<commit_after>from django.core.management.base import BaseCommand
from dateutil.relativedelta import relativedelta
from legalaid.models import Case
from cla_butler.tasks import DeleteOldData
class FindAndDeleteCasesUsingCreationTime(DeleteOldData):
def get_eligible_cases(self):
self._setup()
two_years = self.now - relativedelta(years=2)
return Case.objects.filter(created__lte=two_years).exclude(log__created__gte=two_years)
class Command(BaseCommand):
help = (
"Find or delete cases that are 2 years old or over that were not deleted prior to the task command being fixed"
)
def handle(self, *args, **kwargs):
instance = FindAndDeleteCasesUsingCreationTime()
if len(args) == 0:
cases = instance.get_eligible_cases()
print(cases.count())
elif args[0] == "delete":
instance.run()
|
f02282be3cf2901a9fd6c816f1b4c37b09abdc7b
|
addons/base/models/hooks.py
|
addons/base/models/hooks.py
|
# -*- coding: utf-8 -*-
##############################################################################
#
# Copyright (C) 2014-2015 Anthony Minotti <anthony@minotti.cool>.
#
#
# This file is part of Yameo framework.
#
# Yameo framework is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
# Yameo framework is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with Yameo framework. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
from app.context import models
from lib.exceptions import *
def ressourceConstraints(self, value):
ressource = value.lower().capitalize()
if not models.get(ressource):
raise Core400Exception("Ressource '{}' doesn't exist.".format(ressource))
return ressource
|
# -*- coding: utf-8 -*-
##############################################################################
#
# Copyright (C) 2014-2015 Anthony Minotti <anthony@minotti.cool>.
#
#
# This file is part of Yameo framework.
#
# Yameo framework is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
# Yameo framework is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with Yameo framework. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
from app.context import models
from lib.exceptions import *
def ressourceConstraints(self, value):
ressource = value.lower().capitalize()
if not models.get(ressource):
raise Core400Exception("Ressource '{}' doesn't exist.".format(ressource))
return ressource
def write(self):
# Test if ressource is hookable before performing normal process
if models.get(self.ressource)._hookable:
super(self.__class__, self).write()
else:
raise Core400Exception("Ressource '{}' is not hookable.".format(self.ressource))
def update(self, data2save, domain):
# Test if ressource is hookable before performing normal process
if models.get(self.ressource)._hookable:
super(self.__class__, self).update(data2save, domain)
else:
raise Core400Exception("Ressource '{}' is not hookable.".format(self.ressource))
|
Test if ressource is hookable before write/update
|
Test if ressource is hookable before write/update
|
Python
|
agpl-3.0
|
aminotti/yameo,aminotti/yameo
|
# -*- coding: utf-8 -*-
##############################################################################
#
# Copyright (C) 2014-2015 Anthony Minotti <anthony@minotti.cool>.
#
#
# This file is part of Yameo framework.
#
# Yameo framework is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
# Yameo framework is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with Yameo framework. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
from app.context import models
from lib.exceptions import *
def ressourceConstraints(self, value):
ressource = value.lower().capitalize()
if not models.get(ressource):
raise Core400Exception("Ressource '{}' doesn't exist.".format(ressource))
return ressource
Test if ressource is hookable before write/update
|
# -*- coding: utf-8 -*-
##############################################################################
#
# Copyright (C) 2014-2015 Anthony Minotti <anthony@minotti.cool>.
#
#
# This file is part of Yameo framework.
#
# Yameo framework is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
# Yameo framework is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with Yameo framework. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
from app.context import models
from lib.exceptions import *
def ressourceConstraints(self, value):
ressource = value.lower().capitalize()
if not models.get(ressource):
raise Core400Exception("Ressource '{}' doesn't exist.".format(ressource))
return ressource
def write(self):
# Test if ressource is hookable before performing normal process
if models.get(self.ressource)._hookable:
super(self.__class__, self).write()
else:
raise Core400Exception("Ressource '{}' is not hookable.".format(self.ressource))
def update(self, data2save, domain):
# Test if ressource is hookable before performing normal process
if models.get(self.ressource)._hookable:
super(self.__class__, self).update(data2save, domain)
else:
raise Core400Exception("Ressource '{}' is not hookable.".format(self.ressource))
|
<commit_before># -*- coding: utf-8 -*-
##############################################################################
#
# Copyright (C) 2014-2015 Anthony Minotti <anthony@minotti.cool>.
#
#
# This file is part of Yameo framework.
#
# Yameo framework is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
# Yameo framework is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with Yameo framework. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
from app.context import models
from lib.exceptions import *
def ressourceConstraints(self, value):
ressource = value.lower().capitalize()
if not models.get(ressource):
raise Core400Exception("Ressource '{}' doesn't exist.".format(ressource))
return ressource
<commit_msg>Test if ressource is hookable before write/update<commit_after>
|
# -*- coding: utf-8 -*-
##############################################################################
#
# Copyright (C) 2014-2015 Anthony Minotti <anthony@minotti.cool>.
#
#
# This file is part of Yameo framework.
#
# Yameo framework is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
# Yameo framework is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with Yameo framework. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
from app.context import models
from lib.exceptions import *
def ressourceConstraints(self, value):
ressource = value.lower().capitalize()
if not models.get(ressource):
raise Core400Exception("Ressource '{}' doesn't exist.".format(ressource))
return ressource
def write(self):
# Test if ressource is hookable before performing normal process
if models.get(self.ressource)._hookable:
super(self.__class__, self).write()
else:
raise Core400Exception("Ressource '{}' is not hookable.".format(self.ressource))
def update(self, data2save, domain):
# Test if ressource is hookable before performing normal process
if models.get(self.ressource)._hookable:
super(self.__class__, self).update(data2save, domain)
else:
raise Core400Exception("Ressource '{}' is not hookable.".format(self.ressource))
|
# -*- coding: utf-8 -*-
##############################################################################
#
# Copyright (C) 2014-2015 Anthony Minotti <anthony@minotti.cool>.
#
#
# This file is part of Yameo framework.
#
# Yameo framework is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
# Yameo framework is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with Yameo framework. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
from app.context import models
from lib.exceptions import *
def ressourceConstraints(self, value):
ressource = value.lower().capitalize()
if not models.get(ressource):
raise Core400Exception("Ressource '{}' doesn't exist.".format(ressource))
return ressource
Test if ressource is hookable before write/update# -*- coding: utf-8 -*-
##############################################################################
#
# Copyright (C) 2014-2015 Anthony Minotti <anthony@minotti.cool>.
#
#
# This file is part of Yameo framework.
#
# Yameo framework is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
# Yameo framework is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with Yameo framework. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
from app.context import models
from lib.exceptions import *
def ressourceConstraints(self, value):
ressource = value.lower().capitalize()
if not models.get(ressource):
raise Core400Exception("Ressource '{}' doesn't exist.".format(ressource))
return ressource
def write(self):
# Test if ressource is hookable before performing normal process
if models.get(self.ressource)._hookable:
super(self.__class__, self).write()
else:
raise Core400Exception("Ressource '{}' is not hookable.".format(self.ressource))
def update(self, data2save, domain):
# Test if ressource is hookable before performing normal process
if models.get(self.ressource)._hookable:
super(self.__class__, self).update(data2save, domain)
else:
raise Core400Exception("Ressource '{}' is not hookable.".format(self.ressource))
|
<commit_before># -*- coding: utf-8 -*-
##############################################################################
#
# Copyright (C) 2014-2015 Anthony Minotti <anthony@minotti.cool>.
#
#
# This file is part of Yameo framework.
#
# Yameo framework is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
# Yameo framework is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with Yameo framework. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
from app.context import models
from lib.exceptions import *
def ressourceConstraints(self, value):
ressource = value.lower().capitalize()
if not models.get(ressource):
raise Core400Exception("Ressource '{}' doesn't exist.".format(ressource))
return ressource
<commit_msg>Test if ressource is hookable before write/update<commit_after># -*- coding: utf-8 -*-
##############################################################################
#
# Copyright (C) 2014-2015 Anthony Minotti <anthony@minotti.cool>.
#
#
# This file is part of Yameo framework.
#
# Yameo framework is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
# Yameo framework is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with Yameo framework. If not, see <http://www.gnu.org/licenses/>.
#
##############################################################################
from app.context import models
from lib.exceptions import *
def ressourceConstraints(self, value):
ressource = value.lower().capitalize()
if not models.get(ressource):
raise Core400Exception("Ressource '{}' doesn't exist.".format(ressource))
return ressource
def write(self):
# Test if ressource is hookable before performing normal process
if models.get(self.ressource)._hookable:
super(self.__class__, self).write()
else:
raise Core400Exception("Ressource '{}' is not hookable.".format(self.ressource))
def update(self, data2save, domain):
# Test if ressource is hookable before performing normal process
if models.get(self.ressource)._hookable:
super(self.__class__, self).update(data2save, domain)
else:
raise Core400Exception("Ressource '{}' is not hookable.".format(self.ressource))
|
7dfff7af5c76ab920cf07cb79e5b8c068be33328
|
ingestors/worker.py
|
ingestors/worker.py
|
import logging
from followthemoney import model
from servicelayer.worker import Worker
from ingestors.manager import Manager
log = logging.getLogger(__name__)
class IngestWorker(Worker):
"""A long running task runner that uses Redis as a task queue"""
def dispatch_next(self, task, entities):
next_stage = task.context.get('next_stage')
if next_stage is None:
return
stage = task.job.get_stage(next_stage)
log.info("Sending %s entities to: %s", len(entities), next_stage)
for entity_id in entities:
stage.queue({'entity_id': entity_id}, task.context)
def handle(self, task):
manager = Manager(task.stage, task.context)
entity = model.get_proxy(task.payload)
log.debug("Ingest: %r", entity)
manager.ingest_entity(entity)
manager.close()
self.dispatch_next(task, manager.emitted)
|
import logging
from followthemoney import model
from servicelayer.worker import Worker
from ingestors.manager import Manager
log = logging.getLogger(__name__)
class IngestWorker(Worker):
"""A long running task runner that uses Redis as a task queue"""
def dispatch_next(self, task, entities):
next_stage = task.context.get('next_stage')
if next_stage is None:
return
stage = task.job.get_stage(next_stage)
log.info("Sending %s entities to: %s", len(entities), next_stage)
stage.queue({'entity_ids': entities}, task.context)
def handle(self, task):
manager = Manager(task.stage, task.context)
entity = model.get_proxy(task.payload)
log.debug("Ingest: %r", entity)
manager.ingest_entity(entity)
manager.close()
self.dispatch_next(task, manager.emitted)
|
Fix entity index aggregator argument error
|
Fix entity index aggregator argument error
|
Python
|
mit
|
alephdata/ingestors
|
import logging
from followthemoney import model
from servicelayer.worker import Worker
from ingestors.manager import Manager
log = logging.getLogger(__name__)
class IngestWorker(Worker):
"""A long running task runner that uses Redis as a task queue"""
def dispatch_next(self, task, entities):
next_stage = task.context.get('next_stage')
if next_stage is None:
return
stage = task.job.get_stage(next_stage)
log.info("Sending %s entities to: %s", len(entities), next_stage)
for entity_id in entities:
stage.queue({'entity_id': entity_id}, task.context)
def handle(self, task):
manager = Manager(task.stage, task.context)
entity = model.get_proxy(task.payload)
log.debug("Ingest: %r", entity)
manager.ingest_entity(entity)
manager.close()
self.dispatch_next(task, manager.emitted)
Fix entity index aggregator argument error
|
import logging
from followthemoney import model
from servicelayer.worker import Worker
from ingestors.manager import Manager
log = logging.getLogger(__name__)
class IngestWorker(Worker):
"""A long running task runner that uses Redis as a task queue"""
def dispatch_next(self, task, entities):
next_stage = task.context.get('next_stage')
if next_stage is None:
return
stage = task.job.get_stage(next_stage)
log.info("Sending %s entities to: %s", len(entities), next_stage)
stage.queue({'entity_ids': entities}, task.context)
def handle(self, task):
manager = Manager(task.stage, task.context)
entity = model.get_proxy(task.payload)
log.debug("Ingest: %r", entity)
manager.ingest_entity(entity)
manager.close()
self.dispatch_next(task, manager.emitted)
|
<commit_before>import logging
from followthemoney import model
from servicelayer.worker import Worker
from ingestors.manager import Manager
log = logging.getLogger(__name__)
class IngestWorker(Worker):
"""A long running task runner that uses Redis as a task queue"""
def dispatch_next(self, task, entities):
next_stage = task.context.get('next_stage')
if next_stage is None:
return
stage = task.job.get_stage(next_stage)
log.info("Sending %s entities to: %s", len(entities), next_stage)
for entity_id in entities:
stage.queue({'entity_id': entity_id}, task.context)
def handle(self, task):
manager = Manager(task.stage, task.context)
entity = model.get_proxy(task.payload)
log.debug("Ingest: %r", entity)
manager.ingest_entity(entity)
manager.close()
self.dispatch_next(task, manager.emitted)
<commit_msg>Fix entity index aggregator argument error<commit_after>
|
import logging
from followthemoney import model
from servicelayer.worker import Worker
from ingestors.manager import Manager
log = logging.getLogger(__name__)
class IngestWorker(Worker):
"""A long running task runner that uses Redis as a task queue"""
def dispatch_next(self, task, entities):
next_stage = task.context.get('next_stage')
if next_stage is None:
return
stage = task.job.get_stage(next_stage)
log.info("Sending %s entities to: %s", len(entities), next_stage)
stage.queue({'entity_ids': entities}, task.context)
def handle(self, task):
manager = Manager(task.stage, task.context)
entity = model.get_proxy(task.payload)
log.debug("Ingest: %r", entity)
manager.ingest_entity(entity)
manager.close()
self.dispatch_next(task, manager.emitted)
|
import logging
from followthemoney import model
from servicelayer.worker import Worker
from ingestors.manager import Manager
log = logging.getLogger(__name__)
class IngestWorker(Worker):
"""A long running task runner that uses Redis as a task queue"""
def dispatch_next(self, task, entities):
next_stage = task.context.get('next_stage')
if next_stage is None:
return
stage = task.job.get_stage(next_stage)
log.info("Sending %s entities to: %s", len(entities), next_stage)
for entity_id in entities:
stage.queue({'entity_id': entity_id}, task.context)
def handle(self, task):
manager = Manager(task.stage, task.context)
entity = model.get_proxy(task.payload)
log.debug("Ingest: %r", entity)
manager.ingest_entity(entity)
manager.close()
self.dispatch_next(task, manager.emitted)
Fix entity index aggregator argument errorimport logging
from followthemoney import model
from servicelayer.worker import Worker
from ingestors.manager import Manager
log = logging.getLogger(__name__)
class IngestWorker(Worker):
"""A long running task runner that uses Redis as a task queue"""
def dispatch_next(self, task, entities):
next_stage = task.context.get('next_stage')
if next_stage is None:
return
stage = task.job.get_stage(next_stage)
log.info("Sending %s entities to: %s", len(entities), next_stage)
stage.queue({'entity_ids': entities}, task.context)
def handle(self, task):
manager = Manager(task.stage, task.context)
entity = model.get_proxy(task.payload)
log.debug("Ingest: %r", entity)
manager.ingest_entity(entity)
manager.close()
self.dispatch_next(task, manager.emitted)
|
<commit_before>import logging
from followthemoney import model
from servicelayer.worker import Worker
from ingestors.manager import Manager
log = logging.getLogger(__name__)
class IngestWorker(Worker):
"""A long running task runner that uses Redis as a task queue"""
def dispatch_next(self, task, entities):
next_stage = task.context.get('next_stage')
if next_stage is None:
return
stage = task.job.get_stage(next_stage)
log.info("Sending %s entities to: %s", len(entities), next_stage)
for entity_id in entities:
stage.queue({'entity_id': entity_id}, task.context)
def handle(self, task):
manager = Manager(task.stage, task.context)
entity = model.get_proxy(task.payload)
log.debug("Ingest: %r", entity)
manager.ingest_entity(entity)
manager.close()
self.dispatch_next(task, manager.emitted)
<commit_msg>Fix entity index aggregator argument error<commit_after>import logging
from followthemoney import model
from servicelayer.worker import Worker
from ingestors.manager import Manager
log = logging.getLogger(__name__)
class IngestWorker(Worker):
"""A long running task runner that uses Redis as a task queue"""
def dispatch_next(self, task, entities):
next_stage = task.context.get('next_stage')
if next_stage is None:
return
stage = task.job.get_stage(next_stage)
log.info("Sending %s entities to: %s", len(entities), next_stage)
stage.queue({'entity_ids': entities}, task.context)
def handle(self, task):
manager = Manager(task.stage, task.context)
entity = model.get_proxy(task.payload)
log.debug("Ingest: %r", entity)
manager.ingest_entity(entity)
manager.close()
self.dispatch_next(task, manager.emitted)
|
879a9034b134b542d5e5eed69929b68cb6471390
|
statdyn/analysis/run_analysis.py
|
statdyn/analysis/run_analysis.py
|
#! /usr/bin/env python
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
#
# Copyright © 2017 Malcolm Ramsay <malramsay64@gmail.com>
#
# Distributed under terms of the MIT license.
"""Run an analysis on a trajectory."""
import click
import gsd.hoomd
import numpy as np
from ..sdrun import options
from .order import orientational_order
@click.command()
@options.arg_infile
@options.arg_outfile
def order(infile, outfile):
"""Compute the orientational order for each frame of a trajectory."""
trajectory = gsd.hoomd.open(infile, 'rb')
with open(outfile, 'w') as dst:
print('Timestep, OrientOrder', file=dst)
for snapshot in trajectory:
order = orientational_order(snapshot)
print(f'{snapshot.configuration.step}, {np.sum(order > 0.9) / len(order)}',
file=dst)
|
#! /usr/bin/env python
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
#
# Copyright © 2017 Malcolm Ramsay <malramsay64@gmail.com>
#
# Distributed under terms of the MIT license.
"""Run an analysis on a trajectory."""
import logging
import click
import gsd.hoomd
import numpy as np
from ..sdrun import options
from .order import orientational_order
logger = logging.getLogger(__name__)
logger.setLevel(logging.DEBUG)
@click.command()
@options.arg_infile
@options.arg_outfile
def order(infile, outfile):
"""Compute the orientational order for each frame of a trajectory."""
trajectory = gsd.hoomd.open(infile, 'rb')
with open(outfile, 'w') as dst:
print('Timestep, OrientOrder', file=dst)
for index in range(len(trajectory)):
try:
snapshot = trajectory[index]
except RuntimeError:
logger.info(f'Frame {index} corrupted, continuing...')
continue
order = orientational_order(snapshot)
print(f'{snapshot.configuration.step}, {np.sum(order > 0.9) / len(order)}',
file=dst)
|
Add error handling for corrupted trajectory frames
|
Add error handling for corrupted trajectory frames
When the analysis came across corrupted frames from a trajectory the
analysis stopped. Rather than stopping this should just continue past
the corrupted frames.
|
Python
|
mit
|
malramsay64/MD-Molecules-Hoomd,malramsay64/MD-Molecules-Hoomd
|
#! /usr/bin/env python
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
#
# Copyright © 2017 Malcolm Ramsay <malramsay64@gmail.com>
#
# Distributed under terms of the MIT license.
"""Run an analysis on a trajectory."""
import click
import gsd.hoomd
import numpy as np
from ..sdrun import options
from .order import orientational_order
@click.command()
@options.arg_infile
@options.arg_outfile
def order(infile, outfile):
"""Compute the orientational order for each frame of a trajectory."""
trajectory = gsd.hoomd.open(infile, 'rb')
with open(outfile, 'w') as dst:
print('Timestep, OrientOrder', file=dst)
for snapshot in trajectory:
order = orientational_order(snapshot)
print(f'{snapshot.configuration.step}, {np.sum(order > 0.9) / len(order)}',
file=dst)
Add error handling for corrupted trajectory frames
When the analysis came across corrupted frames from a trajectory the
analysis stopped. Rather than stopping this should just continue past
the corrupted frames.
|
#! /usr/bin/env python
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
#
# Copyright © 2017 Malcolm Ramsay <malramsay64@gmail.com>
#
# Distributed under terms of the MIT license.
"""Run an analysis on a trajectory."""
import logging
import click
import gsd.hoomd
import numpy as np
from ..sdrun import options
from .order import orientational_order
logger = logging.getLogger(__name__)
logger.setLevel(logging.DEBUG)
@click.command()
@options.arg_infile
@options.arg_outfile
def order(infile, outfile):
"""Compute the orientational order for each frame of a trajectory."""
trajectory = gsd.hoomd.open(infile, 'rb')
with open(outfile, 'w') as dst:
print('Timestep, OrientOrder', file=dst)
for index in range(len(trajectory)):
try:
snapshot = trajectory[index]
except RuntimeError:
logger.info(f'Frame {index} corrupted, continuing...')
continue
order = orientational_order(snapshot)
print(f'{snapshot.configuration.step}, {np.sum(order > 0.9) / len(order)}',
file=dst)
|
<commit_before>#! /usr/bin/env python
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
#
# Copyright © 2017 Malcolm Ramsay <malramsay64@gmail.com>
#
# Distributed under terms of the MIT license.
"""Run an analysis on a trajectory."""
import click
import gsd.hoomd
import numpy as np
from ..sdrun import options
from .order import orientational_order
@click.command()
@options.arg_infile
@options.arg_outfile
def order(infile, outfile):
"""Compute the orientational order for each frame of a trajectory."""
trajectory = gsd.hoomd.open(infile, 'rb')
with open(outfile, 'w') as dst:
print('Timestep, OrientOrder', file=dst)
for snapshot in trajectory:
order = orientational_order(snapshot)
print(f'{snapshot.configuration.step}, {np.sum(order > 0.9) / len(order)}',
file=dst)
<commit_msg>Add error handling for corrupted trajectory frames
When the analysis came across corrupted frames from a trajectory the
analysis stopped. Rather than stopping this should just continue past
the corrupted frames.<commit_after>
|
#! /usr/bin/env python
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
#
# Copyright © 2017 Malcolm Ramsay <malramsay64@gmail.com>
#
# Distributed under terms of the MIT license.
"""Run an analysis on a trajectory."""
import logging
import click
import gsd.hoomd
import numpy as np
from ..sdrun import options
from .order import orientational_order
logger = logging.getLogger(__name__)
logger.setLevel(logging.DEBUG)
@click.command()
@options.arg_infile
@options.arg_outfile
def order(infile, outfile):
"""Compute the orientational order for each frame of a trajectory."""
trajectory = gsd.hoomd.open(infile, 'rb')
with open(outfile, 'w') as dst:
print('Timestep, OrientOrder', file=dst)
for index in range(len(trajectory)):
try:
snapshot = trajectory[index]
except RuntimeError:
logger.info(f'Frame {index} corrupted, continuing...')
continue
order = orientational_order(snapshot)
print(f'{snapshot.configuration.step}, {np.sum(order > 0.9) / len(order)}',
file=dst)
|
#! /usr/bin/env python
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
#
# Copyright © 2017 Malcolm Ramsay <malramsay64@gmail.com>
#
# Distributed under terms of the MIT license.
"""Run an analysis on a trajectory."""
import click
import gsd.hoomd
import numpy as np
from ..sdrun import options
from .order import orientational_order
@click.command()
@options.arg_infile
@options.arg_outfile
def order(infile, outfile):
"""Compute the orientational order for each frame of a trajectory."""
trajectory = gsd.hoomd.open(infile, 'rb')
with open(outfile, 'w') as dst:
print('Timestep, OrientOrder', file=dst)
for snapshot in trajectory:
order = orientational_order(snapshot)
print(f'{snapshot.configuration.step}, {np.sum(order > 0.9) / len(order)}',
file=dst)
Add error handling for corrupted trajectory frames
When the analysis came across corrupted frames from a trajectory the
analysis stopped. Rather than stopping this should just continue past
the corrupted frames.#! /usr/bin/env python
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
#
# Copyright © 2017 Malcolm Ramsay <malramsay64@gmail.com>
#
# Distributed under terms of the MIT license.
"""Run an analysis on a trajectory."""
import logging
import click
import gsd.hoomd
import numpy as np
from ..sdrun import options
from .order import orientational_order
logger = logging.getLogger(__name__)
logger.setLevel(logging.DEBUG)
@click.command()
@options.arg_infile
@options.arg_outfile
def order(infile, outfile):
"""Compute the orientational order for each frame of a trajectory."""
trajectory = gsd.hoomd.open(infile, 'rb')
with open(outfile, 'w') as dst:
print('Timestep, OrientOrder', file=dst)
for index in range(len(trajectory)):
try:
snapshot = trajectory[index]
except RuntimeError:
logger.info(f'Frame {index} corrupted, continuing...')
continue
order = orientational_order(snapshot)
print(f'{snapshot.configuration.step}, {np.sum(order > 0.9) / len(order)}',
file=dst)
|
<commit_before>#! /usr/bin/env python
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
#
# Copyright © 2017 Malcolm Ramsay <malramsay64@gmail.com>
#
# Distributed under terms of the MIT license.
"""Run an analysis on a trajectory."""
import click
import gsd.hoomd
import numpy as np
from ..sdrun import options
from .order import orientational_order
@click.command()
@options.arg_infile
@options.arg_outfile
def order(infile, outfile):
"""Compute the orientational order for each frame of a trajectory."""
trajectory = gsd.hoomd.open(infile, 'rb')
with open(outfile, 'w') as dst:
print('Timestep, OrientOrder', file=dst)
for snapshot in trajectory:
order = orientational_order(snapshot)
print(f'{snapshot.configuration.step}, {np.sum(order > 0.9) / len(order)}',
file=dst)
<commit_msg>Add error handling for corrupted trajectory frames
When the analysis came across corrupted frames from a trajectory the
analysis stopped. Rather than stopping this should just continue past
the corrupted frames.<commit_after>#! /usr/bin/env python
# -*- coding: utf-8 -*-
# vim:fenc=utf-8
#
# Copyright © 2017 Malcolm Ramsay <malramsay64@gmail.com>
#
# Distributed under terms of the MIT license.
"""Run an analysis on a trajectory."""
import logging
import click
import gsd.hoomd
import numpy as np
from ..sdrun import options
from .order import orientational_order
logger = logging.getLogger(__name__)
logger.setLevel(logging.DEBUG)
@click.command()
@options.arg_infile
@options.arg_outfile
def order(infile, outfile):
"""Compute the orientational order for each frame of a trajectory."""
trajectory = gsd.hoomd.open(infile, 'rb')
with open(outfile, 'w') as dst:
print('Timestep, OrientOrder', file=dst)
for index in range(len(trajectory)):
try:
snapshot = trajectory[index]
except RuntimeError:
logger.info(f'Frame {index} corrupted, continuing...')
continue
order = orientational_order(snapshot)
print(f'{snapshot.configuration.step}, {np.sum(order > 0.9) / len(order)}',
file=dst)
|
5bbd106aa49f13550ee93c173f7f8684e4fa1d4b
|
biothings/tests/test_query.py
|
biothings/tests/test_query.py
|
'''
Biothings Query Component Common Tests
'''
import os
from nose.core import main
from biothings.tests import BiothingsTestCase
class QueryTests(BiothingsTestCase):
''' Test against server specified in environment variable BT_HOST
and BT_API or MyGene.info production server V3 by default '''
__test__ = True
host = os.getenv("BT_HOST", "http://mygene.info")
api = os.getenv("BT_API", "/v3")
def test_01(self):
''' KWARGS CTRL Format Json '''
self.query(q='*', size='1')
def test_02(self):
''' KWARGS CTRL Format Yaml '''
res = self.request('query?q=*&size=1&out_format=yaml').text
assert res.startswith('max_score:')
def test_03(self):
''' KWARGS CTRL Format Html '''
res = self.request('query?q=*&size=1&out_format=html').text
assert '<html>' in res
def test_04(self):
''' KWARGS CTRL Format Msgpack '''
res = self.request('query?q=*&size=1&out_format=msgpack').content
self.msgpack_ok(res)
if __name__ == '__main__':
main(defaultTest='__main__.QueryTests', argv=['', '-v'])
|
'''
Biothings Query Component Common Tests
'''
import os
from nose.core import main
from biothings.tests import BiothingsTestCase
class QueryTests(BiothingsTestCase):
''' Test against server specified in environment variable BT_HOST
and BT_API or MyGene.info production server V3 by default '''
__test__ = True
host = os.getenv("BT_HOST", "http://mygene.info")
api = os.getenv("BT_API", "/v3")
def test_01(self):
''' KWARGS CTRL Format Json '''
self.query(q='__all__', size='1')
def test_02(self):
''' KWARGS CTRL Format Yaml '''
res = self.request('query?q=__all__&size=1&format=yaml').text
assert res.startswith('max_score:')
def test_03(self):
''' KWARGS CTRL Format Html '''
res = self.request('query?q=__all__&size=1&format=html').text
assert '<html>' in res
def test_04(self):
''' KWARGS CTRL Format Msgpack '''
res = self.request('query?q=__all__&size=1&format=msgpack').content
self.msgpack_ok(res)
if __name__ == '__main__':
main(defaultTest='__main__.QueryTests', argv=['', '-v'])
|
Change match all query syntax
|
Change match all query syntax
|
Python
|
apache-2.0
|
biothings/biothings.api,biothings/biothings.api
|
'''
Biothings Query Component Common Tests
'''
import os
from nose.core import main
from biothings.tests import BiothingsTestCase
class QueryTests(BiothingsTestCase):
''' Test against server specified in environment variable BT_HOST
and BT_API or MyGene.info production server V3 by default '''
__test__ = True
host = os.getenv("BT_HOST", "http://mygene.info")
api = os.getenv("BT_API", "/v3")
def test_01(self):
''' KWARGS CTRL Format Json '''
self.query(q='*', size='1')
def test_02(self):
''' KWARGS CTRL Format Yaml '''
res = self.request('query?q=*&size=1&out_format=yaml').text
assert res.startswith('max_score:')
def test_03(self):
''' KWARGS CTRL Format Html '''
res = self.request('query?q=*&size=1&out_format=html').text
assert '<html>' in res
def test_04(self):
''' KWARGS CTRL Format Msgpack '''
res = self.request('query?q=*&size=1&out_format=msgpack').content
self.msgpack_ok(res)
if __name__ == '__main__':
main(defaultTest='__main__.QueryTests', argv=['', '-v'])
Change match all query syntax
|
'''
Biothings Query Component Common Tests
'''
import os
from nose.core import main
from biothings.tests import BiothingsTestCase
class QueryTests(BiothingsTestCase):
''' Test against server specified in environment variable BT_HOST
and BT_API or MyGene.info production server V3 by default '''
__test__ = True
host = os.getenv("BT_HOST", "http://mygene.info")
api = os.getenv("BT_API", "/v3")
def test_01(self):
''' KWARGS CTRL Format Json '''
self.query(q='__all__', size='1')
def test_02(self):
''' KWARGS CTRL Format Yaml '''
res = self.request('query?q=__all__&size=1&format=yaml').text
assert res.startswith('max_score:')
def test_03(self):
''' KWARGS CTRL Format Html '''
res = self.request('query?q=__all__&size=1&format=html').text
assert '<html>' in res
def test_04(self):
''' KWARGS CTRL Format Msgpack '''
res = self.request('query?q=__all__&size=1&format=msgpack').content
self.msgpack_ok(res)
if __name__ == '__main__':
main(defaultTest='__main__.QueryTests', argv=['', '-v'])
|
<commit_before>'''
Biothings Query Component Common Tests
'''
import os
from nose.core import main
from biothings.tests import BiothingsTestCase
class QueryTests(BiothingsTestCase):
''' Test against server specified in environment variable BT_HOST
and BT_API or MyGene.info production server V3 by default '''
__test__ = True
host = os.getenv("BT_HOST", "http://mygene.info")
api = os.getenv("BT_API", "/v3")
def test_01(self):
''' KWARGS CTRL Format Json '''
self.query(q='*', size='1')
def test_02(self):
''' KWARGS CTRL Format Yaml '''
res = self.request('query?q=*&size=1&out_format=yaml').text
assert res.startswith('max_score:')
def test_03(self):
''' KWARGS CTRL Format Html '''
res = self.request('query?q=*&size=1&out_format=html').text
assert '<html>' in res
def test_04(self):
''' KWARGS CTRL Format Msgpack '''
res = self.request('query?q=*&size=1&out_format=msgpack').content
self.msgpack_ok(res)
if __name__ == '__main__':
main(defaultTest='__main__.QueryTests', argv=['', '-v'])
<commit_msg>Change match all query syntax<commit_after>
|
'''
Biothings Query Component Common Tests
'''
import os
from nose.core import main
from biothings.tests import BiothingsTestCase
class QueryTests(BiothingsTestCase):
''' Test against server specified in environment variable BT_HOST
and BT_API or MyGene.info production server V3 by default '''
__test__ = True
host = os.getenv("BT_HOST", "http://mygene.info")
api = os.getenv("BT_API", "/v3")
def test_01(self):
''' KWARGS CTRL Format Json '''
self.query(q='__all__', size='1')
def test_02(self):
''' KWARGS CTRL Format Yaml '''
res = self.request('query?q=__all__&size=1&format=yaml').text
assert res.startswith('max_score:')
def test_03(self):
''' KWARGS CTRL Format Html '''
res = self.request('query?q=__all__&size=1&format=html').text
assert '<html>' in res
def test_04(self):
''' KWARGS CTRL Format Msgpack '''
res = self.request('query?q=__all__&size=1&format=msgpack').content
self.msgpack_ok(res)
if __name__ == '__main__':
main(defaultTest='__main__.QueryTests', argv=['', '-v'])
|
'''
Biothings Query Component Common Tests
'''
import os
from nose.core import main
from biothings.tests import BiothingsTestCase
class QueryTests(BiothingsTestCase):
''' Test against server specified in environment variable BT_HOST
and BT_API or MyGene.info production server V3 by default '''
__test__ = True
host = os.getenv("BT_HOST", "http://mygene.info")
api = os.getenv("BT_API", "/v3")
def test_01(self):
''' KWARGS CTRL Format Json '''
self.query(q='*', size='1')
def test_02(self):
''' KWARGS CTRL Format Yaml '''
res = self.request('query?q=*&size=1&out_format=yaml').text
assert res.startswith('max_score:')
def test_03(self):
''' KWARGS CTRL Format Html '''
res = self.request('query?q=*&size=1&out_format=html').text
assert '<html>' in res
def test_04(self):
''' KWARGS CTRL Format Msgpack '''
res = self.request('query?q=*&size=1&out_format=msgpack').content
self.msgpack_ok(res)
if __name__ == '__main__':
main(defaultTest='__main__.QueryTests', argv=['', '-v'])
Change match all query syntax'''
Biothings Query Component Common Tests
'''
import os
from nose.core import main
from biothings.tests import BiothingsTestCase
class QueryTests(BiothingsTestCase):
''' Test against server specified in environment variable BT_HOST
and BT_API or MyGene.info production server V3 by default '''
__test__ = True
host = os.getenv("BT_HOST", "http://mygene.info")
api = os.getenv("BT_API", "/v3")
def test_01(self):
''' KWARGS CTRL Format Json '''
self.query(q='__all__', size='1')
def test_02(self):
''' KWARGS CTRL Format Yaml '''
res = self.request('query?q=__all__&size=1&format=yaml').text
assert res.startswith('max_score:')
def test_03(self):
''' KWARGS CTRL Format Html '''
res = self.request('query?q=__all__&size=1&format=html').text
assert '<html>' in res
def test_04(self):
''' KWARGS CTRL Format Msgpack '''
res = self.request('query?q=__all__&size=1&format=msgpack').content
self.msgpack_ok(res)
if __name__ == '__main__':
main(defaultTest='__main__.QueryTests', argv=['', '-v'])
|
<commit_before>'''
Biothings Query Component Common Tests
'''
import os
from nose.core import main
from biothings.tests import BiothingsTestCase
class QueryTests(BiothingsTestCase):
''' Test against server specified in environment variable BT_HOST
and BT_API or MyGene.info production server V3 by default '''
__test__ = True
host = os.getenv("BT_HOST", "http://mygene.info")
api = os.getenv("BT_API", "/v3")
def test_01(self):
''' KWARGS CTRL Format Json '''
self.query(q='*', size='1')
def test_02(self):
''' KWARGS CTRL Format Yaml '''
res = self.request('query?q=*&size=1&out_format=yaml').text
assert res.startswith('max_score:')
def test_03(self):
''' KWARGS CTRL Format Html '''
res = self.request('query?q=*&size=1&out_format=html').text
assert '<html>' in res
def test_04(self):
''' KWARGS CTRL Format Msgpack '''
res = self.request('query?q=*&size=1&out_format=msgpack').content
self.msgpack_ok(res)
if __name__ == '__main__':
main(defaultTest='__main__.QueryTests', argv=['', '-v'])
<commit_msg>Change match all query syntax<commit_after>'''
Biothings Query Component Common Tests
'''
import os
from nose.core import main
from biothings.tests import BiothingsTestCase
class QueryTests(BiothingsTestCase):
''' Test against server specified in environment variable BT_HOST
and BT_API or MyGene.info production server V3 by default '''
__test__ = True
host = os.getenv("BT_HOST", "http://mygene.info")
api = os.getenv("BT_API", "/v3")
def test_01(self):
''' KWARGS CTRL Format Json '''
self.query(q='__all__', size='1')
def test_02(self):
''' KWARGS CTRL Format Yaml '''
res = self.request('query?q=__all__&size=1&format=yaml').text
assert res.startswith('max_score:')
def test_03(self):
''' KWARGS CTRL Format Html '''
res = self.request('query?q=__all__&size=1&format=html').text
assert '<html>' in res
def test_04(self):
''' KWARGS CTRL Format Msgpack '''
res = self.request('query?q=__all__&size=1&format=msgpack').content
self.msgpack_ok(res)
if __name__ == '__main__':
main(defaultTest='__main__.QueryTests', argv=['', '-v'])
|
6cc4eef05c8d92ee4af2d0e40566379f5eba1e19
|
untappd/distinct_per_venue.py
|
untappd/distinct_per_venue.py
|
import user
VENUE = 257163
def GetUserCheckins(user_obj, limit=50, max_id=None):
request = {'limit': limit}
if max_id is not None:
request['max_id'] = max_id
return user_obj.GetUserCheckins(request)
def IsPonyCheckin(checkin):
if 'venue' not in checkin:
return False
return checkin['venue'].get('venue_name') == 'The Pony Bar'
lush = user.User(user_name='adampsyche')
pony_checkins = []
checkins = GetUserCheckins(lush)
while True:
if not checkins:
break
pony_checkins.extend(filter(IsPonyCheckin, checkins))
marker_checkin = checkins[-1].get('checkin_id')
checkins = GetUserCheckins(lush, max_id=marker_checkin)
pony_uniques = set()
pony_uniques.update([c['beer']['beer_name'] for c in pony_checkins)
|
import user
VENUE = 257163
def GetUserCheckins(user_obj, limit=50, max_id=None):
request = {'limit': limit}
if max_id is not None:
request['max_id'] = max_id
return user_obj.GetUserCheckins(request)
def IsPonyCheckin(checkin):
if 'venue' not in checkin:
return False
return checkin['venue'].get('venue_name') == 'The Pony Bar'
lush = user.User(user_name='adampsyche')
pony_checkins = []
checkins = GetUserCheckins(lush)
while True:
if not checkins:
break
pony_checkins.extend(filter(IsPonyCheckin, checkins))
marker_checkin = checkins[-1].get('checkin_id')
checkins = GetUserCheckins(lush, max_id=marker_checkin)
pony_uniques = set()
pony_uniques.update([c['beer']['beer_name'] for c in pony_checkins])
|
Add missing brace to comprehension
|
Add missing brace to comprehension
|
Python
|
mit
|
adamomfg/pytappd
|
import user
VENUE = 257163
def GetUserCheckins(user_obj, limit=50, max_id=None):
request = {'limit': limit}
if max_id is not None:
request['max_id'] = max_id
return user_obj.GetUserCheckins(request)
def IsPonyCheckin(checkin):
if 'venue' not in checkin:
return False
return checkin['venue'].get('venue_name') == 'The Pony Bar'
lush = user.User(user_name='adampsyche')
pony_checkins = []
checkins = GetUserCheckins(lush)
while True:
if not checkins:
break
pony_checkins.extend(filter(IsPonyCheckin, checkins))
marker_checkin = checkins[-1].get('checkin_id')
checkins = GetUserCheckins(lush, max_id=marker_checkin)
pony_uniques = set()
pony_uniques.update([c['beer']['beer_name'] for c in pony_checkins)
Add missing brace to comprehension
|
import user
VENUE = 257163
def GetUserCheckins(user_obj, limit=50, max_id=None):
request = {'limit': limit}
if max_id is not None:
request['max_id'] = max_id
return user_obj.GetUserCheckins(request)
def IsPonyCheckin(checkin):
if 'venue' not in checkin:
return False
return checkin['venue'].get('venue_name') == 'The Pony Bar'
lush = user.User(user_name='adampsyche')
pony_checkins = []
checkins = GetUserCheckins(lush)
while True:
if not checkins:
break
pony_checkins.extend(filter(IsPonyCheckin, checkins))
marker_checkin = checkins[-1].get('checkin_id')
checkins = GetUserCheckins(lush, max_id=marker_checkin)
pony_uniques = set()
pony_uniques.update([c['beer']['beer_name'] for c in pony_checkins])
|
<commit_before>import user
VENUE = 257163
def GetUserCheckins(user_obj, limit=50, max_id=None):
request = {'limit': limit}
if max_id is not None:
request['max_id'] = max_id
return user_obj.GetUserCheckins(request)
def IsPonyCheckin(checkin):
if 'venue' not in checkin:
return False
return checkin['venue'].get('venue_name') == 'The Pony Bar'
lush = user.User(user_name='adampsyche')
pony_checkins = []
checkins = GetUserCheckins(lush)
while True:
if not checkins:
break
pony_checkins.extend(filter(IsPonyCheckin, checkins))
marker_checkin = checkins[-1].get('checkin_id')
checkins = GetUserCheckins(lush, max_id=marker_checkin)
pony_uniques = set()
pony_uniques.update([c['beer']['beer_name'] for c in pony_checkins)
<commit_msg>Add missing brace to comprehension<commit_after>
|
import user
VENUE = 257163
def GetUserCheckins(user_obj, limit=50, max_id=None):
request = {'limit': limit}
if max_id is not None:
request['max_id'] = max_id
return user_obj.GetUserCheckins(request)
def IsPonyCheckin(checkin):
if 'venue' not in checkin:
return False
return checkin['venue'].get('venue_name') == 'The Pony Bar'
lush = user.User(user_name='adampsyche')
pony_checkins = []
checkins = GetUserCheckins(lush)
while True:
if not checkins:
break
pony_checkins.extend(filter(IsPonyCheckin, checkins))
marker_checkin = checkins[-1].get('checkin_id')
checkins = GetUserCheckins(lush, max_id=marker_checkin)
pony_uniques = set()
pony_uniques.update([c['beer']['beer_name'] for c in pony_checkins])
|
import user
VENUE = 257163
def GetUserCheckins(user_obj, limit=50, max_id=None):
request = {'limit': limit}
if max_id is not None:
request['max_id'] = max_id
return user_obj.GetUserCheckins(request)
def IsPonyCheckin(checkin):
if 'venue' not in checkin:
return False
return checkin['venue'].get('venue_name') == 'The Pony Bar'
lush = user.User(user_name='adampsyche')
pony_checkins = []
checkins = GetUserCheckins(lush)
while True:
if not checkins:
break
pony_checkins.extend(filter(IsPonyCheckin, checkins))
marker_checkin = checkins[-1].get('checkin_id')
checkins = GetUserCheckins(lush, max_id=marker_checkin)
pony_uniques = set()
pony_uniques.update([c['beer']['beer_name'] for c in pony_checkins)
Add missing brace to comprehensionimport user
VENUE = 257163
def GetUserCheckins(user_obj, limit=50, max_id=None):
request = {'limit': limit}
if max_id is not None:
request['max_id'] = max_id
return user_obj.GetUserCheckins(request)
def IsPonyCheckin(checkin):
if 'venue' not in checkin:
return False
return checkin['venue'].get('venue_name') == 'The Pony Bar'
lush = user.User(user_name='adampsyche')
pony_checkins = []
checkins = GetUserCheckins(lush)
while True:
if not checkins:
break
pony_checkins.extend(filter(IsPonyCheckin, checkins))
marker_checkin = checkins[-1].get('checkin_id')
checkins = GetUserCheckins(lush, max_id=marker_checkin)
pony_uniques = set()
pony_uniques.update([c['beer']['beer_name'] for c in pony_checkins])
|
<commit_before>import user
VENUE = 257163
def GetUserCheckins(user_obj, limit=50, max_id=None):
request = {'limit': limit}
if max_id is not None:
request['max_id'] = max_id
return user_obj.GetUserCheckins(request)
def IsPonyCheckin(checkin):
if 'venue' not in checkin:
return False
return checkin['venue'].get('venue_name') == 'The Pony Bar'
lush = user.User(user_name='adampsyche')
pony_checkins = []
checkins = GetUserCheckins(lush)
while True:
if not checkins:
break
pony_checkins.extend(filter(IsPonyCheckin, checkins))
marker_checkin = checkins[-1].get('checkin_id')
checkins = GetUserCheckins(lush, max_id=marker_checkin)
pony_uniques = set()
pony_uniques.update([c['beer']['beer_name'] for c in pony_checkins)
<commit_msg>Add missing brace to comprehension<commit_after>import user
VENUE = 257163
def GetUserCheckins(user_obj, limit=50, max_id=None):
request = {'limit': limit}
if max_id is not None:
request['max_id'] = max_id
return user_obj.GetUserCheckins(request)
def IsPonyCheckin(checkin):
if 'venue' not in checkin:
return False
return checkin['venue'].get('venue_name') == 'The Pony Bar'
lush = user.User(user_name='adampsyche')
pony_checkins = []
checkins = GetUserCheckins(lush)
while True:
if not checkins:
break
pony_checkins.extend(filter(IsPonyCheckin, checkins))
marker_checkin = checkins[-1].get('checkin_id')
checkins = GetUserCheckins(lush, max_id=marker_checkin)
pony_uniques = set()
pony_uniques.update([c['beer']['beer_name'] for c in pony_checkins])
|
c8918e5ee06c3f7ec84124ebfccddb738dca2bfb
|
test/python_api/default-constructor/sb_communication.py
|
test/python_api/default-constructor/sb_communication.py
|
"""
Fuzz tests an object after the default construction to make sure it does not crash lldb.
"""
import sys
import lldb
def fuzz_obj(obj):
broadcaster = obj.GetBroadcaster()
# Do fuzz testing on the broadcaster obj, it should not crash lldb.
import sb_broadcaster
sb_broadcaster.fuzz_obj(broadcaster)
obj.AdoptFileDesriptor(0, False)
obj.AdoptFileDesriptor(1, False)
obj.AdoptFileDesriptor(2, False)
obj.Connect("file:/tmp/myfile")
obj.Disconnect()
obj.IsConnected()
obj.GetCloseOnEOF()
obj.SetCloseOnEOF(True)
obj.SetCloseOnEOF(False)
#obj.Write(None, sys.maxint, None)
#obj.Read(None, sys.maxint, 0xffffffff, None)
obj.ReadThreadStart()
obj.ReadThreadStop()
obj.ReadThreadIsRunning()
obj.SetReadThreadBytesReceivedCallback(None, None)
|
"""
Fuzz tests an object after the default construction to make sure it does not crash lldb.
"""
import sys
import lldb
def fuzz_obj(obj):
broadcaster = obj.GetBroadcaster()
# Do fuzz testing on the broadcaster obj, it should not crash lldb.
import sb_broadcaster
sb_broadcaster.fuzz_obj(broadcaster)
obj.AdoptFileDesriptor(0, False)
obj.AdoptFileDesriptor(1, False)
obj.AdoptFileDesriptor(2, False)
obj.Connect("file:/tmp/myfile")
obj.Connect(None)
obj.Disconnect()
obj.IsConnected()
obj.GetCloseOnEOF()
obj.SetCloseOnEOF(True)
obj.SetCloseOnEOF(False)
#obj.Write(None, sys.maxint, None)
#obj.Read(None, sys.maxint, 0xffffffff, None)
obj.ReadThreadStart()
obj.ReadThreadStop()
obj.ReadThreadIsRunning()
obj.SetReadThreadBytesReceivedCallback(None, None)
|
Add a fuzz call for SBCommunication: obj.connect(None).
|
Add a fuzz call for SBCommunication: obj.connect(None).
git-svn-id: 4c4cc70b1ef44ba2b7963015e681894188cea27e@146912 91177308-0d34-0410-b5e6-96231b3b80d8
|
Python
|
apache-2.0
|
llvm-mirror/lldb,apple/swift-lldb,llvm-mirror/lldb,apple/swift-lldb,llvm-mirror/lldb,llvm-mirror/lldb,apple/swift-lldb,apple/swift-lldb,apple/swift-lldb,llvm-mirror/lldb,apple/swift-lldb
|
"""
Fuzz tests an object after the default construction to make sure it does not crash lldb.
"""
import sys
import lldb
def fuzz_obj(obj):
broadcaster = obj.GetBroadcaster()
# Do fuzz testing on the broadcaster obj, it should not crash lldb.
import sb_broadcaster
sb_broadcaster.fuzz_obj(broadcaster)
obj.AdoptFileDesriptor(0, False)
obj.AdoptFileDesriptor(1, False)
obj.AdoptFileDesriptor(2, False)
obj.Connect("file:/tmp/myfile")
obj.Disconnect()
obj.IsConnected()
obj.GetCloseOnEOF()
obj.SetCloseOnEOF(True)
obj.SetCloseOnEOF(False)
#obj.Write(None, sys.maxint, None)
#obj.Read(None, sys.maxint, 0xffffffff, None)
obj.ReadThreadStart()
obj.ReadThreadStop()
obj.ReadThreadIsRunning()
obj.SetReadThreadBytesReceivedCallback(None, None)
Add a fuzz call for SBCommunication: obj.connect(None).
git-svn-id: 4c4cc70b1ef44ba2b7963015e681894188cea27e@146912 91177308-0d34-0410-b5e6-96231b3b80d8
|
"""
Fuzz tests an object after the default construction to make sure it does not crash lldb.
"""
import sys
import lldb
def fuzz_obj(obj):
broadcaster = obj.GetBroadcaster()
# Do fuzz testing on the broadcaster obj, it should not crash lldb.
import sb_broadcaster
sb_broadcaster.fuzz_obj(broadcaster)
obj.AdoptFileDesriptor(0, False)
obj.AdoptFileDesriptor(1, False)
obj.AdoptFileDesriptor(2, False)
obj.Connect("file:/tmp/myfile")
obj.Connect(None)
obj.Disconnect()
obj.IsConnected()
obj.GetCloseOnEOF()
obj.SetCloseOnEOF(True)
obj.SetCloseOnEOF(False)
#obj.Write(None, sys.maxint, None)
#obj.Read(None, sys.maxint, 0xffffffff, None)
obj.ReadThreadStart()
obj.ReadThreadStop()
obj.ReadThreadIsRunning()
obj.SetReadThreadBytesReceivedCallback(None, None)
|
<commit_before>"""
Fuzz tests an object after the default construction to make sure it does not crash lldb.
"""
import sys
import lldb
def fuzz_obj(obj):
broadcaster = obj.GetBroadcaster()
# Do fuzz testing on the broadcaster obj, it should not crash lldb.
import sb_broadcaster
sb_broadcaster.fuzz_obj(broadcaster)
obj.AdoptFileDesriptor(0, False)
obj.AdoptFileDesriptor(1, False)
obj.AdoptFileDesriptor(2, False)
obj.Connect("file:/tmp/myfile")
obj.Disconnect()
obj.IsConnected()
obj.GetCloseOnEOF()
obj.SetCloseOnEOF(True)
obj.SetCloseOnEOF(False)
#obj.Write(None, sys.maxint, None)
#obj.Read(None, sys.maxint, 0xffffffff, None)
obj.ReadThreadStart()
obj.ReadThreadStop()
obj.ReadThreadIsRunning()
obj.SetReadThreadBytesReceivedCallback(None, None)
<commit_msg>Add a fuzz call for SBCommunication: obj.connect(None).
git-svn-id: 4c4cc70b1ef44ba2b7963015e681894188cea27e@146912 91177308-0d34-0410-b5e6-96231b3b80d8<commit_after>
|
"""
Fuzz tests an object after the default construction to make sure it does not crash lldb.
"""
import sys
import lldb
def fuzz_obj(obj):
broadcaster = obj.GetBroadcaster()
# Do fuzz testing on the broadcaster obj, it should not crash lldb.
import sb_broadcaster
sb_broadcaster.fuzz_obj(broadcaster)
obj.AdoptFileDesriptor(0, False)
obj.AdoptFileDesriptor(1, False)
obj.AdoptFileDesriptor(2, False)
obj.Connect("file:/tmp/myfile")
obj.Connect(None)
obj.Disconnect()
obj.IsConnected()
obj.GetCloseOnEOF()
obj.SetCloseOnEOF(True)
obj.SetCloseOnEOF(False)
#obj.Write(None, sys.maxint, None)
#obj.Read(None, sys.maxint, 0xffffffff, None)
obj.ReadThreadStart()
obj.ReadThreadStop()
obj.ReadThreadIsRunning()
obj.SetReadThreadBytesReceivedCallback(None, None)
|
"""
Fuzz tests an object after the default construction to make sure it does not crash lldb.
"""
import sys
import lldb
def fuzz_obj(obj):
broadcaster = obj.GetBroadcaster()
# Do fuzz testing on the broadcaster obj, it should not crash lldb.
import sb_broadcaster
sb_broadcaster.fuzz_obj(broadcaster)
obj.AdoptFileDesriptor(0, False)
obj.AdoptFileDesriptor(1, False)
obj.AdoptFileDesriptor(2, False)
obj.Connect("file:/tmp/myfile")
obj.Disconnect()
obj.IsConnected()
obj.GetCloseOnEOF()
obj.SetCloseOnEOF(True)
obj.SetCloseOnEOF(False)
#obj.Write(None, sys.maxint, None)
#obj.Read(None, sys.maxint, 0xffffffff, None)
obj.ReadThreadStart()
obj.ReadThreadStop()
obj.ReadThreadIsRunning()
obj.SetReadThreadBytesReceivedCallback(None, None)
Add a fuzz call for SBCommunication: obj.connect(None).
git-svn-id: 4c4cc70b1ef44ba2b7963015e681894188cea27e@146912 91177308-0d34-0410-b5e6-96231b3b80d8"""
Fuzz tests an object after the default construction to make sure it does not crash lldb.
"""
import sys
import lldb
def fuzz_obj(obj):
broadcaster = obj.GetBroadcaster()
# Do fuzz testing on the broadcaster obj, it should not crash lldb.
import sb_broadcaster
sb_broadcaster.fuzz_obj(broadcaster)
obj.AdoptFileDesriptor(0, False)
obj.AdoptFileDesriptor(1, False)
obj.AdoptFileDesriptor(2, False)
obj.Connect("file:/tmp/myfile")
obj.Connect(None)
obj.Disconnect()
obj.IsConnected()
obj.GetCloseOnEOF()
obj.SetCloseOnEOF(True)
obj.SetCloseOnEOF(False)
#obj.Write(None, sys.maxint, None)
#obj.Read(None, sys.maxint, 0xffffffff, None)
obj.ReadThreadStart()
obj.ReadThreadStop()
obj.ReadThreadIsRunning()
obj.SetReadThreadBytesReceivedCallback(None, None)
|
<commit_before>"""
Fuzz tests an object after the default construction to make sure it does not crash lldb.
"""
import sys
import lldb
def fuzz_obj(obj):
broadcaster = obj.GetBroadcaster()
# Do fuzz testing on the broadcaster obj, it should not crash lldb.
import sb_broadcaster
sb_broadcaster.fuzz_obj(broadcaster)
obj.AdoptFileDesriptor(0, False)
obj.AdoptFileDesriptor(1, False)
obj.AdoptFileDesriptor(2, False)
obj.Connect("file:/tmp/myfile")
obj.Disconnect()
obj.IsConnected()
obj.GetCloseOnEOF()
obj.SetCloseOnEOF(True)
obj.SetCloseOnEOF(False)
#obj.Write(None, sys.maxint, None)
#obj.Read(None, sys.maxint, 0xffffffff, None)
obj.ReadThreadStart()
obj.ReadThreadStop()
obj.ReadThreadIsRunning()
obj.SetReadThreadBytesReceivedCallback(None, None)
<commit_msg>Add a fuzz call for SBCommunication: obj.connect(None).
git-svn-id: 4c4cc70b1ef44ba2b7963015e681894188cea27e@146912 91177308-0d34-0410-b5e6-96231b3b80d8<commit_after>"""
Fuzz tests an object after the default construction to make sure it does not crash lldb.
"""
import sys
import lldb
def fuzz_obj(obj):
broadcaster = obj.GetBroadcaster()
# Do fuzz testing on the broadcaster obj, it should not crash lldb.
import sb_broadcaster
sb_broadcaster.fuzz_obj(broadcaster)
obj.AdoptFileDesriptor(0, False)
obj.AdoptFileDesriptor(1, False)
obj.AdoptFileDesriptor(2, False)
obj.Connect("file:/tmp/myfile")
obj.Connect(None)
obj.Disconnect()
obj.IsConnected()
obj.GetCloseOnEOF()
obj.SetCloseOnEOF(True)
obj.SetCloseOnEOF(False)
#obj.Write(None, sys.maxint, None)
#obj.Read(None, sys.maxint, 0xffffffff, None)
obj.ReadThreadStart()
obj.ReadThreadStop()
obj.ReadThreadIsRunning()
obj.SetReadThreadBytesReceivedCallback(None, None)
|
4b111c035f92f941cff4b6885d2fa01ddcb1657e
|
titanembeds/database/custom_redislite.py
|
titanembeds/database/custom_redislite.py
|
import urlparse
from limits.storage import Storage
from redislite import Redis
import time
class LimitsRedisLite(Storage): # For Python Limits
STORAGE_SCHEME = "redislite"
def __init__(self, uri, **options):
self.redis_instance = Redis(urlparse.urlparse(uri).netloc)
def check(self):
return True
def get_expiry(self, key):
return self.redis_instance.ttl(key)
def incr(self, key, expiry, elastic_expiry=False):
if not self.redis_instance.exists(key):
self.redis_instance.set(key, 1)
self.redis_instance.expireat(key, int(time.time() + expiry))
else:
oldexp = self.get_expiry(key)
self.redis_instance.set(key, int(self.redis_instance.get(key))+1)
self.redis_instance.expireat(key, int(time.time() + oldexp))
return
def get(self, key):
return int(self.redis_instance.get(key))
def reset(self):
return self.redis_instance.flushdb()
|
import urlparse
from limits.storage import Storage
from redislite import Redis
import time
class LimitsRedisLite(Storage): # For Python Limits
STORAGE_SCHEME = "redislite"
def __init__(self, uri, **options):
self.redis_instance = Redis(urlparse.urlparse(uri).netloc)
def check(self):
return True
def get_expiry(self, key):
return self.redis_instance.ttl(key) or 0
def incr(self, key, expiry, elastic_expiry=False):
if not self.redis_instance.exists(key):
self.redis_instance.set(key, 1, ex=expiry)
else:
oldexp = self.get_expiry(key)
self.redis_instance.set(key, int(self.redis_instance.get(key))+1, ex=oldexp)
return
def get(self, key):
return int(self.redis_instance.get(key))
def reset(self):
return self.redis_instance.flushdb()
|
Fix custom redislite to account for the none errors
|
Fix custom redislite to account for the none errors
|
Python
|
agpl-3.0
|
TitanEmbeds/Titan,TitanEmbeds/Titan,TitanEmbeds/Titan
|
import urlparse
from limits.storage import Storage
from redislite import Redis
import time
class LimitsRedisLite(Storage): # For Python Limits
STORAGE_SCHEME = "redislite"
def __init__(self, uri, **options):
self.redis_instance = Redis(urlparse.urlparse(uri).netloc)
def check(self):
return True
def get_expiry(self, key):
return self.redis_instance.ttl(key)
def incr(self, key, expiry, elastic_expiry=False):
if not self.redis_instance.exists(key):
self.redis_instance.set(key, 1)
self.redis_instance.expireat(key, int(time.time() + expiry))
else:
oldexp = self.get_expiry(key)
self.redis_instance.set(key, int(self.redis_instance.get(key))+1)
self.redis_instance.expireat(key, int(time.time() + oldexp))
return
def get(self, key):
return int(self.redis_instance.get(key))
def reset(self):
return self.redis_instance.flushdb()
Fix custom redislite to account for the none errors
|
import urlparse
from limits.storage import Storage
from redislite import Redis
import time
class LimitsRedisLite(Storage): # For Python Limits
STORAGE_SCHEME = "redislite"
def __init__(self, uri, **options):
self.redis_instance = Redis(urlparse.urlparse(uri).netloc)
def check(self):
return True
def get_expiry(self, key):
return self.redis_instance.ttl(key) or 0
def incr(self, key, expiry, elastic_expiry=False):
if not self.redis_instance.exists(key):
self.redis_instance.set(key, 1, ex=expiry)
else:
oldexp = self.get_expiry(key)
self.redis_instance.set(key, int(self.redis_instance.get(key))+1, ex=oldexp)
return
def get(self, key):
return int(self.redis_instance.get(key))
def reset(self):
return self.redis_instance.flushdb()
|
<commit_before>import urlparse
from limits.storage import Storage
from redislite import Redis
import time
class LimitsRedisLite(Storage): # For Python Limits
STORAGE_SCHEME = "redislite"
def __init__(self, uri, **options):
self.redis_instance = Redis(urlparse.urlparse(uri).netloc)
def check(self):
return True
def get_expiry(self, key):
return self.redis_instance.ttl(key)
def incr(self, key, expiry, elastic_expiry=False):
if not self.redis_instance.exists(key):
self.redis_instance.set(key, 1)
self.redis_instance.expireat(key, int(time.time() + expiry))
else:
oldexp = self.get_expiry(key)
self.redis_instance.set(key, int(self.redis_instance.get(key))+1)
self.redis_instance.expireat(key, int(time.time() + oldexp))
return
def get(self, key):
return int(self.redis_instance.get(key))
def reset(self):
return self.redis_instance.flushdb()
<commit_msg>Fix custom redislite to account for the none errors<commit_after>
|
import urlparse
from limits.storage import Storage
from redislite import Redis
import time
class LimitsRedisLite(Storage): # For Python Limits
STORAGE_SCHEME = "redislite"
def __init__(self, uri, **options):
self.redis_instance = Redis(urlparse.urlparse(uri).netloc)
def check(self):
return True
def get_expiry(self, key):
return self.redis_instance.ttl(key) or 0
def incr(self, key, expiry, elastic_expiry=False):
if not self.redis_instance.exists(key):
self.redis_instance.set(key, 1, ex=expiry)
else:
oldexp = self.get_expiry(key)
self.redis_instance.set(key, int(self.redis_instance.get(key))+1, ex=oldexp)
return
def get(self, key):
return int(self.redis_instance.get(key))
def reset(self):
return self.redis_instance.flushdb()
|
import urlparse
from limits.storage import Storage
from redislite import Redis
import time
class LimitsRedisLite(Storage): # For Python Limits
STORAGE_SCHEME = "redislite"
def __init__(self, uri, **options):
self.redis_instance = Redis(urlparse.urlparse(uri).netloc)
def check(self):
return True
def get_expiry(self, key):
return self.redis_instance.ttl(key)
def incr(self, key, expiry, elastic_expiry=False):
if not self.redis_instance.exists(key):
self.redis_instance.set(key, 1)
self.redis_instance.expireat(key, int(time.time() + expiry))
else:
oldexp = self.get_expiry(key)
self.redis_instance.set(key, int(self.redis_instance.get(key))+1)
self.redis_instance.expireat(key, int(time.time() + oldexp))
return
def get(self, key):
return int(self.redis_instance.get(key))
def reset(self):
return self.redis_instance.flushdb()
Fix custom redislite to account for the none errorsimport urlparse
from limits.storage import Storage
from redislite import Redis
import time
class LimitsRedisLite(Storage): # For Python Limits
STORAGE_SCHEME = "redislite"
def __init__(self, uri, **options):
self.redis_instance = Redis(urlparse.urlparse(uri).netloc)
def check(self):
return True
def get_expiry(self, key):
return self.redis_instance.ttl(key) or 0
def incr(self, key, expiry, elastic_expiry=False):
if not self.redis_instance.exists(key):
self.redis_instance.set(key, 1, ex=expiry)
else:
oldexp = self.get_expiry(key)
self.redis_instance.set(key, int(self.redis_instance.get(key))+1, ex=oldexp)
return
def get(self, key):
return int(self.redis_instance.get(key))
def reset(self):
return self.redis_instance.flushdb()
|
<commit_before>import urlparse
from limits.storage import Storage
from redislite import Redis
import time
class LimitsRedisLite(Storage): # For Python Limits
STORAGE_SCHEME = "redislite"
def __init__(self, uri, **options):
self.redis_instance = Redis(urlparse.urlparse(uri).netloc)
def check(self):
return True
def get_expiry(self, key):
return self.redis_instance.ttl(key)
def incr(self, key, expiry, elastic_expiry=False):
if not self.redis_instance.exists(key):
self.redis_instance.set(key, 1)
self.redis_instance.expireat(key, int(time.time() + expiry))
else:
oldexp = self.get_expiry(key)
self.redis_instance.set(key, int(self.redis_instance.get(key))+1)
self.redis_instance.expireat(key, int(time.time() + oldexp))
return
def get(self, key):
return int(self.redis_instance.get(key))
def reset(self):
return self.redis_instance.flushdb()
<commit_msg>Fix custom redislite to account for the none errors<commit_after>import urlparse
from limits.storage import Storage
from redislite import Redis
import time
class LimitsRedisLite(Storage): # For Python Limits
STORAGE_SCHEME = "redislite"
def __init__(self, uri, **options):
self.redis_instance = Redis(urlparse.urlparse(uri).netloc)
def check(self):
return True
def get_expiry(self, key):
return self.redis_instance.ttl(key) or 0
def incr(self, key, expiry, elastic_expiry=False):
if not self.redis_instance.exists(key):
self.redis_instance.set(key, 1, ex=expiry)
else:
oldexp = self.get_expiry(key)
self.redis_instance.set(key, int(self.redis_instance.get(key))+1, ex=oldexp)
return
def get(self, key):
return int(self.redis_instance.get(key))
def reset(self):
return self.redis_instance.flushdb()
|
63c81a18bd95876cad1bd4c1269d38e18ee3e817
|
wikichatter/TalkPageParser.py
|
wikichatter/TalkPageParser.py
|
import mwparserfromhell as mwp
from . import IndentTree
from . import WikiComments as wc
class Page:
def __init__(self):
self.indent = -2
def __str__(self):
return "Talk_Page"
class Section:
def __init__(self, heading):
self.heading = heading
self.indent = -1
def __str__(self):
return self.heading
def parse(text):
root = IndentTree.IndentTreeNode(None, Page())
parse_list = []
wikicode = mwp.parse(text)
sections = wikicode.get_sections()
for section in sections:
section_text = str(section)
comments = wc.get_linear_merge_comments(section_text)
if len(comments) > 0:
headings = mwp.parse(section_text).filter_headings()
if len(headings) > 0:
heading = "\n" + "\n".join([str(h) for h in headings])
else:
heading = "NO HEADING FOUND"
parse_list.append(Section(heading))
parse_list.extend(comments)
root.generate_tree_from_list(parse_list)
return root
|
import mwparserfromhell as mwp
from . import IndentTree
from . import WikiComments as wc
class Page:
def __init__(self):
self.indent = -2
def __str__(self):
return "Talk_Page"
class Section:
def __init__(self, heading):
self.heading = heading
self.indent = -1
def __str__(self):
return self.heading
def parse(text):
root = IndentTree.IndentTreeNode(None, Page())
parse_list = []
# skip_style_tags is fix for https://github.com/kjschiroo/WikiChatter/issues/10
wikicode = mwp.parse(text, skip_style_tags=True)
sections = wikicode.get_sections()
for section in sections:
section_text = str(section)
comments = wc.get_linear_merge_comments(section_text)
if len(comments) > 0:
headings = mwp.parse(section_text).filter_headings()
if len(headings) > 0:
heading = "\n" + "\n".join([str(h) for h in headings])
else:
heading = "NO HEADING FOUND"
parse_list.append(Section(heading))
parse_list.extend(comments)
root.generate_tree_from_list(parse_list)
return root
|
Make mwparserfromhell skip style tags
|
Make mwparserfromhell skip style tags
Since we do not really care if '' and ''' tags are processed
as plaintext or not, and not processing them as plaintext
causes #10
|
Python
|
mit
|
kjschiroo/WikiChatter
|
import mwparserfromhell as mwp
from . import IndentTree
from . import WikiComments as wc
class Page:
def __init__(self):
self.indent = -2
def __str__(self):
return "Talk_Page"
class Section:
def __init__(self, heading):
self.heading = heading
self.indent = -1
def __str__(self):
return self.heading
def parse(text):
root = IndentTree.IndentTreeNode(None, Page())
parse_list = []
wikicode = mwp.parse(text)
sections = wikicode.get_sections()
for section in sections:
section_text = str(section)
comments = wc.get_linear_merge_comments(section_text)
if len(comments) > 0:
headings = mwp.parse(section_text).filter_headings()
if len(headings) > 0:
heading = "\n" + "\n".join([str(h) for h in headings])
else:
heading = "NO HEADING FOUND"
parse_list.append(Section(heading))
parse_list.extend(comments)
root.generate_tree_from_list(parse_list)
return root
Make mwparserfromhell skip style tags
Since we do not really care if '' and ''' tags are processed
as plaintext or not, and not processing them as plaintext
causes #10
|
import mwparserfromhell as mwp
from . import IndentTree
from . import WikiComments as wc
class Page:
def __init__(self):
self.indent = -2
def __str__(self):
return "Talk_Page"
class Section:
def __init__(self, heading):
self.heading = heading
self.indent = -1
def __str__(self):
return self.heading
def parse(text):
root = IndentTree.IndentTreeNode(None, Page())
parse_list = []
# skip_style_tags is fix for https://github.com/kjschiroo/WikiChatter/issues/10
wikicode = mwp.parse(text, skip_style_tags=True)
sections = wikicode.get_sections()
for section in sections:
section_text = str(section)
comments = wc.get_linear_merge_comments(section_text)
if len(comments) > 0:
headings = mwp.parse(section_text).filter_headings()
if len(headings) > 0:
heading = "\n" + "\n".join([str(h) for h in headings])
else:
heading = "NO HEADING FOUND"
parse_list.append(Section(heading))
parse_list.extend(comments)
root.generate_tree_from_list(parse_list)
return root
|
<commit_before>import mwparserfromhell as mwp
from . import IndentTree
from . import WikiComments as wc
class Page:
def __init__(self):
self.indent = -2
def __str__(self):
return "Talk_Page"
class Section:
def __init__(self, heading):
self.heading = heading
self.indent = -1
def __str__(self):
return self.heading
def parse(text):
root = IndentTree.IndentTreeNode(None, Page())
parse_list = []
wikicode = mwp.parse(text)
sections = wikicode.get_sections()
for section in sections:
section_text = str(section)
comments = wc.get_linear_merge_comments(section_text)
if len(comments) > 0:
headings = mwp.parse(section_text).filter_headings()
if len(headings) > 0:
heading = "\n" + "\n".join([str(h) for h in headings])
else:
heading = "NO HEADING FOUND"
parse_list.append(Section(heading))
parse_list.extend(comments)
root.generate_tree_from_list(parse_list)
return root
<commit_msg>Make mwparserfromhell skip style tags
Since we do not really care if '' and ''' tags are processed
as plaintext or not, and not processing them as plaintext
causes #10<commit_after>
|
import mwparserfromhell as mwp
from . import IndentTree
from . import WikiComments as wc
class Page:
def __init__(self):
self.indent = -2
def __str__(self):
return "Talk_Page"
class Section:
def __init__(self, heading):
self.heading = heading
self.indent = -1
def __str__(self):
return self.heading
def parse(text):
root = IndentTree.IndentTreeNode(None, Page())
parse_list = []
# skip_style_tags is fix for https://github.com/kjschiroo/WikiChatter/issues/10
wikicode = mwp.parse(text, skip_style_tags=True)
sections = wikicode.get_sections()
for section in sections:
section_text = str(section)
comments = wc.get_linear_merge_comments(section_text)
if len(comments) > 0:
headings = mwp.parse(section_text).filter_headings()
if len(headings) > 0:
heading = "\n" + "\n".join([str(h) for h in headings])
else:
heading = "NO HEADING FOUND"
parse_list.append(Section(heading))
parse_list.extend(comments)
root.generate_tree_from_list(parse_list)
return root
|
import mwparserfromhell as mwp
from . import IndentTree
from . import WikiComments as wc
class Page:
def __init__(self):
self.indent = -2
def __str__(self):
return "Talk_Page"
class Section:
def __init__(self, heading):
self.heading = heading
self.indent = -1
def __str__(self):
return self.heading
def parse(text):
root = IndentTree.IndentTreeNode(None, Page())
parse_list = []
wikicode = mwp.parse(text)
sections = wikicode.get_sections()
for section in sections:
section_text = str(section)
comments = wc.get_linear_merge_comments(section_text)
if len(comments) > 0:
headings = mwp.parse(section_text).filter_headings()
if len(headings) > 0:
heading = "\n" + "\n".join([str(h) for h in headings])
else:
heading = "NO HEADING FOUND"
parse_list.append(Section(heading))
parse_list.extend(comments)
root.generate_tree_from_list(parse_list)
return root
Make mwparserfromhell skip style tags
Since we do not really care if '' and ''' tags are processed
as plaintext or not, and not processing them as plaintext
causes #10import mwparserfromhell as mwp
from . import IndentTree
from . import WikiComments as wc
class Page:
def __init__(self):
self.indent = -2
def __str__(self):
return "Talk_Page"
class Section:
def __init__(self, heading):
self.heading = heading
self.indent = -1
def __str__(self):
return self.heading
def parse(text):
root = IndentTree.IndentTreeNode(None, Page())
parse_list = []
# skip_style_tags is fix for https://github.com/kjschiroo/WikiChatter/issues/10
wikicode = mwp.parse(text, skip_style_tags=True)
sections = wikicode.get_sections()
for section in sections:
section_text = str(section)
comments = wc.get_linear_merge_comments(section_text)
if len(comments) > 0:
headings = mwp.parse(section_text).filter_headings()
if len(headings) > 0:
heading = "\n" + "\n".join([str(h) for h in headings])
else:
heading = "NO HEADING FOUND"
parse_list.append(Section(heading))
parse_list.extend(comments)
root.generate_tree_from_list(parse_list)
return root
|
<commit_before>import mwparserfromhell as mwp
from . import IndentTree
from . import WikiComments as wc
class Page:
def __init__(self):
self.indent = -2
def __str__(self):
return "Talk_Page"
class Section:
def __init__(self, heading):
self.heading = heading
self.indent = -1
def __str__(self):
return self.heading
def parse(text):
root = IndentTree.IndentTreeNode(None, Page())
parse_list = []
wikicode = mwp.parse(text)
sections = wikicode.get_sections()
for section in sections:
section_text = str(section)
comments = wc.get_linear_merge_comments(section_text)
if len(comments) > 0:
headings = mwp.parse(section_text).filter_headings()
if len(headings) > 0:
heading = "\n" + "\n".join([str(h) for h in headings])
else:
heading = "NO HEADING FOUND"
parse_list.append(Section(heading))
parse_list.extend(comments)
root.generate_tree_from_list(parse_list)
return root
<commit_msg>Make mwparserfromhell skip style tags
Since we do not really care if '' and ''' tags are processed
as plaintext or not, and not processing them as plaintext
causes #10<commit_after>import mwparserfromhell as mwp
from . import IndentTree
from . import WikiComments as wc
class Page:
def __init__(self):
self.indent = -2
def __str__(self):
return "Talk_Page"
class Section:
def __init__(self, heading):
self.heading = heading
self.indent = -1
def __str__(self):
return self.heading
def parse(text):
root = IndentTree.IndentTreeNode(None, Page())
parse_list = []
# skip_style_tags is fix for https://github.com/kjschiroo/WikiChatter/issues/10
wikicode = mwp.parse(text, skip_style_tags=True)
sections = wikicode.get_sections()
for section in sections:
section_text = str(section)
comments = wc.get_linear_merge_comments(section_text)
if len(comments) > 0:
headings = mwp.parse(section_text).filter_headings()
if len(headings) > 0:
heading = "\n" + "\n".join([str(h) for h in headings])
else:
heading = "NO HEADING FOUND"
parse_list.append(Section(heading))
parse_list.extend(comments)
root.generate_tree_from_list(parse_list)
return root
|
cd0f4758bcb8eacab0a6a1f21f3c4287b2d24995
|
vumi/blinkenlights/heartbeat/__init__.py
|
vumi/blinkenlights/heartbeat/__init__.py
|
from vumi.blinkenlights.heartbeat.publisher import (HeartBeatMessage,
HeartBeatPublisher)
from vumi.blinkenlights.heartbeat.monitor import HeartBeatMonitor
__all__ = ["HeartBeatMessage", "HeartBeatPublisher", "HeartBeatMonitor"]
|
from vumi.blinkenlights.heartbeat.publisher import (HeartBeatMessage,
HeartBeatPublisher)
__all__ = ["HeartBeatMessage", "HeartBeatPublisher"]
|
Resolve a cyclical dependency issue
|
Resolve a cyclical dependency issue
|
Python
|
bsd-3-clause
|
vishwaprakashmishra/xmatrix,TouK/vumi,harrissoerja/vumi,TouK/vumi,harrissoerja/vumi,vishwaprakashmishra/xmatrix,TouK/vumi,vishwaprakashmishra/xmatrix,harrissoerja/vumi
|
from vumi.blinkenlights.heartbeat.publisher import (HeartBeatMessage,
HeartBeatPublisher)
from vumi.blinkenlights.heartbeat.monitor import HeartBeatMonitor
__all__ = ["HeartBeatMessage", "HeartBeatPublisher", "HeartBeatMonitor"]
Resolve a cyclical dependency issue
|
from vumi.blinkenlights.heartbeat.publisher import (HeartBeatMessage,
HeartBeatPublisher)
__all__ = ["HeartBeatMessage", "HeartBeatPublisher"]
|
<commit_before>
from vumi.blinkenlights.heartbeat.publisher import (HeartBeatMessage,
HeartBeatPublisher)
from vumi.blinkenlights.heartbeat.monitor import HeartBeatMonitor
__all__ = ["HeartBeatMessage", "HeartBeatPublisher", "HeartBeatMonitor"]
<commit_msg>Resolve a cyclical dependency issue<commit_after>
|
from vumi.blinkenlights.heartbeat.publisher import (HeartBeatMessage,
HeartBeatPublisher)
__all__ = ["HeartBeatMessage", "HeartBeatPublisher"]
|
from vumi.blinkenlights.heartbeat.publisher import (HeartBeatMessage,
HeartBeatPublisher)
from vumi.blinkenlights.heartbeat.monitor import HeartBeatMonitor
__all__ = ["HeartBeatMessage", "HeartBeatPublisher", "HeartBeatMonitor"]
Resolve a cyclical dependency issue
from vumi.blinkenlights.heartbeat.publisher import (HeartBeatMessage,
HeartBeatPublisher)
__all__ = ["HeartBeatMessage", "HeartBeatPublisher"]
|
<commit_before>
from vumi.blinkenlights.heartbeat.publisher import (HeartBeatMessage,
HeartBeatPublisher)
from vumi.blinkenlights.heartbeat.monitor import HeartBeatMonitor
__all__ = ["HeartBeatMessage", "HeartBeatPublisher", "HeartBeatMonitor"]
<commit_msg>Resolve a cyclical dependency issue<commit_after>
from vumi.blinkenlights.heartbeat.publisher import (HeartBeatMessage,
HeartBeatPublisher)
__all__ = ["HeartBeatMessage", "HeartBeatPublisher"]
|
a5a9807bb4c473442716201b6b220be62d764af4
|
tailor/listeners/filelistener.py
|
tailor/listeners/filelistener.py
|
from tailor.utils.sourcefile import num_lines_in_file, file_too_long
class FileListener:
# pylint: disable=too-few-public-methods
def __init__(self, printer, filepath):
self.__printer = printer
self.__filepath = filepath
def verify(self, max_lines):
self.__verify_file_length(max_lines)
def __verify_file_length(self, max_lines):
if file_too_long(self.__filepath, max_lines):
self.__printer.error('File is over maximum line limit (' +
str(num_lines_in_file(self.__filepath)) +
'/' + str(max_lines) + ')',
loc=(max_lines + 1, 0))
|
from tailor.types.location import Location
from tailor.utils.sourcefile import num_lines_in_file, file_too_long
class FileListener:
# pylint: disable=too-few-public-methods
def __init__(self, printer, filepath):
self.__printer = printer
self.__filepath = filepath
def verify(self, max_lines):
self.__verify_file_length(max_lines)
def __verify_file_length(self, max_lines):
if file_too_long(self.__filepath, max_lines):
self.__printer.error('File is over maximum line limit (' +
str(num_lines_in_file(self.__filepath)) +
'/' + str(max_lines) + ')',
loc=Location(max_lines, 1))
|
Use Location namedtuple when calling printer
|
Use Location namedtuple when calling printer
|
Python
|
mit
|
sleekbyte/tailor,sleekbyte/tailor,sleekbyte/tailor,sleekbyte/tailor,sleekbyte/tailor
|
from tailor.utils.sourcefile import num_lines_in_file, file_too_long
class FileListener:
# pylint: disable=too-few-public-methods
def __init__(self, printer, filepath):
self.__printer = printer
self.__filepath = filepath
def verify(self, max_lines):
self.__verify_file_length(max_lines)
def __verify_file_length(self, max_lines):
if file_too_long(self.__filepath, max_lines):
self.__printer.error('File is over maximum line limit (' +
str(num_lines_in_file(self.__filepath)) +
'/' + str(max_lines) + ')',
loc=(max_lines + 1, 0))
Use Location namedtuple when calling printer
|
from tailor.types.location import Location
from tailor.utils.sourcefile import num_lines_in_file, file_too_long
class FileListener:
# pylint: disable=too-few-public-methods
def __init__(self, printer, filepath):
self.__printer = printer
self.__filepath = filepath
def verify(self, max_lines):
self.__verify_file_length(max_lines)
def __verify_file_length(self, max_lines):
if file_too_long(self.__filepath, max_lines):
self.__printer.error('File is over maximum line limit (' +
str(num_lines_in_file(self.__filepath)) +
'/' + str(max_lines) + ')',
loc=Location(max_lines, 1))
|
<commit_before>from tailor.utils.sourcefile import num_lines_in_file, file_too_long
class FileListener:
# pylint: disable=too-few-public-methods
def __init__(self, printer, filepath):
self.__printer = printer
self.__filepath = filepath
def verify(self, max_lines):
self.__verify_file_length(max_lines)
def __verify_file_length(self, max_lines):
if file_too_long(self.__filepath, max_lines):
self.__printer.error('File is over maximum line limit (' +
str(num_lines_in_file(self.__filepath)) +
'/' + str(max_lines) + ')',
loc=(max_lines + 1, 0))
<commit_msg>Use Location namedtuple when calling printer<commit_after>
|
from tailor.types.location import Location
from tailor.utils.sourcefile import num_lines_in_file, file_too_long
class FileListener:
# pylint: disable=too-few-public-methods
def __init__(self, printer, filepath):
self.__printer = printer
self.__filepath = filepath
def verify(self, max_lines):
self.__verify_file_length(max_lines)
def __verify_file_length(self, max_lines):
if file_too_long(self.__filepath, max_lines):
self.__printer.error('File is over maximum line limit (' +
str(num_lines_in_file(self.__filepath)) +
'/' + str(max_lines) + ')',
loc=Location(max_lines, 1))
|
from tailor.utils.sourcefile import num_lines_in_file, file_too_long
class FileListener:
# pylint: disable=too-few-public-methods
def __init__(self, printer, filepath):
self.__printer = printer
self.__filepath = filepath
def verify(self, max_lines):
self.__verify_file_length(max_lines)
def __verify_file_length(self, max_lines):
if file_too_long(self.__filepath, max_lines):
self.__printer.error('File is over maximum line limit (' +
str(num_lines_in_file(self.__filepath)) +
'/' + str(max_lines) + ')',
loc=(max_lines + 1, 0))
Use Location namedtuple when calling printerfrom tailor.types.location import Location
from tailor.utils.sourcefile import num_lines_in_file, file_too_long
class FileListener:
# pylint: disable=too-few-public-methods
def __init__(self, printer, filepath):
self.__printer = printer
self.__filepath = filepath
def verify(self, max_lines):
self.__verify_file_length(max_lines)
def __verify_file_length(self, max_lines):
if file_too_long(self.__filepath, max_lines):
self.__printer.error('File is over maximum line limit (' +
str(num_lines_in_file(self.__filepath)) +
'/' + str(max_lines) + ')',
loc=Location(max_lines, 1))
|
<commit_before>from tailor.utils.sourcefile import num_lines_in_file, file_too_long
class FileListener:
# pylint: disable=too-few-public-methods
def __init__(self, printer, filepath):
self.__printer = printer
self.__filepath = filepath
def verify(self, max_lines):
self.__verify_file_length(max_lines)
def __verify_file_length(self, max_lines):
if file_too_long(self.__filepath, max_lines):
self.__printer.error('File is over maximum line limit (' +
str(num_lines_in_file(self.__filepath)) +
'/' + str(max_lines) + ')',
loc=(max_lines + 1, 0))
<commit_msg>Use Location namedtuple when calling printer<commit_after>from tailor.types.location import Location
from tailor.utils.sourcefile import num_lines_in_file, file_too_long
class FileListener:
# pylint: disable=too-few-public-methods
def __init__(self, printer, filepath):
self.__printer = printer
self.__filepath = filepath
def verify(self, max_lines):
self.__verify_file_length(max_lines)
def __verify_file_length(self, max_lines):
if file_too_long(self.__filepath, max_lines):
self.__printer.error('File is over maximum line limit (' +
str(num_lines_in_file(self.__filepath)) +
'/' + str(max_lines) + ')',
loc=Location(max_lines, 1))
|
c23570f528b3ad27e256ea402fc02231b528b000
|
django_messages/urls.py
|
django_messages/urls.py
|
from django.conf.urls import patterns, url
from django.views.generic import RedirectView
from django_messages.views import *
urlpatterns = patterns('',
url(r'^$', RedirectView.as_view(url='inbox/'), name='messages_redirect'),
url(r'^inbox/$', inbox, name='messages_inbox'),
url(r'^outbox/$', outbox, name='messages_outbox'),
url(r'^compose/$', compose, name='messages_compose'),
url(r'^compose/(?P<recipient>[\w.@+-]+)/$', compose, name='messages_compose_to'),
url(r'^reply/(?P<message_id>[\d]+)/$', reply, name='messages_reply'),
url(r'^view/(?P<message_id>[\d]+)/$', view, name='messages_detail'),
url(r'^delete/(?P<message_id>[\d]+)/$', delete, name='messages_delete'),
url(r'^undelete/(?P<message_id>[\d]+)/$', undelete, name='messages_undelete'),
url(r'^trash/$', trash, name='messages_trash'),
)
|
from django.conf.urls import patterns, url
from django.views.generic import RedirectView
from django_messages.views import *
urlpatterns = patterns('',
url(r'^$', RedirectView.as_view(permanent=True, url='inbox/'), name='messages_redirect'),
url(r'^inbox/$', inbox, name='messages_inbox'),
url(r'^outbox/$', outbox, name='messages_outbox'),
url(r'^compose/$', compose, name='messages_compose'),
url(r'^compose/(?P<recipient>[\w.@+-]+)/$', compose, name='messages_compose_to'),
url(r'^reply/(?P<message_id>[\d]+)/$', reply, name='messages_reply'),
url(r'^view/(?P<message_id>[\d]+)/$', view, name='messages_detail'),
url(r'^delete/(?P<message_id>[\d]+)/$', delete, name='messages_delete'),
url(r'^undelete/(?P<message_id>[\d]+)/$', undelete, name='messages_undelete'),
url(r'^trash/$', trash, name='messages_trash'),
)
|
Set an explicit value because Default value of 'RedirectView.permanent' will change from True to False in Django 1.9.
|
Set an explicit value because Default value of 'RedirectView.permanent' will change from True to False in Django 1.9.
|
Python
|
bsd-3-clause
|
arneb/django-messages,JordanReiter/django-messages,brajeshvit/Messagemodule,nikhil-above/django-messages,tobiasgoecke/django-messages,brajeshvit/Messagemodule,JordanReiter/django-messages,gustavoam/django-messages,tobiasgoecke/django-messages,procrasti/django-messages,Chris7/django-messages,gustavoam/django-messages,nikhil-above/django-messages,arneb/django-messages,procrasti/django-messages,Chris7/django-messages
|
from django.conf.urls import patterns, url
from django.views.generic import RedirectView
from django_messages.views import *
urlpatterns = patterns('',
url(r'^$', RedirectView.as_view(url='inbox/'), name='messages_redirect'),
url(r'^inbox/$', inbox, name='messages_inbox'),
url(r'^outbox/$', outbox, name='messages_outbox'),
url(r'^compose/$', compose, name='messages_compose'),
url(r'^compose/(?P<recipient>[\w.@+-]+)/$', compose, name='messages_compose_to'),
url(r'^reply/(?P<message_id>[\d]+)/$', reply, name='messages_reply'),
url(r'^view/(?P<message_id>[\d]+)/$', view, name='messages_detail'),
url(r'^delete/(?P<message_id>[\d]+)/$', delete, name='messages_delete'),
url(r'^undelete/(?P<message_id>[\d]+)/$', undelete, name='messages_undelete'),
url(r'^trash/$', trash, name='messages_trash'),
)
Set an explicit value because Default value of 'RedirectView.permanent' will change from True to False in Django 1.9.
|
from django.conf.urls import patterns, url
from django.views.generic import RedirectView
from django_messages.views import *
urlpatterns = patterns('',
url(r'^$', RedirectView.as_view(permanent=True, url='inbox/'), name='messages_redirect'),
url(r'^inbox/$', inbox, name='messages_inbox'),
url(r'^outbox/$', outbox, name='messages_outbox'),
url(r'^compose/$', compose, name='messages_compose'),
url(r'^compose/(?P<recipient>[\w.@+-]+)/$', compose, name='messages_compose_to'),
url(r'^reply/(?P<message_id>[\d]+)/$', reply, name='messages_reply'),
url(r'^view/(?P<message_id>[\d]+)/$', view, name='messages_detail'),
url(r'^delete/(?P<message_id>[\d]+)/$', delete, name='messages_delete'),
url(r'^undelete/(?P<message_id>[\d]+)/$', undelete, name='messages_undelete'),
url(r'^trash/$', trash, name='messages_trash'),
)
|
<commit_before>from django.conf.urls import patterns, url
from django.views.generic import RedirectView
from django_messages.views import *
urlpatterns = patterns('',
url(r'^$', RedirectView.as_view(url='inbox/'), name='messages_redirect'),
url(r'^inbox/$', inbox, name='messages_inbox'),
url(r'^outbox/$', outbox, name='messages_outbox'),
url(r'^compose/$', compose, name='messages_compose'),
url(r'^compose/(?P<recipient>[\w.@+-]+)/$', compose, name='messages_compose_to'),
url(r'^reply/(?P<message_id>[\d]+)/$', reply, name='messages_reply'),
url(r'^view/(?P<message_id>[\d]+)/$', view, name='messages_detail'),
url(r'^delete/(?P<message_id>[\d]+)/$', delete, name='messages_delete'),
url(r'^undelete/(?P<message_id>[\d]+)/$', undelete, name='messages_undelete'),
url(r'^trash/$', trash, name='messages_trash'),
)
<commit_msg>Set an explicit value because Default value of 'RedirectView.permanent' will change from True to False in Django 1.9.<commit_after>
|
from django.conf.urls import patterns, url
from django.views.generic import RedirectView
from django_messages.views import *
urlpatterns = patterns('',
url(r'^$', RedirectView.as_view(permanent=True, url='inbox/'), name='messages_redirect'),
url(r'^inbox/$', inbox, name='messages_inbox'),
url(r'^outbox/$', outbox, name='messages_outbox'),
url(r'^compose/$', compose, name='messages_compose'),
url(r'^compose/(?P<recipient>[\w.@+-]+)/$', compose, name='messages_compose_to'),
url(r'^reply/(?P<message_id>[\d]+)/$', reply, name='messages_reply'),
url(r'^view/(?P<message_id>[\d]+)/$', view, name='messages_detail'),
url(r'^delete/(?P<message_id>[\d]+)/$', delete, name='messages_delete'),
url(r'^undelete/(?P<message_id>[\d]+)/$', undelete, name='messages_undelete'),
url(r'^trash/$', trash, name='messages_trash'),
)
|
from django.conf.urls import patterns, url
from django.views.generic import RedirectView
from django_messages.views import *
urlpatterns = patterns('',
url(r'^$', RedirectView.as_view(url='inbox/'), name='messages_redirect'),
url(r'^inbox/$', inbox, name='messages_inbox'),
url(r'^outbox/$', outbox, name='messages_outbox'),
url(r'^compose/$', compose, name='messages_compose'),
url(r'^compose/(?P<recipient>[\w.@+-]+)/$', compose, name='messages_compose_to'),
url(r'^reply/(?P<message_id>[\d]+)/$', reply, name='messages_reply'),
url(r'^view/(?P<message_id>[\d]+)/$', view, name='messages_detail'),
url(r'^delete/(?P<message_id>[\d]+)/$', delete, name='messages_delete'),
url(r'^undelete/(?P<message_id>[\d]+)/$', undelete, name='messages_undelete'),
url(r'^trash/$', trash, name='messages_trash'),
)
Set an explicit value because Default value of 'RedirectView.permanent' will change from True to False in Django 1.9.from django.conf.urls import patterns, url
from django.views.generic import RedirectView
from django_messages.views import *
urlpatterns = patterns('',
url(r'^$', RedirectView.as_view(permanent=True, url='inbox/'), name='messages_redirect'),
url(r'^inbox/$', inbox, name='messages_inbox'),
url(r'^outbox/$', outbox, name='messages_outbox'),
url(r'^compose/$', compose, name='messages_compose'),
url(r'^compose/(?P<recipient>[\w.@+-]+)/$', compose, name='messages_compose_to'),
url(r'^reply/(?P<message_id>[\d]+)/$', reply, name='messages_reply'),
url(r'^view/(?P<message_id>[\d]+)/$', view, name='messages_detail'),
url(r'^delete/(?P<message_id>[\d]+)/$', delete, name='messages_delete'),
url(r'^undelete/(?P<message_id>[\d]+)/$', undelete, name='messages_undelete'),
url(r'^trash/$', trash, name='messages_trash'),
)
|
<commit_before>from django.conf.urls import patterns, url
from django.views.generic import RedirectView
from django_messages.views import *
urlpatterns = patterns('',
url(r'^$', RedirectView.as_view(url='inbox/'), name='messages_redirect'),
url(r'^inbox/$', inbox, name='messages_inbox'),
url(r'^outbox/$', outbox, name='messages_outbox'),
url(r'^compose/$', compose, name='messages_compose'),
url(r'^compose/(?P<recipient>[\w.@+-]+)/$', compose, name='messages_compose_to'),
url(r'^reply/(?P<message_id>[\d]+)/$', reply, name='messages_reply'),
url(r'^view/(?P<message_id>[\d]+)/$', view, name='messages_detail'),
url(r'^delete/(?P<message_id>[\d]+)/$', delete, name='messages_delete'),
url(r'^undelete/(?P<message_id>[\d]+)/$', undelete, name='messages_undelete'),
url(r'^trash/$', trash, name='messages_trash'),
)
<commit_msg>Set an explicit value because Default value of 'RedirectView.permanent' will change from True to False in Django 1.9.<commit_after>from django.conf.urls import patterns, url
from django.views.generic import RedirectView
from django_messages.views import *
urlpatterns = patterns('',
url(r'^$', RedirectView.as_view(permanent=True, url='inbox/'), name='messages_redirect'),
url(r'^inbox/$', inbox, name='messages_inbox'),
url(r'^outbox/$', outbox, name='messages_outbox'),
url(r'^compose/$', compose, name='messages_compose'),
url(r'^compose/(?P<recipient>[\w.@+-]+)/$', compose, name='messages_compose_to'),
url(r'^reply/(?P<message_id>[\d]+)/$', reply, name='messages_reply'),
url(r'^view/(?P<message_id>[\d]+)/$', view, name='messages_detail'),
url(r'^delete/(?P<message_id>[\d]+)/$', delete, name='messages_delete'),
url(r'^undelete/(?P<message_id>[\d]+)/$', undelete, name='messages_undelete'),
url(r'^trash/$', trash, name='messages_trash'),
)
|
ffbc35a0c19083a53a25aee71b74e06da0aa0a4b
|
timepiece/contracts/admin.py
|
timepiece/contracts/admin.py
|
from django.contrib import admin
from timepiece.contracts.models import ProjectContract, ContractHour,\
ContractAssignment, HourGroup
class ContractAssignmentInline(admin.TabularInline):
model = ContractAssignment
raw_id_fields = ('user',)
def queryset(self, request):
qs = super(ContractAssignmentInline, self).queryset(request)
return qs.select_related()
class ContractHourInline(admin.TabularInline):
model = ContractHour
class ProjectContractAdmin(admin.ModelAdmin):
model = ProjectContract
list_display = ('name', 'start_date', 'end_date', 'status',
'contracted_hours', 'pending_hours',
'hours_assigned', 'hours_unassigned',
'hours_worked',
'type')
inlines = (ContractAssignmentInline, ContractHourInline)
list_filter = ('status', 'type')
filter_horizontal = ('projects',)
list_per_page = 20
search_fields = ('name', 'projects__name', 'projects__business__name')
def hours_unassigned(self, obj):
return obj.contracted_hours() - obj.hours_assigned
class HourGroupAdmin(admin.ModelAdmin):
model = HourGroup
list_display = ('name',)
list_filter = ('activities',)
ordering = ('order', 'name')
filter_horizontal = ('activities',)
admin.site.register(ProjectContract, ProjectContractAdmin)
admin.site.register(HourGroup, HourGroupAdmin)
admin.site.register(ContractHour)
|
from django.contrib import admin
from timepiece.contracts.models import ProjectContract, ContractHour,\
ContractAssignment, HourGroup
class ContractAssignmentInline(admin.TabularInline):
model = ContractAssignment
raw_id_fields = ('user',)
def get_queryset(self, request):
qs = super(ContractAssignmentInline, self).get_queryset(request)
return qs.select_related()
class ContractHourInline(admin.TabularInline):
model = ContractHour
class ProjectContractAdmin(admin.ModelAdmin):
model = ProjectContract
list_display = ('name', 'start_date', 'end_date', 'status',
'contracted_hours', 'pending_hours',
'hours_assigned', 'hours_unassigned',
'hours_worked',
'type')
inlines = (ContractAssignmentInline, ContractHourInline)
list_filter = ('status', 'type')
filter_horizontal = ('projects',)
list_per_page = 20
search_fields = ('name', 'projects__name', 'projects__business__name')
def hours_unassigned(self, obj):
return obj.contracted_hours() - obj.hours_assigned
class HourGroupAdmin(admin.ModelAdmin):
model = HourGroup
list_display = ('name',)
list_filter = ('activities',)
ordering = ('order', 'name')
filter_horizontal = ('activities',)
admin.site.register(ProjectContract, ProjectContractAdmin)
admin.site.register(HourGroup, HourGroupAdmin)
admin.site.register(ContractHour)
|
Update Python/Django: Admin queryset -> get_queryset
|
Update Python/Django: Admin queryset -> get_queryset
|
Python
|
mit
|
arbitrahj/django-timepiece,caktus/django-timepiece,caktus/django-timepiece,BocuStudio/django-timepiece,arbitrahj/django-timepiece,arbitrahj/django-timepiece,BocuStudio/django-timepiece,BocuStudio/django-timepiece,caktus/django-timepiece
|
from django.contrib import admin
from timepiece.contracts.models import ProjectContract, ContractHour,\
ContractAssignment, HourGroup
class ContractAssignmentInline(admin.TabularInline):
model = ContractAssignment
raw_id_fields = ('user',)
def queryset(self, request):
qs = super(ContractAssignmentInline, self).queryset(request)
return qs.select_related()
class ContractHourInline(admin.TabularInline):
model = ContractHour
class ProjectContractAdmin(admin.ModelAdmin):
model = ProjectContract
list_display = ('name', 'start_date', 'end_date', 'status',
'contracted_hours', 'pending_hours',
'hours_assigned', 'hours_unassigned',
'hours_worked',
'type')
inlines = (ContractAssignmentInline, ContractHourInline)
list_filter = ('status', 'type')
filter_horizontal = ('projects',)
list_per_page = 20
search_fields = ('name', 'projects__name', 'projects__business__name')
def hours_unassigned(self, obj):
return obj.contracted_hours() - obj.hours_assigned
class HourGroupAdmin(admin.ModelAdmin):
model = HourGroup
list_display = ('name',)
list_filter = ('activities',)
ordering = ('order', 'name')
filter_horizontal = ('activities',)
admin.site.register(ProjectContract, ProjectContractAdmin)
admin.site.register(HourGroup, HourGroupAdmin)
admin.site.register(ContractHour)
Update Python/Django: Admin queryset -> get_queryset
|
from django.contrib import admin
from timepiece.contracts.models import ProjectContract, ContractHour,\
ContractAssignment, HourGroup
class ContractAssignmentInline(admin.TabularInline):
model = ContractAssignment
raw_id_fields = ('user',)
def get_queryset(self, request):
qs = super(ContractAssignmentInline, self).get_queryset(request)
return qs.select_related()
class ContractHourInline(admin.TabularInline):
model = ContractHour
class ProjectContractAdmin(admin.ModelAdmin):
model = ProjectContract
list_display = ('name', 'start_date', 'end_date', 'status',
'contracted_hours', 'pending_hours',
'hours_assigned', 'hours_unassigned',
'hours_worked',
'type')
inlines = (ContractAssignmentInline, ContractHourInline)
list_filter = ('status', 'type')
filter_horizontal = ('projects',)
list_per_page = 20
search_fields = ('name', 'projects__name', 'projects__business__name')
def hours_unassigned(self, obj):
return obj.contracted_hours() - obj.hours_assigned
class HourGroupAdmin(admin.ModelAdmin):
model = HourGroup
list_display = ('name',)
list_filter = ('activities',)
ordering = ('order', 'name')
filter_horizontal = ('activities',)
admin.site.register(ProjectContract, ProjectContractAdmin)
admin.site.register(HourGroup, HourGroupAdmin)
admin.site.register(ContractHour)
|
<commit_before>from django.contrib import admin
from timepiece.contracts.models import ProjectContract, ContractHour,\
ContractAssignment, HourGroup
class ContractAssignmentInline(admin.TabularInline):
model = ContractAssignment
raw_id_fields = ('user',)
def queryset(self, request):
qs = super(ContractAssignmentInline, self).queryset(request)
return qs.select_related()
class ContractHourInline(admin.TabularInline):
model = ContractHour
class ProjectContractAdmin(admin.ModelAdmin):
model = ProjectContract
list_display = ('name', 'start_date', 'end_date', 'status',
'contracted_hours', 'pending_hours',
'hours_assigned', 'hours_unassigned',
'hours_worked',
'type')
inlines = (ContractAssignmentInline, ContractHourInline)
list_filter = ('status', 'type')
filter_horizontal = ('projects',)
list_per_page = 20
search_fields = ('name', 'projects__name', 'projects__business__name')
def hours_unassigned(self, obj):
return obj.contracted_hours() - obj.hours_assigned
class HourGroupAdmin(admin.ModelAdmin):
model = HourGroup
list_display = ('name',)
list_filter = ('activities',)
ordering = ('order', 'name')
filter_horizontal = ('activities',)
admin.site.register(ProjectContract, ProjectContractAdmin)
admin.site.register(HourGroup, HourGroupAdmin)
admin.site.register(ContractHour)
<commit_msg>Update Python/Django: Admin queryset -> get_queryset<commit_after>
|
from django.contrib import admin
from timepiece.contracts.models import ProjectContract, ContractHour,\
ContractAssignment, HourGroup
class ContractAssignmentInline(admin.TabularInline):
model = ContractAssignment
raw_id_fields = ('user',)
def get_queryset(self, request):
qs = super(ContractAssignmentInline, self).get_queryset(request)
return qs.select_related()
class ContractHourInline(admin.TabularInline):
model = ContractHour
class ProjectContractAdmin(admin.ModelAdmin):
model = ProjectContract
list_display = ('name', 'start_date', 'end_date', 'status',
'contracted_hours', 'pending_hours',
'hours_assigned', 'hours_unassigned',
'hours_worked',
'type')
inlines = (ContractAssignmentInline, ContractHourInline)
list_filter = ('status', 'type')
filter_horizontal = ('projects',)
list_per_page = 20
search_fields = ('name', 'projects__name', 'projects__business__name')
def hours_unassigned(self, obj):
return obj.contracted_hours() - obj.hours_assigned
class HourGroupAdmin(admin.ModelAdmin):
model = HourGroup
list_display = ('name',)
list_filter = ('activities',)
ordering = ('order', 'name')
filter_horizontal = ('activities',)
admin.site.register(ProjectContract, ProjectContractAdmin)
admin.site.register(HourGroup, HourGroupAdmin)
admin.site.register(ContractHour)
|
from django.contrib import admin
from timepiece.contracts.models import ProjectContract, ContractHour,\
ContractAssignment, HourGroup
class ContractAssignmentInline(admin.TabularInline):
model = ContractAssignment
raw_id_fields = ('user',)
def queryset(self, request):
qs = super(ContractAssignmentInline, self).queryset(request)
return qs.select_related()
class ContractHourInline(admin.TabularInline):
model = ContractHour
class ProjectContractAdmin(admin.ModelAdmin):
model = ProjectContract
list_display = ('name', 'start_date', 'end_date', 'status',
'contracted_hours', 'pending_hours',
'hours_assigned', 'hours_unassigned',
'hours_worked',
'type')
inlines = (ContractAssignmentInline, ContractHourInline)
list_filter = ('status', 'type')
filter_horizontal = ('projects',)
list_per_page = 20
search_fields = ('name', 'projects__name', 'projects__business__name')
def hours_unassigned(self, obj):
return obj.contracted_hours() - obj.hours_assigned
class HourGroupAdmin(admin.ModelAdmin):
model = HourGroup
list_display = ('name',)
list_filter = ('activities',)
ordering = ('order', 'name')
filter_horizontal = ('activities',)
admin.site.register(ProjectContract, ProjectContractAdmin)
admin.site.register(HourGroup, HourGroupAdmin)
admin.site.register(ContractHour)
Update Python/Django: Admin queryset -> get_querysetfrom django.contrib import admin
from timepiece.contracts.models import ProjectContract, ContractHour,\
ContractAssignment, HourGroup
class ContractAssignmentInline(admin.TabularInline):
model = ContractAssignment
raw_id_fields = ('user',)
def get_queryset(self, request):
qs = super(ContractAssignmentInline, self).get_queryset(request)
return qs.select_related()
class ContractHourInline(admin.TabularInline):
model = ContractHour
class ProjectContractAdmin(admin.ModelAdmin):
model = ProjectContract
list_display = ('name', 'start_date', 'end_date', 'status',
'contracted_hours', 'pending_hours',
'hours_assigned', 'hours_unassigned',
'hours_worked',
'type')
inlines = (ContractAssignmentInline, ContractHourInline)
list_filter = ('status', 'type')
filter_horizontal = ('projects',)
list_per_page = 20
search_fields = ('name', 'projects__name', 'projects__business__name')
def hours_unassigned(self, obj):
return obj.contracted_hours() - obj.hours_assigned
class HourGroupAdmin(admin.ModelAdmin):
model = HourGroup
list_display = ('name',)
list_filter = ('activities',)
ordering = ('order', 'name')
filter_horizontal = ('activities',)
admin.site.register(ProjectContract, ProjectContractAdmin)
admin.site.register(HourGroup, HourGroupAdmin)
admin.site.register(ContractHour)
|
<commit_before>from django.contrib import admin
from timepiece.contracts.models import ProjectContract, ContractHour,\
ContractAssignment, HourGroup
class ContractAssignmentInline(admin.TabularInline):
model = ContractAssignment
raw_id_fields = ('user',)
def queryset(self, request):
qs = super(ContractAssignmentInline, self).queryset(request)
return qs.select_related()
class ContractHourInline(admin.TabularInline):
model = ContractHour
class ProjectContractAdmin(admin.ModelAdmin):
model = ProjectContract
list_display = ('name', 'start_date', 'end_date', 'status',
'contracted_hours', 'pending_hours',
'hours_assigned', 'hours_unassigned',
'hours_worked',
'type')
inlines = (ContractAssignmentInline, ContractHourInline)
list_filter = ('status', 'type')
filter_horizontal = ('projects',)
list_per_page = 20
search_fields = ('name', 'projects__name', 'projects__business__name')
def hours_unassigned(self, obj):
return obj.contracted_hours() - obj.hours_assigned
class HourGroupAdmin(admin.ModelAdmin):
model = HourGroup
list_display = ('name',)
list_filter = ('activities',)
ordering = ('order', 'name')
filter_horizontal = ('activities',)
admin.site.register(ProjectContract, ProjectContractAdmin)
admin.site.register(HourGroup, HourGroupAdmin)
admin.site.register(ContractHour)
<commit_msg>Update Python/Django: Admin queryset -> get_queryset<commit_after>from django.contrib import admin
from timepiece.contracts.models import ProjectContract, ContractHour,\
ContractAssignment, HourGroup
class ContractAssignmentInline(admin.TabularInline):
model = ContractAssignment
raw_id_fields = ('user',)
def get_queryset(self, request):
qs = super(ContractAssignmentInline, self).get_queryset(request)
return qs.select_related()
class ContractHourInline(admin.TabularInline):
model = ContractHour
class ProjectContractAdmin(admin.ModelAdmin):
model = ProjectContract
list_display = ('name', 'start_date', 'end_date', 'status',
'contracted_hours', 'pending_hours',
'hours_assigned', 'hours_unassigned',
'hours_worked',
'type')
inlines = (ContractAssignmentInline, ContractHourInline)
list_filter = ('status', 'type')
filter_horizontal = ('projects',)
list_per_page = 20
search_fields = ('name', 'projects__name', 'projects__business__name')
def hours_unassigned(self, obj):
return obj.contracted_hours() - obj.hours_assigned
class HourGroupAdmin(admin.ModelAdmin):
model = HourGroup
list_display = ('name',)
list_filter = ('activities',)
ordering = ('order', 'name')
filter_horizontal = ('activities',)
admin.site.register(ProjectContract, ProjectContractAdmin)
admin.site.register(HourGroup, HourGroupAdmin)
admin.site.register(ContractHour)
|
93cb07ed61f17a1debbe353963120ab117598f3f
|
src/yunohost/utils/yunopaste.py
|
src/yunohost/utils/yunopaste.py
|
# -*- coding: utf-8 -*-
import requests
import json
import errno
from moulinette.core import MoulinetteError
def yunopaste(data):
paste_server = "https://paste.yunohost.org"
try:
r = requests.post("%s/documents" % paste_server, data=data, timeout=30)
except Exception as e:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s" % str(e))
if r.status_code != 200:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s" % r.text)
try:
url = json.loads(r.text)["key"]
except:
raise MoulinetteError(errno.EIO,
"Uhoh, couldn't parse the answer from paste.yunohost.org : %s" % r.text)
return "%s/raw/%s" % (paste_server, url)
|
# -*- coding: utf-8 -*-
import requests
import json
import errno
from moulinette.core import MoulinetteError
def yunopaste(data):
paste_server = "https://paste.yunohost.org"
try:
r = requests.post("%s/documents" % paste_server, data=data, timeout=30)
except Exception as e:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s" % str(e))
if r.status_code != 200:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s, %s" % (r.status_code, r.text))
try:
url = json.loads(r.text)["key"]
except:
raise MoulinetteError(errno.EIO,
"Uhoh, couldn't parse the answer from paste.yunohost.org : %s" % r.text)
return "%s/raw/%s" % (paste_server, url)
|
Add status code to error message
|
Add status code to error message
|
Python
|
agpl-3.0
|
YunoHost/yunohost,YunoHost/moulinette-yunohost,YunoHost/moulinette-yunohost,YunoHost/moulinette-yunohost,YunoHost/moulinette-yunohost,YunoHost/yunohost,YunoHost/moulinette-yunohost,YunoHost/yunohost,YunoHost/yunohost
|
# -*- coding: utf-8 -*-
import requests
import json
import errno
from moulinette.core import MoulinetteError
def yunopaste(data):
paste_server = "https://paste.yunohost.org"
try:
r = requests.post("%s/documents" % paste_server, data=data, timeout=30)
except Exception as e:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s" % str(e))
if r.status_code != 200:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s" % r.text)
try:
url = json.loads(r.text)["key"]
except:
raise MoulinetteError(errno.EIO,
"Uhoh, couldn't parse the answer from paste.yunohost.org : %s" % r.text)
return "%s/raw/%s" % (paste_server, url)
Add status code to error message
|
# -*- coding: utf-8 -*-
import requests
import json
import errno
from moulinette.core import MoulinetteError
def yunopaste(data):
paste_server = "https://paste.yunohost.org"
try:
r = requests.post("%s/documents" % paste_server, data=data, timeout=30)
except Exception as e:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s" % str(e))
if r.status_code != 200:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s, %s" % (r.status_code, r.text))
try:
url = json.loads(r.text)["key"]
except:
raise MoulinetteError(errno.EIO,
"Uhoh, couldn't parse the answer from paste.yunohost.org : %s" % r.text)
return "%s/raw/%s" % (paste_server, url)
|
<commit_before># -*- coding: utf-8 -*-
import requests
import json
import errno
from moulinette.core import MoulinetteError
def yunopaste(data):
paste_server = "https://paste.yunohost.org"
try:
r = requests.post("%s/documents" % paste_server, data=data, timeout=30)
except Exception as e:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s" % str(e))
if r.status_code != 200:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s" % r.text)
try:
url = json.loads(r.text)["key"]
except:
raise MoulinetteError(errno.EIO,
"Uhoh, couldn't parse the answer from paste.yunohost.org : %s" % r.text)
return "%s/raw/%s" % (paste_server, url)
<commit_msg>Add status code to error message<commit_after>
|
# -*- coding: utf-8 -*-
import requests
import json
import errno
from moulinette.core import MoulinetteError
def yunopaste(data):
paste_server = "https://paste.yunohost.org"
try:
r = requests.post("%s/documents" % paste_server, data=data, timeout=30)
except Exception as e:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s" % str(e))
if r.status_code != 200:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s, %s" % (r.status_code, r.text))
try:
url = json.loads(r.text)["key"]
except:
raise MoulinetteError(errno.EIO,
"Uhoh, couldn't parse the answer from paste.yunohost.org : %s" % r.text)
return "%s/raw/%s" % (paste_server, url)
|
# -*- coding: utf-8 -*-
import requests
import json
import errno
from moulinette.core import MoulinetteError
def yunopaste(data):
paste_server = "https://paste.yunohost.org"
try:
r = requests.post("%s/documents" % paste_server, data=data, timeout=30)
except Exception as e:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s" % str(e))
if r.status_code != 200:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s" % r.text)
try:
url = json.loads(r.text)["key"]
except:
raise MoulinetteError(errno.EIO,
"Uhoh, couldn't parse the answer from paste.yunohost.org : %s" % r.text)
return "%s/raw/%s" % (paste_server, url)
Add status code to error message# -*- coding: utf-8 -*-
import requests
import json
import errno
from moulinette.core import MoulinetteError
def yunopaste(data):
paste_server = "https://paste.yunohost.org"
try:
r = requests.post("%s/documents" % paste_server, data=data, timeout=30)
except Exception as e:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s" % str(e))
if r.status_code != 200:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s, %s" % (r.status_code, r.text))
try:
url = json.loads(r.text)["key"]
except:
raise MoulinetteError(errno.EIO,
"Uhoh, couldn't parse the answer from paste.yunohost.org : %s" % r.text)
return "%s/raw/%s" % (paste_server, url)
|
<commit_before># -*- coding: utf-8 -*-
import requests
import json
import errno
from moulinette.core import MoulinetteError
def yunopaste(data):
paste_server = "https://paste.yunohost.org"
try:
r = requests.post("%s/documents" % paste_server, data=data, timeout=30)
except Exception as e:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s" % str(e))
if r.status_code != 200:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s" % r.text)
try:
url = json.loads(r.text)["key"]
except:
raise MoulinetteError(errno.EIO,
"Uhoh, couldn't parse the answer from paste.yunohost.org : %s" % r.text)
return "%s/raw/%s" % (paste_server, url)
<commit_msg>Add status code to error message<commit_after># -*- coding: utf-8 -*-
import requests
import json
import errno
from moulinette.core import MoulinetteError
def yunopaste(data):
paste_server = "https://paste.yunohost.org"
try:
r = requests.post("%s/documents" % paste_server, data=data, timeout=30)
except Exception as e:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s" % str(e))
if r.status_code != 200:
raise MoulinetteError(errno.EIO,
"Something wrong happened while trying to paste data on paste.yunohost.org : %s, %s" % (r.status_code, r.text))
try:
url = json.loads(r.text)["key"]
except:
raise MoulinetteError(errno.EIO,
"Uhoh, couldn't parse the answer from paste.yunohost.org : %s" % r.text)
return "%s/raw/%s" % (paste_server, url)
|
f3eee368e13ee37048d52bde0d067efea057fef8
|
monkeylearn/extraction.py
|
monkeylearn/extraction.py
|
# -*- coding: utf-8 -*-
from __future__ import (
print_function, unicode_literals, division, absolute_import)
from six.moves import range
from monkeylearn.utils import SleepRequestsMixin, MonkeyLearnResponse, HandleErrorsMixin
from monkeylearn.settings import DEFAULT_BASE_ENDPOINT, DEFAULT_BATCH_SIZE
class Extraction(SleepRequestsMixin, HandleErrorsMixin):
def __init__(self, token, base_endpoint=DEFAULT_BASE_ENDPOINT):
self.token = token
self.endpoint = base_endpoint + 'extractors/'
def extract(self, module_id, text_list, batch_size=DEFAULT_BATCH_SIZE,
sleep_if_throttled=True):
text_list = list(text_list)
self.check_batch_limits(text_list, batch_size)
url = self.endpoint + module_id + '/extract/'
res = []
responses = []
for i in range(0, len(text_list), batch_size):
data = {
'text_list': text_list[i:i+batch_size]
}
response = self.make_request(url, 'POST', data, sleep_if_throttled)
self.handle_errors(response)
responses.append(response)
res.extend(response.json()['result'])
return MonkeyLearnResponse(res, responses)
|
# -*- coding: utf-8 -*-
from __future__ import (
print_function, unicode_literals, division, absolute_import)
from six.moves import range
from monkeylearn.utils import SleepRequestsMixin, MonkeyLearnResponse, HandleErrorsMixin
from monkeylearn.settings import DEFAULT_BASE_ENDPOINT, DEFAULT_BATCH_SIZE
class Extraction(SleepRequestsMixin, HandleErrorsMixin):
def __init__(self, token, base_endpoint=DEFAULT_BASE_ENDPOINT):
self.token = token
self.endpoint = base_endpoint + 'extractors/'
def extract(self, module_id, text_list, batch_size=DEFAULT_BATCH_SIZE,
sleep_if_throttled=True):
text_list = list(text_list)
self.check_batch_limits(text_list, batch_size)
url = self.endpoint + module_id + '/extract/'
res = []
responses = []
for i in range(0, len(text_list), batch_size):
data = {
'text_list': text_list[i:i+batch_size]
}
if kwargs is not None:
for key, value in kwargs.iteritems():
data[key] = value
response = self.make_request(url, 'POST', data, sleep_if_throttled)
self.handle_errors(response)
responses.append(response)
res.extend(response.json()['result'])
return MonkeyLearnResponse(res, responses)
|
Support for extra parameters in extractors
|
Support for extra parameters in extractors
|
Python
|
mit
|
monkeylearn/monkeylearn-python
|
# -*- coding: utf-8 -*-
from __future__ import (
print_function, unicode_literals, division, absolute_import)
from six.moves import range
from monkeylearn.utils import SleepRequestsMixin, MonkeyLearnResponse, HandleErrorsMixin
from monkeylearn.settings import DEFAULT_BASE_ENDPOINT, DEFAULT_BATCH_SIZE
class Extraction(SleepRequestsMixin, HandleErrorsMixin):
def __init__(self, token, base_endpoint=DEFAULT_BASE_ENDPOINT):
self.token = token
self.endpoint = base_endpoint + 'extractors/'
def extract(self, module_id, text_list, batch_size=DEFAULT_BATCH_SIZE,
sleep_if_throttled=True):
text_list = list(text_list)
self.check_batch_limits(text_list, batch_size)
url = self.endpoint + module_id + '/extract/'
res = []
responses = []
for i in range(0, len(text_list), batch_size):
data = {
'text_list': text_list[i:i+batch_size]
}
response = self.make_request(url, 'POST', data, sleep_if_throttled)
self.handle_errors(response)
responses.append(response)
res.extend(response.json()['result'])
return MonkeyLearnResponse(res, responses)
Support for extra parameters in extractors
|
# -*- coding: utf-8 -*-
from __future__ import (
print_function, unicode_literals, division, absolute_import)
from six.moves import range
from monkeylearn.utils import SleepRequestsMixin, MonkeyLearnResponse, HandleErrorsMixin
from monkeylearn.settings import DEFAULT_BASE_ENDPOINT, DEFAULT_BATCH_SIZE
class Extraction(SleepRequestsMixin, HandleErrorsMixin):
def __init__(self, token, base_endpoint=DEFAULT_BASE_ENDPOINT):
self.token = token
self.endpoint = base_endpoint + 'extractors/'
def extract(self, module_id, text_list, batch_size=DEFAULT_BATCH_SIZE,
sleep_if_throttled=True):
text_list = list(text_list)
self.check_batch_limits(text_list, batch_size)
url = self.endpoint + module_id + '/extract/'
res = []
responses = []
for i in range(0, len(text_list), batch_size):
data = {
'text_list': text_list[i:i+batch_size]
}
if kwargs is not None:
for key, value in kwargs.iteritems():
data[key] = value
response = self.make_request(url, 'POST', data, sleep_if_throttled)
self.handle_errors(response)
responses.append(response)
res.extend(response.json()['result'])
return MonkeyLearnResponse(res, responses)
|
<commit_before># -*- coding: utf-8 -*-
from __future__ import (
print_function, unicode_literals, division, absolute_import)
from six.moves import range
from monkeylearn.utils import SleepRequestsMixin, MonkeyLearnResponse, HandleErrorsMixin
from monkeylearn.settings import DEFAULT_BASE_ENDPOINT, DEFAULT_BATCH_SIZE
class Extraction(SleepRequestsMixin, HandleErrorsMixin):
def __init__(self, token, base_endpoint=DEFAULT_BASE_ENDPOINT):
self.token = token
self.endpoint = base_endpoint + 'extractors/'
def extract(self, module_id, text_list, batch_size=DEFAULT_BATCH_SIZE,
sleep_if_throttled=True):
text_list = list(text_list)
self.check_batch_limits(text_list, batch_size)
url = self.endpoint + module_id + '/extract/'
res = []
responses = []
for i in range(0, len(text_list), batch_size):
data = {
'text_list': text_list[i:i+batch_size]
}
response = self.make_request(url, 'POST', data, sleep_if_throttled)
self.handle_errors(response)
responses.append(response)
res.extend(response.json()['result'])
return MonkeyLearnResponse(res, responses)
<commit_msg>Support for extra parameters in extractors<commit_after>
|
# -*- coding: utf-8 -*-
from __future__ import (
print_function, unicode_literals, division, absolute_import)
from six.moves import range
from monkeylearn.utils import SleepRequestsMixin, MonkeyLearnResponse, HandleErrorsMixin
from monkeylearn.settings import DEFAULT_BASE_ENDPOINT, DEFAULT_BATCH_SIZE
class Extraction(SleepRequestsMixin, HandleErrorsMixin):
def __init__(self, token, base_endpoint=DEFAULT_BASE_ENDPOINT):
self.token = token
self.endpoint = base_endpoint + 'extractors/'
def extract(self, module_id, text_list, batch_size=DEFAULT_BATCH_SIZE,
sleep_if_throttled=True):
text_list = list(text_list)
self.check_batch_limits(text_list, batch_size)
url = self.endpoint + module_id + '/extract/'
res = []
responses = []
for i in range(0, len(text_list), batch_size):
data = {
'text_list': text_list[i:i+batch_size]
}
if kwargs is not None:
for key, value in kwargs.iteritems():
data[key] = value
response = self.make_request(url, 'POST', data, sleep_if_throttled)
self.handle_errors(response)
responses.append(response)
res.extend(response.json()['result'])
return MonkeyLearnResponse(res, responses)
|
# -*- coding: utf-8 -*-
from __future__ import (
print_function, unicode_literals, division, absolute_import)
from six.moves import range
from monkeylearn.utils import SleepRequestsMixin, MonkeyLearnResponse, HandleErrorsMixin
from monkeylearn.settings import DEFAULT_BASE_ENDPOINT, DEFAULT_BATCH_SIZE
class Extraction(SleepRequestsMixin, HandleErrorsMixin):
def __init__(self, token, base_endpoint=DEFAULT_BASE_ENDPOINT):
self.token = token
self.endpoint = base_endpoint + 'extractors/'
def extract(self, module_id, text_list, batch_size=DEFAULT_BATCH_SIZE,
sleep_if_throttled=True):
text_list = list(text_list)
self.check_batch_limits(text_list, batch_size)
url = self.endpoint + module_id + '/extract/'
res = []
responses = []
for i in range(0, len(text_list), batch_size):
data = {
'text_list': text_list[i:i+batch_size]
}
response = self.make_request(url, 'POST', data, sleep_if_throttled)
self.handle_errors(response)
responses.append(response)
res.extend(response.json()['result'])
return MonkeyLearnResponse(res, responses)
Support for extra parameters in extractors# -*- coding: utf-8 -*-
from __future__ import (
print_function, unicode_literals, division, absolute_import)
from six.moves import range
from monkeylearn.utils import SleepRequestsMixin, MonkeyLearnResponse, HandleErrorsMixin
from monkeylearn.settings import DEFAULT_BASE_ENDPOINT, DEFAULT_BATCH_SIZE
class Extraction(SleepRequestsMixin, HandleErrorsMixin):
def __init__(self, token, base_endpoint=DEFAULT_BASE_ENDPOINT):
self.token = token
self.endpoint = base_endpoint + 'extractors/'
def extract(self, module_id, text_list, batch_size=DEFAULT_BATCH_SIZE,
sleep_if_throttled=True):
text_list = list(text_list)
self.check_batch_limits(text_list, batch_size)
url = self.endpoint + module_id + '/extract/'
res = []
responses = []
for i in range(0, len(text_list), batch_size):
data = {
'text_list': text_list[i:i+batch_size]
}
if kwargs is not None:
for key, value in kwargs.iteritems():
data[key] = value
response = self.make_request(url, 'POST', data, sleep_if_throttled)
self.handle_errors(response)
responses.append(response)
res.extend(response.json()['result'])
return MonkeyLearnResponse(res, responses)
|
<commit_before># -*- coding: utf-8 -*-
from __future__ import (
print_function, unicode_literals, division, absolute_import)
from six.moves import range
from monkeylearn.utils import SleepRequestsMixin, MonkeyLearnResponse, HandleErrorsMixin
from monkeylearn.settings import DEFAULT_BASE_ENDPOINT, DEFAULT_BATCH_SIZE
class Extraction(SleepRequestsMixin, HandleErrorsMixin):
def __init__(self, token, base_endpoint=DEFAULT_BASE_ENDPOINT):
self.token = token
self.endpoint = base_endpoint + 'extractors/'
def extract(self, module_id, text_list, batch_size=DEFAULT_BATCH_SIZE,
sleep_if_throttled=True):
text_list = list(text_list)
self.check_batch_limits(text_list, batch_size)
url = self.endpoint + module_id + '/extract/'
res = []
responses = []
for i in range(0, len(text_list), batch_size):
data = {
'text_list': text_list[i:i+batch_size]
}
response = self.make_request(url, 'POST', data, sleep_if_throttled)
self.handle_errors(response)
responses.append(response)
res.extend(response.json()['result'])
return MonkeyLearnResponse(res, responses)
<commit_msg>Support for extra parameters in extractors<commit_after># -*- coding: utf-8 -*-
from __future__ import (
print_function, unicode_literals, division, absolute_import)
from six.moves import range
from monkeylearn.utils import SleepRequestsMixin, MonkeyLearnResponse, HandleErrorsMixin
from monkeylearn.settings import DEFAULT_BASE_ENDPOINT, DEFAULT_BATCH_SIZE
class Extraction(SleepRequestsMixin, HandleErrorsMixin):
def __init__(self, token, base_endpoint=DEFAULT_BASE_ENDPOINT):
self.token = token
self.endpoint = base_endpoint + 'extractors/'
def extract(self, module_id, text_list, batch_size=DEFAULT_BATCH_SIZE,
sleep_if_throttled=True):
text_list = list(text_list)
self.check_batch_limits(text_list, batch_size)
url = self.endpoint + module_id + '/extract/'
res = []
responses = []
for i in range(0, len(text_list), batch_size):
data = {
'text_list': text_list[i:i+batch_size]
}
if kwargs is not None:
for key, value in kwargs.iteritems():
data[key] = value
response = self.make_request(url, 'POST', data, sleep_if_throttled)
self.handle_errors(response)
responses.append(response)
res.extend(response.json()['result'])
return MonkeyLearnResponse(res, responses)
|
edd06989628e90d4fdfa98e4af84720d815322f9
|
pinax/likes/migrations/0001_initial.py
|
pinax/likes/migrations/0001_initial.py
|
# -*- coding: utf-8 -*-
# Generated by Django 1.9.1 on 2016-01-29 16:12
from __future__ import unicode_literals
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
dependencies = [
('contenttypes', '0002_remove_content_type_name'),
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
]
operations = [
migrations.CreateModel(
name='Like',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('receiver_object_id', models.PositiveIntegerField()),
('timestamp', models.DateTimeField(default=django.utils.timezone.now)),
('receiver_content_type', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='contenttypes.ContentType')),
('sender', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='liking', to=settings.AUTH_USER_MODEL)),
],
),
migrations.AlterUniqueTogether(
name='like',
unique_together=set([('sender', 'receiver_content_type', 'receiver_object_id')]),
),
]
|
# -*- coding: utf-8 -*-
# Generated by Django 1.9.1 on 2016-01-29 16:12
from __future__ import unicode_literals
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
dependencies = [
('contenttypes', '0002_remove_content_type_name'),
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
]
operations = [
migrations.CreateModel(
name='Like',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('receiver_object_id', models.PositiveIntegerField()),
('timestamp', models.DateTimeField(default=django.utils.timezone.now)),
('receiver_content_type', models.ForeignKey('contenttypes.ContentType', on_delete=django.db.models.deletion.CASCADE)),
('sender', models.ForeignKey(settings.AUTH_USER_MODEL, on_delete=django.db.models.deletion.CASCADE, related_name='liking')),
],
),
migrations.AlterUniqueTogether(
name='like',
unique_together=set([('sender', 'receiver_content_type', 'receiver_object_id')]),
),
]
|
Drop features removed in Django 2.0
|
Drop features removed in Django 2.0
Field.rel and Field.remote_field.to are removed
https://docs.djangoproject.com/en/dev/releases/2.0/#features-removed-in-2-0
|
Python
|
mit
|
pinax/pinax-likes
|
# -*- coding: utf-8 -*-
# Generated by Django 1.9.1 on 2016-01-29 16:12
from __future__ import unicode_literals
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
dependencies = [
('contenttypes', '0002_remove_content_type_name'),
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
]
operations = [
migrations.CreateModel(
name='Like',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('receiver_object_id', models.PositiveIntegerField()),
('timestamp', models.DateTimeField(default=django.utils.timezone.now)),
('receiver_content_type', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='contenttypes.ContentType')),
('sender', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='liking', to=settings.AUTH_USER_MODEL)),
],
),
migrations.AlterUniqueTogether(
name='like',
unique_together=set([('sender', 'receiver_content_type', 'receiver_object_id')]),
),
]
Drop features removed in Django 2.0
Field.rel and Field.remote_field.to are removed
https://docs.djangoproject.com/en/dev/releases/2.0/#features-removed-in-2-0
|
# -*- coding: utf-8 -*-
# Generated by Django 1.9.1 on 2016-01-29 16:12
from __future__ import unicode_literals
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
dependencies = [
('contenttypes', '0002_remove_content_type_name'),
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
]
operations = [
migrations.CreateModel(
name='Like',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('receiver_object_id', models.PositiveIntegerField()),
('timestamp', models.DateTimeField(default=django.utils.timezone.now)),
('receiver_content_type', models.ForeignKey('contenttypes.ContentType', on_delete=django.db.models.deletion.CASCADE)),
('sender', models.ForeignKey(settings.AUTH_USER_MODEL, on_delete=django.db.models.deletion.CASCADE, related_name='liking')),
],
),
migrations.AlterUniqueTogether(
name='like',
unique_together=set([('sender', 'receiver_content_type', 'receiver_object_id')]),
),
]
|
<commit_before># -*- coding: utf-8 -*-
# Generated by Django 1.9.1 on 2016-01-29 16:12
from __future__ import unicode_literals
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
dependencies = [
('contenttypes', '0002_remove_content_type_name'),
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
]
operations = [
migrations.CreateModel(
name='Like',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('receiver_object_id', models.PositiveIntegerField()),
('timestamp', models.DateTimeField(default=django.utils.timezone.now)),
('receiver_content_type', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='contenttypes.ContentType')),
('sender', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='liking', to=settings.AUTH_USER_MODEL)),
],
),
migrations.AlterUniqueTogether(
name='like',
unique_together=set([('sender', 'receiver_content_type', 'receiver_object_id')]),
),
]
<commit_msg>Drop features removed in Django 2.0
Field.rel and Field.remote_field.to are removed
https://docs.djangoproject.com/en/dev/releases/2.0/#features-removed-in-2-0<commit_after>
|
# -*- coding: utf-8 -*-
# Generated by Django 1.9.1 on 2016-01-29 16:12
from __future__ import unicode_literals
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
dependencies = [
('contenttypes', '0002_remove_content_type_name'),
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
]
operations = [
migrations.CreateModel(
name='Like',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('receiver_object_id', models.PositiveIntegerField()),
('timestamp', models.DateTimeField(default=django.utils.timezone.now)),
('receiver_content_type', models.ForeignKey('contenttypes.ContentType', on_delete=django.db.models.deletion.CASCADE)),
('sender', models.ForeignKey(settings.AUTH_USER_MODEL, on_delete=django.db.models.deletion.CASCADE, related_name='liking')),
],
),
migrations.AlterUniqueTogether(
name='like',
unique_together=set([('sender', 'receiver_content_type', 'receiver_object_id')]),
),
]
|
# -*- coding: utf-8 -*-
# Generated by Django 1.9.1 on 2016-01-29 16:12
from __future__ import unicode_literals
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
dependencies = [
('contenttypes', '0002_remove_content_type_name'),
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
]
operations = [
migrations.CreateModel(
name='Like',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('receiver_object_id', models.PositiveIntegerField()),
('timestamp', models.DateTimeField(default=django.utils.timezone.now)),
('receiver_content_type', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='contenttypes.ContentType')),
('sender', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='liking', to=settings.AUTH_USER_MODEL)),
],
),
migrations.AlterUniqueTogether(
name='like',
unique_together=set([('sender', 'receiver_content_type', 'receiver_object_id')]),
),
]
Drop features removed in Django 2.0
Field.rel and Field.remote_field.to are removed
https://docs.djangoproject.com/en/dev/releases/2.0/#features-removed-in-2-0# -*- coding: utf-8 -*-
# Generated by Django 1.9.1 on 2016-01-29 16:12
from __future__ import unicode_literals
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
dependencies = [
('contenttypes', '0002_remove_content_type_name'),
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
]
operations = [
migrations.CreateModel(
name='Like',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('receiver_object_id', models.PositiveIntegerField()),
('timestamp', models.DateTimeField(default=django.utils.timezone.now)),
('receiver_content_type', models.ForeignKey('contenttypes.ContentType', on_delete=django.db.models.deletion.CASCADE)),
('sender', models.ForeignKey(settings.AUTH_USER_MODEL, on_delete=django.db.models.deletion.CASCADE, related_name='liking')),
],
),
migrations.AlterUniqueTogether(
name='like',
unique_together=set([('sender', 'receiver_content_type', 'receiver_object_id')]),
),
]
|
<commit_before># -*- coding: utf-8 -*-
# Generated by Django 1.9.1 on 2016-01-29 16:12
from __future__ import unicode_literals
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
dependencies = [
('contenttypes', '0002_remove_content_type_name'),
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
]
operations = [
migrations.CreateModel(
name='Like',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('receiver_object_id', models.PositiveIntegerField()),
('timestamp', models.DateTimeField(default=django.utils.timezone.now)),
('receiver_content_type', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='contenttypes.ContentType')),
('sender', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='liking', to=settings.AUTH_USER_MODEL)),
],
),
migrations.AlterUniqueTogether(
name='like',
unique_together=set([('sender', 'receiver_content_type', 'receiver_object_id')]),
),
]
<commit_msg>Drop features removed in Django 2.0
Field.rel and Field.remote_field.to are removed
https://docs.djangoproject.com/en/dev/releases/2.0/#features-removed-in-2-0<commit_after># -*- coding: utf-8 -*-
# Generated by Django 1.9.1 on 2016-01-29 16:12
from __future__ import unicode_literals
from django.conf import settings
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
class Migration(migrations.Migration):
initial = True
dependencies = [
('contenttypes', '0002_remove_content_type_name'),
migrations.swappable_dependency(settings.AUTH_USER_MODEL),
]
operations = [
migrations.CreateModel(
name='Like',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('receiver_object_id', models.PositiveIntegerField()),
('timestamp', models.DateTimeField(default=django.utils.timezone.now)),
('receiver_content_type', models.ForeignKey('contenttypes.ContentType', on_delete=django.db.models.deletion.CASCADE)),
('sender', models.ForeignKey(settings.AUTH_USER_MODEL, on_delete=django.db.models.deletion.CASCADE, related_name='liking')),
],
),
migrations.AlterUniqueTogether(
name='like',
unique_together=set([('sender', 'receiver_content_type', 'receiver_object_id')]),
),
]
|
c9cb55a4a9f3409a3c22edd0d5a8b6bfbdca1208
|
mopidy_somafm/__init__.py
|
mopidy_somafm/__init__.py
|
from __future__ import unicode_literals
import os
from mopidy import config, exceptions, ext
__version__ = '0.3.0'
class Extension(ext.Extension):
dist_name = 'Mopidy-SomaFM'
ext_name = 'somafm'
version = __version__
def get_default_config(self):
conf_file = os.path.join(os.path.dirname(__file__), 'ext.conf')
return config.read(conf_file)
def get_config_schema(self):
schema = super(Extension, self).get_config_schema()
return schema
def validate_environment(self):
try:
import requests
except ImportError as e:
raise ExtensionError('Library requests not found', e)
def get_backend_classes(self):
from .actor import SomaFMBackend
return [SomaFMBackend]
|
from __future__ import unicode_literals
import os
from mopidy import config, ext
__version__ = '0.3.0'
class Extension(ext.Extension):
dist_name = 'Mopidy-SomaFM'
ext_name = 'somafm'
version = __version__
def get_default_config(self):
conf_file = os.path.join(os.path.dirname(__file__), 'ext.conf')
return config.read(conf_file)
def get_config_schema(self):
schema = super(Extension, self).get_config_schema()
return schema
def get_backend_classes(self):
from .actor import SomaFMBackend
return [SomaFMBackend]
|
Remove dependency check done by Mopidy
|
Remove dependency check done by Mopidy
|
Python
|
mit
|
AlexandrePTJ/mopidy-somafm
|
from __future__ import unicode_literals
import os
from mopidy import config, exceptions, ext
__version__ = '0.3.0'
class Extension(ext.Extension):
dist_name = 'Mopidy-SomaFM'
ext_name = 'somafm'
version = __version__
def get_default_config(self):
conf_file = os.path.join(os.path.dirname(__file__), 'ext.conf')
return config.read(conf_file)
def get_config_schema(self):
schema = super(Extension, self).get_config_schema()
return schema
def validate_environment(self):
try:
import requests
except ImportError as e:
raise ExtensionError('Library requests not found', e)
def get_backend_classes(self):
from .actor import SomaFMBackend
return [SomaFMBackend]
Remove dependency check done by Mopidy
|
from __future__ import unicode_literals
import os
from mopidy import config, ext
__version__ = '0.3.0'
class Extension(ext.Extension):
dist_name = 'Mopidy-SomaFM'
ext_name = 'somafm'
version = __version__
def get_default_config(self):
conf_file = os.path.join(os.path.dirname(__file__), 'ext.conf')
return config.read(conf_file)
def get_config_schema(self):
schema = super(Extension, self).get_config_schema()
return schema
def get_backend_classes(self):
from .actor import SomaFMBackend
return [SomaFMBackend]
|
<commit_before>from __future__ import unicode_literals
import os
from mopidy import config, exceptions, ext
__version__ = '0.3.0'
class Extension(ext.Extension):
dist_name = 'Mopidy-SomaFM'
ext_name = 'somafm'
version = __version__
def get_default_config(self):
conf_file = os.path.join(os.path.dirname(__file__), 'ext.conf')
return config.read(conf_file)
def get_config_schema(self):
schema = super(Extension, self).get_config_schema()
return schema
def validate_environment(self):
try:
import requests
except ImportError as e:
raise ExtensionError('Library requests not found', e)
def get_backend_classes(self):
from .actor import SomaFMBackend
return [SomaFMBackend]
<commit_msg>Remove dependency check done by Mopidy<commit_after>
|
from __future__ import unicode_literals
import os
from mopidy import config, ext
__version__ = '0.3.0'
class Extension(ext.Extension):
dist_name = 'Mopidy-SomaFM'
ext_name = 'somafm'
version = __version__
def get_default_config(self):
conf_file = os.path.join(os.path.dirname(__file__), 'ext.conf')
return config.read(conf_file)
def get_config_schema(self):
schema = super(Extension, self).get_config_schema()
return schema
def get_backend_classes(self):
from .actor import SomaFMBackend
return [SomaFMBackend]
|
from __future__ import unicode_literals
import os
from mopidy import config, exceptions, ext
__version__ = '0.3.0'
class Extension(ext.Extension):
dist_name = 'Mopidy-SomaFM'
ext_name = 'somafm'
version = __version__
def get_default_config(self):
conf_file = os.path.join(os.path.dirname(__file__), 'ext.conf')
return config.read(conf_file)
def get_config_schema(self):
schema = super(Extension, self).get_config_schema()
return schema
def validate_environment(self):
try:
import requests
except ImportError as e:
raise ExtensionError('Library requests not found', e)
def get_backend_classes(self):
from .actor import SomaFMBackend
return [SomaFMBackend]
Remove dependency check done by Mopidyfrom __future__ import unicode_literals
import os
from mopidy import config, ext
__version__ = '0.3.0'
class Extension(ext.Extension):
dist_name = 'Mopidy-SomaFM'
ext_name = 'somafm'
version = __version__
def get_default_config(self):
conf_file = os.path.join(os.path.dirname(__file__), 'ext.conf')
return config.read(conf_file)
def get_config_schema(self):
schema = super(Extension, self).get_config_schema()
return schema
def get_backend_classes(self):
from .actor import SomaFMBackend
return [SomaFMBackend]
|
<commit_before>from __future__ import unicode_literals
import os
from mopidy import config, exceptions, ext
__version__ = '0.3.0'
class Extension(ext.Extension):
dist_name = 'Mopidy-SomaFM'
ext_name = 'somafm'
version = __version__
def get_default_config(self):
conf_file = os.path.join(os.path.dirname(__file__), 'ext.conf')
return config.read(conf_file)
def get_config_schema(self):
schema = super(Extension, self).get_config_schema()
return schema
def validate_environment(self):
try:
import requests
except ImportError as e:
raise ExtensionError('Library requests not found', e)
def get_backend_classes(self):
from .actor import SomaFMBackend
return [SomaFMBackend]
<commit_msg>Remove dependency check done by Mopidy<commit_after>from __future__ import unicode_literals
import os
from mopidy import config, ext
__version__ = '0.3.0'
class Extension(ext.Extension):
dist_name = 'Mopidy-SomaFM'
ext_name = 'somafm'
version = __version__
def get_default_config(self):
conf_file = os.path.join(os.path.dirname(__file__), 'ext.conf')
return config.read(conf_file)
def get_config_schema(self):
schema = super(Extension, self).get_config_schema()
return schema
def get_backend_classes(self):
from .actor import SomaFMBackend
return [SomaFMBackend]
|
6894db57f74cf4c813e470d9cee1def9cf14cc3d
|
megaprojects/scripts.py
|
megaprojects/scripts.py
|
def migrate_posts_to_articles():
from django.core.files import base
from articles.models import Article, Image
from blog.models import Post
for p in Post.objects.all():
a = Article()
a.author = p.author
a.body = p.body
a.enable_comments = p.enable_comments
a.pubdate = p.pubdate
a.reviewed = p.reviewed
a.title = p.title
a.save()
if p.status:
a.status = 'p'
else:
a.status = 'd'
for pi in p.image_set.all():
ai = Image()
ai.article = a
ai.image = base.ContentFile(pi.image.read())
ai.reviewed = pi.reviewed
ai.shortuuid = pi.shortuuid
ai.status = pi.status
ai.thumbnail = pi.thumbnail
ai.title = pi.title
ai.save()
|
def migrate_posts_to_articles():
from articles.models import Article
from blog.models import Post
for p in Post.objects.all():
try:
Article.objects.get(shortuuid=p.shortuuid)
continue
except Article.DoesNotExist:
a = Article()
a.author = p.author
a.body = p.body
a.changed = p.changed
a.created = p.created
a.enable_comments = p.enable_comments
a.kind = Article.KIND_BLOG
a.pubdate = p.pubdate
a.reviewed = p.reviewed
a.shortuuid = p.shortuuid
a.slug = p.slug
a.status = Article.STATUS_PUBLISHED if p.status else Article.STATUS_DRAFT
a.title = p.title
a.uuid = p.uuid
a.save()
def migrate_post_images_to_article_images():
from django.core.files import base
from articles.models import Article, Image as ArticleImage
from blog.models import Post, Image as PostImage
for pi in PostImage.objects.all():
try:
a = Article.objects.get(
kind=Article.KIND_BLOG, shortuuid=pi.post.shortuuid)
try:
ai = ArticleImage()
ai.article = a
ai.changed = pi.changed
ai.created = pi.created
ai.image = base.ContentFile(pi.image.read())
ai.reviewed = pi.reviewed
ai.save()
ai.shortuuid = pi.shortuuid
ai.status = pi.status
ai.thumbnail = pi.thumbnail
ai.title = pi.title
ai.uuid = pi.uuid
ai.save()
except IOError, e:
print e
except Article.DoesNotExist, e:
print e
|
Update post -> article migration script, include all fields
|
Update post -> article migration script, include all fields
|
Python
|
apache-2.0
|
megaprojectske/megaprojects.co.ke,megaprojectske/megaprojects.co.ke,megaprojectske/megaprojects.co.ke
|
def migrate_posts_to_articles():
from django.core.files import base
from articles.models import Article, Image
from blog.models import Post
for p in Post.objects.all():
a = Article()
a.author = p.author
a.body = p.body
a.enable_comments = p.enable_comments
a.pubdate = p.pubdate
a.reviewed = p.reviewed
a.title = p.title
a.save()
if p.status:
a.status = 'p'
else:
a.status = 'd'
for pi in p.image_set.all():
ai = Image()
ai.article = a
ai.image = base.ContentFile(pi.image.read())
ai.reviewed = pi.reviewed
ai.shortuuid = pi.shortuuid
ai.status = pi.status
ai.thumbnail = pi.thumbnail
ai.title = pi.title
ai.save()
Update post -> article migration script, include all fields
|
def migrate_posts_to_articles():
from articles.models import Article
from blog.models import Post
for p in Post.objects.all():
try:
Article.objects.get(shortuuid=p.shortuuid)
continue
except Article.DoesNotExist:
a = Article()
a.author = p.author
a.body = p.body
a.changed = p.changed
a.created = p.created
a.enable_comments = p.enable_comments
a.kind = Article.KIND_BLOG
a.pubdate = p.pubdate
a.reviewed = p.reviewed
a.shortuuid = p.shortuuid
a.slug = p.slug
a.status = Article.STATUS_PUBLISHED if p.status else Article.STATUS_DRAFT
a.title = p.title
a.uuid = p.uuid
a.save()
def migrate_post_images_to_article_images():
from django.core.files import base
from articles.models import Article, Image as ArticleImage
from blog.models import Post, Image as PostImage
for pi in PostImage.objects.all():
try:
a = Article.objects.get(
kind=Article.KIND_BLOG, shortuuid=pi.post.shortuuid)
try:
ai = ArticleImage()
ai.article = a
ai.changed = pi.changed
ai.created = pi.created
ai.image = base.ContentFile(pi.image.read())
ai.reviewed = pi.reviewed
ai.save()
ai.shortuuid = pi.shortuuid
ai.status = pi.status
ai.thumbnail = pi.thumbnail
ai.title = pi.title
ai.uuid = pi.uuid
ai.save()
except IOError, e:
print e
except Article.DoesNotExist, e:
print e
|
<commit_before>def migrate_posts_to_articles():
from django.core.files import base
from articles.models import Article, Image
from blog.models import Post
for p in Post.objects.all():
a = Article()
a.author = p.author
a.body = p.body
a.enable_comments = p.enable_comments
a.pubdate = p.pubdate
a.reviewed = p.reviewed
a.title = p.title
a.save()
if p.status:
a.status = 'p'
else:
a.status = 'd'
for pi in p.image_set.all():
ai = Image()
ai.article = a
ai.image = base.ContentFile(pi.image.read())
ai.reviewed = pi.reviewed
ai.shortuuid = pi.shortuuid
ai.status = pi.status
ai.thumbnail = pi.thumbnail
ai.title = pi.title
ai.save()
<commit_msg>Update post -> article migration script, include all fields<commit_after>
|
def migrate_posts_to_articles():
from articles.models import Article
from blog.models import Post
for p in Post.objects.all():
try:
Article.objects.get(shortuuid=p.shortuuid)
continue
except Article.DoesNotExist:
a = Article()
a.author = p.author
a.body = p.body
a.changed = p.changed
a.created = p.created
a.enable_comments = p.enable_comments
a.kind = Article.KIND_BLOG
a.pubdate = p.pubdate
a.reviewed = p.reviewed
a.shortuuid = p.shortuuid
a.slug = p.slug
a.status = Article.STATUS_PUBLISHED if p.status else Article.STATUS_DRAFT
a.title = p.title
a.uuid = p.uuid
a.save()
def migrate_post_images_to_article_images():
from django.core.files import base
from articles.models import Article, Image as ArticleImage
from blog.models import Post, Image as PostImage
for pi in PostImage.objects.all():
try:
a = Article.objects.get(
kind=Article.KIND_BLOG, shortuuid=pi.post.shortuuid)
try:
ai = ArticleImage()
ai.article = a
ai.changed = pi.changed
ai.created = pi.created
ai.image = base.ContentFile(pi.image.read())
ai.reviewed = pi.reviewed
ai.save()
ai.shortuuid = pi.shortuuid
ai.status = pi.status
ai.thumbnail = pi.thumbnail
ai.title = pi.title
ai.uuid = pi.uuid
ai.save()
except IOError, e:
print e
except Article.DoesNotExist, e:
print e
|
def migrate_posts_to_articles():
from django.core.files import base
from articles.models import Article, Image
from blog.models import Post
for p in Post.objects.all():
a = Article()
a.author = p.author
a.body = p.body
a.enable_comments = p.enable_comments
a.pubdate = p.pubdate
a.reviewed = p.reviewed
a.title = p.title
a.save()
if p.status:
a.status = 'p'
else:
a.status = 'd'
for pi in p.image_set.all():
ai = Image()
ai.article = a
ai.image = base.ContentFile(pi.image.read())
ai.reviewed = pi.reviewed
ai.shortuuid = pi.shortuuid
ai.status = pi.status
ai.thumbnail = pi.thumbnail
ai.title = pi.title
ai.save()
Update post -> article migration script, include all fieldsdef migrate_posts_to_articles():
from articles.models import Article
from blog.models import Post
for p in Post.objects.all():
try:
Article.objects.get(shortuuid=p.shortuuid)
continue
except Article.DoesNotExist:
a = Article()
a.author = p.author
a.body = p.body
a.changed = p.changed
a.created = p.created
a.enable_comments = p.enable_comments
a.kind = Article.KIND_BLOG
a.pubdate = p.pubdate
a.reviewed = p.reviewed
a.shortuuid = p.shortuuid
a.slug = p.slug
a.status = Article.STATUS_PUBLISHED if p.status else Article.STATUS_DRAFT
a.title = p.title
a.uuid = p.uuid
a.save()
def migrate_post_images_to_article_images():
from django.core.files import base
from articles.models import Article, Image as ArticleImage
from blog.models import Post, Image as PostImage
for pi in PostImage.objects.all():
try:
a = Article.objects.get(
kind=Article.KIND_BLOG, shortuuid=pi.post.shortuuid)
try:
ai = ArticleImage()
ai.article = a
ai.changed = pi.changed
ai.created = pi.created
ai.image = base.ContentFile(pi.image.read())
ai.reviewed = pi.reviewed
ai.save()
ai.shortuuid = pi.shortuuid
ai.status = pi.status
ai.thumbnail = pi.thumbnail
ai.title = pi.title
ai.uuid = pi.uuid
ai.save()
except IOError, e:
print e
except Article.DoesNotExist, e:
print e
|
<commit_before>def migrate_posts_to_articles():
from django.core.files import base
from articles.models import Article, Image
from blog.models import Post
for p in Post.objects.all():
a = Article()
a.author = p.author
a.body = p.body
a.enable_comments = p.enable_comments
a.pubdate = p.pubdate
a.reviewed = p.reviewed
a.title = p.title
a.save()
if p.status:
a.status = 'p'
else:
a.status = 'd'
for pi in p.image_set.all():
ai = Image()
ai.article = a
ai.image = base.ContentFile(pi.image.read())
ai.reviewed = pi.reviewed
ai.shortuuid = pi.shortuuid
ai.status = pi.status
ai.thumbnail = pi.thumbnail
ai.title = pi.title
ai.save()
<commit_msg>Update post -> article migration script, include all fields<commit_after>def migrate_posts_to_articles():
from articles.models import Article
from blog.models import Post
for p in Post.objects.all():
try:
Article.objects.get(shortuuid=p.shortuuid)
continue
except Article.DoesNotExist:
a = Article()
a.author = p.author
a.body = p.body
a.changed = p.changed
a.created = p.created
a.enable_comments = p.enable_comments
a.kind = Article.KIND_BLOG
a.pubdate = p.pubdate
a.reviewed = p.reviewed
a.shortuuid = p.shortuuid
a.slug = p.slug
a.status = Article.STATUS_PUBLISHED if p.status else Article.STATUS_DRAFT
a.title = p.title
a.uuid = p.uuid
a.save()
def migrate_post_images_to_article_images():
from django.core.files import base
from articles.models import Article, Image as ArticleImage
from blog.models import Post, Image as PostImage
for pi in PostImage.objects.all():
try:
a = Article.objects.get(
kind=Article.KIND_BLOG, shortuuid=pi.post.shortuuid)
try:
ai = ArticleImage()
ai.article = a
ai.changed = pi.changed
ai.created = pi.created
ai.image = base.ContentFile(pi.image.read())
ai.reviewed = pi.reviewed
ai.save()
ai.shortuuid = pi.shortuuid
ai.status = pi.status
ai.thumbnail = pi.thumbnail
ai.title = pi.title
ai.uuid = pi.uuid
ai.save()
except IOError, e:
print e
except Article.DoesNotExist, e:
print e
|
0be963472bc4ecaafa42872c9fffef5b8f3426f3
|
synapse/replication/slave/storage/directory.py
|
synapse/replication/slave/storage/directory.py
|
# -*- coding: utf-8 -*-
# Copyright 2015, 2016 OpenMarket Ltd
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from ._base import BaseSlavedStore
from synapse.storage.directory import DirectoryStore
class DirectoryStore(BaseSlavedStore):
get_aliases_for_room = DirectoryStore.__dict__[
"get_aliases_for_room"
].orig
|
# -*- coding: utf-8 -*-
# Copyright 2015, 2016 OpenMarket Ltd
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from ._base import BaseSlavedStore
from synapse.storage.directory import DirectoryStore
class DirectoryStore(BaseSlavedStore):
get_aliases_for_room = DirectoryStore.__dict__[
"get_aliases_for_room"
]
|
Use cached version of get_aliases_for_room
|
Use cached version of get_aliases_for_room
|
Python
|
apache-2.0
|
matrix-org/synapse,TribeMedia/synapse,TribeMedia/synapse,TribeMedia/synapse,matrix-org/synapse,matrix-org/synapse,TribeMedia/synapse,matrix-org/synapse,matrix-org/synapse,matrix-org/synapse,TribeMedia/synapse
|
# -*- coding: utf-8 -*-
# Copyright 2015, 2016 OpenMarket Ltd
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from ._base import BaseSlavedStore
from synapse.storage.directory import DirectoryStore
class DirectoryStore(BaseSlavedStore):
get_aliases_for_room = DirectoryStore.__dict__[
"get_aliases_for_room"
].orig
Use cached version of get_aliases_for_room
|
# -*- coding: utf-8 -*-
# Copyright 2015, 2016 OpenMarket Ltd
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from ._base import BaseSlavedStore
from synapse.storage.directory import DirectoryStore
class DirectoryStore(BaseSlavedStore):
get_aliases_for_room = DirectoryStore.__dict__[
"get_aliases_for_room"
]
|
<commit_before># -*- coding: utf-8 -*-
# Copyright 2015, 2016 OpenMarket Ltd
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from ._base import BaseSlavedStore
from synapse.storage.directory import DirectoryStore
class DirectoryStore(BaseSlavedStore):
get_aliases_for_room = DirectoryStore.__dict__[
"get_aliases_for_room"
].orig
<commit_msg>Use cached version of get_aliases_for_room<commit_after>
|
# -*- coding: utf-8 -*-
# Copyright 2015, 2016 OpenMarket Ltd
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from ._base import BaseSlavedStore
from synapse.storage.directory import DirectoryStore
class DirectoryStore(BaseSlavedStore):
get_aliases_for_room = DirectoryStore.__dict__[
"get_aliases_for_room"
]
|
# -*- coding: utf-8 -*-
# Copyright 2015, 2016 OpenMarket Ltd
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from ._base import BaseSlavedStore
from synapse.storage.directory import DirectoryStore
class DirectoryStore(BaseSlavedStore):
get_aliases_for_room = DirectoryStore.__dict__[
"get_aliases_for_room"
].orig
Use cached version of get_aliases_for_room# -*- coding: utf-8 -*-
# Copyright 2015, 2016 OpenMarket Ltd
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from ._base import BaseSlavedStore
from synapse.storage.directory import DirectoryStore
class DirectoryStore(BaseSlavedStore):
get_aliases_for_room = DirectoryStore.__dict__[
"get_aliases_for_room"
]
|
<commit_before># -*- coding: utf-8 -*-
# Copyright 2015, 2016 OpenMarket Ltd
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from ._base import BaseSlavedStore
from synapse.storage.directory import DirectoryStore
class DirectoryStore(BaseSlavedStore):
get_aliases_for_room = DirectoryStore.__dict__[
"get_aliases_for_room"
].orig
<commit_msg>Use cached version of get_aliases_for_room<commit_after># -*- coding: utf-8 -*-
# Copyright 2015, 2016 OpenMarket Ltd
#
# 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, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
from ._base import BaseSlavedStore
from synapse.storage.directory import DirectoryStore
class DirectoryStore(BaseSlavedStore):
get_aliases_for_room = DirectoryStore.__dict__[
"get_aliases_for_room"
]
|
ce05cf03738572bbe52de0e649ad25480a1f65f1
|
networkzero/__init__.py
|
networkzero/__init__.py
|
from .discovery import advertise, unadvertise, discover
from .messenger import (
send_command, wait_for_command,
send_request, wait_for_request, send_reply,
publish_news, wait_for_news
)
from .core import address
|
# -*- coding: utf-8 -*-
"""networkzero - easy network discovery & messaging
Aimed at a classrom or club situation, networkzero makes it simpler to
have several machines or several processes on one machine discovering
each other and talking across a network. Typical examples would include:
* Sending commands to a robot
* Sending scores to a scoreboard
* Having a remote sensor ping a central controller
* A peer-to-peer chat / instant messenger
Example code:
[Computer 1]:
import networkzero as nw0
echo_address = nw0.advertise("echo")
while True:
name = nw0.wait_for_request(echo_address)
nw0.send_reply(echo_address, "Hello " + name)
[Computer 2]:
import networkzero as nw0
echo_address = nw0.discover("echo")
print(nw0.send_request(echo_address, "Alice"))
print(nw0.send_request(echo_address, "Bob"))
"""
from .discovery import advertise, unadvertise, discover
from .messenger import (
send_command, wait_for_command,
send_request, wait_for_request, send_reply,
publish_news, wait_for_news
)
from .core import address
|
Put some high-level module docs together, including a simple example
|
Put some high-level module docs together, including a simple example
|
Python
|
mit
|
tjguk/networkzero,tjguk/networkzero,tjguk/networkzero
|
from .discovery import advertise, unadvertise, discover
from .messenger import (
send_command, wait_for_command,
send_request, wait_for_request, send_reply,
publish_news, wait_for_news
)
from .core import addressPut some high-level module docs together, including a simple example
|
# -*- coding: utf-8 -*-
"""networkzero - easy network discovery & messaging
Aimed at a classrom or club situation, networkzero makes it simpler to
have several machines or several processes on one machine discovering
each other and talking across a network. Typical examples would include:
* Sending commands to a robot
* Sending scores to a scoreboard
* Having a remote sensor ping a central controller
* A peer-to-peer chat / instant messenger
Example code:
[Computer 1]:
import networkzero as nw0
echo_address = nw0.advertise("echo")
while True:
name = nw0.wait_for_request(echo_address)
nw0.send_reply(echo_address, "Hello " + name)
[Computer 2]:
import networkzero as nw0
echo_address = nw0.discover("echo")
print(nw0.send_request(echo_address, "Alice"))
print(nw0.send_request(echo_address, "Bob"))
"""
from .discovery import advertise, unadvertise, discover
from .messenger import (
send_command, wait_for_command,
send_request, wait_for_request, send_reply,
publish_news, wait_for_news
)
from .core import address
|
<commit_before>from .discovery import advertise, unadvertise, discover
from .messenger import (
send_command, wait_for_command,
send_request, wait_for_request, send_reply,
publish_news, wait_for_news
)
from .core import address<commit_msg>Put some high-level module docs together, including a simple example<commit_after>
|
# -*- coding: utf-8 -*-
"""networkzero - easy network discovery & messaging
Aimed at a classrom or club situation, networkzero makes it simpler to
have several machines or several processes on one machine discovering
each other and talking across a network. Typical examples would include:
* Sending commands to a robot
* Sending scores to a scoreboard
* Having a remote sensor ping a central controller
* A peer-to-peer chat / instant messenger
Example code:
[Computer 1]:
import networkzero as nw0
echo_address = nw0.advertise("echo")
while True:
name = nw0.wait_for_request(echo_address)
nw0.send_reply(echo_address, "Hello " + name)
[Computer 2]:
import networkzero as nw0
echo_address = nw0.discover("echo")
print(nw0.send_request(echo_address, "Alice"))
print(nw0.send_request(echo_address, "Bob"))
"""
from .discovery import advertise, unadvertise, discover
from .messenger import (
send_command, wait_for_command,
send_request, wait_for_request, send_reply,
publish_news, wait_for_news
)
from .core import address
|
from .discovery import advertise, unadvertise, discover
from .messenger import (
send_command, wait_for_command,
send_request, wait_for_request, send_reply,
publish_news, wait_for_news
)
from .core import addressPut some high-level module docs together, including a simple example# -*- coding: utf-8 -*-
"""networkzero - easy network discovery & messaging
Aimed at a classrom or club situation, networkzero makes it simpler to
have several machines or several processes on one machine discovering
each other and talking across a network. Typical examples would include:
* Sending commands to a robot
* Sending scores to a scoreboard
* Having a remote sensor ping a central controller
* A peer-to-peer chat / instant messenger
Example code:
[Computer 1]:
import networkzero as nw0
echo_address = nw0.advertise("echo")
while True:
name = nw0.wait_for_request(echo_address)
nw0.send_reply(echo_address, "Hello " + name)
[Computer 2]:
import networkzero as nw0
echo_address = nw0.discover("echo")
print(nw0.send_request(echo_address, "Alice"))
print(nw0.send_request(echo_address, "Bob"))
"""
from .discovery import advertise, unadvertise, discover
from .messenger import (
send_command, wait_for_command,
send_request, wait_for_request, send_reply,
publish_news, wait_for_news
)
from .core import address
|
<commit_before>from .discovery import advertise, unadvertise, discover
from .messenger import (
send_command, wait_for_command,
send_request, wait_for_request, send_reply,
publish_news, wait_for_news
)
from .core import address<commit_msg>Put some high-level module docs together, including a simple example<commit_after># -*- coding: utf-8 -*-
"""networkzero - easy network discovery & messaging
Aimed at a classrom or club situation, networkzero makes it simpler to
have several machines or several processes on one machine discovering
each other and talking across a network. Typical examples would include:
* Sending commands to a robot
* Sending scores to a scoreboard
* Having a remote sensor ping a central controller
* A peer-to-peer chat / instant messenger
Example code:
[Computer 1]:
import networkzero as nw0
echo_address = nw0.advertise("echo")
while True:
name = nw0.wait_for_request(echo_address)
nw0.send_reply(echo_address, "Hello " + name)
[Computer 2]:
import networkzero as nw0
echo_address = nw0.discover("echo")
print(nw0.send_request(echo_address, "Alice"))
print(nw0.send_request(echo_address, "Bob"))
"""
from .discovery import advertise, unadvertise, discover
from .messenger import (
send_command, wait_for_command,
send_request, wait_for_request, send_reply,
publish_news, wait_for_news
)
from .core import address
|
cc4d9c43167f9060fd8d8ec1c8c4150b79a104b6
|
example/config/production.py
|
example/config/production.py
|
import os
# Gunicorn
# ========
bind = '127.0.0.1:5000'
# Muffin
# ======
PLUGINS = (
# Contrib plugins
'muffin_jinja2',
'muffin_peewee',
'muffin_session',
'muffin_oauth',
'muffin_admin',
'muffin_debugtoolbar',
)
STATIC_FOLDERS = 'example/static',
# Plugin options
# ==============
SESSION_SECRET = 'SecretHere'
JINJA2_TEMPLATE_FOLDERS = 'example/templates',
OAUTH_CLIENTS = {
'github': {
'client_id': 'b212c829c357ea0bd950',
'client_secret': 'e2bdda59f9da853ec39d0d1e07baade595f50202',
}
}
PEEWEE_MIGRATIONS_PATH = 'example/migrations'
PEEWEE_CONNECTION = os.environ.get('DATABASE_URL', 'sqlite:///example.sqlite')
DEBUGTOOLBAR_EXCLUDE = ['/static']
|
import os
# Gunicorn
# ========
bind = '127.0.0.1:5000'
# Muffin
# ======
PLUGINS = (
# Contrib plugins
'muffin_jinja2',
'muffin_peewee',
'muffin_session',
'muffin_oauth',
'muffin_admin',
'muffin_debugtoolbar',
)
STATIC_FOLDERS = 'example/static',
# Plugin options
# ==============
SESSION_SECRET = 'SecretHere'
JINJA2_TEMPLATE_FOLDERS = 'example/templates',
OAUTH_CLIENTS = {
'github': {
'client_id': 'b212c829c357ea0bd950',
'client_secret': 'e2bdda59f9da853ec39d0d1e07baade595f50202',
}
}
PEEWEE_MIGRATIONS_PATH = 'example/migrations'
PEEWEE_CONNECTION = os.environ.get('DATABASE_URL', 'sqlite:///example.sqlite')
DEBUGTOOLBAR_EXCLUDE = ['/static']
DEBUGTOOLBAR_HOSTS = ['0.0.0.0']
|
Enable DT for all hosts
|
Enable DT for all hosts
|
Python
|
mit
|
klen/muffin-example,klen/muffin-example
|
import os
# Gunicorn
# ========
bind = '127.0.0.1:5000'
# Muffin
# ======
PLUGINS = (
# Contrib plugins
'muffin_jinja2',
'muffin_peewee',
'muffin_session',
'muffin_oauth',
'muffin_admin',
'muffin_debugtoolbar',
)
STATIC_FOLDERS = 'example/static',
# Plugin options
# ==============
SESSION_SECRET = 'SecretHere'
JINJA2_TEMPLATE_FOLDERS = 'example/templates',
OAUTH_CLIENTS = {
'github': {
'client_id': 'b212c829c357ea0bd950',
'client_secret': 'e2bdda59f9da853ec39d0d1e07baade595f50202',
}
}
PEEWEE_MIGRATIONS_PATH = 'example/migrations'
PEEWEE_CONNECTION = os.environ.get('DATABASE_URL', 'sqlite:///example.sqlite')
DEBUGTOOLBAR_EXCLUDE = ['/static']
Enable DT for all hosts
|
import os
# Gunicorn
# ========
bind = '127.0.0.1:5000'
# Muffin
# ======
PLUGINS = (
# Contrib plugins
'muffin_jinja2',
'muffin_peewee',
'muffin_session',
'muffin_oauth',
'muffin_admin',
'muffin_debugtoolbar',
)
STATIC_FOLDERS = 'example/static',
# Plugin options
# ==============
SESSION_SECRET = 'SecretHere'
JINJA2_TEMPLATE_FOLDERS = 'example/templates',
OAUTH_CLIENTS = {
'github': {
'client_id': 'b212c829c357ea0bd950',
'client_secret': 'e2bdda59f9da853ec39d0d1e07baade595f50202',
}
}
PEEWEE_MIGRATIONS_PATH = 'example/migrations'
PEEWEE_CONNECTION = os.environ.get('DATABASE_URL', 'sqlite:///example.sqlite')
DEBUGTOOLBAR_EXCLUDE = ['/static']
DEBUGTOOLBAR_HOSTS = ['0.0.0.0']
|
<commit_before>import os
# Gunicorn
# ========
bind = '127.0.0.1:5000'
# Muffin
# ======
PLUGINS = (
# Contrib plugins
'muffin_jinja2',
'muffin_peewee',
'muffin_session',
'muffin_oauth',
'muffin_admin',
'muffin_debugtoolbar',
)
STATIC_FOLDERS = 'example/static',
# Plugin options
# ==============
SESSION_SECRET = 'SecretHere'
JINJA2_TEMPLATE_FOLDERS = 'example/templates',
OAUTH_CLIENTS = {
'github': {
'client_id': 'b212c829c357ea0bd950',
'client_secret': 'e2bdda59f9da853ec39d0d1e07baade595f50202',
}
}
PEEWEE_MIGRATIONS_PATH = 'example/migrations'
PEEWEE_CONNECTION = os.environ.get('DATABASE_URL', 'sqlite:///example.sqlite')
DEBUGTOOLBAR_EXCLUDE = ['/static']
<commit_msg>Enable DT for all hosts<commit_after>
|
import os
# Gunicorn
# ========
bind = '127.0.0.1:5000'
# Muffin
# ======
PLUGINS = (
# Contrib plugins
'muffin_jinja2',
'muffin_peewee',
'muffin_session',
'muffin_oauth',
'muffin_admin',
'muffin_debugtoolbar',
)
STATIC_FOLDERS = 'example/static',
# Plugin options
# ==============
SESSION_SECRET = 'SecretHere'
JINJA2_TEMPLATE_FOLDERS = 'example/templates',
OAUTH_CLIENTS = {
'github': {
'client_id': 'b212c829c357ea0bd950',
'client_secret': 'e2bdda59f9da853ec39d0d1e07baade595f50202',
}
}
PEEWEE_MIGRATIONS_PATH = 'example/migrations'
PEEWEE_CONNECTION = os.environ.get('DATABASE_URL', 'sqlite:///example.sqlite')
DEBUGTOOLBAR_EXCLUDE = ['/static']
DEBUGTOOLBAR_HOSTS = ['0.0.0.0']
|
import os
# Gunicorn
# ========
bind = '127.0.0.1:5000'
# Muffin
# ======
PLUGINS = (
# Contrib plugins
'muffin_jinja2',
'muffin_peewee',
'muffin_session',
'muffin_oauth',
'muffin_admin',
'muffin_debugtoolbar',
)
STATIC_FOLDERS = 'example/static',
# Plugin options
# ==============
SESSION_SECRET = 'SecretHere'
JINJA2_TEMPLATE_FOLDERS = 'example/templates',
OAUTH_CLIENTS = {
'github': {
'client_id': 'b212c829c357ea0bd950',
'client_secret': 'e2bdda59f9da853ec39d0d1e07baade595f50202',
}
}
PEEWEE_MIGRATIONS_PATH = 'example/migrations'
PEEWEE_CONNECTION = os.environ.get('DATABASE_URL', 'sqlite:///example.sqlite')
DEBUGTOOLBAR_EXCLUDE = ['/static']
Enable DT for all hostsimport os
# Gunicorn
# ========
bind = '127.0.0.1:5000'
# Muffin
# ======
PLUGINS = (
# Contrib plugins
'muffin_jinja2',
'muffin_peewee',
'muffin_session',
'muffin_oauth',
'muffin_admin',
'muffin_debugtoolbar',
)
STATIC_FOLDERS = 'example/static',
# Plugin options
# ==============
SESSION_SECRET = 'SecretHere'
JINJA2_TEMPLATE_FOLDERS = 'example/templates',
OAUTH_CLIENTS = {
'github': {
'client_id': 'b212c829c357ea0bd950',
'client_secret': 'e2bdda59f9da853ec39d0d1e07baade595f50202',
}
}
PEEWEE_MIGRATIONS_PATH = 'example/migrations'
PEEWEE_CONNECTION = os.environ.get('DATABASE_URL', 'sqlite:///example.sqlite')
DEBUGTOOLBAR_EXCLUDE = ['/static']
DEBUGTOOLBAR_HOSTS = ['0.0.0.0']
|
<commit_before>import os
# Gunicorn
# ========
bind = '127.0.0.1:5000'
# Muffin
# ======
PLUGINS = (
# Contrib plugins
'muffin_jinja2',
'muffin_peewee',
'muffin_session',
'muffin_oauth',
'muffin_admin',
'muffin_debugtoolbar',
)
STATIC_FOLDERS = 'example/static',
# Plugin options
# ==============
SESSION_SECRET = 'SecretHere'
JINJA2_TEMPLATE_FOLDERS = 'example/templates',
OAUTH_CLIENTS = {
'github': {
'client_id': 'b212c829c357ea0bd950',
'client_secret': 'e2bdda59f9da853ec39d0d1e07baade595f50202',
}
}
PEEWEE_MIGRATIONS_PATH = 'example/migrations'
PEEWEE_CONNECTION = os.environ.get('DATABASE_URL', 'sqlite:///example.sqlite')
DEBUGTOOLBAR_EXCLUDE = ['/static']
<commit_msg>Enable DT for all hosts<commit_after>import os
# Gunicorn
# ========
bind = '127.0.0.1:5000'
# Muffin
# ======
PLUGINS = (
# Contrib plugins
'muffin_jinja2',
'muffin_peewee',
'muffin_session',
'muffin_oauth',
'muffin_admin',
'muffin_debugtoolbar',
)
STATIC_FOLDERS = 'example/static',
# Plugin options
# ==============
SESSION_SECRET = 'SecretHere'
JINJA2_TEMPLATE_FOLDERS = 'example/templates',
OAUTH_CLIENTS = {
'github': {
'client_id': 'b212c829c357ea0bd950',
'client_secret': 'e2bdda59f9da853ec39d0d1e07baade595f50202',
}
}
PEEWEE_MIGRATIONS_PATH = 'example/migrations'
PEEWEE_CONNECTION = os.environ.get('DATABASE_URL', 'sqlite:///example.sqlite')
DEBUGTOOLBAR_EXCLUDE = ['/static']
DEBUGTOOLBAR_HOSTS = ['0.0.0.0']
|
d13b3d89124d03f563c2ee2143ae16eec7d0b191
|
tests/Epsilon_tests/ImportTest.py
|
tests/Epsilon_tests/ImportTest.py
|
#!/usr/bin/env python
"""
:Author Patrik Valkovic
:Created 23.06.2017 16:39
:Licence GNUv3
Part of grammpy
"""
from unittest import TestCase, main
from grammpy import EPS
from grammpy import EPSILON
class ImportTest(TestCase):
def test_idSame(self):
self.assertEqual(id(EPS), id(EPSILON))
def test_equal(self):
self.assertEqual(EPS, EPSILON)
def test_equalToSelf(self):
self.assertEqual(EPS, EPS)
def test_notEqualToNumber(self):
self.assertNotEqual(EPS, 5)
def test_notEqualToString(self):
self.assertNotEqual(EPS, "asdf")
def test_notEqualToObject(self):
self.assertNotEqual(EPS, object())
if __name__ == '__main__':
main()
|
#!/usr/bin/env python
"""
:Author Patrik Valkovic
:Created 23.06.2017 16:39
:Licence GNUv3
Part of grammpy
"""
from unittest import TestCase, main
from grammpy import EPS
from grammpy import EPSILON
class ImportTest(TestCase):
def test_idSame(self):
self.assertEqual(id(EPS),id(EPSILON))
def test_equal(self):
self.assertEqual(EPS, EPSILON)
if __name__ == '__main__':
main()
|
Revert "Add tests to compare epsilon with another objects"
|
Revert "Add tests to compare epsilon with another objects"
This reverts commit ae4b4fe5fb5c5774720dd3a14549aa88bde91043.
|
Python
|
mit
|
PatrikValkovic/grammpy
|
#!/usr/bin/env python
"""
:Author Patrik Valkovic
:Created 23.06.2017 16:39
:Licence GNUv3
Part of grammpy
"""
from unittest import TestCase, main
from grammpy import EPS
from grammpy import EPSILON
class ImportTest(TestCase):
def test_idSame(self):
self.assertEqual(id(EPS), id(EPSILON))
def test_equal(self):
self.assertEqual(EPS, EPSILON)
def test_equalToSelf(self):
self.assertEqual(EPS, EPS)
def test_notEqualToNumber(self):
self.assertNotEqual(EPS, 5)
def test_notEqualToString(self):
self.assertNotEqual(EPS, "asdf")
def test_notEqualToObject(self):
self.assertNotEqual(EPS, object())
if __name__ == '__main__':
main()
Revert "Add tests to compare epsilon with another objects"
This reverts commit ae4b4fe5fb5c5774720dd3a14549aa88bde91043.
|
#!/usr/bin/env python
"""
:Author Patrik Valkovic
:Created 23.06.2017 16:39
:Licence GNUv3
Part of grammpy
"""
from unittest import TestCase, main
from grammpy import EPS
from grammpy import EPSILON
class ImportTest(TestCase):
def test_idSame(self):
self.assertEqual(id(EPS),id(EPSILON))
def test_equal(self):
self.assertEqual(EPS, EPSILON)
if __name__ == '__main__':
main()
|
<commit_before>#!/usr/bin/env python
"""
:Author Patrik Valkovic
:Created 23.06.2017 16:39
:Licence GNUv3
Part of grammpy
"""
from unittest import TestCase, main
from grammpy import EPS
from grammpy import EPSILON
class ImportTest(TestCase):
def test_idSame(self):
self.assertEqual(id(EPS), id(EPSILON))
def test_equal(self):
self.assertEqual(EPS, EPSILON)
def test_equalToSelf(self):
self.assertEqual(EPS, EPS)
def test_notEqualToNumber(self):
self.assertNotEqual(EPS, 5)
def test_notEqualToString(self):
self.assertNotEqual(EPS, "asdf")
def test_notEqualToObject(self):
self.assertNotEqual(EPS, object())
if __name__ == '__main__':
main()
<commit_msg>Revert "Add tests to compare epsilon with another objects"
This reverts commit ae4b4fe5fb5c5774720dd3a14549aa88bde91043.<commit_after>
|
#!/usr/bin/env python
"""
:Author Patrik Valkovic
:Created 23.06.2017 16:39
:Licence GNUv3
Part of grammpy
"""
from unittest import TestCase, main
from grammpy import EPS
from grammpy import EPSILON
class ImportTest(TestCase):
def test_idSame(self):
self.assertEqual(id(EPS),id(EPSILON))
def test_equal(self):
self.assertEqual(EPS, EPSILON)
if __name__ == '__main__':
main()
|
#!/usr/bin/env python
"""
:Author Patrik Valkovic
:Created 23.06.2017 16:39
:Licence GNUv3
Part of grammpy
"""
from unittest import TestCase, main
from grammpy import EPS
from grammpy import EPSILON
class ImportTest(TestCase):
def test_idSame(self):
self.assertEqual(id(EPS), id(EPSILON))
def test_equal(self):
self.assertEqual(EPS, EPSILON)
def test_equalToSelf(self):
self.assertEqual(EPS, EPS)
def test_notEqualToNumber(self):
self.assertNotEqual(EPS, 5)
def test_notEqualToString(self):
self.assertNotEqual(EPS, "asdf")
def test_notEqualToObject(self):
self.assertNotEqual(EPS, object())
if __name__ == '__main__':
main()
Revert "Add tests to compare epsilon with another objects"
This reverts commit ae4b4fe5fb5c5774720dd3a14549aa88bde91043.#!/usr/bin/env python
"""
:Author Patrik Valkovic
:Created 23.06.2017 16:39
:Licence GNUv3
Part of grammpy
"""
from unittest import TestCase, main
from grammpy import EPS
from grammpy import EPSILON
class ImportTest(TestCase):
def test_idSame(self):
self.assertEqual(id(EPS),id(EPSILON))
def test_equal(self):
self.assertEqual(EPS, EPSILON)
if __name__ == '__main__':
main()
|
<commit_before>#!/usr/bin/env python
"""
:Author Patrik Valkovic
:Created 23.06.2017 16:39
:Licence GNUv3
Part of grammpy
"""
from unittest import TestCase, main
from grammpy import EPS
from grammpy import EPSILON
class ImportTest(TestCase):
def test_idSame(self):
self.assertEqual(id(EPS), id(EPSILON))
def test_equal(self):
self.assertEqual(EPS, EPSILON)
def test_equalToSelf(self):
self.assertEqual(EPS, EPS)
def test_notEqualToNumber(self):
self.assertNotEqual(EPS, 5)
def test_notEqualToString(self):
self.assertNotEqual(EPS, "asdf")
def test_notEqualToObject(self):
self.assertNotEqual(EPS, object())
if __name__ == '__main__':
main()
<commit_msg>Revert "Add tests to compare epsilon with another objects"
This reverts commit ae4b4fe5fb5c5774720dd3a14549aa88bde91043.<commit_after>#!/usr/bin/env python
"""
:Author Patrik Valkovic
:Created 23.06.2017 16:39
:Licence GNUv3
Part of grammpy
"""
from unittest import TestCase, main
from grammpy import EPS
from grammpy import EPSILON
class ImportTest(TestCase):
def test_idSame(self):
self.assertEqual(id(EPS),id(EPSILON))
def test_equal(self):
self.assertEqual(EPS, EPSILON)
if __name__ == '__main__':
main()
|
8d40cbd1d2cf431454dcfd9a9088be73687e7c1a
|
skimage/viewer/__init__.py
|
skimage/viewer/__init__.py
|
try:
from .qt import QtGui as _QtGui
except ImportError as e:
raise ImportError('Viewer requires Qt')
from .viewers import ImageViewer, CollectionViewer
|
import warnings
try:
from .viewers import ImageViewer, CollectionViewer
except ImportError as e:
warnings.warn('Viewer requires Qt')
|
Allow viewer package to import without Qt
|
Allow viewer package to import without Qt
|
Python
|
bsd-3-clause
|
pratapvardhan/scikit-image,paalge/scikit-image,youprofit/scikit-image,michaelaye/scikit-image,blink1073/scikit-image,newville/scikit-image,warmspringwinds/scikit-image,pratapvardhan/scikit-image,juliusbierk/scikit-image,ajaybhat/scikit-image,jwiggins/scikit-image,chriscrosscutler/scikit-image,robintw/scikit-image,GaZ3ll3/scikit-image,bennlich/scikit-image,GaZ3ll3/scikit-image,blink1073/scikit-image,paalge/scikit-image,ofgulban/scikit-image,youprofit/scikit-image,Hiyorimi/scikit-image,dpshelio/scikit-image,bennlich/scikit-image,emon10005/scikit-image,rjeli/scikit-image,bsipocz/scikit-image,vighneshbirodkar/scikit-image,rjeli/scikit-image,ajaybhat/scikit-image,vighneshbirodkar/scikit-image,emon10005/scikit-image,Midafi/scikit-image,juliusbierk/scikit-image,keflavich/scikit-image,chriscrosscutler/scikit-image,WarrenWeckesser/scikits-image,Britefury/scikit-image,bsipocz/scikit-image,warmspringwinds/scikit-image,paalge/scikit-image,robintw/scikit-image,ClinicalGraphics/scikit-image,keflavich/scikit-image,rjeli/scikit-image,WarrenWeckesser/scikits-image,vighneshbirodkar/scikit-image,newville/scikit-image,ofgulban/scikit-image,oew1v07/scikit-image,Britefury/scikit-image,jwiggins/scikit-image,dpshelio/scikit-image,ofgulban/scikit-image,michaelpacer/scikit-image,Hiyorimi/scikit-image,Midafi/scikit-image,michaelaye/scikit-image,ClinicalGraphics/scikit-image,oew1v07/scikit-image,michaelpacer/scikit-image
|
try:
from .qt import QtGui as _QtGui
except ImportError as e:
raise ImportError('Viewer requires Qt')
from .viewers import ImageViewer, CollectionViewer
Allow viewer package to import without Qt
|
import warnings
try:
from .viewers import ImageViewer, CollectionViewer
except ImportError as e:
warnings.warn('Viewer requires Qt')
|
<commit_before>try:
from .qt import QtGui as _QtGui
except ImportError as e:
raise ImportError('Viewer requires Qt')
from .viewers import ImageViewer, CollectionViewer
<commit_msg>Allow viewer package to import without Qt<commit_after>
|
import warnings
try:
from .viewers import ImageViewer, CollectionViewer
except ImportError as e:
warnings.warn('Viewer requires Qt')
|
try:
from .qt import QtGui as _QtGui
except ImportError as e:
raise ImportError('Viewer requires Qt')
from .viewers import ImageViewer, CollectionViewer
Allow viewer package to import without Qtimport warnings
try:
from .viewers import ImageViewer, CollectionViewer
except ImportError as e:
warnings.warn('Viewer requires Qt')
|
<commit_before>try:
from .qt import QtGui as _QtGui
except ImportError as e:
raise ImportError('Viewer requires Qt')
from .viewers import ImageViewer, CollectionViewer
<commit_msg>Allow viewer package to import without Qt<commit_after>import warnings
try:
from .viewers import ImageViewer, CollectionViewer
except ImportError as e:
warnings.warn('Viewer requires Qt')
|
5f2676d61c15d23b62264069a2e4ed659f4a7f69
|
markdowntoc/base.py
|
markdowntoc/base.py
|
import pprint
import sublime
import json
from .util import Util
# for debug
pp = pprint.PrettyPrinter(indent=4)
class Base(object):
def settings(self, attr):
settings = json.loads(sublime.load_resource('Packages/MarkdownTOC/MarkdownTOC.sublime-settings'))
user_settings = json.loads(sublime.load_resource('Packages/User/MarkdownTOC.sublime-settings'))
Util.dict_merge(settings, user_settings)
return settings[attr]
def defaults(self):
return self.settings('defaults')
def log(self, arg):
if self.settings('logging') is True:
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
def error(self, arg):
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
|
import pprint
import sublime
import json
from .util import Util
# for debug
pp = pprint.PrettyPrinter(indent=4)
class Base(object):
def settings(self, attr):
settings = json.loads(sublime.load_resource('Packages/MarkdownTOC/MarkdownTOC.sublime-settings'))
user_settings = json.loads(sublime.load_resource('Packages/User/MarkdownTOC.sublime-settings'))
Util.dict_merge(settings, user_settings)
return settings[attr]
def defaults(self):
return self.settings('defaults')
def log(self, arg):
if self.settings('logging') is True:
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
def error(self, arg):
arg = 'MarkdownTOC Error: '+arg
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
|
Add label in error message
|
Add label in error message
|
Python
|
mit
|
naokazuterada/MarkdownTOC
|
import pprint
import sublime
import json
from .util import Util
# for debug
pp = pprint.PrettyPrinter(indent=4)
class Base(object):
def settings(self, attr):
settings = json.loads(sublime.load_resource('Packages/MarkdownTOC/MarkdownTOC.sublime-settings'))
user_settings = json.loads(sublime.load_resource('Packages/User/MarkdownTOC.sublime-settings'))
Util.dict_merge(settings, user_settings)
return settings[attr]
def defaults(self):
return self.settings('defaults')
def log(self, arg):
if self.settings('logging') is True:
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
def error(self, arg):
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
Add label in error message
|
import pprint
import sublime
import json
from .util import Util
# for debug
pp = pprint.PrettyPrinter(indent=4)
class Base(object):
def settings(self, attr):
settings = json.loads(sublime.load_resource('Packages/MarkdownTOC/MarkdownTOC.sublime-settings'))
user_settings = json.loads(sublime.load_resource('Packages/User/MarkdownTOC.sublime-settings'))
Util.dict_merge(settings, user_settings)
return settings[attr]
def defaults(self):
return self.settings('defaults')
def log(self, arg):
if self.settings('logging') is True:
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
def error(self, arg):
arg = 'MarkdownTOC Error: '+arg
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
|
<commit_before>import pprint
import sublime
import json
from .util import Util
# for debug
pp = pprint.PrettyPrinter(indent=4)
class Base(object):
def settings(self, attr):
settings = json.loads(sublime.load_resource('Packages/MarkdownTOC/MarkdownTOC.sublime-settings'))
user_settings = json.loads(sublime.load_resource('Packages/User/MarkdownTOC.sublime-settings'))
Util.dict_merge(settings, user_settings)
return settings[attr]
def defaults(self):
return self.settings('defaults')
def log(self, arg):
if self.settings('logging') is True:
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
def error(self, arg):
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
<commit_msg>Add label in error message<commit_after>
|
import pprint
import sublime
import json
from .util import Util
# for debug
pp = pprint.PrettyPrinter(indent=4)
class Base(object):
def settings(self, attr):
settings = json.loads(sublime.load_resource('Packages/MarkdownTOC/MarkdownTOC.sublime-settings'))
user_settings = json.loads(sublime.load_resource('Packages/User/MarkdownTOC.sublime-settings'))
Util.dict_merge(settings, user_settings)
return settings[attr]
def defaults(self):
return self.settings('defaults')
def log(self, arg):
if self.settings('logging') is True:
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
def error(self, arg):
arg = 'MarkdownTOC Error: '+arg
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
|
import pprint
import sublime
import json
from .util import Util
# for debug
pp = pprint.PrettyPrinter(indent=4)
class Base(object):
def settings(self, attr):
settings = json.loads(sublime.load_resource('Packages/MarkdownTOC/MarkdownTOC.sublime-settings'))
user_settings = json.loads(sublime.load_resource('Packages/User/MarkdownTOC.sublime-settings'))
Util.dict_merge(settings, user_settings)
return settings[attr]
def defaults(self):
return self.settings('defaults')
def log(self, arg):
if self.settings('logging') is True:
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
def error(self, arg):
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
Add label in error messageimport pprint
import sublime
import json
from .util import Util
# for debug
pp = pprint.PrettyPrinter(indent=4)
class Base(object):
def settings(self, attr):
settings = json.loads(sublime.load_resource('Packages/MarkdownTOC/MarkdownTOC.sublime-settings'))
user_settings = json.loads(sublime.load_resource('Packages/User/MarkdownTOC.sublime-settings'))
Util.dict_merge(settings, user_settings)
return settings[attr]
def defaults(self):
return self.settings('defaults')
def log(self, arg):
if self.settings('logging') is True:
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
def error(self, arg):
arg = 'MarkdownTOC Error: '+arg
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
|
<commit_before>import pprint
import sublime
import json
from .util import Util
# for debug
pp = pprint.PrettyPrinter(indent=4)
class Base(object):
def settings(self, attr):
settings = json.loads(sublime.load_resource('Packages/MarkdownTOC/MarkdownTOC.sublime-settings'))
user_settings = json.loads(sublime.load_resource('Packages/User/MarkdownTOC.sublime-settings'))
Util.dict_merge(settings, user_settings)
return settings[attr]
def defaults(self):
return self.settings('defaults')
def log(self, arg):
if self.settings('logging') is True:
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
def error(self, arg):
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
<commit_msg>Add label in error message<commit_after>import pprint
import sublime
import json
from .util import Util
# for debug
pp = pprint.PrettyPrinter(indent=4)
class Base(object):
def settings(self, attr):
settings = json.loads(sublime.load_resource('Packages/MarkdownTOC/MarkdownTOC.sublime-settings'))
user_settings = json.loads(sublime.load_resource('Packages/User/MarkdownTOC.sublime-settings'))
Util.dict_merge(settings, user_settings)
return settings[attr]
def defaults(self):
return self.settings('defaults')
def log(self, arg):
if self.settings('logging') is True:
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
def error(self, arg):
arg = 'MarkdownTOC Error: '+arg
arg = str(arg)
sublime.status_message(arg)
pp.pprint(arg)
|
b43f7e3c08f4b679debda1a418b632e235dcbc8d
|
organizations/__init__.py
|
organizations/__init__.py
|
"""
edx-organizations app initialization module
"""
__version__ = '6.0.0' # pragma: no cover
|
"""
edx-organizations app initialization module
"""
__version__ = '6.1.0' # pragma: no cover
|
Bump version to 6.1.0 from 6.0.0
|
Bump version to 6.1.0 from 6.0.0
|
Python
|
agpl-3.0
|
edx/edx-organizations
|
"""
edx-organizations app initialization module
"""
__version__ = '6.0.0' # pragma: no cover
Bump version to 6.1.0 from 6.0.0
|
"""
edx-organizations app initialization module
"""
__version__ = '6.1.0' # pragma: no cover
|
<commit_before>"""
edx-organizations app initialization module
"""
__version__ = '6.0.0' # pragma: no cover
<commit_msg>Bump version to 6.1.0 from 6.0.0<commit_after>
|
"""
edx-organizations app initialization module
"""
__version__ = '6.1.0' # pragma: no cover
|
"""
edx-organizations app initialization module
"""
__version__ = '6.0.0' # pragma: no cover
Bump version to 6.1.0 from 6.0.0"""
edx-organizations app initialization module
"""
__version__ = '6.1.0' # pragma: no cover
|
<commit_before>"""
edx-organizations app initialization module
"""
__version__ = '6.0.0' # pragma: no cover
<commit_msg>Bump version to 6.1.0 from 6.0.0<commit_after>"""
edx-organizations app initialization module
"""
__version__ = '6.1.0' # pragma: no cover
|
f84f2ad1943059f6ddf9d48a3af6895cf09dcce7
|
teknologr/registration/views.py
|
teknologr/registration/views.py
|
from django.shortcuts import render, redirect
from django.conf import settings
from django.views import View
from members.programmes import DEGREE_PROGRAMME_CHOICES
from registration.forms import RegistrationForm
from registration.mailutils import mailApplicantSubmission
class BaseView(View):
context = {'DEBUG': settings.DEBUG}
class HomeView(BaseView):
template = 'registration.html'
def get(self, request):
self.context['programmes'] = DEGREE_PROGRAMME_CHOICES
self.context['form'] = RegistrationForm()
return render(request, self.template, self.context)
class SubmitView(BaseView):
template = 'submit.html'
def get(self, request, **kwargs):
previous_context = request.session.pop('context', None)
if not previous_context:
return redirect('registration.views.home')
return render(request, self.template, previous_context)
def post(self, request):
form = RegistrationForm(request.POST)
if form.is_valid():
registration = form.instance
next_context = {
'name': registration.preferred_name or registration.given_names.split(' ')[0],
'email': registration.email,
}
# FIXME: handle situation where email is not sent (e.g. admin log tool)
mailApplicantSubmission(self.context)
registration.save()
request.session['context'] = next_context
return redirect('registration.views.submit')
else:
self.context['form'] = form
return render(request, HomeView.template, self.context, status=400)
|
from django.shortcuts import render, redirect
from django.conf import settings
from django.views import View
from members.programmes import DEGREE_PROGRAMME_CHOICES
from registration.forms import RegistrationForm
from registration.mailutils import mailApplicantSubmission
class BaseView(View):
context = {'DEBUG': settings.DEBUG}
class HomeView(BaseView):
template = 'registration.html'
def get(self, request):
self.context['programmes'] = DEGREE_PROGRAMME_CHOICES
self.context['form'] = RegistrationForm()
return render(request, self.template, self.context)
class SubmitView(BaseView):
template = 'submit.html'
def get(self, request, **kwargs):
previous_context = request.session.pop('context', None)
if not previous_context:
return redirect('registration.views.home')
return render(request, self.template, previous_context)
def post(self, request):
form = RegistrationForm(request.POST)
if form.is_valid():
registration = form.instance
next_context = {
'name': registration.preferred_name or registration.given_names.split(' ')[0],
'email': registration.email,
}
# FIXME: handle situation where email is not sent (e.g. admin log tool)
mailApplicantSubmission(next_context)
registration.save()
request.session['context'] = next_context
return redirect('registration.views.submit')
else:
self.context['form'] = form
return render(request, HomeView.template, self.context, status=400)
|
Fix context given to mailutils
|
Fix context given to mailutils
|
Python
|
mit
|
Teknologforeningen/teknologr.io,Teknologforeningen/teknologr.io,Teknologforeningen/teknologr.io,Teknologforeningen/teknologr.io
|
from django.shortcuts import render, redirect
from django.conf import settings
from django.views import View
from members.programmes import DEGREE_PROGRAMME_CHOICES
from registration.forms import RegistrationForm
from registration.mailutils import mailApplicantSubmission
class BaseView(View):
context = {'DEBUG': settings.DEBUG}
class HomeView(BaseView):
template = 'registration.html'
def get(self, request):
self.context['programmes'] = DEGREE_PROGRAMME_CHOICES
self.context['form'] = RegistrationForm()
return render(request, self.template, self.context)
class SubmitView(BaseView):
template = 'submit.html'
def get(self, request, **kwargs):
previous_context = request.session.pop('context', None)
if not previous_context:
return redirect('registration.views.home')
return render(request, self.template, previous_context)
def post(self, request):
form = RegistrationForm(request.POST)
if form.is_valid():
registration = form.instance
next_context = {
'name': registration.preferred_name or registration.given_names.split(' ')[0],
'email': registration.email,
}
# FIXME: handle situation where email is not sent (e.g. admin log tool)
mailApplicantSubmission(self.context)
registration.save()
request.session['context'] = next_context
return redirect('registration.views.submit')
else:
self.context['form'] = form
return render(request, HomeView.template, self.context, status=400)
Fix context given to mailutils
|
from django.shortcuts import render, redirect
from django.conf import settings
from django.views import View
from members.programmes import DEGREE_PROGRAMME_CHOICES
from registration.forms import RegistrationForm
from registration.mailutils import mailApplicantSubmission
class BaseView(View):
context = {'DEBUG': settings.DEBUG}
class HomeView(BaseView):
template = 'registration.html'
def get(self, request):
self.context['programmes'] = DEGREE_PROGRAMME_CHOICES
self.context['form'] = RegistrationForm()
return render(request, self.template, self.context)
class SubmitView(BaseView):
template = 'submit.html'
def get(self, request, **kwargs):
previous_context = request.session.pop('context', None)
if not previous_context:
return redirect('registration.views.home')
return render(request, self.template, previous_context)
def post(self, request):
form = RegistrationForm(request.POST)
if form.is_valid():
registration = form.instance
next_context = {
'name': registration.preferred_name or registration.given_names.split(' ')[0],
'email': registration.email,
}
# FIXME: handle situation where email is not sent (e.g. admin log tool)
mailApplicantSubmission(next_context)
registration.save()
request.session['context'] = next_context
return redirect('registration.views.submit')
else:
self.context['form'] = form
return render(request, HomeView.template, self.context, status=400)
|
<commit_before>from django.shortcuts import render, redirect
from django.conf import settings
from django.views import View
from members.programmes import DEGREE_PROGRAMME_CHOICES
from registration.forms import RegistrationForm
from registration.mailutils import mailApplicantSubmission
class BaseView(View):
context = {'DEBUG': settings.DEBUG}
class HomeView(BaseView):
template = 'registration.html'
def get(self, request):
self.context['programmes'] = DEGREE_PROGRAMME_CHOICES
self.context['form'] = RegistrationForm()
return render(request, self.template, self.context)
class SubmitView(BaseView):
template = 'submit.html'
def get(self, request, **kwargs):
previous_context = request.session.pop('context', None)
if not previous_context:
return redirect('registration.views.home')
return render(request, self.template, previous_context)
def post(self, request):
form = RegistrationForm(request.POST)
if form.is_valid():
registration = form.instance
next_context = {
'name': registration.preferred_name or registration.given_names.split(' ')[0],
'email': registration.email,
}
# FIXME: handle situation where email is not sent (e.g. admin log tool)
mailApplicantSubmission(self.context)
registration.save()
request.session['context'] = next_context
return redirect('registration.views.submit')
else:
self.context['form'] = form
return render(request, HomeView.template, self.context, status=400)
<commit_msg>Fix context given to mailutils<commit_after>
|
from django.shortcuts import render, redirect
from django.conf import settings
from django.views import View
from members.programmes import DEGREE_PROGRAMME_CHOICES
from registration.forms import RegistrationForm
from registration.mailutils import mailApplicantSubmission
class BaseView(View):
context = {'DEBUG': settings.DEBUG}
class HomeView(BaseView):
template = 'registration.html'
def get(self, request):
self.context['programmes'] = DEGREE_PROGRAMME_CHOICES
self.context['form'] = RegistrationForm()
return render(request, self.template, self.context)
class SubmitView(BaseView):
template = 'submit.html'
def get(self, request, **kwargs):
previous_context = request.session.pop('context', None)
if not previous_context:
return redirect('registration.views.home')
return render(request, self.template, previous_context)
def post(self, request):
form = RegistrationForm(request.POST)
if form.is_valid():
registration = form.instance
next_context = {
'name': registration.preferred_name or registration.given_names.split(' ')[0],
'email': registration.email,
}
# FIXME: handle situation where email is not sent (e.g. admin log tool)
mailApplicantSubmission(next_context)
registration.save()
request.session['context'] = next_context
return redirect('registration.views.submit')
else:
self.context['form'] = form
return render(request, HomeView.template, self.context, status=400)
|
from django.shortcuts import render, redirect
from django.conf import settings
from django.views import View
from members.programmes import DEGREE_PROGRAMME_CHOICES
from registration.forms import RegistrationForm
from registration.mailutils import mailApplicantSubmission
class BaseView(View):
context = {'DEBUG': settings.DEBUG}
class HomeView(BaseView):
template = 'registration.html'
def get(self, request):
self.context['programmes'] = DEGREE_PROGRAMME_CHOICES
self.context['form'] = RegistrationForm()
return render(request, self.template, self.context)
class SubmitView(BaseView):
template = 'submit.html'
def get(self, request, **kwargs):
previous_context = request.session.pop('context', None)
if not previous_context:
return redirect('registration.views.home')
return render(request, self.template, previous_context)
def post(self, request):
form = RegistrationForm(request.POST)
if form.is_valid():
registration = form.instance
next_context = {
'name': registration.preferred_name or registration.given_names.split(' ')[0],
'email': registration.email,
}
# FIXME: handle situation where email is not sent (e.g. admin log tool)
mailApplicantSubmission(self.context)
registration.save()
request.session['context'] = next_context
return redirect('registration.views.submit')
else:
self.context['form'] = form
return render(request, HomeView.template, self.context, status=400)
Fix context given to mailutilsfrom django.shortcuts import render, redirect
from django.conf import settings
from django.views import View
from members.programmes import DEGREE_PROGRAMME_CHOICES
from registration.forms import RegistrationForm
from registration.mailutils import mailApplicantSubmission
class BaseView(View):
context = {'DEBUG': settings.DEBUG}
class HomeView(BaseView):
template = 'registration.html'
def get(self, request):
self.context['programmes'] = DEGREE_PROGRAMME_CHOICES
self.context['form'] = RegistrationForm()
return render(request, self.template, self.context)
class SubmitView(BaseView):
template = 'submit.html'
def get(self, request, **kwargs):
previous_context = request.session.pop('context', None)
if not previous_context:
return redirect('registration.views.home')
return render(request, self.template, previous_context)
def post(self, request):
form = RegistrationForm(request.POST)
if form.is_valid():
registration = form.instance
next_context = {
'name': registration.preferred_name or registration.given_names.split(' ')[0],
'email': registration.email,
}
# FIXME: handle situation where email is not sent (e.g. admin log tool)
mailApplicantSubmission(next_context)
registration.save()
request.session['context'] = next_context
return redirect('registration.views.submit')
else:
self.context['form'] = form
return render(request, HomeView.template, self.context, status=400)
|
<commit_before>from django.shortcuts import render, redirect
from django.conf import settings
from django.views import View
from members.programmes import DEGREE_PROGRAMME_CHOICES
from registration.forms import RegistrationForm
from registration.mailutils import mailApplicantSubmission
class BaseView(View):
context = {'DEBUG': settings.DEBUG}
class HomeView(BaseView):
template = 'registration.html'
def get(self, request):
self.context['programmes'] = DEGREE_PROGRAMME_CHOICES
self.context['form'] = RegistrationForm()
return render(request, self.template, self.context)
class SubmitView(BaseView):
template = 'submit.html'
def get(self, request, **kwargs):
previous_context = request.session.pop('context', None)
if not previous_context:
return redirect('registration.views.home')
return render(request, self.template, previous_context)
def post(self, request):
form = RegistrationForm(request.POST)
if form.is_valid():
registration = form.instance
next_context = {
'name': registration.preferred_name or registration.given_names.split(' ')[0],
'email': registration.email,
}
# FIXME: handle situation where email is not sent (e.g. admin log tool)
mailApplicantSubmission(self.context)
registration.save()
request.session['context'] = next_context
return redirect('registration.views.submit')
else:
self.context['form'] = form
return render(request, HomeView.template, self.context, status=400)
<commit_msg>Fix context given to mailutils<commit_after>from django.shortcuts import render, redirect
from django.conf import settings
from django.views import View
from members.programmes import DEGREE_PROGRAMME_CHOICES
from registration.forms import RegistrationForm
from registration.mailutils import mailApplicantSubmission
class BaseView(View):
context = {'DEBUG': settings.DEBUG}
class HomeView(BaseView):
template = 'registration.html'
def get(self, request):
self.context['programmes'] = DEGREE_PROGRAMME_CHOICES
self.context['form'] = RegistrationForm()
return render(request, self.template, self.context)
class SubmitView(BaseView):
template = 'submit.html'
def get(self, request, **kwargs):
previous_context = request.session.pop('context', None)
if not previous_context:
return redirect('registration.views.home')
return render(request, self.template, previous_context)
def post(self, request):
form = RegistrationForm(request.POST)
if form.is_valid():
registration = form.instance
next_context = {
'name': registration.preferred_name or registration.given_names.split(' ')[0],
'email': registration.email,
}
# FIXME: handle situation where email is not sent (e.g. admin log tool)
mailApplicantSubmission(next_context)
registration.save()
request.session['context'] = next_context
return redirect('registration.views.submit')
else:
self.context['form'] = form
return render(request, HomeView.template, self.context, status=400)
|
0d9c151d9f61d03e57f815d99158e1b90c9dca5e
|
erpnext/education/doctype/instructor/instructor.py
|
erpnext/education/doctype/instructor/instructor.py
|
# -*- coding: utf-8 -*-
# Copyright (c) 2015, Frappe Technologies and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe import _
from frappe.model.document import Document
from frappe.model.naming import set_name_by_naming_series
class Instructor(Document):
def autoname(self):
naming_method = frappe.db.get_value("Education Settings", None, "instructor_created_by")
if not naming_method:
frappe.throw(_("Please setup Instructor Naming System in Education > Education Settings"))
else:
if naming_method == 'Naming Series':
set_name_by_naming_series(self)
elif naming_method == 'Employee Number':
if not self.employee:
frappe.throw(_("Please select Employee"))
self.name = self.employee
elif naming_method == 'Full Name':
self.name = self.instructor_name
def validate(self):
self.validate_duplicate_employee()
def validate_duplicate_employee(self):
if self.employee and frappe.db.get_value("Instructor", {'employee': self.employee}, 'name'):
frappe.throw(_("Employee ID is linked with another instructor"))
|
# -*- coding: utf-8 -*-
# Copyright (c) 2015, Frappe Technologies and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe import _
from frappe.model.document import Document
from frappe.model.naming import set_name_by_naming_series
class Instructor(Document):
def autoname(self):
naming_method = frappe.db.get_value("Education Settings", None, "instructor_created_by")
if not naming_method:
frappe.throw(_("Please setup Instructor Naming System in Education > Education Settings"))
else:
if naming_method == 'Naming Series':
set_name_by_naming_series(self)
elif naming_method == 'Employee Number':
if not self.employee:
frappe.throw(_("Please select Employee"))
self.name = self.employee
elif naming_method == 'Full Name':
self.name = self.instructor_name
def validate(self):
self.validate_duplicate_employee()
def validate_duplicate_employee(self):
if self.employee and frappe.db.get_value("Instructor", {'employee': self.employee, 'name': ['!=', self.name]}, 'name'):
frappe.throw(_("Employee ID is linked with another instructor"))
|
Exclude current record while validating duplicate employee
|
fix: Exclude current record while validating duplicate employee
|
Python
|
agpl-3.0
|
gsnbng/erpnext,gsnbng/erpnext,gsnbng/erpnext,gsnbng/erpnext
|
# -*- coding: utf-8 -*-
# Copyright (c) 2015, Frappe Technologies and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe import _
from frappe.model.document import Document
from frappe.model.naming import set_name_by_naming_series
class Instructor(Document):
def autoname(self):
naming_method = frappe.db.get_value("Education Settings", None, "instructor_created_by")
if not naming_method:
frappe.throw(_("Please setup Instructor Naming System in Education > Education Settings"))
else:
if naming_method == 'Naming Series':
set_name_by_naming_series(self)
elif naming_method == 'Employee Number':
if not self.employee:
frappe.throw(_("Please select Employee"))
self.name = self.employee
elif naming_method == 'Full Name':
self.name = self.instructor_name
def validate(self):
self.validate_duplicate_employee()
def validate_duplicate_employee(self):
if self.employee and frappe.db.get_value("Instructor", {'employee': self.employee}, 'name'):
frappe.throw(_("Employee ID is linked with another instructor"))
fix: Exclude current record while validating duplicate employee
|
# -*- coding: utf-8 -*-
# Copyright (c) 2015, Frappe Technologies and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe import _
from frappe.model.document import Document
from frappe.model.naming import set_name_by_naming_series
class Instructor(Document):
def autoname(self):
naming_method = frappe.db.get_value("Education Settings", None, "instructor_created_by")
if not naming_method:
frappe.throw(_("Please setup Instructor Naming System in Education > Education Settings"))
else:
if naming_method == 'Naming Series':
set_name_by_naming_series(self)
elif naming_method == 'Employee Number':
if not self.employee:
frappe.throw(_("Please select Employee"))
self.name = self.employee
elif naming_method == 'Full Name':
self.name = self.instructor_name
def validate(self):
self.validate_duplicate_employee()
def validate_duplicate_employee(self):
if self.employee and frappe.db.get_value("Instructor", {'employee': self.employee, 'name': ['!=', self.name]}, 'name'):
frappe.throw(_("Employee ID is linked with another instructor"))
|
<commit_before># -*- coding: utf-8 -*-
# Copyright (c) 2015, Frappe Technologies and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe import _
from frappe.model.document import Document
from frappe.model.naming import set_name_by_naming_series
class Instructor(Document):
def autoname(self):
naming_method = frappe.db.get_value("Education Settings", None, "instructor_created_by")
if not naming_method:
frappe.throw(_("Please setup Instructor Naming System in Education > Education Settings"))
else:
if naming_method == 'Naming Series':
set_name_by_naming_series(self)
elif naming_method == 'Employee Number':
if not self.employee:
frappe.throw(_("Please select Employee"))
self.name = self.employee
elif naming_method == 'Full Name':
self.name = self.instructor_name
def validate(self):
self.validate_duplicate_employee()
def validate_duplicate_employee(self):
if self.employee and frappe.db.get_value("Instructor", {'employee': self.employee}, 'name'):
frappe.throw(_("Employee ID is linked with another instructor"))
<commit_msg>fix: Exclude current record while validating duplicate employee<commit_after>
|
# -*- coding: utf-8 -*-
# Copyright (c) 2015, Frappe Technologies and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe import _
from frappe.model.document import Document
from frappe.model.naming import set_name_by_naming_series
class Instructor(Document):
def autoname(self):
naming_method = frappe.db.get_value("Education Settings", None, "instructor_created_by")
if not naming_method:
frappe.throw(_("Please setup Instructor Naming System in Education > Education Settings"))
else:
if naming_method == 'Naming Series':
set_name_by_naming_series(self)
elif naming_method == 'Employee Number':
if not self.employee:
frappe.throw(_("Please select Employee"))
self.name = self.employee
elif naming_method == 'Full Name':
self.name = self.instructor_name
def validate(self):
self.validate_duplicate_employee()
def validate_duplicate_employee(self):
if self.employee and frappe.db.get_value("Instructor", {'employee': self.employee, 'name': ['!=', self.name]}, 'name'):
frappe.throw(_("Employee ID is linked with another instructor"))
|
# -*- coding: utf-8 -*-
# Copyright (c) 2015, Frappe Technologies and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe import _
from frappe.model.document import Document
from frappe.model.naming import set_name_by_naming_series
class Instructor(Document):
def autoname(self):
naming_method = frappe.db.get_value("Education Settings", None, "instructor_created_by")
if not naming_method:
frappe.throw(_("Please setup Instructor Naming System in Education > Education Settings"))
else:
if naming_method == 'Naming Series':
set_name_by_naming_series(self)
elif naming_method == 'Employee Number':
if not self.employee:
frappe.throw(_("Please select Employee"))
self.name = self.employee
elif naming_method == 'Full Name':
self.name = self.instructor_name
def validate(self):
self.validate_duplicate_employee()
def validate_duplicate_employee(self):
if self.employee and frappe.db.get_value("Instructor", {'employee': self.employee}, 'name'):
frappe.throw(_("Employee ID is linked with another instructor"))
fix: Exclude current record while validating duplicate employee# -*- coding: utf-8 -*-
# Copyright (c) 2015, Frappe Technologies and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe import _
from frappe.model.document import Document
from frappe.model.naming import set_name_by_naming_series
class Instructor(Document):
def autoname(self):
naming_method = frappe.db.get_value("Education Settings", None, "instructor_created_by")
if not naming_method:
frappe.throw(_("Please setup Instructor Naming System in Education > Education Settings"))
else:
if naming_method == 'Naming Series':
set_name_by_naming_series(self)
elif naming_method == 'Employee Number':
if not self.employee:
frappe.throw(_("Please select Employee"))
self.name = self.employee
elif naming_method == 'Full Name':
self.name = self.instructor_name
def validate(self):
self.validate_duplicate_employee()
def validate_duplicate_employee(self):
if self.employee and frappe.db.get_value("Instructor", {'employee': self.employee, 'name': ['!=', self.name]}, 'name'):
frappe.throw(_("Employee ID is linked with another instructor"))
|
<commit_before># -*- coding: utf-8 -*-
# Copyright (c) 2015, Frappe Technologies and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe import _
from frappe.model.document import Document
from frappe.model.naming import set_name_by_naming_series
class Instructor(Document):
def autoname(self):
naming_method = frappe.db.get_value("Education Settings", None, "instructor_created_by")
if not naming_method:
frappe.throw(_("Please setup Instructor Naming System in Education > Education Settings"))
else:
if naming_method == 'Naming Series':
set_name_by_naming_series(self)
elif naming_method == 'Employee Number':
if not self.employee:
frappe.throw(_("Please select Employee"))
self.name = self.employee
elif naming_method == 'Full Name':
self.name = self.instructor_name
def validate(self):
self.validate_duplicate_employee()
def validate_duplicate_employee(self):
if self.employee and frappe.db.get_value("Instructor", {'employee': self.employee}, 'name'):
frappe.throw(_("Employee ID is linked with another instructor"))
<commit_msg>fix: Exclude current record while validating duplicate employee<commit_after># -*- coding: utf-8 -*-
# Copyright (c) 2015, Frappe Technologies and contributors
# For license information, please see license.txt
from __future__ import unicode_literals
import frappe
from frappe import _
from frappe.model.document import Document
from frappe.model.naming import set_name_by_naming_series
class Instructor(Document):
def autoname(self):
naming_method = frappe.db.get_value("Education Settings", None, "instructor_created_by")
if not naming_method:
frappe.throw(_("Please setup Instructor Naming System in Education > Education Settings"))
else:
if naming_method == 'Naming Series':
set_name_by_naming_series(self)
elif naming_method == 'Employee Number':
if not self.employee:
frappe.throw(_("Please select Employee"))
self.name = self.employee
elif naming_method == 'Full Name':
self.name = self.instructor_name
def validate(self):
self.validate_duplicate_employee()
def validate_duplicate_employee(self):
if self.employee and frappe.db.get_value("Instructor", {'employee': self.employee, 'name': ['!=', self.name]}, 'name'):
frappe.throw(_("Employee ID is linked with another instructor"))
|
22bca7f50c9db97aaa79c1199b385b0f59968328
|
client/tests/tests_msgpack.py
|
client/tests/tests_msgpack.py
|
import unittest
from msgpack import *
class MessagePackTestCase(unittest.TestCase):
"""
This is not really a comprehensive test suite for messagepack but instead a
way to learn how to use the api.
"""
def test_can_pack_fixarray(self):
"""
Checks that we can pack a fix array (len(array) < 16).
"""
data = [1,2,3]
expected = bytes([0x93, 1, 2, 3])
self.assertEqual(expected, packb(data))
def test_can_pack_bytes(self):
"""
Checks that we can use binary types. By default msgpack uses str types
for bytes() so we need to use a Packer object correctly configured.
"""
packer = Packer(use_bin_type=True)
data = bytes([0, 1, 2, 3])
# Format is 0xc4, lenght, data
expected = bytes([0xc4, 4, 0, 1, 2, 3])
self.assertEqual(expected, packer.pack(data))
|
import unittest
from msgpack import *
class MessagePackTestCase(unittest.TestCase):
"""
This is not really a comprehensive test suite for messagepack but instead a
way to learn how to use the api.
"""
def test_can_pack_fixarray(self):
"""
Checks that we can pack a fix array (len(array) < 16).
"""
data = [1,2,3]
expected = bytes([0x93, 1, 2, 3])
self.assertEqual(expected, packb(data))
def test_can_pack_bytes(self):
"""
Checks that we can use binary types. By default msgpack uses str types
for bytes() so we need to use a Packer object correctly configured.
"""
packer = Packer(use_bin_type=True)
data = bytes([0, 1, 2, 3])
# Format is 0xc4, lenght, data
expected = bytes([0xc4, 4, 0, 1, 2, 3])
self.assertEqual(expected, packer.pack(data))
def test_can_unpack_multiple_values(self):
"""
Checks that we can unpack a stream of value as used in the command format.
"""
packer = Packer(use_bin_type=True)
# Creates command stream
data = packb(1) + packb([1,2,3])
# Stream deserializes it
a = Unpacker()
a.feed(data)
self.assertEqual(list(a), [1, [1,2,3]])
|
Add an example showing stream unpacking
|
Add an example showing stream unpacking
|
Python
|
bsd-2-clause
|
cvra/can-bootloader,cvra/can-bootloader,cvra/can-bootloader,cvra/can-bootloader
|
import unittest
from msgpack import *
class MessagePackTestCase(unittest.TestCase):
"""
This is not really a comprehensive test suite for messagepack but instead a
way to learn how to use the api.
"""
def test_can_pack_fixarray(self):
"""
Checks that we can pack a fix array (len(array) < 16).
"""
data = [1,2,3]
expected = bytes([0x93, 1, 2, 3])
self.assertEqual(expected, packb(data))
def test_can_pack_bytes(self):
"""
Checks that we can use binary types. By default msgpack uses str types
for bytes() so we need to use a Packer object correctly configured.
"""
packer = Packer(use_bin_type=True)
data = bytes([0, 1, 2, 3])
# Format is 0xc4, lenght, data
expected = bytes([0xc4, 4, 0, 1, 2, 3])
self.assertEqual(expected, packer.pack(data))
Add an example showing stream unpacking
|
import unittest
from msgpack import *
class MessagePackTestCase(unittest.TestCase):
"""
This is not really a comprehensive test suite for messagepack but instead a
way to learn how to use the api.
"""
def test_can_pack_fixarray(self):
"""
Checks that we can pack a fix array (len(array) < 16).
"""
data = [1,2,3]
expected = bytes([0x93, 1, 2, 3])
self.assertEqual(expected, packb(data))
def test_can_pack_bytes(self):
"""
Checks that we can use binary types. By default msgpack uses str types
for bytes() so we need to use a Packer object correctly configured.
"""
packer = Packer(use_bin_type=True)
data = bytes([0, 1, 2, 3])
# Format is 0xc4, lenght, data
expected = bytes([0xc4, 4, 0, 1, 2, 3])
self.assertEqual(expected, packer.pack(data))
def test_can_unpack_multiple_values(self):
"""
Checks that we can unpack a stream of value as used in the command format.
"""
packer = Packer(use_bin_type=True)
# Creates command stream
data = packb(1) + packb([1,2,3])
# Stream deserializes it
a = Unpacker()
a.feed(data)
self.assertEqual(list(a), [1, [1,2,3]])
|
<commit_before>import unittest
from msgpack import *
class MessagePackTestCase(unittest.TestCase):
"""
This is not really a comprehensive test suite for messagepack but instead a
way to learn how to use the api.
"""
def test_can_pack_fixarray(self):
"""
Checks that we can pack a fix array (len(array) < 16).
"""
data = [1,2,3]
expected = bytes([0x93, 1, 2, 3])
self.assertEqual(expected, packb(data))
def test_can_pack_bytes(self):
"""
Checks that we can use binary types. By default msgpack uses str types
for bytes() so we need to use a Packer object correctly configured.
"""
packer = Packer(use_bin_type=True)
data = bytes([0, 1, 2, 3])
# Format is 0xc4, lenght, data
expected = bytes([0xc4, 4, 0, 1, 2, 3])
self.assertEqual(expected, packer.pack(data))
<commit_msg>Add an example showing stream unpacking<commit_after>
|
import unittest
from msgpack import *
class MessagePackTestCase(unittest.TestCase):
"""
This is not really a comprehensive test suite for messagepack but instead a
way to learn how to use the api.
"""
def test_can_pack_fixarray(self):
"""
Checks that we can pack a fix array (len(array) < 16).
"""
data = [1,2,3]
expected = bytes([0x93, 1, 2, 3])
self.assertEqual(expected, packb(data))
def test_can_pack_bytes(self):
"""
Checks that we can use binary types. By default msgpack uses str types
for bytes() so we need to use a Packer object correctly configured.
"""
packer = Packer(use_bin_type=True)
data = bytes([0, 1, 2, 3])
# Format is 0xc4, lenght, data
expected = bytes([0xc4, 4, 0, 1, 2, 3])
self.assertEqual(expected, packer.pack(data))
def test_can_unpack_multiple_values(self):
"""
Checks that we can unpack a stream of value as used in the command format.
"""
packer = Packer(use_bin_type=True)
# Creates command stream
data = packb(1) + packb([1,2,3])
# Stream deserializes it
a = Unpacker()
a.feed(data)
self.assertEqual(list(a), [1, [1,2,3]])
|
import unittest
from msgpack import *
class MessagePackTestCase(unittest.TestCase):
"""
This is not really a comprehensive test suite for messagepack but instead a
way to learn how to use the api.
"""
def test_can_pack_fixarray(self):
"""
Checks that we can pack a fix array (len(array) < 16).
"""
data = [1,2,3]
expected = bytes([0x93, 1, 2, 3])
self.assertEqual(expected, packb(data))
def test_can_pack_bytes(self):
"""
Checks that we can use binary types. By default msgpack uses str types
for bytes() so we need to use a Packer object correctly configured.
"""
packer = Packer(use_bin_type=True)
data = bytes([0, 1, 2, 3])
# Format is 0xc4, lenght, data
expected = bytes([0xc4, 4, 0, 1, 2, 3])
self.assertEqual(expected, packer.pack(data))
Add an example showing stream unpackingimport unittest
from msgpack import *
class MessagePackTestCase(unittest.TestCase):
"""
This is not really a comprehensive test suite for messagepack but instead a
way to learn how to use the api.
"""
def test_can_pack_fixarray(self):
"""
Checks that we can pack a fix array (len(array) < 16).
"""
data = [1,2,3]
expected = bytes([0x93, 1, 2, 3])
self.assertEqual(expected, packb(data))
def test_can_pack_bytes(self):
"""
Checks that we can use binary types. By default msgpack uses str types
for bytes() so we need to use a Packer object correctly configured.
"""
packer = Packer(use_bin_type=True)
data = bytes([0, 1, 2, 3])
# Format is 0xc4, lenght, data
expected = bytes([0xc4, 4, 0, 1, 2, 3])
self.assertEqual(expected, packer.pack(data))
def test_can_unpack_multiple_values(self):
"""
Checks that we can unpack a stream of value as used in the command format.
"""
packer = Packer(use_bin_type=True)
# Creates command stream
data = packb(1) + packb([1,2,3])
# Stream deserializes it
a = Unpacker()
a.feed(data)
self.assertEqual(list(a), [1, [1,2,3]])
|
<commit_before>import unittest
from msgpack import *
class MessagePackTestCase(unittest.TestCase):
"""
This is not really a comprehensive test suite for messagepack but instead a
way to learn how to use the api.
"""
def test_can_pack_fixarray(self):
"""
Checks that we can pack a fix array (len(array) < 16).
"""
data = [1,2,3]
expected = bytes([0x93, 1, 2, 3])
self.assertEqual(expected, packb(data))
def test_can_pack_bytes(self):
"""
Checks that we can use binary types. By default msgpack uses str types
for bytes() so we need to use a Packer object correctly configured.
"""
packer = Packer(use_bin_type=True)
data = bytes([0, 1, 2, 3])
# Format is 0xc4, lenght, data
expected = bytes([0xc4, 4, 0, 1, 2, 3])
self.assertEqual(expected, packer.pack(data))
<commit_msg>Add an example showing stream unpacking<commit_after>import unittest
from msgpack import *
class MessagePackTestCase(unittest.TestCase):
"""
This is not really a comprehensive test suite for messagepack but instead a
way to learn how to use the api.
"""
def test_can_pack_fixarray(self):
"""
Checks that we can pack a fix array (len(array) < 16).
"""
data = [1,2,3]
expected = bytes([0x93, 1, 2, 3])
self.assertEqual(expected, packb(data))
def test_can_pack_bytes(self):
"""
Checks that we can use binary types. By default msgpack uses str types
for bytes() so we need to use a Packer object correctly configured.
"""
packer = Packer(use_bin_type=True)
data = bytes([0, 1, 2, 3])
# Format is 0xc4, lenght, data
expected = bytes([0xc4, 4, 0, 1, 2, 3])
self.assertEqual(expected, packer.pack(data))
def test_can_unpack_multiple_values(self):
"""
Checks that we can unpack a stream of value as used in the command format.
"""
packer = Packer(use_bin_type=True)
# Creates command stream
data = packb(1) + packb([1,2,3])
# Stream deserializes it
a = Unpacker()
a.feed(data)
self.assertEqual(list(a), [1, [1,2,3]])
|
0ba44cc7a8e906be42d98599b59e28ad142648b7
|
blogApp/forms/upload_image.py
|
blogApp/forms/upload_image.py
|
from django import forms
from crispy_forms.helper import FormHelper
from crispy_forms.bootstrap import FormActions, Div
from crispy_forms.layout import Layout, Field, HTML, Button, Submit, Reset
class UploadImageForm(forms.Form):
helper = FormHelper()
helper.form_tag = False
helper.form_class = 'form-horizontal'
helper.label_class = 'col-xs-3'
helper.field_class = 'col-xs-9'
title = forms.CharField(
label = "Alt. Title",
required = True,
max_length=50,
)
image = forms.FileField(
label = "Image",
required = True,
)
resize = forms.IntegerField(
label = "Resize to this width or height",
initial = 1000,
required = True,
)
helper.layout = Layout(
Field('title'),
Field('image'),
Field('resize'),
Div(
FormActions(
HTML('<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>'),
Submit('save', 'Upload'),
),
css_class="modal-footer"
),
)
|
from django import forms
from crispy_forms.helper import FormHelper
from crispy_forms.bootstrap import FormActions, Div, AppendedText
from crispy_forms.layout import Layout, Field, HTML, Button, Submit, Reset
class UploadImageForm(forms.Form):
helper = FormHelper()
helper.form_tag = False
helper.form_class = 'form-horizontal'
helper.label_class = 'col-xs-3'
helper.field_class = 'col-xs-9'
title = forms.CharField(
label = "Alt. Title",
required = True,
max_length=50,
)
image = forms.FileField(
label = "Image",
required = True,
)
resize = forms.IntegerField(
label = "Resize to this width or height",
initial = 1000,
required = True,
)
helper.layout = Layout(
Field('title'),
Field('image'),
AppendedText('resize', 'px'),
Div(
FormActions(
HTML('<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>'),
Submit('save', 'Upload'),
),
css_class="modal-footer"
),
)
|
Append 'px' to end of image upload form resize field
|
Append 'px' to end of image upload form resize field
|
Python
|
mit
|
SPARLab/BikeMaps,SPARLab/BikeMaps,SPARLab/BikeMaps
|
from django import forms
from crispy_forms.helper import FormHelper
from crispy_forms.bootstrap import FormActions, Div
from crispy_forms.layout import Layout, Field, HTML, Button, Submit, Reset
class UploadImageForm(forms.Form):
helper = FormHelper()
helper.form_tag = False
helper.form_class = 'form-horizontal'
helper.label_class = 'col-xs-3'
helper.field_class = 'col-xs-9'
title = forms.CharField(
label = "Alt. Title",
required = True,
max_length=50,
)
image = forms.FileField(
label = "Image",
required = True,
)
resize = forms.IntegerField(
label = "Resize to this width or height",
initial = 1000,
required = True,
)
helper.layout = Layout(
Field('title'),
Field('image'),
Field('resize'),
Div(
FormActions(
HTML('<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>'),
Submit('save', 'Upload'),
),
css_class="modal-footer"
),
)
Append 'px' to end of image upload form resize field
|
from django import forms
from crispy_forms.helper import FormHelper
from crispy_forms.bootstrap import FormActions, Div, AppendedText
from crispy_forms.layout import Layout, Field, HTML, Button, Submit, Reset
class UploadImageForm(forms.Form):
helper = FormHelper()
helper.form_tag = False
helper.form_class = 'form-horizontal'
helper.label_class = 'col-xs-3'
helper.field_class = 'col-xs-9'
title = forms.CharField(
label = "Alt. Title",
required = True,
max_length=50,
)
image = forms.FileField(
label = "Image",
required = True,
)
resize = forms.IntegerField(
label = "Resize to this width or height",
initial = 1000,
required = True,
)
helper.layout = Layout(
Field('title'),
Field('image'),
AppendedText('resize', 'px'),
Div(
FormActions(
HTML('<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>'),
Submit('save', 'Upload'),
),
css_class="modal-footer"
),
)
|
<commit_before>from django import forms
from crispy_forms.helper import FormHelper
from crispy_forms.bootstrap import FormActions, Div
from crispy_forms.layout import Layout, Field, HTML, Button, Submit, Reset
class UploadImageForm(forms.Form):
helper = FormHelper()
helper.form_tag = False
helper.form_class = 'form-horizontal'
helper.label_class = 'col-xs-3'
helper.field_class = 'col-xs-9'
title = forms.CharField(
label = "Alt. Title",
required = True,
max_length=50,
)
image = forms.FileField(
label = "Image",
required = True,
)
resize = forms.IntegerField(
label = "Resize to this width or height",
initial = 1000,
required = True,
)
helper.layout = Layout(
Field('title'),
Field('image'),
Field('resize'),
Div(
FormActions(
HTML('<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>'),
Submit('save', 'Upload'),
),
css_class="modal-footer"
),
)
<commit_msg>Append 'px' to end of image upload form resize field<commit_after>
|
from django import forms
from crispy_forms.helper import FormHelper
from crispy_forms.bootstrap import FormActions, Div, AppendedText
from crispy_forms.layout import Layout, Field, HTML, Button, Submit, Reset
class UploadImageForm(forms.Form):
helper = FormHelper()
helper.form_tag = False
helper.form_class = 'form-horizontal'
helper.label_class = 'col-xs-3'
helper.field_class = 'col-xs-9'
title = forms.CharField(
label = "Alt. Title",
required = True,
max_length=50,
)
image = forms.FileField(
label = "Image",
required = True,
)
resize = forms.IntegerField(
label = "Resize to this width or height",
initial = 1000,
required = True,
)
helper.layout = Layout(
Field('title'),
Field('image'),
AppendedText('resize', 'px'),
Div(
FormActions(
HTML('<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>'),
Submit('save', 'Upload'),
),
css_class="modal-footer"
),
)
|
from django import forms
from crispy_forms.helper import FormHelper
from crispy_forms.bootstrap import FormActions, Div
from crispy_forms.layout import Layout, Field, HTML, Button, Submit, Reset
class UploadImageForm(forms.Form):
helper = FormHelper()
helper.form_tag = False
helper.form_class = 'form-horizontal'
helper.label_class = 'col-xs-3'
helper.field_class = 'col-xs-9'
title = forms.CharField(
label = "Alt. Title",
required = True,
max_length=50,
)
image = forms.FileField(
label = "Image",
required = True,
)
resize = forms.IntegerField(
label = "Resize to this width or height",
initial = 1000,
required = True,
)
helper.layout = Layout(
Field('title'),
Field('image'),
Field('resize'),
Div(
FormActions(
HTML('<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>'),
Submit('save', 'Upload'),
),
css_class="modal-footer"
),
)
Append 'px' to end of image upload form resize fieldfrom django import forms
from crispy_forms.helper import FormHelper
from crispy_forms.bootstrap import FormActions, Div, AppendedText
from crispy_forms.layout import Layout, Field, HTML, Button, Submit, Reset
class UploadImageForm(forms.Form):
helper = FormHelper()
helper.form_tag = False
helper.form_class = 'form-horizontal'
helper.label_class = 'col-xs-3'
helper.field_class = 'col-xs-9'
title = forms.CharField(
label = "Alt. Title",
required = True,
max_length=50,
)
image = forms.FileField(
label = "Image",
required = True,
)
resize = forms.IntegerField(
label = "Resize to this width or height",
initial = 1000,
required = True,
)
helper.layout = Layout(
Field('title'),
Field('image'),
AppendedText('resize', 'px'),
Div(
FormActions(
HTML('<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>'),
Submit('save', 'Upload'),
),
css_class="modal-footer"
),
)
|
<commit_before>from django import forms
from crispy_forms.helper import FormHelper
from crispy_forms.bootstrap import FormActions, Div
from crispy_forms.layout import Layout, Field, HTML, Button, Submit, Reset
class UploadImageForm(forms.Form):
helper = FormHelper()
helper.form_tag = False
helper.form_class = 'form-horizontal'
helper.label_class = 'col-xs-3'
helper.field_class = 'col-xs-9'
title = forms.CharField(
label = "Alt. Title",
required = True,
max_length=50,
)
image = forms.FileField(
label = "Image",
required = True,
)
resize = forms.IntegerField(
label = "Resize to this width or height",
initial = 1000,
required = True,
)
helper.layout = Layout(
Field('title'),
Field('image'),
Field('resize'),
Div(
FormActions(
HTML('<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>'),
Submit('save', 'Upload'),
),
css_class="modal-footer"
),
)
<commit_msg>Append 'px' to end of image upload form resize field<commit_after>from django import forms
from crispy_forms.helper import FormHelper
from crispy_forms.bootstrap import FormActions, Div, AppendedText
from crispy_forms.layout import Layout, Field, HTML, Button, Submit, Reset
class UploadImageForm(forms.Form):
helper = FormHelper()
helper.form_tag = False
helper.form_class = 'form-horizontal'
helper.label_class = 'col-xs-3'
helper.field_class = 'col-xs-9'
title = forms.CharField(
label = "Alt. Title",
required = True,
max_length=50,
)
image = forms.FileField(
label = "Image",
required = True,
)
resize = forms.IntegerField(
label = "Resize to this width or height",
initial = 1000,
required = True,
)
helper.layout = Layout(
Field('title'),
Field('image'),
AppendedText('resize', 'px'),
Div(
FormActions(
HTML('<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>'),
Submit('save', 'Upload'),
),
css_class="modal-footer"
),
)
|
90991af1b5c50c106bf18b743c9e29e9aafd5f32
|
pony_server/api/urls.py
|
pony_server/api/urls.py
|
from django.conf.urls.defaults import *
from piston.resource import Resource
from pony_server.api.handlers import PackageHandler, RootHandler, BuildHandler, TagHandler
package_handler = Resource(PackageHandler)
root_handler = Resource(RootHandler)
build_handler = Resource(BuildHandler)
tag_handler = Resource(TagHandler)
urlpatterns = patterns('',
url(r'^package/(?P<slug>[^/]+)/builds/latest/', build_handler, {'latest': True }),
url(r'^package/(?P<slug>[^/]+)/builds/(?P<data>[^/]+)/', build_handler),
url(r'^package/(?P<slug>[^/]+)/builds/', build_handler),
url(r'^package/(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/latest/', tag_handler, {'latest': True }),
url(r'^package/(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/', tag_handler),
url(r'^package/(?P<slug>[^/]+)/tags/', tag_handler),
url(r'^package/(?P<slug>[^/]+)/', package_handler),
url(r'^$', root_handler),
)
|
from django.conf.urls.defaults import *
from piston.resource import Resource
from pony_server.api.handlers import PackageHandler, RootHandler, BuildHandler, TagHandler
package_handler = Resource(PackageHandler)
root_handler = Resource(RootHandler)
build_handler = Resource(BuildHandler)
tag_handler = Resource(TagHandler)
urlpatterns = patterns('',
url(r'^(?P<slug>[^/]+)/builds/latest/', build_handler, {'latest': True }),
url(r'^(?P<slug>[^/]+)/builds/(?P<data>[^/]+)/', build_handler),
url(r'^(?P<slug>[^/]+)/builds/', build_handler),
url(r'^(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/latest/', tag_handler, {'latest': True }),
url(r'^(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/', tag_handler),
url(r'^(?P<slug>[^/]+)/tags/', tag_handler),
url(r'^(?P<slug>[^/]+)/', package_handler),
url(r'^$', root_handler),
)
|
Remove package namespace in the URLS since it was useless.
|
Remove package namespace in the URLS since it was useless.
|
Python
|
mit
|
ericholscher/devmason-server,ericholscher/devmason-server
|
from django.conf.urls.defaults import *
from piston.resource import Resource
from pony_server.api.handlers import PackageHandler, RootHandler, BuildHandler, TagHandler
package_handler = Resource(PackageHandler)
root_handler = Resource(RootHandler)
build_handler = Resource(BuildHandler)
tag_handler = Resource(TagHandler)
urlpatterns = patterns('',
url(r'^package/(?P<slug>[^/]+)/builds/latest/', build_handler, {'latest': True }),
url(r'^package/(?P<slug>[^/]+)/builds/(?P<data>[^/]+)/', build_handler),
url(r'^package/(?P<slug>[^/]+)/builds/', build_handler),
url(r'^package/(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/latest/', tag_handler, {'latest': True }),
url(r'^package/(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/', tag_handler),
url(r'^package/(?P<slug>[^/]+)/tags/', tag_handler),
url(r'^package/(?P<slug>[^/]+)/', package_handler),
url(r'^$', root_handler),
)
Remove package namespace in the URLS since it was useless.
|
from django.conf.urls.defaults import *
from piston.resource import Resource
from pony_server.api.handlers import PackageHandler, RootHandler, BuildHandler, TagHandler
package_handler = Resource(PackageHandler)
root_handler = Resource(RootHandler)
build_handler = Resource(BuildHandler)
tag_handler = Resource(TagHandler)
urlpatterns = patterns('',
url(r'^(?P<slug>[^/]+)/builds/latest/', build_handler, {'latest': True }),
url(r'^(?P<slug>[^/]+)/builds/(?P<data>[^/]+)/', build_handler),
url(r'^(?P<slug>[^/]+)/builds/', build_handler),
url(r'^(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/latest/', tag_handler, {'latest': True }),
url(r'^(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/', tag_handler),
url(r'^(?P<slug>[^/]+)/tags/', tag_handler),
url(r'^(?P<slug>[^/]+)/', package_handler),
url(r'^$', root_handler),
)
|
<commit_before>from django.conf.urls.defaults import *
from piston.resource import Resource
from pony_server.api.handlers import PackageHandler, RootHandler, BuildHandler, TagHandler
package_handler = Resource(PackageHandler)
root_handler = Resource(RootHandler)
build_handler = Resource(BuildHandler)
tag_handler = Resource(TagHandler)
urlpatterns = patterns('',
url(r'^package/(?P<slug>[^/]+)/builds/latest/', build_handler, {'latest': True }),
url(r'^package/(?P<slug>[^/]+)/builds/(?P<data>[^/]+)/', build_handler),
url(r'^package/(?P<slug>[^/]+)/builds/', build_handler),
url(r'^package/(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/latest/', tag_handler, {'latest': True }),
url(r'^package/(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/', tag_handler),
url(r'^package/(?P<slug>[^/]+)/tags/', tag_handler),
url(r'^package/(?P<slug>[^/]+)/', package_handler),
url(r'^$', root_handler),
)
<commit_msg>Remove package namespace in the URLS since it was useless.<commit_after>
|
from django.conf.urls.defaults import *
from piston.resource import Resource
from pony_server.api.handlers import PackageHandler, RootHandler, BuildHandler, TagHandler
package_handler = Resource(PackageHandler)
root_handler = Resource(RootHandler)
build_handler = Resource(BuildHandler)
tag_handler = Resource(TagHandler)
urlpatterns = patterns('',
url(r'^(?P<slug>[^/]+)/builds/latest/', build_handler, {'latest': True }),
url(r'^(?P<slug>[^/]+)/builds/(?P<data>[^/]+)/', build_handler),
url(r'^(?P<slug>[^/]+)/builds/', build_handler),
url(r'^(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/latest/', tag_handler, {'latest': True }),
url(r'^(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/', tag_handler),
url(r'^(?P<slug>[^/]+)/tags/', tag_handler),
url(r'^(?P<slug>[^/]+)/', package_handler),
url(r'^$', root_handler),
)
|
from django.conf.urls.defaults import *
from piston.resource import Resource
from pony_server.api.handlers import PackageHandler, RootHandler, BuildHandler, TagHandler
package_handler = Resource(PackageHandler)
root_handler = Resource(RootHandler)
build_handler = Resource(BuildHandler)
tag_handler = Resource(TagHandler)
urlpatterns = patterns('',
url(r'^package/(?P<slug>[^/]+)/builds/latest/', build_handler, {'latest': True }),
url(r'^package/(?P<slug>[^/]+)/builds/(?P<data>[^/]+)/', build_handler),
url(r'^package/(?P<slug>[^/]+)/builds/', build_handler),
url(r'^package/(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/latest/', tag_handler, {'latest': True }),
url(r'^package/(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/', tag_handler),
url(r'^package/(?P<slug>[^/]+)/tags/', tag_handler),
url(r'^package/(?P<slug>[^/]+)/', package_handler),
url(r'^$', root_handler),
)
Remove package namespace in the URLS since it was useless.from django.conf.urls.defaults import *
from piston.resource import Resource
from pony_server.api.handlers import PackageHandler, RootHandler, BuildHandler, TagHandler
package_handler = Resource(PackageHandler)
root_handler = Resource(RootHandler)
build_handler = Resource(BuildHandler)
tag_handler = Resource(TagHandler)
urlpatterns = patterns('',
url(r'^(?P<slug>[^/]+)/builds/latest/', build_handler, {'latest': True }),
url(r'^(?P<slug>[^/]+)/builds/(?P<data>[^/]+)/', build_handler),
url(r'^(?P<slug>[^/]+)/builds/', build_handler),
url(r'^(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/latest/', tag_handler, {'latest': True }),
url(r'^(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/', tag_handler),
url(r'^(?P<slug>[^/]+)/tags/', tag_handler),
url(r'^(?P<slug>[^/]+)/', package_handler),
url(r'^$', root_handler),
)
|
<commit_before>from django.conf.urls.defaults import *
from piston.resource import Resource
from pony_server.api.handlers import PackageHandler, RootHandler, BuildHandler, TagHandler
package_handler = Resource(PackageHandler)
root_handler = Resource(RootHandler)
build_handler = Resource(BuildHandler)
tag_handler = Resource(TagHandler)
urlpatterns = patterns('',
url(r'^package/(?P<slug>[^/]+)/builds/latest/', build_handler, {'latest': True }),
url(r'^package/(?P<slug>[^/]+)/builds/(?P<data>[^/]+)/', build_handler),
url(r'^package/(?P<slug>[^/]+)/builds/', build_handler),
url(r'^package/(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/latest/', tag_handler, {'latest': True }),
url(r'^package/(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/', tag_handler),
url(r'^package/(?P<slug>[^/]+)/tags/', tag_handler),
url(r'^package/(?P<slug>[^/]+)/', package_handler),
url(r'^$', root_handler),
)
<commit_msg>Remove package namespace in the URLS since it was useless.<commit_after>from django.conf.urls.defaults import *
from piston.resource import Resource
from pony_server.api.handlers import PackageHandler, RootHandler, BuildHandler, TagHandler
package_handler = Resource(PackageHandler)
root_handler = Resource(RootHandler)
build_handler = Resource(BuildHandler)
tag_handler = Resource(TagHandler)
urlpatterns = patterns('',
url(r'^(?P<slug>[^/]+)/builds/latest/', build_handler, {'latest': True }),
url(r'^(?P<slug>[^/]+)/builds/(?P<data>[^/]+)/', build_handler),
url(r'^(?P<slug>[^/]+)/builds/', build_handler),
url(r'^(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/latest/', tag_handler, {'latest': True }),
url(r'^(?P<slug>[^/]+)/tags/(?P<data>[^/]+)/', tag_handler),
url(r'^(?P<slug>[^/]+)/tags/', tag_handler),
url(r'^(?P<slug>[^/]+)/', package_handler),
url(r'^$', root_handler),
)
|
5407e5dbde014c1957216a2a5cddf79bc4b9dad6
|
create/server.py
|
create/server.py
|
#!/usr/bin/env python
from flask import Flask, render_template
app = Flask(__name__)
app.config.from_envvar('CREATE_CFG')
@app.route('/')
def index():
return render_template('index.html')
if __name__ == '__main__':
app.run(host='0.0.0.0', port=app.config['PORT'])
|
#!/usr/bin/env python
from flask import Flask, render_template
app = Flask(__name__)
app.config.from_envvar('CREATE_CFG')
@app.route('/')
def index():
return render_template('index.html')
if __name__ == '__main__':
app.run(host='0.0.0.0', port=app.config['PORT'])
|
Move query stuff to model.py due to fight within team over it. It was brutally removed.
|
Move query stuff to model.py due to fight within team over it. It was brutally removed.
|
Python
|
mit
|
Garee/CREATe,Garee/CREATe,Garee/CREATe
|
#!/usr/bin/env python
from flask import Flask, render_template
app = Flask(__name__)
app.config.from_envvar('CREATE_CFG')
@app.route('/')
def index():
return render_template('index.html')
if __name__ == '__main__':
app.run(host='0.0.0.0', port=app.config['PORT'])Move query stuff to model.py due to fight within team over it. It was brutally removed.
|
#!/usr/bin/env python
from flask import Flask, render_template
app = Flask(__name__)
app.config.from_envvar('CREATE_CFG')
@app.route('/')
def index():
return render_template('index.html')
if __name__ == '__main__':
app.run(host='0.0.0.0', port=app.config['PORT'])
|
<commit_before>#!/usr/bin/env python
from flask import Flask, render_template
app = Flask(__name__)
app.config.from_envvar('CREATE_CFG')
@app.route('/')
def index():
return render_template('index.html')
if __name__ == '__main__':
app.run(host='0.0.0.0', port=app.config['PORT'])<commit_msg>Move query stuff to model.py due to fight within team over it. It was brutally removed.<commit_after>
|
#!/usr/bin/env python
from flask import Flask, render_template
app = Flask(__name__)
app.config.from_envvar('CREATE_CFG')
@app.route('/')
def index():
return render_template('index.html')
if __name__ == '__main__':
app.run(host='0.0.0.0', port=app.config['PORT'])
|
#!/usr/bin/env python
from flask import Flask, render_template
app = Flask(__name__)
app.config.from_envvar('CREATE_CFG')
@app.route('/')
def index():
return render_template('index.html')
if __name__ == '__main__':
app.run(host='0.0.0.0', port=app.config['PORT'])Move query stuff to model.py due to fight within team over it. It was brutally removed.#!/usr/bin/env python
from flask import Flask, render_template
app = Flask(__name__)
app.config.from_envvar('CREATE_CFG')
@app.route('/')
def index():
return render_template('index.html')
if __name__ == '__main__':
app.run(host='0.0.0.0', port=app.config['PORT'])
|
<commit_before>#!/usr/bin/env python
from flask import Flask, render_template
app = Flask(__name__)
app.config.from_envvar('CREATE_CFG')
@app.route('/')
def index():
return render_template('index.html')
if __name__ == '__main__':
app.run(host='0.0.0.0', port=app.config['PORT'])<commit_msg>Move query stuff to model.py due to fight within team over it. It was brutally removed.<commit_after>#!/usr/bin/env python
from flask import Flask, render_template
app = Flask(__name__)
app.config.from_envvar('CREATE_CFG')
@app.route('/')
def index():
return render_template('index.html')
if __name__ == '__main__':
app.run(host='0.0.0.0', port=app.config['PORT'])
|
2f76c0629ee1ff995718300f268b27cc3bd532f1
|
ddsc_api/views.py
|
ddsc_api/views.py
|
# (c) Nelen & Schuurmans. MIT licensed, see LICENSE.rst.
from __future__ import print_function, unicode_literals
from __future__ import absolute_import, division
from collections import OrderedDict
from rest_framework.reverse import reverse
from rest_framework.views import APIView
from rest_framework.response import Response
class Root(APIView):
def get(self, request, format=None):
response = OrderedDict([
('datasets', reverse('dataset-list', request=request)),
('locations', reverse('location-list', request=request)),
('timeseries', reverse('timeseries-list', request=request)),
('parameters', reverse('parameter-list', request=request)),
('logicalgroups', reverse('logicalgroup-list', request=request)),
('layers', reverse('layer-list', request=request)),
('collages', reverse('collage-list', request=request)),
])
user = getattr(request, 'user', None)
if user is not None and user.is_superuser:
response.update({
'users': reverse('user-list', request=request),
'groups': reverse('usergroup-list', request=request),
'roles': reverse('role-list', request=request),
})
return Response(response)
|
# (c) Nelen & Schuurmans. MIT licensed, see LICENSE.rst.
from __future__ import print_function, unicode_literals
from __future__ import absolute_import, division
from collections import OrderedDict
from rest_framework.reverse import reverse
from rest_framework.views import APIView
from rest_framework.response import Response
class Root(APIView):
def get(self, request, format=None):
response = OrderedDict([
('datasets', reverse('dataset-list', request=request)),
('locations', reverse('location-list', request=request)),
('timeseries', reverse('timeseries-list', request=request)),
('parameters', reverse('parameter-list', request=request)),
('logicalgroups', reverse('logicalgroup-list', request=request)),
('layers', reverse('layer-list', request=request)),
('collages', reverse('collage-list', request=request)),
('collageitems', reverse('collageitems-list', request))
])
user = getattr(request, 'user', None)
if user is not None and user.is_superuser:
response.update({
'users': reverse('user-list', request=request),
'groups': reverse('usergroup-list', request=request),
'roles': reverse('role-list', request=request),
})
return Response(response)
|
Add collageitems to the view.
|
Add collageitems to the view.
|
Python
|
mit
|
ddsc/ddsc-api,ddsc/ddsc-api
|
# (c) Nelen & Schuurmans. MIT licensed, see LICENSE.rst.
from __future__ import print_function, unicode_literals
from __future__ import absolute_import, division
from collections import OrderedDict
from rest_framework.reverse import reverse
from rest_framework.views import APIView
from rest_framework.response import Response
class Root(APIView):
def get(self, request, format=None):
response = OrderedDict([
('datasets', reverse('dataset-list', request=request)),
('locations', reverse('location-list', request=request)),
('timeseries', reverse('timeseries-list', request=request)),
('parameters', reverse('parameter-list', request=request)),
('logicalgroups', reverse('logicalgroup-list', request=request)),
('layers', reverse('layer-list', request=request)),
('collages', reverse('collage-list', request=request)),
])
user = getattr(request, 'user', None)
if user is not None and user.is_superuser:
response.update({
'users': reverse('user-list', request=request),
'groups': reverse('usergroup-list', request=request),
'roles': reverse('role-list', request=request),
})
return Response(response)
Add collageitems to the view.
|
# (c) Nelen & Schuurmans. MIT licensed, see LICENSE.rst.
from __future__ import print_function, unicode_literals
from __future__ import absolute_import, division
from collections import OrderedDict
from rest_framework.reverse import reverse
from rest_framework.views import APIView
from rest_framework.response import Response
class Root(APIView):
def get(self, request, format=None):
response = OrderedDict([
('datasets', reverse('dataset-list', request=request)),
('locations', reverse('location-list', request=request)),
('timeseries', reverse('timeseries-list', request=request)),
('parameters', reverse('parameter-list', request=request)),
('logicalgroups', reverse('logicalgroup-list', request=request)),
('layers', reverse('layer-list', request=request)),
('collages', reverse('collage-list', request=request)),
('collageitems', reverse('collageitems-list', request))
])
user = getattr(request, 'user', None)
if user is not None and user.is_superuser:
response.update({
'users': reverse('user-list', request=request),
'groups': reverse('usergroup-list', request=request),
'roles': reverse('role-list', request=request),
})
return Response(response)
|
<commit_before># (c) Nelen & Schuurmans. MIT licensed, see LICENSE.rst.
from __future__ import print_function, unicode_literals
from __future__ import absolute_import, division
from collections import OrderedDict
from rest_framework.reverse import reverse
from rest_framework.views import APIView
from rest_framework.response import Response
class Root(APIView):
def get(self, request, format=None):
response = OrderedDict([
('datasets', reverse('dataset-list', request=request)),
('locations', reverse('location-list', request=request)),
('timeseries', reverse('timeseries-list', request=request)),
('parameters', reverse('parameter-list', request=request)),
('logicalgroups', reverse('logicalgroup-list', request=request)),
('layers', reverse('layer-list', request=request)),
('collages', reverse('collage-list', request=request)),
])
user = getattr(request, 'user', None)
if user is not None and user.is_superuser:
response.update({
'users': reverse('user-list', request=request),
'groups': reverse('usergroup-list', request=request),
'roles': reverse('role-list', request=request),
})
return Response(response)
<commit_msg>Add collageitems to the view.<commit_after>
|
# (c) Nelen & Schuurmans. MIT licensed, see LICENSE.rst.
from __future__ import print_function, unicode_literals
from __future__ import absolute_import, division
from collections import OrderedDict
from rest_framework.reverse import reverse
from rest_framework.views import APIView
from rest_framework.response import Response
class Root(APIView):
def get(self, request, format=None):
response = OrderedDict([
('datasets', reverse('dataset-list', request=request)),
('locations', reverse('location-list', request=request)),
('timeseries', reverse('timeseries-list', request=request)),
('parameters', reverse('parameter-list', request=request)),
('logicalgroups', reverse('logicalgroup-list', request=request)),
('layers', reverse('layer-list', request=request)),
('collages', reverse('collage-list', request=request)),
('collageitems', reverse('collageitems-list', request))
])
user = getattr(request, 'user', None)
if user is not None and user.is_superuser:
response.update({
'users': reverse('user-list', request=request),
'groups': reverse('usergroup-list', request=request),
'roles': reverse('role-list', request=request),
})
return Response(response)
|
# (c) Nelen & Schuurmans. MIT licensed, see LICENSE.rst.
from __future__ import print_function, unicode_literals
from __future__ import absolute_import, division
from collections import OrderedDict
from rest_framework.reverse import reverse
from rest_framework.views import APIView
from rest_framework.response import Response
class Root(APIView):
def get(self, request, format=None):
response = OrderedDict([
('datasets', reverse('dataset-list', request=request)),
('locations', reverse('location-list', request=request)),
('timeseries', reverse('timeseries-list', request=request)),
('parameters', reverse('parameter-list', request=request)),
('logicalgroups', reverse('logicalgroup-list', request=request)),
('layers', reverse('layer-list', request=request)),
('collages', reverse('collage-list', request=request)),
])
user = getattr(request, 'user', None)
if user is not None and user.is_superuser:
response.update({
'users': reverse('user-list', request=request),
'groups': reverse('usergroup-list', request=request),
'roles': reverse('role-list', request=request),
})
return Response(response)
Add collageitems to the view.# (c) Nelen & Schuurmans. MIT licensed, see LICENSE.rst.
from __future__ import print_function, unicode_literals
from __future__ import absolute_import, division
from collections import OrderedDict
from rest_framework.reverse import reverse
from rest_framework.views import APIView
from rest_framework.response import Response
class Root(APIView):
def get(self, request, format=None):
response = OrderedDict([
('datasets', reverse('dataset-list', request=request)),
('locations', reverse('location-list', request=request)),
('timeseries', reverse('timeseries-list', request=request)),
('parameters', reverse('parameter-list', request=request)),
('logicalgroups', reverse('logicalgroup-list', request=request)),
('layers', reverse('layer-list', request=request)),
('collages', reverse('collage-list', request=request)),
('collageitems', reverse('collageitems-list', request))
])
user = getattr(request, 'user', None)
if user is not None and user.is_superuser:
response.update({
'users': reverse('user-list', request=request),
'groups': reverse('usergroup-list', request=request),
'roles': reverse('role-list', request=request),
})
return Response(response)
|
<commit_before># (c) Nelen & Schuurmans. MIT licensed, see LICENSE.rst.
from __future__ import print_function, unicode_literals
from __future__ import absolute_import, division
from collections import OrderedDict
from rest_framework.reverse import reverse
from rest_framework.views import APIView
from rest_framework.response import Response
class Root(APIView):
def get(self, request, format=None):
response = OrderedDict([
('datasets', reverse('dataset-list', request=request)),
('locations', reverse('location-list', request=request)),
('timeseries', reverse('timeseries-list', request=request)),
('parameters', reverse('parameter-list', request=request)),
('logicalgroups', reverse('logicalgroup-list', request=request)),
('layers', reverse('layer-list', request=request)),
('collages', reverse('collage-list', request=request)),
])
user = getattr(request, 'user', None)
if user is not None and user.is_superuser:
response.update({
'users': reverse('user-list', request=request),
'groups': reverse('usergroup-list', request=request),
'roles': reverse('role-list', request=request),
})
return Response(response)
<commit_msg>Add collageitems to the view.<commit_after># (c) Nelen & Schuurmans. MIT licensed, see LICENSE.rst.
from __future__ import print_function, unicode_literals
from __future__ import absolute_import, division
from collections import OrderedDict
from rest_framework.reverse import reverse
from rest_framework.views import APIView
from rest_framework.response import Response
class Root(APIView):
def get(self, request, format=None):
response = OrderedDict([
('datasets', reverse('dataset-list', request=request)),
('locations', reverse('location-list', request=request)),
('timeseries', reverse('timeseries-list', request=request)),
('parameters', reverse('parameter-list', request=request)),
('logicalgroups', reverse('logicalgroup-list', request=request)),
('layers', reverse('layer-list', request=request)),
('collages', reverse('collage-list', request=request)),
('collageitems', reverse('collageitems-list', request))
])
user = getattr(request, 'user', None)
if user is not None and user.is_superuser:
response.update({
'users': reverse('user-list', request=request),
'groups': reverse('usergroup-list', request=request),
'roles': reverse('role-list', request=request),
})
return Response(response)
|
b93644f758baa3f3a4e4ea506e8f0305d6503305
|
pathvalidate/_interface.py
|
pathvalidate/_interface.py
|
# encoding: utf-8
"""
.. codeauthor:: Tsuyoshi Hombashi <tsuyoshi.hombashi@gmail.com>
"""
from __future__ import absolute_import, unicode_literals
import abc
from ._common import _validate_null_string, is_pathlike_obj
from ._six import add_metaclass, text_type
@add_metaclass(abc.ABCMeta)
class NameSanitizer(object):
@abc.abstractproperty
def reserved_keywords(self): # pragma: no cover
pass
@abc.abstractmethod
def validate(self): # pragma: no cover
pass
@abc.abstractmethod
def sanitize(self, replacement_text=""): # pragma: no cover
pass
@property
def _str(self):
return text_type(self._value)
def __init__(self, value):
self._validate_null_string(value)
if is_pathlike_obj(value):
self._value = value
else:
self._value = value.strip()
def _is_pathlike_obj(self):
return is_pathlike_obj(self._value)
def _is_reserved_keyword(self, value):
return value in self.reserved_keywords
@staticmethod
def _validate_null_string(text, error_msg="null name"):
_validate_null_string(text)
|
# encoding: utf-8
"""
.. codeauthor:: Tsuyoshi Hombashi <tsuyoshi.hombashi@gmail.com>
"""
from __future__ import absolute_import, unicode_literals
import abc
from ._common import _validate_null_string, is_pathlike_obj
from ._six import add_metaclass, text_type
@add_metaclass(abc.ABCMeta)
class NameSanitizer(object):
@abc.abstractproperty
def reserved_keywords(self): # pragma: no cover
pass
@abc.abstractmethod
def validate(self): # pragma: no cover
pass
@abc.abstractmethod
def sanitize(self, replacement_text=""): # pragma: no cover
pass
@property
def _str(self):
return text_type(self._value)
def __init__(self, value):
self._validate_null_string(value)
if is_pathlike_obj(value):
self._value = value
else:
self._value = value.strip()
def _is_pathlike_obj(self):
return is_pathlike_obj(self._value)
def _is_reserved_keyword(self, value):
return value in self.reserved_keywords
@staticmethod
def _validate_null_string(text):
_validate_null_string(text, error_msg="null name")
|
Modify a function call argument
|
Modify a function call argument
|
Python
|
mit
|
thombashi/pathvalidate
|
# encoding: utf-8
"""
.. codeauthor:: Tsuyoshi Hombashi <tsuyoshi.hombashi@gmail.com>
"""
from __future__ import absolute_import, unicode_literals
import abc
from ._common import _validate_null_string, is_pathlike_obj
from ._six import add_metaclass, text_type
@add_metaclass(abc.ABCMeta)
class NameSanitizer(object):
@abc.abstractproperty
def reserved_keywords(self): # pragma: no cover
pass
@abc.abstractmethod
def validate(self): # pragma: no cover
pass
@abc.abstractmethod
def sanitize(self, replacement_text=""): # pragma: no cover
pass
@property
def _str(self):
return text_type(self._value)
def __init__(self, value):
self._validate_null_string(value)
if is_pathlike_obj(value):
self._value = value
else:
self._value = value.strip()
def _is_pathlike_obj(self):
return is_pathlike_obj(self._value)
def _is_reserved_keyword(self, value):
return value in self.reserved_keywords
@staticmethod
def _validate_null_string(text, error_msg="null name"):
_validate_null_string(text)
Modify a function call argument
|
# encoding: utf-8
"""
.. codeauthor:: Tsuyoshi Hombashi <tsuyoshi.hombashi@gmail.com>
"""
from __future__ import absolute_import, unicode_literals
import abc
from ._common import _validate_null_string, is_pathlike_obj
from ._six import add_metaclass, text_type
@add_metaclass(abc.ABCMeta)
class NameSanitizer(object):
@abc.abstractproperty
def reserved_keywords(self): # pragma: no cover
pass
@abc.abstractmethod
def validate(self): # pragma: no cover
pass
@abc.abstractmethod
def sanitize(self, replacement_text=""): # pragma: no cover
pass
@property
def _str(self):
return text_type(self._value)
def __init__(self, value):
self._validate_null_string(value)
if is_pathlike_obj(value):
self._value = value
else:
self._value = value.strip()
def _is_pathlike_obj(self):
return is_pathlike_obj(self._value)
def _is_reserved_keyword(self, value):
return value in self.reserved_keywords
@staticmethod
def _validate_null_string(text):
_validate_null_string(text, error_msg="null name")
|
<commit_before># encoding: utf-8
"""
.. codeauthor:: Tsuyoshi Hombashi <tsuyoshi.hombashi@gmail.com>
"""
from __future__ import absolute_import, unicode_literals
import abc
from ._common import _validate_null_string, is_pathlike_obj
from ._six import add_metaclass, text_type
@add_metaclass(abc.ABCMeta)
class NameSanitizer(object):
@abc.abstractproperty
def reserved_keywords(self): # pragma: no cover
pass
@abc.abstractmethod
def validate(self): # pragma: no cover
pass
@abc.abstractmethod
def sanitize(self, replacement_text=""): # pragma: no cover
pass
@property
def _str(self):
return text_type(self._value)
def __init__(self, value):
self._validate_null_string(value)
if is_pathlike_obj(value):
self._value = value
else:
self._value = value.strip()
def _is_pathlike_obj(self):
return is_pathlike_obj(self._value)
def _is_reserved_keyword(self, value):
return value in self.reserved_keywords
@staticmethod
def _validate_null_string(text, error_msg="null name"):
_validate_null_string(text)
<commit_msg>Modify a function call argument<commit_after>
|
# encoding: utf-8
"""
.. codeauthor:: Tsuyoshi Hombashi <tsuyoshi.hombashi@gmail.com>
"""
from __future__ import absolute_import, unicode_literals
import abc
from ._common import _validate_null_string, is_pathlike_obj
from ._six import add_metaclass, text_type
@add_metaclass(abc.ABCMeta)
class NameSanitizer(object):
@abc.abstractproperty
def reserved_keywords(self): # pragma: no cover
pass
@abc.abstractmethod
def validate(self): # pragma: no cover
pass
@abc.abstractmethod
def sanitize(self, replacement_text=""): # pragma: no cover
pass
@property
def _str(self):
return text_type(self._value)
def __init__(self, value):
self._validate_null_string(value)
if is_pathlike_obj(value):
self._value = value
else:
self._value = value.strip()
def _is_pathlike_obj(self):
return is_pathlike_obj(self._value)
def _is_reserved_keyword(self, value):
return value in self.reserved_keywords
@staticmethod
def _validate_null_string(text):
_validate_null_string(text, error_msg="null name")
|
# encoding: utf-8
"""
.. codeauthor:: Tsuyoshi Hombashi <tsuyoshi.hombashi@gmail.com>
"""
from __future__ import absolute_import, unicode_literals
import abc
from ._common import _validate_null_string, is_pathlike_obj
from ._six import add_metaclass, text_type
@add_metaclass(abc.ABCMeta)
class NameSanitizer(object):
@abc.abstractproperty
def reserved_keywords(self): # pragma: no cover
pass
@abc.abstractmethod
def validate(self): # pragma: no cover
pass
@abc.abstractmethod
def sanitize(self, replacement_text=""): # pragma: no cover
pass
@property
def _str(self):
return text_type(self._value)
def __init__(self, value):
self._validate_null_string(value)
if is_pathlike_obj(value):
self._value = value
else:
self._value = value.strip()
def _is_pathlike_obj(self):
return is_pathlike_obj(self._value)
def _is_reserved_keyword(self, value):
return value in self.reserved_keywords
@staticmethod
def _validate_null_string(text, error_msg="null name"):
_validate_null_string(text)
Modify a function call argument# encoding: utf-8
"""
.. codeauthor:: Tsuyoshi Hombashi <tsuyoshi.hombashi@gmail.com>
"""
from __future__ import absolute_import, unicode_literals
import abc
from ._common import _validate_null_string, is_pathlike_obj
from ._six import add_metaclass, text_type
@add_metaclass(abc.ABCMeta)
class NameSanitizer(object):
@abc.abstractproperty
def reserved_keywords(self): # pragma: no cover
pass
@abc.abstractmethod
def validate(self): # pragma: no cover
pass
@abc.abstractmethod
def sanitize(self, replacement_text=""): # pragma: no cover
pass
@property
def _str(self):
return text_type(self._value)
def __init__(self, value):
self._validate_null_string(value)
if is_pathlike_obj(value):
self._value = value
else:
self._value = value.strip()
def _is_pathlike_obj(self):
return is_pathlike_obj(self._value)
def _is_reserved_keyword(self, value):
return value in self.reserved_keywords
@staticmethod
def _validate_null_string(text):
_validate_null_string(text, error_msg="null name")
|
<commit_before># encoding: utf-8
"""
.. codeauthor:: Tsuyoshi Hombashi <tsuyoshi.hombashi@gmail.com>
"""
from __future__ import absolute_import, unicode_literals
import abc
from ._common import _validate_null_string, is_pathlike_obj
from ._six import add_metaclass, text_type
@add_metaclass(abc.ABCMeta)
class NameSanitizer(object):
@abc.abstractproperty
def reserved_keywords(self): # pragma: no cover
pass
@abc.abstractmethod
def validate(self): # pragma: no cover
pass
@abc.abstractmethod
def sanitize(self, replacement_text=""): # pragma: no cover
pass
@property
def _str(self):
return text_type(self._value)
def __init__(self, value):
self._validate_null_string(value)
if is_pathlike_obj(value):
self._value = value
else:
self._value = value.strip()
def _is_pathlike_obj(self):
return is_pathlike_obj(self._value)
def _is_reserved_keyword(self, value):
return value in self.reserved_keywords
@staticmethod
def _validate_null_string(text, error_msg="null name"):
_validate_null_string(text)
<commit_msg>Modify a function call argument<commit_after># encoding: utf-8
"""
.. codeauthor:: Tsuyoshi Hombashi <tsuyoshi.hombashi@gmail.com>
"""
from __future__ import absolute_import, unicode_literals
import abc
from ._common import _validate_null_string, is_pathlike_obj
from ._six import add_metaclass, text_type
@add_metaclass(abc.ABCMeta)
class NameSanitizer(object):
@abc.abstractproperty
def reserved_keywords(self): # pragma: no cover
pass
@abc.abstractmethod
def validate(self): # pragma: no cover
pass
@abc.abstractmethod
def sanitize(self, replacement_text=""): # pragma: no cover
pass
@property
def _str(self):
return text_type(self._value)
def __init__(self, value):
self._validate_null_string(value)
if is_pathlike_obj(value):
self._value = value
else:
self._value = value.strip()
def _is_pathlike_obj(self):
return is_pathlike_obj(self._value)
def _is_reserved_keyword(self, value):
return value in self.reserved_keywords
@staticmethod
def _validate_null_string(text):
_validate_null_string(text, error_msg="null name")
|
e4de56768dd9d06c2bfc62b4d27ce0ba265857f3
|
plugins/telegram/setup.py
|
plugins/telegram/setup.py
|
from setuptools import setup, find_packages
version = '0.0.1'
setup(
name="alerta-telegram",
version=version,
description='Alerta plugin for Telegram',
url='https://github.com/alerta/alerta-contrib',
license='MIT',
author='Nick Satterly',
author_email='nick.satterly@theguardian.com',
packages=find_packages(),
py_modules=['alerta_telegram'],
install_requires=[
'telebot'
],
include_package_data=True,
zip_safe=True,
entry_points={
'alerta.plugins': [
'telegram = alerta_telegram:TelegramBot'
]
}
)
|
from setuptools import setup, find_packages
version = '0.0.1'
setup(
name="alerta-telegram",
version=version,
description='Alerta plugin for Telegram',
url='https://github.com/alerta/alerta-contrib',
license='MIT',
author='Nick Satterly',
author_email='nick.satterly@theguardian.com',
packages=find_packages(),
py_modules=['alerta_telegram'],
install_requires=[
'telepot'
],
include_package_data=True,
zip_safe=True,
entry_points={
'alerta.plugins': [
'telegram = alerta_telegram:TelegramBot'
]
}
)
|
Fix telegram plugin install requires
|
Fix telegram plugin install requires
|
Python
|
mit
|
alerta/alerta-contrib,msupino/alerta-contrib,alerta/alerta-contrib,alerta/alerta-contrib,msupino/alerta-contrib
|
from setuptools import setup, find_packages
version = '0.0.1'
setup(
name="alerta-telegram",
version=version,
description='Alerta plugin for Telegram',
url='https://github.com/alerta/alerta-contrib',
license='MIT',
author='Nick Satterly',
author_email='nick.satterly@theguardian.com',
packages=find_packages(),
py_modules=['alerta_telegram'],
install_requires=[
'telebot'
],
include_package_data=True,
zip_safe=True,
entry_points={
'alerta.plugins': [
'telegram = alerta_telegram:TelegramBot'
]
}
)
Fix telegram plugin install requires
|
from setuptools import setup, find_packages
version = '0.0.1'
setup(
name="alerta-telegram",
version=version,
description='Alerta plugin for Telegram',
url='https://github.com/alerta/alerta-contrib',
license='MIT',
author='Nick Satterly',
author_email='nick.satterly@theguardian.com',
packages=find_packages(),
py_modules=['alerta_telegram'],
install_requires=[
'telepot'
],
include_package_data=True,
zip_safe=True,
entry_points={
'alerta.plugins': [
'telegram = alerta_telegram:TelegramBot'
]
}
)
|
<commit_before>
from setuptools import setup, find_packages
version = '0.0.1'
setup(
name="alerta-telegram",
version=version,
description='Alerta plugin for Telegram',
url='https://github.com/alerta/alerta-contrib',
license='MIT',
author='Nick Satterly',
author_email='nick.satterly@theguardian.com',
packages=find_packages(),
py_modules=['alerta_telegram'],
install_requires=[
'telebot'
],
include_package_data=True,
zip_safe=True,
entry_points={
'alerta.plugins': [
'telegram = alerta_telegram:TelegramBot'
]
}
)
<commit_msg>Fix telegram plugin install requires<commit_after>
|
from setuptools import setup, find_packages
version = '0.0.1'
setup(
name="alerta-telegram",
version=version,
description='Alerta plugin for Telegram',
url='https://github.com/alerta/alerta-contrib',
license='MIT',
author='Nick Satterly',
author_email='nick.satterly@theguardian.com',
packages=find_packages(),
py_modules=['alerta_telegram'],
install_requires=[
'telepot'
],
include_package_data=True,
zip_safe=True,
entry_points={
'alerta.plugins': [
'telegram = alerta_telegram:TelegramBot'
]
}
)
|
from setuptools import setup, find_packages
version = '0.0.1'
setup(
name="alerta-telegram",
version=version,
description='Alerta plugin for Telegram',
url='https://github.com/alerta/alerta-contrib',
license='MIT',
author='Nick Satterly',
author_email='nick.satterly@theguardian.com',
packages=find_packages(),
py_modules=['alerta_telegram'],
install_requires=[
'telebot'
],
include_package_data=True,
zip_safe=True,
entry_points={
'alerta.plugins': [
'telegram = alerta_telegram:TelegramBot'
]
}
)
Fix telegram plugin install requires
from setuptools import setup, find_packages
version = '0.0.1'
setup(
name="alerta-telegram",
version=version,
description='Alerta plugin for Telegram',
url='https://github.com/alerta/alerta-contrib',
license='MIT',
author='Nick Satterly',
author_email='nick.satterly@theguardian.com',
packages=find_packages(),
py_modules=['alerta_telegram'],
install_requires=[
'telepot'
],
include_package_data=True,
zip_safe=True,
entry_points={
'alerta.plugins': [
'telegram = alerta_telegram:TelegramBot'
]
}
)
|
<commit_before>
from setuptools import setup, find_packages
version = '0.0.1'
setup(
name="alerta-telegram",
version=version,
description='Alerta plugin for Telegram',
url='https://github.com/alerta/alerta-contrib',
license='MIT',
author='Nick Satterly',
author_email='nick.satterly@theguardian.com',
packages=find_packages(),
py_modules=['alerta_telegram'],
install_requires=[
'telebot'
],
include_package_data=True,
zip_safe=True,
entry_points={
'alerta.plugins': [
'telegram = alerta_telegram:TelegramBot'
]
}
)
<commit_msg>Fix telegram plugin install requires<commit_after>
from setuptools import setup, find_packages
version = '0.0.1'
setup(
name="alerta-telegram",
version=version,
description='Alerta plugin for Telegram',
url='https://github.com/alerta/alerta-contrib',
license='MIT',
author='Nick Satterly',
author_email='nick.satterly@theguardian.com',
packages=find_packages(),
py_modules=['alerta_telegram'],
install_requires=[
'telepot'
],
include_package_data=True,
zip_safe=True,
entry_points={
'alerta.plugins': [
'telegram = alerta_telegram:TelegramBot'
]
}
)
|
241a59f35fbcba392dbc8b3037f6fdb243b87500
|
dimod/__init__.py
|
dimod/__init__.py
|
from __future__ import absolute_import
import sys
__version__ = '0.3.1'
__author__ = 'D-Wave Systems Inc.'
__authoremail__ = 'acondello@dwavesys.com'
__description__ = 'A shared API for binary quadratic model samplers.'
_PY2 = sys.version_info[0] == 2
from dimod.template_sampler import *
from dimod.samplers import *
import dimod.samplers
from dimod.template_composite import *
from dimod.composites import *
import dimod.composites
from dimod.template_response import *
from dimod.responses import *
import dimod.responses
from dimod.utilities import *
import dimod.utilities
from dimod.keyword_arguments import *
import dimod.keyword_arguments
import dimod.decorators
|
from __future__ import absolute_import
import sys
__version__ = '0.4.0'
__author__ = 'D-Wave Systems Inc.'
__authoremail__ = 'acondello@dwavesys.com'
__description__ = 'A shared API for binary quadratic model samplers.'
_PY2 = sys.version_info[0] == 2
from dimod.template_sampler import *
from dimod.samplers import *
import dimod.samplers
from dimod.template_composite import *
from dimod.composites import *
import dimod.composites
from dimod.template_response import *
from dimod.responses import *
import dimod.responses
from dimod.utilities import *
import dimod.utilities
from dimod.keyword_arguments import *
import dimod.keyword_arguments
import dimod.decorators
|
Increment version 0.3.1 -> 0.4.0
|
Increment version 0.3.1 -> 0.4.0
|
Python
|
apache-2.0
|
dwavesystems/dimod,dwavesystems/dimod
|
from __future__ import absolute_import
import sys
__version__ = '0.3.1'
__author__ = 'D-Wave Systems Inc.'
__authoremail__ = 'acondello@dwavesys.com'
__description__ = 'A shared API for binary quadratic model samplers.'
_PY2 = sys.version_info[0] == 2
from dimod.template_sampler import *
from dimod.samplers import *
import dimod.samplers
from dimod.template_composite import *
from dimod.composites import *
import dimod.composites
from dimod.template_response import *
from dimod.responses import *
import dimod.responses
from dimod.utilities import *
import dimod.utilities
from dimod.keyword_arguments import *
import dimod.keyword_arguments
import dimod.decorators
Increment version 0.3.1 -> 0.4.0
|
from __future__ import absolute_import
import sys
__version__ = '0.4.0'
__author__ = 'D-Wave Systems Inc.'
__authoremail__ = 'acondello@dwavesys.com'
__description__ = 'A shared API for binary quadratic model samplers.'
_PY2 = sys.version_info[0] == 2
from dimod.template_sampler import *
from dimod.samplers import *
import dimod.samplers
from dimod.template_composite import *
from dimod.composites import *
import dimod.composites
from dimod.template_response import *
from dimod.responses import *
import dimod.responses
from dimod.utilities import *
import dimod.utilities
from dimod.keyword_arguments import *
import dimod.keyword_arguments
import dimod.decorators
|
<commit_before>from __future__ import absolute_import
import sys
__version__ = '0.3.1'
__author__ = 'D-Wave Systems Inc.'
__authoremail__ = 'acondello@dwavesys.com'
__description__ = 'A shared API for binary quadratic model samplers.'
_PY2 = sys.version_info[0] == 2
from dimod.template_sampler import *
from dimod.samplers import *
import dimod.samplers
from dimod.template_composite import *
from dimod.composites import *
import dimod.composites
from dimod.template_response import *
from dimod.responses import *
import dimod.responses
from dimod.utilities import *
import dimod.utilities
from dimod.keyword_arguments import *
import dimod.keyword_arguments
import dimod.decorators
<commit_msg>Increment version 0.3.1 -> 0.4.0<commit_after>
|
from __future__ import absolute_import
import sys
__version__ = '0.4.0'
__author__ = 'D-Wave Systems Inc.'
__authoremail__ = 'acondello@dwavesys.com'
__description__ = 'A shared API for binary quadratic model samplers.'
_PY2 = sys.version_info[0] == 2
from dimod.template_sampler import *
from dimod.samplers import *
import dimod.samplers
from dimod.template_composite import *
from dimod.composites import *
import dimod.composites
from dimod.template_response import *
from dimod.responses import *
import dimod.responses
from dimod.utilities import *
import dimod.utilities
from dimod.keyword_arguments import *
import dimod.keyword_arguments
import dimod.decorators
|
from __future__ import absolute_import
import sys
__version__ = '0.3.1'
__author__ = 'D-Wave Systems Inc.'
__authoremail__ = 'acondello@dwavesys.com'
__description__ = 'A shared API for binary quadratic model samplers.'
_PY2 = sys.version_info[0] == 2
from dimod.template_sampler import *
from dimod.samplers import *
import dimod.samplers
from dimod.template_composite import *
from dimod.composites import *
import dimod.composites
from dimod.template_response import *
from dimod.responses import *
import dimod.responses
from dimod.utilities import *
import dimod.utilities
from dimod.keyword_arguments import *
import dimod.keyword_arguments
import dimod.decorators
Increment version 0.3.1 -> 0.4.0from __future__ import absolute_import
import sys
__version__ = '0.4.0'
__author__ = 'D-Wave Systems Inc.'
__authoremail__ = 'acondello@dwavesys.com'
__description__ = 'A shared API for binary quadratic model samplers.'
_PY2 = sys.version_info[0] == 2
from dimod.template_sampler import *
from dimod.samplers import *
import dimod.samplers
from dimod.template_composite import *
from dimod.composites import *
import dimod.composites
from dimod.template_response import *
from dimod.responses import *
import dimod.responses
from dimod.utilities import *
import dimod.utilities
from dimod.keyword_arguments import *
import dimod.keyword_arguments
import dimod.decorators
|
<commit_before>from __future__ import absolute_import
import sys
__version__ = '0.3.1'
__author__ = 'D-Wave Systems Inc.'
__authoremail__ = 'acondello@dwavesys.com'
__description__ = 'A shared API for binary quadratic model samplers.'
_PY2 = sys.version_info[0] == 2
from dimod.template_sampler import *
from dimod.samplers import *
import dimod.samplers
from dimod.template_composite import *
from dimod.composites import *
import dimod.composites
from dimod.template_response import *
from dimod.responses import *
import dimod.responses
from dimod.utilities import *
import dimod.utilities
from dimod.keyword_arguments import *
import dimod.keyword_arguments
import dimod.decorators
<commit_msg>Increment version 0.3.1 -> 0.4.0<commit_after>from __future__ import absolute_import
import sys
__version__ = '0.4.0'
__author__ = 'D-Wave Systems Inc.'
__authoremail__ = 'acondello@dwavesys.com'
__description__ = 'A shared API for binary quadratic model samplers.'
_PY2 = sys.version_info[0] == 2
from dimod.template_sampler import *
from dimod.samplers import *
import dimod.samplers
from dimod.template_composite import *
from dimod.composites import *
import dimod.composites
from dimod.template_response import *
from dimod.responses import *
import dimod.responses
from dimod.utilities import *
import dimod.utilities
from dimod.keyword_arguments import *
import dimod.keyword_arguments
import dimod.decorators
|
5d278330812618d55ba4efafcb097e3f5ee6db04
|
project/category/views.py
|
project/category/views.py
|
from flask import render_template, Blueprint, url_for, \
redirect, flash, request
from project.models import Category, Webinar
category_blueprint = Blueprint('category', __name__,)
@category_blueprint.route('/categories')
def index():
categories = Category.query.all()
return render_template('category/categories.html', categories=categories)
|
from flask import render_template, Blueprint, url_for, \
redirect, flash, request
from project.models import Category, Webinar
category_blueprint = Blueprint('category', __name__,)
@category_blueprint.route('/categories')
def index():
categories = Category.query.all()
return render_template('category/categories.html', categories=categories)
@category_blueprint.route('/category/<category_slug>')
def show(category_slug):
category = Category.query.filter_by(slug=category_slug)
return render_template('category/category.html', category=category)
|
Add basic view to see category show page
|
Add basic view to see category show page
|
Python
|
mit
|
dylanshine/streamschool,dylanshine/streamschool
|
from flask import render_template, Blueprint, url_for, \
redirect, flash, request
from project.models import Category, Webinar
category_blueprint = Blueprint('category', __name__,)
@category_blueprint.route('/categories')
def index():
categories = Category.query.all()
return render_template('category/categories.html', categories=categories)
Add basic view to see category show page
|
from flask import render_template, Blueprint, url_for, \
redirect, flash, request
from project.models import Category, Webinar
category_blueprint = Blueprint('category', __name__,)
@category_blueprint.route('/categories')
def index():
categories = Category.query.all()
return render_template('category/categories.html', categories=categories)
@category_blueprint.route('/category/<category_slug>')
def show(category_slug):
category = Category.query.filter_by(slug=category_slug)
return render_template('category/category.html', category=category)
|
<commit_before>from flask import render_template, Blueprint, url_for, \
redirect, flash, request
from project.models import Category, Webinar
category_blueprint = Blueprint('category', __name__,)
@category_blueprint.route('/categories')
def index():
categories = Category.query.all()
return render_template('category/categories.html', categories=categories)
<commit_msg>Add basic view to see category show page<commit_after>
|
from flask import render_template, Blueprint, url_for, \
redirect, flash, request
from project.models import Category, Webinar
category_blueprint = Blueprint('category', __name__,)
@category_blueprint.route('/categories')
def index():
categories = Category.query.all()
return render_template('category/categories.html', categories=categories)
@category_blueprint.route('/category/<category_slug>')
def show(category_slug):
category = Category.query.filter_by(slug=category_slug)
return render_template('category/category.html', category=category)
|
from flask import render_template, Blueprint, url_for, \
redirect, flash, request
from project.models import Category, Webinar
category_blueprint = Blueprint('category', __name__,)
@category_blueprint.route('/categories')
def index():
categories = Category.query.all()
return render_template('category/categories.html', categories=categories)
Add basic view to see category show pagefrom flask import render_template, Blueprint, url_for, \
redirect, flash, request
from project.models import Category, Webinar
category_blueprint = Blueprint('category', __name__,)
@category_blueprint.route('/categories')
def index():
categories = Category.query.all()
return render_template('category/categories.html', categories=categories)
@category_blueprint.route('/category/<category_slug>')
def show(category_slug):
category = Category.query.filter_by(slug=category_slug)
return render_template('category/category.html', category=category)
|
<commit_before>from flask import render_template, Blueprint, url_for, \
redirect, flash, request
from project.models import Category, Webinar
category_blueprint = Blueprint('category', __name__,)
@category_blueprint.route('/categories')
def index():
categories = Category.query.all()
return render_template('category/categories.html', categories=categories)
<commit_msg>Add basic view to see category show page<commit_after>from flask import render_template, Blueprint, url_for, \
redirect, flash, request
from project.models import Category, Webinar
category_blueprint = Blueprint('category', __name__,)
@category_blueprint.route('/categories')
def index():
categories = Category.query.all()
return render_template('category/categories.html', categories=categories)
@category_blueprint.route('/category/<category_slug>')
def show(category_slug):
category = Category.query.filter_by(slug=category_slug)
return render_template('category/category.html', category=category)
|
9689887cbdc59c29c8a13bfa82eb1391ce691631
|
zephyr/decorator.py
|
zephyr/decorator.py
|
import types
class TornadoAsyncException(Exception): pass
class _DefGen_Return(BaseException):
def __init__(self, value):
self.value = value
def returnResponse(value):
raise _DefGen_Return(value)
def asynchronous(method):
def wrapper(request, *args, **kwargs):
try:
v = method(request, request._tornado_handler, *args, **kwargs)
if v == None or type(v) == types.GeneratorType:
raise TornadoAsyncException
except _DefGen_Return, e:
request._tornado_handler.finish(e.value.content)
return v
return wrapper
|
import types
class TornadoAsyncException(Exception): pass
class _DefGen_Return(BaseException):
def __init__(self, value):
self.value = value
def returnResponse(value):
raise _DefGen_Return(value)
def asynchronous(method):
def wrapper(request, *args, **kwargs):
try:
v = method(request, request._tornado_handler, *args, **kwargs)
if v == None or type(v) == types.GeneratorType:
raise TornadoAsyncException
except _DefGen_Return, e:
request._tornado_handler.finish(e.value.content)
return v
if getattr(method, 'csrf_exempt', False):
wrapper.csrf_exempt = True
return wrapper
|
Copy the csrf_exempt attribute in @asynchronous
|
Copy the csrf_exempt attribute in @asynchronous
Needed for @csrf_exempt to work.
(imported from commit 563ab11b0d26262511e9a6d9cc2735b0b835a391)
|
Python
|
apache-2.0
|
blaze225/zulip,Cheppers/zulip,xuanhan863/zulip,dnmfarrell/zulip,RobotCaleb/zulip,esander91/zulip,wweiradio/zulip,vikas-parashar/zulip,zulip/zulip,luyifan/zulip,grave-w-grave/zulip,amallia/zulip,hafeez3000/zulip,fw1121/zulip,Gabriel0402/zulip,jackrzhang/zulip,umkay/zulip,he15his/zulip,glovebx/zulip,ufosky-server/zulip,TigorC/zulip,dawran6/zulip,zofuthan/zulip,tommyip/zulip,Galexrt/zulip,amanharitsh123/zulip,qq1012803704/zulip,bssrdf/zulip,dxq-git/zulip,shrikrishnaholla/zulip,thomasboyt/zulip,sonali0901/zulip,yuvipanda/zulip,amanharitsh123/zulip,shaunstanislaus/zulip,zorojean/zulip,thomasboyt/zulip,aliceriot/zulip,DazWorrall/zulip,gkotian/zulip,sonali0901/zulip,jrowan/zulip,mdavid/zulip,JPJPJPOPOP/zulip,LAndreas/zulip,zulip/zulip,cosmicAsymmetry/zulip,jeffcao/zulip,niftynei/zulip,AZtheAsian/zulip,karamcnair/zulip,joshisa/zulip,zorojean/zulip,itnihao/zulip,seapasulli/zulip,deer-hope/zulip,hj3938/zulip,kokoar/zulip,joshisa/zulip,avastu/zulip,babbage/zulip,jerryge/zulip,moria/zulip,suxinde2009/zulip,bluesea/zulip,glovebx/zulip,timabbott/zulip,blaze225/zulip,brainwane/zulip,jeffcao/zulip,esander91/zulip,fw1121/zulip,KJin99/zulip,hayderimran7/zulip,ahmadassaf/zulip,Jianchun1/zulip,johnnygaddarr/zulip,wangdeshui/zulip,codeKonami/zulip,shaunstanislaus/zulip,susansls/zulip,MariaFaBella85/zulip,xuxiao/zulip,ufosky-server/zulip,kou/zulip,tiansiyuan/zulip,yocome/zulip,tommyip/zulip,jrowan/zulip,ikasumiwt/zulip,stamhe/zulip,vikas-parashar/zulip,jonesgithub/zulip,deer-hope/zulip,wavelets/zulip,zhaoweigg/zulip,bssrdf/zulip,gigawhitlocks/zulip,joyhchen/zulip,wdaher/zulip,armooo/zulip,so0k/zulip,adnanh/zulip,pradiptad/zulip,peguin40/zulip,fw1121/zulip,ashwinirudrappa/zulip,kaiyuanheshang/zulip,jerryge/zulip,wweiradio/zulip,tommyip/zulip,ericzhou2008/zulip,arpith/zulip,huangkebo/zulip,vaidap/zulip,ipernet/zulip,peguin40/zulip,joshisa/zulip,Qgap/zulip,luyifan/zulip,hafeez3000/zulip,dnmfarrell/zulip,mohsenSy/zulip,christi3k/zulip,SmartPeople/zulip,bluesea/zulip,adnanh/zulip,wavelets/zulip,ashwinirudrappa/zulip,willingc/zulip,luyifan/zulip,DazWorrall/zulip,ikasumiwt/zulip,Gabriel0402/zulip,firstblade/zulip,m1ssou/zulip,reyha/zulip,hengqujushi/zulip,jessedhillon/zulip,timabbott/zulip,jessedhillon/zulip,bitemyapp/zulip,susansls/zulip,Juanvulcano/zulip,bastianh/zulip,kokoar/zulip,dxq-git/zulip,Suninus/zulip,guiquanz/zulip,Vallher/zulip,dotcool/zulip,alliejones/zulip,wavelets/zulip,ashwinirudrappa/zulip,timabbott/zulip,themass/zulip,cosmicAsymmetry/zulip,dhcrzf/zulip,gkotian/zulip,codeKonami/zulip,tiansiyuan/zulip,souravbadami/zulip,Juanvulcano/zulip,akuseru/zulip,brockwhittaker/zulip,shrikrishnaholla/zulip,wweiradio/zulip,moria/zulip,guiquanz/zulip,sharmaeklavya2/zulip,MariaFaBella85/zulip,punchagan/zulip,amallia/zulip,ericzhou2008/zulip,hustlzp/zulip,amallia/zulip,guiquanz/zulip,levixie/zulip,ApsOps/zulip,jeffcao/zulip,gkotian/zulip,wangdeshui/zulip,stamhe/zulip,jeffcao/zulip,wavelets/zulip,hackerkid/zulip,PhilSk/zulip,bluesea/zulip,verma-varsha/zulip,Diptanshu8/zulip,m1ssou/zulip,easyfmxu/zulip,arpith/zulip,jonesgithub/zulip,arpith/zulip,zwily/zulip,ryanbackman/zulip,rishig/zulip,jonesgithub/zulip,yuvipanda/zulip,technicalpickles/zulip,arpitpanwar/zulip,susansls/zulip,AZtheAsian/zulip,paxapy/zulip,aakash-cr7/zulip,dattatreya303/zulip,xuxiao/zulip,natanovia/zulip,dnmfarrell/zulip,reyha/zulip,hackerkid/zulip,samatdav/zulip,calvinleenyc/zulip,kaiyuanheshang/zulip,bssrdf/zulip,Suninus/zulip,luyifan/zulip,suxinde2009/zulip,firstblade/zulip,avastu/zulip,vaidap/zulip,technicalpickles/zulip,udxxabp/zulip,amanharitsh123/zulip,avastu/zulip,willingc/zulip,umkay/zulip,esander91/zulip,firstblade/zulip,vakila/zulip,SmartPeople/zulip,Diptanshu8/zulip,calvinleenyc/zulip,arpitpanwar/zulip,tbutter/zulip,TigorC/zulip,timabbott/zulip,samatdav/zulip,hustlzp/zulip,he15his/zulip,codeKonami/zulip,avastu/zulip,schatt/zulip,itnihao/zulip,shrikrishnaholla/zulip,ericzhou2008/zulip,jimmy54/zulip,aakash-cr7/zulip,itnihao/zulip,ahmadassaf/zulip,paxapy/zulip,LeeRisk/zulip,dwrpayne/zulip,PaulPetring/zulip,saitodisse/zulip,ikasumiwt/zulip,bastianh/zulip,bssrdf/zulip,seapasulli/zulip,arpitpanwar/zulip,amallia/zulip,ryansnowboarder/zulip,pradiptad/zulip,mansilladev/zulip,Batterfii/zulip,hackerkid/zulip,babbage/zulip,wweiradio/zulip,souravbadami/zulip,brockwhittaker/zulip,noroot/zulip,levixie/zulip,vabs22/zulip,mahim97/zulip,Galexrt/zulip,glovebx/zulip,jackrzhang/zulip,themass/zulip,swinghu/zulip,kokoar/zulip,suxinde2009/zulip,easyfmxu/zulip,ahmadassaf/zulip,amallia/zulip,sonali0901/zulip,nicholasbs/zulip,Drooids/zulip,natanovia/zulip,Vallher/zulip,andersk/zulip,levixie/zulip,brainwane/zulip,dwrpayne/zulip,armooo/zulip,Suninus/zulip,fw1121/zulip,Batterfii/zulip,ufosky-server/zulip,EasonYi/zulip,paxapy/zulip,dattatreya303/zulip,developerfm/zulip,vakila/zulip,adnanh/zulip,zorojean/zulip,johnny9/zulip,eastlhu/zulip,pradiptad/zulip,ipernet/zulip,cosmicAsymmetry/zulip,zhaoweigg/zulip,noroot/zulip,lfranchi/zulip,Frouk/zulip,nicholasbs/zulip,yuvipanda/zulip,tdr130/zulip,shubhamdhama/zulip,LeeRisk/zulip,ikasumiwt/zulip,Juanvulcano/zulip,swinghu/zulip,littledogboy/zulip,saitodisse/zulip,eastlhu/zulip,gkotian/zulip,zwily/zulip,sonali0901/zulip,Vallher/zulip,LAndreas/zulip,so0k/zulip,deer-hope/zulip,ikasumiwt/zulip,EasonYi/zulip,ApsOps/zulip,hayderimran7/zulip,levixie/zulip,bitemyapp/zulip,deer-hope/zulip,Drooids/zulip,dhcrzf/zulip,kaiyuanheshang/zulip,dhcrzf/zulip,aps-sids/zulip,sharmaeklavya2/zulip,noroot/zulip,guiquanz/zulip,nicholasbs/zulip,luyifan/zulip,wdaher/zulip,PaulPetring/zulip,udxxabp/zulip,technicalpickles/zulip,MayB/zulip,joshisa/zulip,zachallaun/zulip,vaidap/zulip,aakash-cr7/zulip,dxq-git/zulip,zacps/zulip,guiquanz/zulip,verma-varsha/zulip,synicalsyntax/zulip,eastlhu/zulip,hj3938/zulip,reyha/zulip,verma-varsha/zulip,dotcool/zulip,dwrpayne/zulip,Diptanshu8/zulip,jainayush975/zulip,jonesgithub/zulip,ipernet/zulip,hackerkid/zulip,glovebx/zulip,timabbott/zulip,zacps/zulip,bowlofstew/zulip,PaulPetring/zulip,aps-sids/zulip,zofuthan/zulip,babbage/zulip,dattatreya303/zulip,schatt/zulip,zorojean/zulip,showell/zulip,wdaher/zulip,peiwei/zulip,voidException/zulip,yocome/zulip,dxq-git/zulip,hafeez3000/zulip,bluesea/zulip,udxxabp/zulip,voidException/zulip,proliming/zulip,alliejones/zulip,avastu/zulip,SmartPeople/zulip,babbage/zulip,mohsenSy/zulip,rishig/zulip,Diptanshu8/zulip,natanovia/zulip,vakila/zulip,tdr130/zulip,KJin99/zulip,seapasulli/zulip,zachallaun/zulip,suxinde2009/zulip,xuanhan863/zulip,jainayush975/zulip,hayderimran7/zulip,dwrpayne/zulip,levixie/zulip,TigorC/zulip,mahim97/zulip,yocome/zulip,jeffcao/zulip,PhilSk/zulip,nicholasbs/zulip,joshisa/zulip,atomic-labs/zulip,punchagan/zulip,blaze225/zulip,ipernet/zulip,sup95/zulip,xuxiao/zulip,developerfm/zulip,bssrdf/zulip,vakila/zulip,suxinde2009/zulip,peguin40/zulip,kou/zulip,rishig/zulip,jerryge/zulip,zacps/zulip,johnny9/zulip,EasonYi/zulip,proliming/zulip,mdavid/zulip,m1ssou/zulip,eeshangarg/zulip,krtkmj/zulip,aakash-cr7/zulip,amanharitsh123/zulip,pradiptad/zulip,rht/zulip,souravbadami/zulip,rishig/zulip,proliming/zulip,sup95/zulip,dnmfarrell/zulip,bitemyapp/zulip,jonesgithub/zulip,ryansnowboarder/zulip,rishig/zulip,calvinleenyc/zulip,johnny9/zulip,Diptanshu8/zulip,KingxBanana/zulip,shubhamdhama/zulip,arpitpanwar/zulip,thomasboyt/zulip,synicalsyntax/zulip,xuanhan863/zulip,ikasumiwt/zulip,ahmadassaf/zulip,voidException/zulip,zachallaun/zulip,Galexrt/zulip,verma-varsha/zulip,zhaoweigg/zulip,eastlhu/zulip,developerfm/zulip,Jianchun1/zulip,akuseru/zulip,yuvipanda/zulip,MayB/zulip,punchagan/zulip,aps-sids/zulip,yocome/zulip,rht/zulip,zachallaun/zulip,andersk/zulip,technicalpickles/zulip,JanzTam/zulip,stamhe/zulip,JPJPJPOPOP/zulip,wdaher/zulip,ufosky-server/zulip,LAndreas/zulip,PhilSk/zulip,praveenaki/zulip,mansilladev/zulip,hafeez3000/zulip,brockwhittaker/zulip,natanovia/zulip,willingc/zulip,schatt/zulip,sharmaeklavya2/zulip,firstblade/zulip,Drooids/zulip,jackrzhang/zulip,Cheppers/zulip,noroot/zulip,tommyip/zulip,jimmy54/zulip,bowlofstew/zulip,zorojean/zulip,jimmy54/zulip,grave-w-grave/zulip,wangdeshui/zulip,moria/zulip,bowlofstew/zulip,eastlhu/zulip,xuxiao/zulip,akuseru/zulip,JanzTam/zulip,kaiyuanheshang/zulip,udxxabp/zulip,johnnygaddarr/zulip,vabs22/zulip,reyha/zulip,tiansiyuan/zulip,andersk/zulip,jerryge/zulip,tiansiyuan/zulip,rht/zulip,jphilipsen05/zulip,isht3/zulip,johnnygaddarr/zulip,bitemyapp/zulip,jphilipsen05/zulip,eeshangarg/zulip,firstblade/zulip,showell/zulip,suxinde2009/zulip,krtkmj/zulip,armooo/zulip,krtkmj/zulip,tbutter/zulip,reyha/zulip,easyfmxu/zulip,MariaFaBella85/zulip,KJin99/zulip,codeKonami/zulip,karamcnair/zulip,gigawhitlocks/zulip,showell/zulip,Qgap/zulip,seapasulli/zulip,ahmadassaf/zulip,nicholasbs/zulip,peguin40/zulip,saitodisse/zulip,grave-w-grave/zulip,kou/zulip,alliejones/zulip,JanzTam/zulip,schatt/zulip,guiquanz/zulip,mansilladev/zulip,proliming/zulip,Suninus/zulip,hayderimran7/zulip,LeeRisk/zulip,mdavid/zulip,synicalsyntax/zulip,stamhe/zulip,tdr130/zulip,jimmy54/zulip,schatt/zulip,xuanhan863/zulip,tdr130/zulip,lfranchi/zulip,m1ssou/zulip,Qgap/zulip,bowlofstew/zulip,xuanhan863/zulip,Galexrt/zulip,atomic-labs/zulip,Frouk/zulip,shrikrishnaholla/zulip,Juanvulcano/zulip,zwily/zulip,vikas-parashar/zulip,blaze225/zulip,dawran6/zulip,AZtheAsian/zulip,brainwane/zulip,hj3938/zulip,Galexrt/zulip,Qgap/zulip,armooo/zulip,technicalpickles/zulip,aakash-cr7/zulip,dhcrzf/zulip,bssrdf/zulip,praveenaki/zulip,zachallaun/zulip,arpith/zulip,xuxiao/zulip,so0k/zulip,thomasboyt/zulip,noroot/zulip,DazWorrall/zulip,zacps/zulip,m1ssou/zulip,mdavid/zulip,shaunstanislaus/zulip,umkay/zulip,atomic-labs/zulip,Batterfii/zulip,moria/zulip,peiwei/zulip,Qgap/zulip,JPJPJPOPOP/zulip,alliejones/zulip,showell/zulip,lfranchi/zulip,joyhchen/zulip,hustlzp/zulip,codeKonami/zulip,vabs22/zulip,aliceriot/zulip,bitemyapp/zulip,MayB/zulip,vikas-parashar/zulip,firstblade/zulip,mansilladev/zulip,showell/zulip,jrowan/zulip,tdr130/zulip,jonesgithub/zulip,tbutter/zulip,ryanbackman/zulip,KJin99/zulip,atomic-labs/zulip,Cheppers/zulip,j831/zulip,codeKonami/zulip,grave-w-grave/zulip,rht/zulip,themass/zulip,noroot/zulip,qq1012803704/zulip,JanzTam/zulip,babbage/zulip,proliming/zulip,hackerkid/zulip,bitemyapp/zulip,TigorC/zulip,gkotian/zulip,huangkebo/zulip,jphilipsen05/zulip,m1ssou/zulip,umkay/zulip,dxq-git/zulip,dnmfarrell/zulip,Drooids/zulip,praveenaki/zulip,krtkmj/zulip,armooo/zulip,hayderimran7/zulip,armooo/zulip,peiwei/zulip,luyifan/zulip,saitodisse/zulip,niftynei/zulip,xuanhan863/zulip,umkay/zulip,proliming/zulip,timabbott/zulip,alliejones/zulip,huangkebo/zulip,jimmy54/zulip,ahmadassaf/zulip,JPJPJPOPOP/zulip,reyha/zulip,zofuthan/zulip,krtkmj/zulip,isht3/zulip,amyliu345/zulip,jessedhillon/zulip,wdaher/zulip,themass/zulip,rht/zulip,dhcrzf/zulip,kou/zulip,peguin40/zulip,mahim97/zulip,tdr130/zulip,moria/zulip,andersk/zulip,krtkmj/zulip,sup95/zulip,joyhchen/zulip,Batterfii/zulip,so0k/zulip,PaulPetring/zulip,ryansnowboarder/zulip,wangdeshui/zulip,souravbadami/zulip,esander91/zulip,ApsOps/zulip,hustlzp/zulip,dotcool/zulip,kokoar/zulip,dattatreya303/zulip,LAndreas/zulip,fw1121/zulip,shubhamdhama/zulip,levixie/zulip,atomic-labs/zulip,cosmicAsymmetry/zulip,vakila/zulip,praveenaki/zulip,PhilSk/zulip,itnihao/zulip,johnnygaddarr/zulip,bastianh/zulip,jimmy54/zulip,zulip/zulip,souravbadami/zulip,atomic-labs/zulip,karamcnair/zulip,he15his/zulip,amyliu345/zulip,avastu/zulip,LeeRisk/zulip,zhaoweigg/zulip,littledogboy/zulip,mansilladev/zulip,ericzhou2008/zulip,hackerkid/zulip,blaze225/zulip,isht3/zulip,voidException/zulip,aliceriot/zulip,dnmfarrell/zulip,eeshangarg/zulip,niftynei/zulip,showell/zulip,jackrzhang/zulip,jrowan/zulip,yuvipanda/zulip,sharmaeklavya2/zulip,karamcnair/zulip,bitemyapp/zulip,voidException/zulip,zulip/zulip,fw1121/zulip,akuseru/zulip,Diptanshu8/zulip,ryanbackman/zulip,avastu/zulip,easyfmxu/zulip,mohsenSy/zulip,ryanbackman/zulip,sharmaeklavya2/zulip,ryansnowboarder/zulip,RobotCaleb/zulip,tbutter/zulip,joshisa/zulip,amyliu345/zulip,niftynei/zulip,kokoar/zulip,TigorC/zulip,zacps/zulip,so0k/zulip,eastlhu/zulip,xuanhan863/zulip,vikas-parashar/zulip,samatdav/zulip,johnnygaddarr/zulip,dxq-git/zulip,pradiptad/zulip,saitodisse/zulip,saitodisse/zulip,ahmadassaf/zulip,ashwinirudrappa/zulip,akuseru/zulip,wweiradio/zulip,dnmfarrell/zulip,tommyip/zulip,vabs22/zulip,KingxBanana/zulip,brainwane/zulip,arpitpanwar/zulip,Batterfii/zulip,brainwane/zulip,Suninus/zulip,kokoar/zulip,Frouk/zulip,EasonYi/zulip,wavelets/zulip,shrikrishnaholla/zulip,christi3k/zulip,kokoar/zulip,Frouk/zulip,isht3/zulip,sup95/zulip,adnanh/zulip,littledogboy/zulip,amallia/zulip,hafeez3000/zulip,jphilipsen05/zulip,swinghu/zulip,brockwhittaker/zulip,LeeRisk/zulip,mohsenSy/zulip,dawran6/zulip,ryanbackman/zulip,gkotian/zulip,arpith/zulip,MariaFaBella85/zulip,bastianh/zulip,itnihao/zulip,ashwinirudrappa/zulip,hengqujushi/zulip,babbage/zulip,jerryge/zulip,qq1012803704/zulip,JPJPJPOPOP/zulip,punchagan/zulip,andersk/zulip,j831/zulip,jeffcao/zulip,lfranchi/zulip,hj3938/zulip,LAndreas/zulip,andersk/zulip,mdavid/zulip,Jianchun1/zulip,kou/zulip,Suninus/zulip,sup95/zulip,Vallher/zulip,DazWorrall/zulip,arpitpanwar/zulip,jainayush975/zulip,jimmy54/zulip,Cheppers/zulip,wweiradio/zulip,amyliu345/zulip,verma-varsha/zulip,seapasulli/zulip,wavelets/zulip,natanovia/zulip,johnny9/zulip,johnny9/zulip,aps-sids/zulip,rht/zulip,synicalsyntax/zulip,thomasboyt/zulip,xuxiao/zulip,jphilipsen05/zulip,developerfm/zulip,j831/zulip,pradiptad/zulip,Cheppers/zulip,karamcnair/zulip,he15his/zulip,jessedhillon/zulip,jonesgithub/zulip,JanzTam/zulip,mahim97/zulip,Batterfii/zulip,qq1012803704/zulip,dotcool/zulip,zachallaun/zulip,hustlzp/zulip,Frouk/zulip,technicalpickles/zulip,EasonYi/zulip,tbutter/zulip,zwily/zulip,dwrpayne/zulip,umkay/zulip,Vallher/zulip,Vallher/zulip,qq1012803704/zulip,esander91/zulip,susansls/zulip,swinghu/zulip,zofuthan/zulip,esander91/zulip,easyfmxu/zulip,glovebx/zulip,SmartPeople/zulip,shaunstanislaus/zulip,KJin99/zulip,mahim97/zulip,dhcrzf/zulip,vabs22/zulip,calvinleenyc/zulip,willingc/zulip,gigawhitlocks/zulip,TigorC/zulip,dotcool/zulip,paxapy/zulip,jrowan/zulip,cosmicAsymmetry/zulip,Drooids/zulip,tommyip/zulip,lfranchi/zulip,karamcnair/zulip,krtkmj/zulip,wdaher/zulip,punchagan/zulip,sonali0901/zulip,hustlzp/zulip,dattatreya303/zulip,MayB/zulip,synicalsyntax/zulip,Galexrt/zulip,SmartPeople/zulip,schatt/zulip,glovebx/zulip,bastianh/zulip,bastianh/zulip,noroot/zulip,developerfm/zulip,praveenaki/zulip,lfranchi/zulip,tiansiyuan/zulip,hustlzp/zulip,grave-w-grave/zulip,KingxBanana/zulip,Juanvulcano/zulip,jerryge/zulip,LeeRisk/zulip,PhilSk/zulip,grave-w-grave/zulip,MariaFaBella85/zulip,huangkebo/zulip,Gabriel0402/zulip,Drooids/zulip,ApsOps/zulip,thomasboyt/zulip,dotcool/zulip,PaulPetring/zulip,zorojean/zulip,tiansiyuan/zulip,arpitpanwar/zulip,samatdav/zulip,willingc/zulip,joyhchen/zulip,ericzhou2008/zulip,ApsOps/zulip,deer-hope/zulip,sonali0901/zulip,johnny9/zulip,ikasumiwt/zulip,hayderimran7/zulip,vaidap/zulip,gigawhitlocks/zulip,guiquanz/zulip,kaiyuanheshang/zulip,amanharitsh123/zulip,Jianchun1/zulip,zofuthan/zulip,adnanh/zulip,RobotCaleb/zulip,susansls/zulip,RobotCaleb/zulip,voidException/zulip,paxapy/zulip,pradiptad/zulip,shaunstanislaus/zulip,dwrpayne/zulip,firstblade/zulip,dotcool/zulip,mohsenSy/zulip,deer-hope/zulip,hengqujushi/zulip,eastlhu/zulip,ryansnowboarder/zulip,cosmicAsymmetry/zulip,souravbadami/zulip,Vallher/zulip,arpith/zulip,ufosky-server/zulip,swinghu/zulip,brockwhittaker/zulip,DazWorrall/zulip,umkay/zulip,j831/zulip,dxq-git/zulip,tiansiyuan/zulip,brainwane/zulip,christi3k/zulip,shrikrishnaholla/zulip,amyliu345/zulip,zhaoweigg/zulip,RobotCaleb/zulip,adnanh/zulip,stamhe/zulip,samatdav/zulip,aliceriot/zulip,dawran6/zulip,DazWorrall/zulip,praveenaki/zulip,dawran6/zulip,schatt/zulip,MayB/zulip,calvinleenyc/zulip,alliejones/zulip,deer-hope/zulip,jackrzhang/zulip,zhaoweigg/zulip,zulip/zulip,mansilladev/zulip,proliming/zulip,m1ssou/zulip,JPJPJPOPOP/zulip,JanzTam/zulip,wavelets/zulip,aps-sids/zulip,seapasulli/zulip,niftynei/zulip,fw1121/zulip,huangkebo/zulip,zulip/zulip,littledogboy/zulip,alliejones/zulip,jrowan/zulip,PaulPetring/zulip,PhilSk/zulip,ashwinirudrappa/zulip,armooo/zulip,punchagan/zulip,yocome/zulip,Cheppers/zulip,punchagan/zulip,zulip/zulip,huangkebo/zulip,nicholasbs/zulip,peiwei/zulip,codeKonami/zulip,zacps/zulip,Cheppers/zulip,amanharitsh123/zulip,Gabriel0402/zulip,bastianh/zulip,peguin40/zulip,jainayush975/zulip,hafeez3000/zulip,susansls/zulip,mdavid/zulip,jerryge/zulip,vaidap/zulip,wangdeshui/zulip,Qgap/zulip,karamcnair/zulip,EasonYi/zulip,MayB/zulip,joshisa/zulip,atomic-labs/zulip,calvinleenyc/zulip,timabbott/zulip,jeffcao/zulip,natanovia/zulip,synicalsyntax/zulip,bowlofstew/zulip,hj3938/zulip,wangdeshui/zulip,gigawhitlocks/zulip,LeeRisk/zulip,DazWorrall/zulip,jainayush975/zulip,he15his/zulip,shrikrishnaholla/zulip,itnihao/zulip,luyifan/zulip,yuvipanda/zulip,zhaoweigg/zulip,qq1012803704/zulip,KingxBanana/zulip,Frouk/zulip,ipernet/zulip,johnnygaddarr/zulip,hengqujushi/zulip,Batterfii/zulip,brockwhittaker/zulip,stamhe/zulip,themass/zulip,he15his/zulip,Gabriel0402/zulip,hj3938/zulip,udxxabp/zulip,ApsOps/zulip,willingc/zulip,ufosky-server/zulip,wdaher/zulip,aliceriot/zulip,Galexrt/zulip,rht/zulip,AZtheAsian/zulip,peiwei/zulip,akuseru/zulip,andersk/zulip,jackrzhang/zulip,peiwei/zulip,samatdav/zulip,seapasulli/zulip,ryansnowboarder/zulip,developerfm/zulip,tdr130/zulip,blaze225/zulip,MayB/zulip,aliceriot/zulip,eeshangarg/zulip,johnny9/zulip,verma-varsha/zulip,natanovia/zulip,babbage/zulip,gkotian/zulip,stamhe/zulip,joyhchen/zulip,kaiyuanheshang/zulip,swinghu/zulip,mahim97/zulip,praveenaki/zulip,Drooids/zulip,RobotCaleb/zulip,paxapy/zulip,dawran6/zulip,KingxBanana/zulip,joyhchen/zulip,ryansnowboarder/zulip,yocome/zulip,nicholasbs/zulip,zwily/zulip,eeshangarg/zulip,jessedhillon/zulip,lfranchi/zulip,AZtheAsian/zulip,MariaFaBella85/zulip,developerfm/zulip,jessedhillon/zulip,isht3/zulip,vaidap/zulip,isht3/zulip,tommyip/zulip,dhcrzf/zulip,easyfmxu/zulip,yuvipanda/zulip,christi3k/zulip,littledogboy/zulip,aps-sids/zulip,kou/zulip,hj3938/zulip,synicalsyntax/zulip,KingxBanana/zulip,RobotCaleb/zulip,shubhamdhama/zulip,Qgap/zulip,KJin99/zulip,themass/zulip,jackrzhang/zulip,KJin99/zulip,christi3k/zulip,mansilladev/zulip,Gabriel0402/zulip,amallia/zulip,sharmaeklavya2/zulip,jainayush975/zulip,shubhamdhama/zulip,qq1012803704/zulip,esander91/zulip,ericzhou2008/zulip,aps-sids/zulip,xuxiao/zulip,Frouk/zulip,niftynei/zulip,kaiyuanheshang/zulip,sup95/zulip,hengqujushi/zulip,kou/zulip,ufosky-server/zulip,shaunstanislaus/zulip,adnanh/zulip,bowlofstew/zulip,vakila/zulip,Gabriel0402/zulip,voidException/zulip,huangkebo/zulip,akuseru/zulip,bowlofstew/zulip,so0k/zulip,themass/zulip,amyliu345/zulip,bluesea/zulip,tbutter/zulip,vikas-parashar/zulip,Juanvulcano/zulip,ipernet/zulip,AZtheAsian/zulip,suxinde2009/zulip,bssrdf/zulip,eeshangarg/zulip,wweiradio/zulip,JanzTam/zulip,brainwane/zulip,ApsOps/zulip,yocome/zulip,thomasboyt/zulip,j831/zulip,gigawhitlocks/zulip,littledogboy/zulip,ryanbackman/zulip,mdavid/zulip,shubhamdhama/zulip,littledogboy/zulip,so0k/zulip,dattatreya303/zulip,glovebx/zulip,MariaFaBella85/zulip,jphilipsen05/zulip,christi3k/zulip,johnnygaddarr/zulip,shaunstanislaus/zulip,easyfmxu/zulip,wangdeshui/zulip,zorojean/zulip,hafeez3000/zulip,LAndreas/zulip,levixie/zulip,moria/zulip,Jianchun1/zulip,Jianchun1/zulip,technicalpickles/zulip,showell/zulip,saitodisse/zulip,SmartPeople/zulip,willingc/zulip,rishig/zulip,peiwei/zulip,PaulPetring/zulip,eeshangarg/zulip,hayderimran7/zulip,zachallaun/zulip,zwily/zulip,vabs22/zulip,bluesea/zulip,zwily/zulip,hackerkid/zulip,he15his/zulip,tbutter/zulip,swinghu/zulip,hengqujushi/zulip,dwrpayne/zulip,udxxabp/zulip,aakash-cr7/zulip,shubhamdhama/zulip,LAndreas/zulip,hengqujushi/zulip,jessedhillon/zulip,udxxabp/zulip,Suninus/zulip,zofuthan/zulip,bluesea/zulip,j831/zulip,vakila/zulip,ashwinirudrappa/zulip,ipernet/zulip,aliceriot/zulip,gigawhitlocks/zulip,itnihao/zulip,mohsenSy/zulip,rishig/zulip,moria/zulip,ericzhou2008/zulip,zofuthan/zulip,EasonYi/zulip
|
import types
class TornadoAsyncException(Exception): pass
class _DefGen_Return(BaseException):
def __init__(self, value):
self.value = value
def returnResponse(value):
raise _DefGen_Return(value)
def asynchronous(method):
def wrapper(request, *args, **kwargs):
try:
v = method(request, request._tornado_handler, *args, **kwargs)
if v == None or type(v) == types.GeneratorType:
raise TornadoAsyncException
except _DefGen_Return, e:
request._tornado_handler.finish(e.value.content)
return v
return wrapper
Copy the csrf_exempt attribute in @asynchronous
Needed for @csrf_exempt to work.
(imported from commit 563ab11b0d26262511e9a6d9cc2735b0b835a391)
|
import types
class TornadoAsyncException(Exception): pass
class _DefGen_Return(BaseException):
def __init__(self, value):
self.value = value
def returnResponse(value):
raise _DefGen_Return(value)
def asynchronous(method):
def wrapper(request, *args, **kwargs):
try:
v = method(request, request._tornado_handler, *args, **kwargs)
if v == None or type(v) == types.GeneratorType:
raise TornadoAsyncException
except _DefGen_Return, e:
request._tornado_handler.finish(e.value.content)
return v
if getattr(method, 'csrf_exempt', False):
wrapper.csrf_exempt = True
return wrapper
|
<commit_before>import types
class TornadoAsyncException(Exception): pass
class _DefGen_Return(BaseException):
def __init__(self, value):
self.value = value
def returnResponse(value):
raise _DefGen_Return(value)
def asynchronous(method):
def wrapper(request, *args, **kwargs):
try:
v = method(request, request._tornado_handler, *args, **kwargs)
if v == None or type(v) == types.GeneratorType:
raise TornadoAsyncException
except _DefGen_Return, e:
request._tornado_handler.finish(e.value.content)
return v
return wrapper
<commit_msg>Copy the csrf_exempt attribute in @asynchronous
Needed for @csrf_exempt to work.
(imported from commit 563ab11b0d26262511e9a6d9cc2735b0b835a391)<commit_after>
|
import types
class TornadoAsyncException(Exception): pass
class _DefGen_Return(BaseException):
def __init__(self, value):
self.value = value
def returnResponse(value):
raise _DefGen_Return(value)
def asynchronous(method):
def wrapper(request, *args, **kwargs):
try:
v = method(request, request._tornado_handler, *args, **kwargs)
if v == None or type(v) == types.GeneratorType:
raise TornadoAsyncException
except _DefGen_Return, e:
request._tornado_handler.finish(e.value.content)
return v
if getattr(method, 'csrf_exempt', False):
wrapper.csrf_exempt = True
return wrapper
|
import types
class TornadoAsyncException(Exception): pass
class _DefGen_Return(BaseException):
def __init__(self, value):
self.value = value
def returnResponse(value):
raise _DefGen_Return(value)
def asynchronous(method):
def wrapper(request, *args, **kwargs):
try:
v = method(request, request._tornado_handler, *args, **kwargs)
if v == None or type(v) == types.GeneratorType:
raise TornadoAsyncException
except _DefGen_Return, e:
request._tornado_handler.finish(e.value.content)
return v
return wrapper
Copy the csrf_exempt attribute in @asynchronous
Needed for @csrf_exempt to work.
(imported from commit 563ab11b0d26262511e9a6d9cc2735b0b835a391)import types
class TornadoAsyncException(Exception): pass
class _DefGen_Return(BaseException):
def __init__(self, value):
self.value = value
def returnResponse(value):
raise _DefGen_Return(value)
def asynchronous(method):
def wrapper(request, *args, **kwargs):
try:
v = method(request, request._tornado_handler, *args, **kwargs)
if v == None or type(v) == types.GeneratorType:
raise TornadoAsyncException
except _DefGen_Return, e:
request._tornado_handler.finish(e.value.content)
return v
if getattr(method, 'csrf_exempt', False):
wrapper.csrf_exempt = True
return wrapper
|
<commit_before>import types
class TornadoAsyncException(Exception): pass
class _DefGen_Return(BaseException):
def __init__(self, value):
self.value = value
def returnResponse(value):
raise _DefGen_Return(value)
def asynchronous(method):
def wrapper(request, *args, **kwargs):
try:
v = method(request, request._tornado_handler, *args, **kwargs)
if v == None or type(v) == types.GeneratorType:
raise TornadoAsyncException
except _DefGen_Return, e:
request._tornado_handler.finish(e.value.content)
return v
return wrapper
<commit_msg>Copy the csrf_exempt attribute in @asynchronous
Needed for @csrf_exempt to work.
(imported from commit 563ab11b0d26262511e9a6d9cc2735b0b835a391)<commit_after>import types
class TornadoAsyncException(Exception): pass
class _DefGen_Return(BaseException):
def __init__(self, value):
self.value = value
def returnResponse(value):
raise _DefGen_Return(value)
def asynchronous(method):
def wrapper(request, *args, **kwargs):
try:
v = method(request, request._tornado_handler, *args, **kwargs)
if v == None or type(v) == types.GeneratorType:
raise TornadoAsyncException
except _DefGen_Return, e:
request._tornado_handler.finish(e.value.content)
return v
if getattr(method, 'csrf_exempt', False):
wrapper.csrf_exempt = True
return wrapper
|
6cb38efab37f8953c8ba56662ba512af0f84432f
|
tests/semver_test.py
|
tests/semver_test.py
|
# -*- coding: utf-8 -*-
from unittest import TestCase
from semver import compare
from semver import match
from semver import parse
class TestSemver(TestCase):
def test_should_parse_version(self):
self.assertEquals(
parse("1.2.3-alpha.1.2+build.11.e0f985a"),
{'major': 1,
'minor': 2,
'patch': 3,
'prerelease': 'alpha.1.2',
'build': 'build.11.e0f985a'})
def test_should_get_less(self):
self.assertEquals(
compare("1.0.0", "2.0.0"),
-1)
def test_should_get_greater(self):
self.assertEquals(
compare("2.0.0", "1.0.0"),
1)
def test_should_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.6"),
True)
def test_should_no_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.8"),
False)
|
# -*- coding: utf-8 -*-
from unittest import TestCase
from semver import compare
from semver import match
from semver import parse
class TestSemver(TestCase):
def test_should_parse_version(self):
self.assertEquals(
parse("1.2.3-alpha.1.2+build.11.e0f985a"),
{'major': 1,
'minor': 2,
'patch': 3,
'prerelease': 'alpha.1.2',
'build': 'build.11.e0f985a'})
def test_should_get_less(self):
self.assertEquals(
compare("1.0.0", "2.0.0"),
-1)
def test_should_get_greater(self):
self.assertEquals(
compare("2.0.0", "1.0.0"),
1)
def test_should_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.6"),
True)
def test_should_no_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.8"),
False)
def test_should_raise_value_error_for_invalid_value(self):
self.assertRaises(ValueError, compare, 'foo', 'bar')
self.assertRaises(ValueError, compare, '1.0', '1.0.0')
self.assertRaises(ValueError, compare, '1.x', '1.0.0')
def test_should_raise_value_error_for_invalid_match_expression(self):
self.assertRaises(ValueError, match, '1.0.0', '')
self.assertRaises(ValueError, match, '1.0.0', '!')
self.assertRaises(ValueError, match, '1.0.0', '1.0.0')
|
Add tests for error cases that proves incompatibility with Python 2.5 and early versions.
|
Add tests for error cases that proves incompatibility with Python 2.5 and early versions.
|
Python
|
bsd-3-clause
|
python-semver/python-semver,k-bx/python-semver
|
# -*- coding: utf-8 -*-
from unittest import TestCase
from semver import compare
from semver import match
from semver import parse
class TestSemver(TestCase):
def test_should_parse_version(self):
self.assertEquals(
parse("1.2.3-alpha.1.2+build.11.e0f985a"),
{'major': 1,
'minor': 2,
'patch': 3,
'prerelease': 'alpha.1.2',
'build': 'build.11.e0f985a'})
def test_should_get_less(self):
self.assertEquals(
compare("1.0.0", "2.0.0"),
-1)
def test_should_get_greater(self):
self.assertEquals(
compare("2.0.0", "1.0.0"),
1)
def test_should_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.6"),
True)
def test_should_no_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.8"),
False)
Add tests for error cases that proves incompatibility with Python 2.5 and early versions.
|
# -*- coding: utf-8 -*-
from unittest import TestCase
from semver import compare
from semver import match
from semver import parse
class TestSemver(TestCase):
def test_should_parse_version(self):
self.assertEquals(
parse("1.2.3-alpha.1.2+build.11.e0f985a"),
{'major': 1,
'minor': 2,
'patch': 3,
'prerelease': 'alpha.1.2',
'build': 'build.11.e0f985a'})
def test_should_get_less(self):
self.assertEquals(
compare("1.0.0", "2.0.0"),
-1)
def test_should_get_greater(self):
self.assertEquals(
compare("2.0.0", "1.0.0"),
1)
def test_should_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.6"),
True)
def test_should_no_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.8"),
False)
def test_should_raise_value_error_for_invalid_value(self):
self.assertRaises(ValueError, compare, 'foo', 'bar')
self.assertRaises(ValueError, compare, '1.0', '1.0.0')
self.assertRaises(ValueError, compare, '1.x', '1.0.0')
def test_should_raise_value_error_for_invalid_match_expression(self):
self.assertRaises(ValueError, match, '1.0.0', '')
self.assertRaises(ValueError, match, '1.0.0', '!')
self.assertRaises(ValueError, match, '1.0.0', '1.0.0')
|
<commit_before># -*- coding: utf-8 -*-
from unittest import TestCase
from semver import compare
from semver import match
from semver import parse
class TestSemver(TestCase):
def test_should_parse_version(self):
self.assertEquals(
parse("1.2.3-alpha.1.2+build.11.e0f985a"),
{'major': 1,
'minor': 2,
'patch': 3,
'prerelease': 'alpha.1.2',
'build': 'build.11.e0f985a'})
def test_should_get_less(self):
self.assertEquals(
compare("1.0.0", "2.0.0"),
-1)
def test_should_get_greater(self):
self.assertEquals(
compare("2.0.0", "1.0.0"),
1)
def test_should_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.6"),
True)
def test_should_no_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.8"),
False)
<commit_msg>Add tests for error cases that proves incompatibility with Python 2.5 and early versions.<commit_after>
|
# -*- coding: utf-8 -*-
from unittest import TestCase
from semver import compare
from semver import match
from semver import parse
class TestSemver(TestCase):
def test_should_parse_version(self):
self.assertEquals(
parse("1.2.3-alpha.1.2+build.11.e0f985a"),
{'major': 1,
'minor': 2,
'patch': 3,
'prerelease': 'alpha.1.2',
'build': 'build.11.e0f985a'})
def test_should_get_less(self):
self.assertEquals(
compare("1.0.0", "2.0.0"),
-1)
def test_should_get_greater(self):
self.assertEquals(
compare("2.0.0", "1.0.0"),
1)
def test_should_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.6"),
True)
def test_should_no_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.8"),
False)
def test_should_raise_value_error_for_invalid_value(self):
self.assertRaises(ValueError, compare, 'foo', 'bar')
self.assertRaises(ValueError, compare, '1.0', '1.0.0')
self.assertRaises(ValueError, compare, '1.x', '1.0.0')
def test_should_raise_value_error_for_invalid_match_expression(self):
self.assertRaises(ValueError, match, '1.0.0', '')
self.assertRaises(ValueError, match, '1.0.0', '!')
self.assertRaises(ValueError, match, '1.0.0', '1.0.0')
|
# -*- coding: utf-8 -*-
from unittest import TestCase
from semver import compare
from semver import match
from semver import parse
class TestSemver(TestCase):
def test_should_parse_version(self):
self.assertEquals(
parse("1.2.3-alpha.1.2+build.11.e0f985a"),
{'major': 1,
'minor': 2,
'patch': 3,
'prerelease': 'alpha.1.2',
'build': 'build.11.e0f985a'})
def test_should_get_less(self):
self.assertEquals(
compare("1.0.0", "2.0.0"),
-1)
def test_should_get_greater(self):
self.assertEquals(
compare("2.0.0", "1.0.0"),
1)
def test_should_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.6"),
True)
def test_should_no_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.8"),
False)
Add tests for error cases that proves incompatibility with Python 2.5 and early versions.# -*- coding: utf-8 -*-
from unittest import TestCase
from semver import compare
from semver import match
from semver import parse
class TestSemver(TestCase):
def test_should_parse_version(self):
self.assertEquals(
parse("1.2.3-alpha.1.2+build.11.e0f985a"),
{'major': 1,
'minor': 2,
'patch': 3,
'prerelease': 'alpha.1.2',
'build': 'build.11.e0f985a'})
def test_should_get_less(self):
self.assertEquals(
compare("1.0.0", "2.0.0"),
-1)
def test_should_get_greater(self):
self.assertEquals(
compare("2.0.0", "1.0.0"),
1)
def test_should_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.6"),
True)
def test_should_no_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.8"),
False)
def test_should_raise_value_error_for_invalid_value(self):
self.assertRaises(ValueError, compare, 'foo', 'bar')
self.assertRaises(ValueError, compare, '1.0', '1.0.0')
self.assertRaises(ValueError, compare, '1.x', '1.0.0')
def test_should_raise_value_error_for_invalid_match_expression(self):
self.assertRaises(ValueError, match, '1.0.0', '')
self.assertRaises(ValueError, match, '1.0.0', '!')
self.assertRaises(ValueError, match, '1.0.0', '1.0.0')
|
<commit_before># -*- coding: utf-8 -*-
from unittest import TestCase
from semver import compare
from semver import match
from semver import parse
class TestSemver(TestCase):
def test_should_parse_version(self):
self.assertEquals(
parse("1.2.3-alpha.1.2+build.11.e0f985a"),
{'major': 1,
'minor': 2,
'patch': 3,
'prerelease': 'alpha.1.2',
'build': 'build.11.e0f985a'})
def test_should_get_less(self):
self.assertEquals(
compare("1.0.0", "2.0.0"),
-1)
def test_should_get_greater(self):
self.assertEquals(
compare("2.0.0", "1.0.0"),
1)
def test_should_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.6"),
True)
def test_should_no_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.8"),
False)
<commit_msg>Add tests for error cases that proves incompatibility with Python 2.5 and early versions.<commit_after># -*- coding: utf-8 -*-
from unittest import TestCase
from semver import compare
from semver import match
from semver import parse
class TestSemver(TestCase):
def test_should_parse_version(self):
self.assertEquals(
parse("1.2.3-alpha.1.2+build.11.e0f985a"),
{'major': 1,
'minor': 2,
'patch': 3,
'prerelease': 'alpha.1.2',
'build': 'build.11.e0f985a'})
def test_should_get_less(self):
self.assertEquals(
compare("1.0.0", "2.0.0"),
-1)
def test_should_get_greater(self):
self.assertEquals(
compare("2.0.0", "1.0.0"),
1)
def test_should_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.6"),
True)
def test_should_no_match_simple(self):
self.assertEquals(
match("2.3.7", ">=2.3.8"),
False)
def test_should_raise_value_error_for_invalid_value(self):
self.assertRaises(ValueError, compare, 'foo', 'bar')
self.assertRaises(ValueError, compare, '1.0', '1.0.0')
self.assertRaises(ValueError, compare, '1.x', '1.0.0')
def test_should_raise_value_error_for_invalid_match_expression(self):
self.assertRaises(ValueError, match, '1.0.0', '')
self.assertRaises(ValueError, match, '1.0.0', '!')
self.assertRaises(ValueError, match, '1.0.0', '1.0.0')
|
c783af3af004ec2de31b85045d1c517f5c3a9ccc
|
tests/v6/test_date_generator.py
|
tests/v6/test_date_generator.py
|
import datetime as dt
from .context import tohu
from tohu.v6.primitive_generators import Date
def test_single_date():
g = Date(start="2018-01-01", end="2018-01-01")
dates = g.generate(100, seed=12345)
assert all([x == dt.date(2018, 1, 1) for x in dates])
def test_date_range():
g = Date(start="1999-11-28", end="1999-12-01")
dates = g.generate(1000, seed=12345)
dates_expected = [
dt.date(1999, 11, 28),
dt.date(1999, 11, 29),
dt.date(1999, 11, 30),
dt.date(1999, 12, 1),
]
assert set(dates_expected) == set(dates)
|
import datetime as dt
from .context import tohu
from tohu.v6.primitive_generators import Date
def test_single_date():
g = Date(start="2018-01-01", end="2018-01-01")
dates = g.generate(100, seed=12345)
assert all([x == dt.date(2018, 1, 1) for x in dates])
def test_date_range():
g = Date(start="1999-11-28", end="1999-12-01")
dates = g.generate(1000, seed=12345)
dates_expected = [
dt.date(1999, 11, 28),
dt.date(1999, 11, 29),
dt.date(1999, 11, 30),
dt.date(1999, 12, 1),
]
assert set(dates_expected) == set(dates)
def test_start_and_end():
g = Date(start="1999-11-28", end="1999-12-01")
assert g.start == dt.date(1999, 11, 28)
assert g.end == dt.date(1999, 12, 1)
|
Add test for start/end values
|
Add test for start/end values
|
Python
|
mit
|
maxalbert/tohu
|
import datetime as dt
from .context import tohu
from tohu.v6.primitive_generators import Date
def test_single_date():
g = Date(start="2018-01-01", end="2018-01-01")
dates = g.generate(100, seed=12345)
assert all([x == dt.date(2018, 1, 1) for x in dates])
def test_date_range():
g = Date(start="1999-11-28", end="1999-12-01")
dates = g.generate(1000, seed=12345)
dates_expected = [
dt.date(1999, 11, 28),
dt.date(1999, 11, 29),
dt.date(1999, 11, 30),
dt.date(1999, 12, 1),
]
assert set(dates_expected) == set(dates)
Add test for start/end values
|
import datetime as dt
from .context import tohu
from tohu.v6.primitive_generators import Date
def test_single_date():
g = Date(start="2018-01-01", end="2018-01-01")
dates = g.generate(100, seed=12345)
assert all([x == dt.date(2018, 1, 1) for x in dates])
def test_date_range():
g = Date(start="1999-11-28", end="1999-12-01")
dates = g.generate(1000, seed=12345)
dates_expected = [
dt.date(1999, 11, 28),
dt.date(1999, 11, 29),
dt.date(1999, 11, 30),
dt.date(1999, 12, 1),
]
assert set(dates_expected) == set(dates)
def test_start_and_end():
g = Date(start="1999-11-28", end="1999-12-01")
assert g.start == dt.date(1999, 11, 28)
assert g.end == dt.date(1999, 12, 1)
|
<commit_before>import datetime as dt
from .context import tohu
from tohu.v6.primitive_generators import Date
def test_single_date():
g = Date(start="2018-01-01", end="2018-01-01")
dates = g.generate(100, seed=12345)
assert all([x == dt.date(2018, 1, 1) for x in dates])
def test_date_range():
g = Date(start="1999-11-28", end="1999-12-01")
dates = g.generate(1000, seed=12345)
dates_expected = [
dt.date(1999, 11, 28),
dt.date(1999, 11, 29),
dt.date(1999, 11, 30),
dt.date(1999, 12, 1),
]
assert set(dates_expected) == set(dates)
<commit_msg>Add test for start/end values<commit_after>
|
import datetime as dt
from .context import tohu
from tohu.v6.primitive_generators import Date
def test_single_date():
g = Date(start="2018-01-01", end="2018-01-01")
dates = g.generate(100, seed=12345)
assert all([x == dt.date(2018, 1, 1) for x in dates])
def test_date_range():
g = Date(start="1999-11-28", end="1999-12-01")
dates = g.generate(1000, seed=12345)
dates_expected = [
dt.date(1999, 11, 28),
dt.date(1999, 11, 29),
dt.date(1999, 11, 30),
dt.date(1999, 12, 1),
]
assert set(dates_expected) == set(dates)
def test_start_and_end():
g = Date(start="1999-11-28", end="1999-12-01")
assert g.start == dt.date(1999, 11, 28)
assert g.end == dt.date(1999, 12, 1)
|
import datetime as dt
from .context import tohu
from tohu.v6.primitive_generators import Date
def test_single_date():
g = Date(start="2018-01-01", end="2018-01-01")
dates = g.generate(100, seed=12345)
assert all([x == dt.date(2018, 1, 1) for x in dates])
def test_date_range():
g = Date(start="1999-11-28", end="1999-12-01")
dates = g.generate(1000, seed=12345)
dates_expected = [
dt.date(1999, 11, 28),
dt.date(1999, 11, 29),
dt.date(1999, 11, 30),
dt.date(1999, 12, 1),
]
assert set(dates_expected) == set(dates)
Add test for start/end valuesimport datetime as dt
from .context import tohu
from tohu.v6.primitive_generators import Date
def test_single_date():
g = Date(start="2018-01-01", end="2018-01-01")
dates = g.generate(100, seed=12345)
assert all([x == dt.date(2018, 1, 1) for x in dates])
def test_date_range():
g = Date(start="1999-11-28", end="1999-12-01")
dates = g.generate(1000, seed=12345)
dates_expected = [
dt.date(1999, 11, 28),
dt.date(1999, 11, 29),
dt.date(1999, 11, 30),
dt.date(1999, 12, 1),
]
assert set(dates_expected) == set(dates)
def test_start_and_end():
g = Date(start="1999-11-28", end="1999-12-01")
assert g.start == dt.date(1999, 11, 28)
assert g.end == dt.date(1999, 12, 1)
|
<commit_before>import datetime as dt
from .context import tohu
from tohu.v6.primitive_generators import Date
def test_single_date():
g = Date(start="2018-01-01", end="2018-01-01")
dates = g.generate(100, seed=12345)
assert all([x == dt.date(2018, 1, 1) for x in dates])
def test_date_range():
g = Date(start="1999-11-28", end="1999-12-01")
dates = g.generate(1000, seed=12345)
dates_expected = [
dt.date(1999, 11, 28),
dt.date(1999, 11, 29),
dt.date(1999, 11, 30),
dt.date(1999, 12, 1),
]
assert set(dates_expected) == set(dates)
<commit_msg>Add test for start/end values<commit_after>import datetime as dt
from .context import tohu
from tohu.v6.primitive_generators import Date
def test_single_date():
g = Date(start="2018-01-01", end="2018-01-01")
dates = g.generate(100, seed=12345)
assert all([x == dt.date(2018, 1, 1) for x in dates])
def test_date_range():
g = Date(start="1999-11-28", end="1999-12-01")
dates = g.generate(1000, seed=12345)
dates_expected = [
dt.date(1999, 11, 28),
dt.date(1999, 11, 29),
dt.date(1999, 11, 30),
dt.date(1999, 12, 1),
]
assert set(dates_expected) == set(dates)
def test_start_and_end():
g = Date(start="1999-11-28", end="1999-12-01")
assert g.start == dt.date(1999, 11, 28)
assert g.end == dt.date(1999, 12, 1)
|
50df670d1c338c72d43b39a26ecb31d94d6161d7
|
tools/addvariable.py
|
tools/addvariable.py
|
#!/usr/bin/env python
import sys
sys.path.append('..')
from cli import *
from optparse import OptionParser
parse = OptionParser()
parse.add_option('-a', '--variable', dest='variables',
help='Add variable',
default=[], action='append', type=str)
parse.add_option('-r', '--random', dest='randoms',
help='Add random (is_var=0)',
default=[], action='append', type=str)
o = parse.parse_args()[0]
for var in o.variables:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 1)
session.add(v)
for var in o.randoms:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 0)
session.add(v)
session.commit()
|
#!/usr/bin/env python
import sys
sys.path.append('..')
from cli import *
from optparse import OptionParser
parse = OptionParser()
parse.add_option('-a', '--variable', dest='variables',
help='Add variable',
default=[], action='append', type=str)
parse.add_option('-r', '--random', dest='randoms',
help='Add random (is_var=0)',
default=[], action='append', type=str)
parse.add_option('-l', '--list', dest='list_vars',
default=False, action='store_true')
o = parse.parse_args()[0]
if o.list_vars:
vars = session.query(Variable).all()
for x in vars:
print x
exit()
for var in o.variables:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 1)
session.add(v)
for var in o.randoms:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 0)
session.add(v)
session.commit()
|
Add --list to variable tool.
|
Tools: Add --list to variable tool.
|
Python
|
agpl-3.0
|
MerlijnWajer/SRL-Stats
|
#!/usr/bin/env python
import sys
sys.path.append('..')
from cli import *
from optparse import OptionParser
parse = OptionParser()
parse.add_option('-a', '--variable', dest='variables',
help='Add variable',
default=[], action='append', type=str)
parse.add_option('-r', '--random', dest='randoms',
help='Add random (is_var=0)',
default=[], action='append', type=str)
o = parse.parse_args()[0]
for var in o.variables:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 1)
session.add(v)
for var in o.randoms:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 0)
session.add(v)
session.commit()
Tools: Add --list to variable tool.
|
#!/usr/bin/env python
import sys
sys.path.append('..')
from cli import *
from optparse import OptionParser
parse = OptionParser()
parse.add_option('-a', '--variable', dest='variables',
help='Add variable',
default=[], action='append', type=str)
parse.add_option('-r', '--random', dest='randoms',
help='Add random (is_var=0)',
default=[], action='append', type=str)
parse.add_option('-l', '--list', dest='list_vars',
default=False, action='store_true')
o = parse.parse_args()[0]
if o.list_vars:
vars = session.query(Variable).all()
for x in vars:
print x
exit()
for var in o.variables:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 1)
session.add(v)
for var in o.randoms:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 0)
session.add(v)
session.commit()
|
<commit_before>#!/usr/bin/env python
import sys
sys.path.append('..')
from cli import *
from optparse import OptionParser
parse = OptionParser()
parse.add_option('-a', '--variable', dest='variables',
help='Add variable',
default=[], action='append', type=str)
parse.add_option('-r', '--random', dest='randoms',
help='Add random (is_var=0)',
default=[], action='append', type=str)
o = parse.parse_args()[0]
for var in o.variables:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 1)
session.add(v)
for var in o.randoms:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 0)
session.add(v)
session.commit()
<commit_msg>Tools: Add --list to variable tool.<commit_after>
|
#!/usr/bin/env python
import sys
sys.path.append('..')
from cli import *
from optparse import OptionParser
parse = OptionParser()
parse.add_option('-a', '--variable', dest='variables',
help='Add variable',
default=[], action='append', type=str)
parse.add_option('-r', '--random', dest='randoms',
help='Add random (is_var=0)',
default=[], action='append', type=str)
parse.add_option('-l', '--list', dest='list_vars',
default=False, action='store_true')
o = parse.parse_args()[0]
if o.list_vars:
vars = session.query(Variable).all()
for x in vars:
print x
exit()
for var in o.variables:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 1)
session.add(v)
for var in o.randoms:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 0)
session.add(v)
session.commit()
|
#!/usr/bin/env python
import sys
sys.path.append('..')
from cli import *
from optparse import OptionParser
parse = OptionParser()
parse.add_option('-a', '--variable', dest='variables',
help='Add variable',
default=[], action='append', type=str)
parse.add_option('-r', '--random', dest='randoms',
help='Add random (is_var=0)',
default=[], action='append', type=str)
o = parse.parse_args()[0]
for var in o.variables:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 1)
session.add(v)
for var in o.randoms:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 0)
session.add(v)
session.commit()
Tools: Add --list to variable tool.#!/usr/bin/env python
import sys
sys.path.append('..')
from cli import *
from optparse import OptionParser
parse = OptionParser()
parse.add_option('-a', '--variable', dest='variables',
help='Add variable',
default=[], action='append', type=str)
parse.add_option('-r', '--random', dest='randoms',
help='Add random (is_var=0)',
default=[], action='append', type=str)
parse.add_option('-l', '--list', dest='list_vars',
default=False, action='store_true')
o = parse.parse_args()[0]
if o.list_vars:
vars = session.query(Variable).all()
for x in vars:
print x
exit()
for var in o.variables:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 1)
session.add(v)
for var in o.randoms:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 0)
session.add(v)
session.commit()
|
<commit_before>#!/usr/bin/env python
import sys
sys.path.append('..')
from cli import *
from optparse import OptionParser
parse = OptionParser()
parse.add_option('-a', '--variable', dest='variables',
help='Add variable',
default=[], action='append', type=str)
parse.add_option('-r', '--random', dest='randoms',
help='Add random (is_var=0)',
default=[], action='append', type=str)
o = parse.parse_args()[0]
for var in o.variables:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 1)
session.add(v)
for var in o.randoms:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 0)
session.add(v)
session.commit()
<commit_msg>Tools: Add --list to variable tool.<commit_after>#!/usr/bin/env python
import sys
sys.path.append('..')
from cli import *
from optparse import OptionParser
parse = OptionParser()
parse.add_option('-a', '--variable', dest='variables',
help='Add variable',
default=[], action='append', type=str)
parse.add_option('-r', '--random', dest='randoms',
help='Add random (is_var=0)',
default=[], action='append', type=str)
parse.add_option('-l', '--list', dest='list_vars',
default=False, action='store_true')
o = parse.parse_args()[0]
if o.list_vars:
vars = session.query(Variable).all()
for x in vars:
print x
exit()
for var in o.variables:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 1)
session.add(v)
for var in o.randoms:
exists = session.query(Variable).filter(Variable.name == var).first()
if exists is not None:
print '%s already exists!' % var
exit()
v = Variable(var, 0)
session.add(v)
session.commit()
|
55cc4ce70ec5da104ae3078dc0fed023153b3de8
|
ForumSite/urls.py
|
ForumSite/urls.py
|
from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Examples:
# url(r'^$', 'ForumSite.views.home', name='home'),
# url(r'^blog/', include('blog.urls')),
url(r'^', include('Forum.urls'), {'forum_id':0}),
url(r'^admin/', include(admin.site.urls)),
)
|
from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Examples:
# url(r'^$', 'ForumSite.views.home', name='home'),
# url(r'^blog/', include('blog.urls')),
url(r'^', include('Forum.urls'), {'forum_id':0}),
url(r'^(?P<forum_id>\d+)', include('Forum.urls')),
url(r'^admin/', include(admin.site.urls)),
)
|
Test project allow multiple forums
|
Test project allow multiple forums
|
Python
|
mit
|
Galbar/django-forum,Galbar/django-forum
|
from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Examples:
# url(r'^$', 'ForumSite.views.home', name='home'),
# url(r'^blog/', include('blog.urls')),
url(r'^', include('Forum.urls'), {'forum_id':0}),
url(r'^admin/', include(admin.site.urls)),
)
Test project allow multiple forums
|
from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Examples:
# url(r'^$', 'ForumSite.views.home', name='home'),
# url(r'^blog/', include('blog.urls')),
url(r'^', include('Forum.urls'), {'forum_id':0}),
url(r'^(?P<forum_id>\d+)', include('Forum.urls')),
url(r'^admin/', include(admin.site.urls)),
)
|
<commit_before>from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Examples:
# url(r'^$', 'ForumSite.views.home', name='home'),
# url(r'^blog/', include('blog.urls')),
url(r'^', include('Forum.urls'), {'forum_id':0}),
url(r'^admin/', include(admin.site.urls)),
)
<commit_msg>Test project allow multiple forums<commit_after>
|
from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Examples:
# url(r'^$', 'ForumSite.views.home', name='home'),
# url(r'^blog/', include('blog.urls')),
url(r'^', include('Forum.urls'), {'forum_id':0}),
url(r'^(?P<forum_id>\d+)', include('Forum.urls')),
url(r'^admin/', include(admin.site.urls)),
)
|
from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Examples:
# url(r'^$', 'ForumSite.views.home', name='home'),
# url(r'^blog/', include('blog.urls')),
url(r'^', include('Forum.urls'), {'forum_id':0}),
url(r'^admin/', include(admin.site.urls)),
)
Test project allow multiple forumsfrom django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Examples:
# url(r'^$', 'ForumSite.views.home', name='home'),
# url(r'^blog/', include('blog.urls')),
url(r'^', include('Forum.urls'), {'forum_id':0}),
url(r'^(?P<forum_id>\d+)', include('Forum.urls')),
url(r'^admin/', include(admin.site.urls)),
)
|
<commit_before>from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Examples:
# url(r'^$', 'ForumSite.views.home', name='home'),
# url(r'^blog/', include('blog.urls')),
url(r'^', include('Forum.urls'), {'forum_id':0}),
url(r'^admin/', include(admin.site.urls)),
)
<commit_msg>Test project allow multiple forums<commit_after>from django.conf.urls import patterns, include, url
from django.contrib import admin
admin.autodiscover()
urlpatterns = patterns('',
# Examples:
# url(r'^$', 'ForumSite.views.home', name='home'),
# url(r'^blog/', include('blog.urls')),
url(r'^', include('Forum.urls'), {'forum_id':0}),
url(r'^(?P<forum_id>\d+)', include('Forum.urls')),
url(r'^admin/', include(admin.site.urls)),
)
|
1be9c51d4029c0fa32f7071072c171db42d21c83
|
doc-src/index.py
|
doc-src/index.py
|
import countershape
from countershape import Page, Directory, PythonModule
import countershape.grok
this.layout = countershape.Layout("_layout.html")
this.markdown = "rst"
ns.docTitle = "Countershape Manual"
ns.docMaintainer = "Aldo Cortesi"
ns.docMaintainerEmail = "dev@nullcube.com"
ns.copyright = "Copyright Nullcube 2007"
ns.head = countershape.template.File(None, "_banner.html")
ns.sidebar = countershape.widgets.SiblingPageIndex(
'/index.html',
exclude=['countershape']
)
ns.parse = countershape.grok.parse("../countershape")
pages = [
Page("index.html", "Introduction"),
Page("structure.html", "Document Structure"),
Page("doc.html", "Documenting Code"),
Page("api/apiref.html", "API Reference"),
Directory("api"),
PythonModule("../countershape", "Source"),
Page("admin.html", "Administrivia")
]
ns.imgBanner = countershape.html.IMG(
src=countershape.model.UrlTo("countershape.png"),
width="280",
height="77",
align="right"
)
|
import countershape
from countershape import Page, Directory, PythonModule
import countershape.grok
this.layout = countershape.Layout("_layout.html")
this.markdown = "rst"
ns.docTitle = "Countershape Manual"
ns.docMaintainer = "Aldo Cortesi"
ns.docMaintainerEmail = "dev@nullcube.com"
ns.copyright = "Copyright Nullcube 2007"
ns.head = countershape.template.File(None, "_banner.html")
ns.sidebar = countershape.widgets.SiblingPageIndex(
'/index.html',
exclude=['countershape']
)
ns.parse = countershape.grok.parse("../countershape")
pages = [
Page("index.html", "Introduction"),
Page("structure/structure.html", "Document Structure"),
Directory("structure"),
Page("doc.html", "Documenting Code"),
Page("api/apiref.html", "API Reference"),
Directory("api"),
PythonModule("../countershape", "Source"),
Page("admin.html", "Administrivia")
]
ns.imgBanner = countershape.html.IMG(
src=countershape.model.UrlTo("countershape.png"),
width="280",
height="77",
align="right"
)
|
Move structure to a separate directory
|
Move structure to a separate directory
|
Python
|
mit
|
mhils/countershape,cortesi/countershape,samtaufa/countershape,mhils/countershape,cortesi/countershape,samtaufa/countershape
|
import countershape
from countershape import Page, Directory, PythonModule
import countershape.grok
this.layout = countershape.Layout("_layout.html")
this.markdown = "rst"
ns.docTitle = "Countershape Manual"
ns.docMaintainer = "Aldo Cortesi"
ns.docMaintainerEmail = "dev@nullcube.com"
ns.copyright = "Copyright Nullcube 2007"
ns.head = countershape.template.File(None, "_banner.html")
ns.sidebar = countershape.widgets.SiblingPageIndex(
'/index.html',
exclude=['countershape']
)
ns.parse = countershape.grok.parse("../countershape")
pages = [
Page("index.html", "Introduction"),
Page("structure.html", "Document Structure"),
Page("doc.html", "Documenting Code"),
Page("api/apiref.html", "API Reference"),
Directory("api"),
PythonModule("../countershape", "Source"),
Page("admin.html", "Administrivia")
]
ns.imgBanner = countershape.html.IMG(
src=countershape.model.UrlTo("countershape.png"),
width="280",
height="77",
align="right"
)Move structure to a separate directory
|
import countershape
from countershape import Page, Directory, PythonModule
import countershape.grok
this.layout = countershape.Layout("_layout.html")
this.markdown = "rst"
ns.docTitle = "Countershape Manual"
ns.docMaintainer = "Aldo Cortesi"
ns.docMaintainerEmail = "dev@nullcube.com"
ns.copyright = "Copyright Nullcube 2007"
ns.head = countershape.template.File(None, "_banner.html")
ns.sidebar = countershape.widgets.SiblingPageIndex(
'/index.html',
exclude=['countershape']
)
ns.parse = countershape.grok.parse("../countershape")
pages = [
Page("index.html", "Introduction"),
Page("structure/structure.html", "Document Structure"),
Directory("structure"),
Page("doc.html", "Documenting Code"),
Page("api/apiref.html", "API Reference"),
Directory("api"),
PythonModule("../countershape", "Source"),
Page("admin.html", "Administrivia")
]
ns.imgBanner = countershape.html.IMG(
src=countershape.model.UrlTo("countershape.png"),
width="280",
height="77",
align="right"
)
|
<commit_before>import countershape
from countershape import Page, Directory, PythonModule
import countershape.grok
this.layout = countershape.Layout("_layout.html")
this.markdown = "rst"
ns.docTitle = "Countershape Manual"
ns.docMaintainer = "Aldo Cortesi"
ns.docMaintainerEmail = "dev@nullcube.com"
ns.copyright = "Copyright Nullcube 2007"
ns.head = countershape.template.File(None, "_banner.html")
ns.sidebar = countershape.widgets.SiblingPageIndex(
'/index.html',
exclude=['countershape']
)
ns.parse = countershape.grok.parse("../countershape")
pages = [
Page("index.html", "Introduction"),
Page("structure.html", "Document Structure"),
Page("doc.html", "Documenting Code"),
Page("api/apiref.html", "API Reference"),
Directory("api"),
PythonModule("../countershape", "Source"),
Page("admin.html", "Administrivia")
]
ns.imgBanner = countershape.html.IMG(
src=countershape.model.UrlTo("countershape.png"),
width="280",
height="77",
align="right"
)<commit_msg>Move structure to a separate directory<commit_after>
|
import countershape
from countershape import Page, Directory, PythonModule
import countershape.grok
this.layout = countershape.Layout("_layout.html")
this.markdown = "rst"
ns.docTitle = "Countershape Manual"
ns.docMaintainer = "Aldo Cortesi"
ns.docMaintainerEmail = "dev@nullcube.com"
ns.copyright = "Copyright Nullcube 2007"
ns.head = countershape.template.File(None, "_banner.html")
ns.sidebar = countershape.widgets.SiblingPageIndex(
'/index.html',
exclude=['countershape']
)
ns.parse = countershape.grok.parse("../countershape")
pages = [
Page("index.html", "Introduction"),
Page("structure/structure.html", "Document Structure"),
Directory("structure"),
Page("doc.html", "Documenting Code"),
Page("api/apiref.html", "API Reference"),
Directory("api"),
PythonModule("../countershape", "Source"),
Page("admin.html", "Administrivia")
]
ns.imgBanner = countershape.html.IMG(
src=countershape.model.UrlTo("countershape.png"),
width="280",
height="77",
align="right"
)
|
import countershape
from countershape import Page, Directory, PythonModule
import countershape.grok
this.layout = countershape.Layout("_layout.html")
this.markdown = "rst"
ns.docTitle = "Countershape Manual"
ns.docMaintainer = "Aldo Cortesi"
ns.docMaintainerEmail = "dev@nullcube.com"
ns.copyright = "Copyright Nullcube 2007"
ns.head = countershape.template.File(None, "_banner.html")
ns.sidebar = countershape.widgets.SiblingPageIndex(
'/index.html',
exclude=['countershape']
)
ns.parse = countershape.grok.parse("../countershape")
pages = [
Page("index.html", "Introduction"),
Page("structure.html", "Document Structure"),
Page("doc.html", "Documenting Code"),
Page("api/apiref.html", "API Reference"),
Directory("api"),
PythonModule("../countershape", "Source"),
Page("admin.html", "Administrivia")
]
ns.imgBanner = countershape.html.IMG(
src=countershape.model.UrlTo("countershape.png"),
width="280",
height="77",
align="right"
)Move structure to a separate directoryimport countershape
from countershape import Page, Directory, PythonModule
import countershape.grok
this.layout = countershape.Layout("_layout.html")
this.markdown = "rst"
ns.docTitle = "Countershape Manual"
ns.docMaintainer = "Aldo Cortesi"
ns.docMaintainerEmail = "dev@nullcube.com"
ns.copyright = "Copyright Nullcube 2007"
ns.head = countershape.template.File(None, "_banner.html")
ns.sidebar = countershape.widgets.SiblingPageIndex(
'/index.html',
exclude=['countershape']
)
ns.parse = countershape.grok.parse("../countershape")
pages = [
Page("index.html", "Introduction"),
Page("structure/structure.html", "Document Structure"),
Directory("structure"),
Page("doc.html", "Documenting Code"),
Page("api/apiref.html", "API Reference"),
Directory("api"),
PythonModule("../countershape", "Source"),
Page("admin.html", "Administrivia")
]
ns.imgBanner = countershape.html.IMG(
src=countershape.model.UrlTo("countershape.png"),
width="280",
height="77",
align="right"
)
|
<commit_before>import countershape
from countershape import Page, Directory, PythonModule
import countershape.grok
this.layout = countershape.Layout("_layout.html")
this.markdown = "rst"
ns.docTitle = "Countershape Manual"
ns.docMaintainer = "Aldo Cortesi"
ns.docMaintainerEmail = "dev@nullcube.com"
ns.copyright = "Copyright Nullcube 2007"
ns.head = countershape.template.File(None, "_banner.html")
ns.sidebar = countershape.widgets.SiblingPageIndex(
'/index.html',
exclude=['countershape']
)
ns.parse = countershape.grok.parse("../countershape")
pages = [
Page("index.html", "Introduction"),
Page("structure.html", "Document Structure"),
Page("doc.html", "Documenting Code"),
Page("api/apiref.html", "API Reference"),
Directory("api"),
PythonModule("../countershape", "Source"),
Page("admin.html", "Administrivia")
]
ns.imgBanner = countershape.html.IMG(
src=countershape.model.UrlTo("countershape.png"),
width="280",
height="77",
align="right"
)<commit_msg>Move structure to a separate directory<commit_after>import countershape
from countershape import Page, Directory, PythonModule
import countershape.grok
this.layout = countershape.Layout("_layout.html")
this.markdown = "rst"
ns.docTitle = "Countershape Manual"
ns.docMaintainer = "Aldo Cortesi"
ns.docMaintainerEmail = "dev@nullcube.com"
ns.copyright = "Copyright Nullcube 2007"
ns.head = countershape.template.File(None, "_banner.html")
ns.sidebar = countershape.widgets.SiblingPageIndex(
'/index.html',
exclude=['countershape']
)
ns.parse = countershape.grok.parse("../countershape")
pages = [
Page("index.html", "Introduction"),
Page("structure/structure.html", "Document Structure"),
Directory("structure"),
Page("doc.html", "Documenting Code"),
Page("api/apiref.html", "API Reference"),
Directory("api"),
PythonModule("../countershape", "Source"),
Page("admin.html", "Administrivia")
]
ns.imgBanner = countershape.html.IMG(
src=countershape.model.UrlTo("countershape.png"),
width="280",
height="77",
align="right"
)
|
f8110564d37303b2679575450bea40710dc96fa5
|
odin/serializers.py
|
odin/serializers.py
|
# -*- coding: utf-8 -*-
import datetime
from odin import datetimeutil
class DatetimeEcmaFormat(object):
"""
Serialize a datetime object into the ECMA defined format.
"""
input_type = datetime.datetime
def __init__(self, assume_local=True):
self.assume_local = assume_local
def __call__(self, value):
assert isinstance(value, self.input_type)
return datetimeutil.to_ecma_date_string(value, self.assume_local)
datetime_ecma_format = DatetimeEcmaFormat()
|
# -*- coding: utf-8 -*-
import datetime
from odin import datetimeutil
class DatetimeEcmaFormat(object):
"""
Serialize a datetime object into the ECMA defined format.
"""
input_type = datetime.datetime
def __init__(self, assume_local=True):
self.assume_local = assume_local
def __call__(self, value):
assert isinstance(value, self.input_type)
return datetimeutil.to_ecma_datetime_string(value, self.assume_local)
datetime_ecma_format = DatetimeEcmaFormat()
|
Change serialise field reference to update method name in datetimeutil
|
Change serialise field reference to update method name in datetimeutil
|
Python
|
bsd-3-clause
|
python-odin/odin
|
# -*- coding: utf-8 -*-
import datetime
from odin import datetimeutil
class DatetimeEcmaFormat(object):
"""
Serialize a datetime object into the ECMA defined format.
"""
input_type = datetime.datetime
def __init__(self, assume_local=True):
self.assume_local = assume_local
def __call__(self, value):
assert isinstance(value, self.input_type)
return datetimeutil.to_ecma_date_string(value, self.assume_local)
datetime_ecma_format = DatetimeEcmaFormat()
Change serialise field reference to update method name in datetimeutil
|
# -*- coding: utf-8 -*-
import datetime
from odin import datetimeutil
class DatetimeEcmaFormat(object):
"""
Serialize a datetime object into the ECMA defined format.
"""
input_type = datetime.datetime
def __init__(self, assume_local=True):
self.assume_local = assume_local
def __call__(self, value):
assert isinstance(value, self.input_type)
return datetimeutil.to_ecma_datetime_string(value, self.assume_local)
datetime_ecma_format = DatetimeEcmaFormat()
|
<commit_before># -*- coding: utf-8 -*-
import datetime
from odin import datetimeutil
class DatetimeEcmaFormat(object):
"""
Serialize a datetime object into the ECMA defined format.
"""
input_type = datetime.datetime
def __init__(self, assume_local=True):
self.assume_local = assume_local
def __call__(self, value):
assert isinstance(value, self.input_type)
return datetimeutil.to_ecma_date_string(value, self.assume_local)
datetime_ecma_format = DatetimeEcmaFormat()
<commit_msg>Change serialise field reference to update method name in datetimeutil<commit_after>
|
# -*- coding: utf-8 -*-
import datetime
from odin import datetimeutil
class DatetimeEcmaFormat(object):
"""
Serialize a datetime object into the ECMA defined format.
"""
input_type = datetime.datetime
def __init__(self, assume_local=True):
self.assume_local = assume_local
def __call__(self, value):
assert isinstance(value, self.input_type)
return datetimeutil.to_ecma_datetime_string(value, self.assume_local)
datetime_ecma_format = DatetimeEcmaFormat()
|
# -*- coding: utf-8 -*-
import datetime
from odin import datetimeutil
class DatetimeEcmaFormat(object):
"""
Serialize a datetime object into the ECMA defined format.
"""
input_type = datetime.datetime
def __init__(self, assume_local=True):
self.assume_local = assume_local
def __call__(self, value):
assert isinstance(value, self.input_type)
return datetimeutil.to_ecma_date_string(value, self.assume_local)
datetime_ecma_format = DatetimeEcmaFormat()
Change serialise field reference to update method name in datetimeutil# -*- coding: utf-8 -*-
import datetime
from odin import datetimeutil
class DatetimeEcmaFormat(object):
"""
Serialize a datetime object into the ECMA defined format.
"""
input_type = datetime.datetime
def __init__(self, assume_local=True):
self.assume_local = assume_local
def __call__(self, value):
assert isinstance(value, self.input_type)
return datetimeutil.to_ecma_datetime_string(value, self.assume_local)
datetime_ecma_format = DatetimeEcmaFormat()
|
<commit_before># -*- coding: utf-8 -*-
import datetime
from odin import datetimeutil
class DatetimeEcmaFormat(object):
"""
Serialize a datetime object into the ECMA defined format.
"""
input_type = datetime.datetime
def __init__(self, assume_local=True):
self.assume_local = assume_local
def __call__(self, value):
assert isinstance(value, self.input_type)
return datetimeutil.to_ecma_date_string(value, self.assume_local)
datetime_ecma_format = DatetimeEcmaFormat()
<commit_msg>Change serialise field reference to update method name in datetimeutil<commit_after># -*- coding: utf-8 -*-
import datetime
from odin import datetimeutil
class DatetimeEcmaFormat(object):
"""
Serialize a datetime object into the ECMA defined format.
"""
input_type = datetime.datetime
def __init__(self, assume_local=True):
self.assume_local = assume_local
def __call__(self, value):
assert isinstance(value, self.input_type)
return datetimeutil.to_ecma_datetime_string(value, self.assume_local)
datetime_ecma_format = DatetimeEcmaFormat()
|
f0dc0309518e8862ac7ad785d97a485df538b965
|
grip/constants.py
|
grip/constants.py
|
# The supported extensions, as defined by https://github.com/github/markup
supported_extensions = ['.md', '.markdown']
# The default filenames when no file is provided
default_filenames = map(lambda ext: 'README' + ext, supported_extensions)
|
# The supported extensions, as defined by https://github.com/github/markup
supported_extensions = ['.md', '.markdown']
# The default filenames when no file is provided
default_filenames = ['README' + ext for ext in supported_extensions]
|
Fix map resolving to empty list on Python 3.
|
Fix map resolving to empty list on Python 3.
|
Python
|
mit
|
jbarreras/grip,mgoddard-pivotal/grip,jbarreras/grip,ssundarraj/grip,joeyespo/grip,mgoddard-pivotal/grip,joeyespo/grip,ssundarraj/grip
|
# The supported extensions, as defined by https://github.com/github/markup
supported_extensions = ['.md', '.markdown']
# The default filenames when no file is provided
default_filenames = map(lambda ext: 'README' + ext, supported_extensions)
Fix map resolving to empty list on Python 3.
|
# The supported extensions, as defined by https://github.com/github/markup
supported_extensions = ['.md', '.markdown']
# The default filenames when no file is provided
default_filenames = ['README' + ext for ext in supported_extensions]
|
<commit_before># The supported extensions, as defined by https://github.com/github/markup
supported_extensions = ['.md', '.markdown']
# The default filenames when no file is provided
default_filenames = map(lambda ext: 'README' + ext, supported_extensions)
<commit_msg>Fix map resolving to empty list on Python 3.<commit_after>
|
# The supported extensions, as defined by https://github.com/github/markup
supported_extensions = ['.md', '.markdown']
# The default filenames when no file is provided
default_filenames = ['README' + ext for ext in supported_extensions]
|
# The supported extensions, as defined by https://github.com/github/markup
supported_extensions = ['.md', '.markdown']
# The default filenames when no file is provided
default_filenames = map(lambda ext: 'README' + ext, supported_extensions)
Fix map resolving to empty list on Python 3.# The supported extensions, as defined by https://github.com/github/markup
supported_extensions = ['.md', '.markdown']
# The default filenames when no file is provided
default_filenames = ['README' + ext for ext in supported_extensions]
|
<commit_before># The supported extensions, as defined by https://github.com/github/markup
supported_extensions = ['.md', '.markdown']
# The default filenames when no file is provided
default_filenames = map(lambda ext: 'README' + ext, supported_extensions)
<commit_msg>Fix map resolving to empty list on Python 3.<commit_after># The supported extensions, as defined by https://github.com/github/markup
supported_extensions = ['.md', '.markdown']
# The default filenames when no file is provided
default_filenames = ['README' + ext for ext in supported_extensions]
|
2f85d8985bf4089e39d2510190bf6dedea91fe5b
|
polling_stations/apps/addressbase/migrations/0001_initial.py
|
polling_stations/apps/addressbase/migrations/0001_initial.py
|
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
import django.contrib.gis.db.models.fields
class Migration(migrations.Migration):
replaces = [('addressbase', '0001_initial'), ('addressbase', '0002_auto_20160611_1700'), ('addressbase', '0003_auto_20160611_2130'), ('addressbase', '0004_auto_20160611_2304'), ('addressbase', '0005_auto_20160612_0904')]
dependencies = [
]
operations = [
migrations.CreateModel(
name='Address',
fields=[
('uprn', models.CharField(primary_key=True, max_length=100, serialize=False)),
('address', models.TextField(blank=True)),
('postcode', models.CharField(db_index=True, max_length=15, blank=True)),
('location', django.contrib.gis.db.models.fields.PointField(null=True, srid=4326, blank=True)),
],
),
]
|
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
import django.contrib.gis.db.models.fields
class Migration(migrations.Migration):
dependencies = [
]
operations = [
migrations.CreateModel(
name='Address',
fields=[
('uprn', models.CharField(primary_key=True, max_length=100, serialize=False)),
('address', models.TextField(blank=True)),
('postcode', models.CharField(db_index=True, max_length=15, blank=True)),
('location', django.contrib.gis.db.models.fields.PointField(null=True, srid=4326, blank=True)),
],
),
]
|
Convert squashed migration to regular migration
|
Convert squashed migration to regular migration
This confuses the hell out of me every time
|
Python
|
bsd-3-clause
|
chris48s/UK-Polling-Stations,DemocracyClub/UK-Polling-Stations,DemocracyClub/UK-Polling-Stations,DemocracyClub/UK-Polling-Stations,chris48s/UK-Polling-Stations,chris48s/UK-Polling-Stations
|
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
import django.contrib.gis.db.models.fields
class Migration(migrations.Migration):
replaces = [('addressbase', '0001_initial'), ('addressbase', '0002_auto_20160611_1700'), ('addressbase', '0003_auto_20160611_2130'), ('addressbase', '0004_auto_20160611_2304'), ('addressbase', '0005_auto_20160612_0904')]
dependencies = [
]
operations = [
migrations.CreateModel(
name='Address',
fields=[
('uprn', models.CharField(primary_key=True, max_length=100, serialize=False)),
('address', models.TextField(blank=True)),
('postcode', models.CharField(db_index=True, max_length=15, blank=True)),
('location', django.contrib.gis.db.models.fields.PointField(null=True, srid=4326, blank=True)),
],
),
]
Convert squashed migration to regular migration
This confuses the hell out of me every time
|
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
import django.contrib.gis.db.models.fields
class Migration(migrations.Migration):
dependencies = [
]
operations = [
migrations.CreateModel(
name='Address',
fields=[
('uprn', models.CharField(primary_key=True, max_length=100, serialize=False)),
('address', models.TextField(blank=True)),
('postcode', models.CharField(db_index=True, max_length=15, blank=True)),
('location', django.contrib.gis.db.models.fields.PointField(null=True, srid=4326, blank=True)),
],
),
]
|
<commit_before># -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
import django.contrib.gis.db.models.fields
class Migration(migrations.Migration):
replaces = [('addressbase', '0001_initial'), ('addressbase', '0002_auto_20160611_1700'), ('addressbase', '0003_auto_20160611_2130'), ('addressbase', '0004_auto_20160611_2304'), ('addressbase', '0005_auto_20160612_0904')]
dependencies = [
]
operations = [
migrations.CreateModel(
name='Address',
fields=[
('uprn', models.CharField(primary_key=True, max_length=100, serialize=False)),
('address', models.TextField(blank=True)),
('postcode', models.CharField(db_index=True, max_length=15, blank=True)),
('location', django.contrib.gis.db.models.fields.PointField(null=True, srid=4326, blank=True)),
],
),
]
<commit_msg>Convert squashed migration to regular migration
This confuses the hell out of me every time<commit_after>
|
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
import django.contrib.gis.db.models.fields
class Migration(migrations.Migration):
dependencies = [
]
operations = [
migrations.CreateModel(
name='Address',
fields=[
('uprn', models.CharField(primary_key=True, max_length=100, serialize=False)),
('address', models.TextField(blank=True)),
('postcode', models.CharField(db_index=True, max_length=15, blank=True)),
('location', django.contrib.gis.db.models.fields.PointField(null=True, srid=4326, blank=True)),
],
),
]
|
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
import django.contrib.gis.db.models.fields
class Migration(migrations.Migration):
replaces = [('addressbase', '0001_initial'), ('addressbase', '0002_auto_20160611_1700'), ('addressbase', '0003_auto_20160611_2130'), ('addressbase', '0004_auto_20160611_2304'), ('addressbase', '0005_auto_20160612_0904')]
dependencies = [
]
operations = [
migrations.CreateModel(
name='Address',
fields=[
('uprn', models.CharField(primary_key=True, max_length=100, serialize=False)),
('address', models.TextField(blank=True)),
('postcode', models.CharField(db_index=True, max_length=15, blank=True)),
('location', django.contrib.gis.db.models.fields.PointField(null=True, srid=4326, blank=True)),
],
),
]
Convert squashed migration to regular migration
This confuses the hell out of me every time# -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
import django.contrib.gis.db.models.fields
class Migration(migrations.Migration):
dependencies = [
]
operations = [
migrations.CreateModel(
name='Address',
fields=[
('uprn', models.CharField(primary_key=True, max_length=100, serialize=False)),
('address', models.TextField(blank=True)),
('postcode', models.CharField(db_index=True, max_length=15, blank=True)),
('location', django.contrib.gis.db.models.fields.PointField(null=True, srid=4326, blank=True)),
],
),
]
|
<commit_before># -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
import django.contrib.gis.db.models.fields
class Migration(migrations.Migration):
replaces = [('addressbase', '0001_initial'), ('addressbase', '0002_auto_20160611_1700'), ('addressbase', '0003_auto_20160611_2130'), ('addressbase', '0004_auto_20160611_2304'), ('addressbase', '0005_auto_20160612_0904')]
dependencies = [
]
operations = [
migrations.CreateModel(
name='Address',
fields=[
('uprn', models.CharField(primary_key=True, max_length=100, serialize=False)),
('address', models.TextField(blank=True)),
('postcode', models.CharField(db_index=True, max_length=15, blank=True)),
('location', django.contrib.gis.db.models.fields.PointField(null=True, srid=4326, blank=True)),
],
),
]
<commit_msg>Convert squashed migration to regular migration
This confuses the hell out of me every time<commit_after># -*- coding: utf-8 -*-
from __future__ import unicode_literals
from django.db import models, migrations
import django.contrib.gis.db.models.fields
class Migration(migrations.Migration):
dependencies = [
]
operations = [
migrations.CreateModel(
name='Address',
fields=[
('uprn', models.CharField(primary_key=True, max_length=100, serialize=False)),
('address', models.TextField(blank=True)),
('postcode', models.CharField(db_index=True, max_length=15, blank=True)),
('location', django.contrib.gis.db.models.fields.PointField(null=True, srid=4326, blank=True)),
],
),
]
|
bce11d469177eb4287d9d926b9880e7528bd53c0
|
thumbnails/cache_backends.py
|
thumbnails/cache_backends.py
|
# -*- coding: utf-8 -*-
class BaseCacheBackend(object):
def get(self, thumbnail_name):
if isinstance(thumbnail_name, list):
thumbnail_name = ''.join(thumbnail_name)
return self._get(thumbnail_name)
def set(self, thumbnail):
thumbnail_name = thumbnail.name
if isinstance(thumbnail_name, list):
thumbnail_name = ''.join(thumbnail_name)
return self._set(thumbnail_name, thumbnail)
def _get(self, thumbnail_name):
raise NotImplementedError
def _set(self, thumbnail_name, thumbnail):
raise NotImplementedError
class SimpleCacheBackend(BaseCacheBackend):
thumbnails = {}
def _get(self, thumbnail_name):
if thumbnail_name in self.thumbnails:
return self.thumbnails[thumbnail_name]
def _set(self, thumbnail_name, thumbnail):
self.thumbnails[thumbnail_name] = thumbnail
class DjangoCacheBackend(BaseCacheBackend):
def __init__(self):
from django.core.cache import cache # noqa isort:skip
self.cache = cache
def _get(self, thumbnail_name):
return self.cache.get(thumbnail_name.replace('/', ''))
def _set(self, thumbnail_name, thumbnail):
self.cache.set(thumbnail_name.replace('/', ''), thumbnail)
|
# -*- coding: utf-8 -*-
class BaseCacheBackend(object):
def get(self, thumbnail_name):
if isinstance(thumbnail_name, list):
thumbnail_name = ''.join(thumbnail_name)
return self._get(thumbnail_name)
def set(self, thumbnail):
return self._set(thumbnail.name, thumbnail)
def _get(self, thumbnail_name):
raise NotImplementedError
def _set(self, thumbnail_name, thumbnail):
raise NotImplementedError
class SimpleCacheBackend(BaseCacheBackend):
thumbnails = {}
def _get(self, thumbnail_name):
if thumbnail_name in self.thumbnails:
return self.thumbnails[thumbnail_name]
def _set(self, thumbnail_name, thumbnail):
self.thumbnails[thumbnail_name] = thumbnail
class DjangoCacheBackend(BaseCacheBackend):
def __init__(self):
from django.core.cache import cache # noqa isort:skip
self.cache = cache
def _get(self, thumbnail_name):
return self.cache.get(thumbnail_name.replace('/', ''))
def _set(self, thumbnail_name, thumbnail):
self.cache.set(thumbnail_name.replace('/', ''), thumbnail)
|
Remove unecessary code in cache backend _set
|
Remove unecessary code in cache backend _set
|
Python
|
mit
|
python-thumbnails/python-thumbnails,relekang/python-thumbnails
|
# -*- coding: utf-8 -*-
class BaseCacheBackend(object):
def get(self, thumbnail_name):
if isinstance(thumbnail_name, list):
thumbnail_name = ''.join(thumbnail_name)
return self._get(thumbnail_name)
def set(self, thumbnail):
thumbnail_name = thumbnail.name
if isinstance(thumbnail_name, list):
thumbnail_name = ''.join(thumbnail_name)
return self._set(thumbnail_name, thumbnail)
def _get(self, thumbnail_name):
raise NotImplementedError
def _set(self, thumbnail_name, thumbnail):
raise NotImplementedError
class SimpleCacheBackend(BaseCacheBackend):
thumbnails = {}
def _get(self, thumbnail_name):
if thumbnail_name in self.thumbnails:
return self.thumbnails[thumbnail_name]
def _set(self, thumbnail_name, thumbnail):
self.thumbnails[thumbnail_name] = thumbnail
class DjangoCacheBackend(BaseCacheBackend):
def __init__(self):
from django.core.cache import cache # noqa isort:skip
self.cache = cache
def _get(self, thumbnail_name):
return self.cache.get(thumbnail_name.replace('/', ''))
def _set(self, thumbnail_name, thumbnail):
self.cache.set(thumbnail_name.replace('/', ''), thumbnail)
Remove unecessary code in cache backend _set
|
# -*- coding: utf-8 -*-
class BaseCacheBackend(object):
def get(self, thumbnail_name):
if isinstance(thumbnail_name, list):
thumbnail_name = ''.join(thumbnail_name)
return self._get(thumbnail_name)
def set(self, thumbnail):
return self._set(thumbnail.name, thumbnail)
def _get(self, thumbnail_name):
raise NotImplementedError
def _set(self, thumbnail_name, thumbnail):
raise NotImplementedError
class SimpleCacheBackend(BaseCacheBackend):
thumbnails = {}
def _get(self, thumbnail_name):
if thumbnail_name in self.thumbnails:
return self.thumbnails[thumbnail_name]
def _set(self, thumbnail_name, thumbnail):
self.thumbnails[thumbnail_name] = thumbnail
class DjangoCacheBackend(BaseCacheBackend):
def __init__(self):
from django.core.cache import cache # noqa isort:skip
self.cache = cache
def _get(self, thumbnail_name):
return self.cache.get(thumbnail_name.replace('/', ''))
def _set(self, thumbnail_name, thumbnail):
self.cache.set(thumbnail_name.replace('/', ''), thumbnail)
|
<commit_before># -*- coding: utf-8 -*-
class BaseCacheBackend(object):
def get(self, thumbnail_name):
if isinstance(thumbnail_name, list):
thumbnail_name = ''.join(thumbnail_name)
return self._get(thumbnail_name)
def set(self, thumbnail):
thumbnail_name = thumbnail.name
if isinstance(thumbnail_name, list):
thumbnail_name = ''.join(thumbnail_name)
return self._set(thumbnail_name, thumbnail)
def _get(self, thumbnail_name):
raise NotImplementedError
def _set(self, thumbnail_name, thumbnail):
raise NotImplementedError
class SimpleCacheBackend(BaseCacheBackend):
thumbnails = {}
def _get(self, thumbnail_name):
if thumbnail_name in self.thumbnails:
return self.thumbnails[thumbnail_name]
def _set(self, thumbnail_name, thumbnail):
self.thumbnails[thumbnail_name] = thumbnail
class DjangoCacheBackend(BaseCacheBackend):
def __init__(self):
from django.core.cache import cache # noqa isort:skip
self.cache = cache
def _get(self, thumbnail_name):
return self.cache.get(thumbnail_name.replace('/', ''))
def _set(self, thumbnail_name, thumbnail):
self.cache.set(thumbnail_name.replace('/', ''), thumbnail)
<commit_msg>Remove unecessary code in cache backend _set<commit_after>
|
# -*- coding: utf-8 -*-
class BaseCacheBackend(object):
def get(self, thumbnail_name):
if isinstance(thumbnail_name, list):
thumbnail_name = ''.join(thumbnail_name)
return self._get(thumbnail_name)
def set(self, thumbnail):
return self._set(thumbnail.name, thumbnail)
def _get(self, thumbnail_name):
raise NotImplementedError
def _set(self, thumbnail_name, thumbnail):
raise NotImplementedError
class SimpleCacheBackend(BaseCacheBackend):
thumbnails = {}
def _get(self, thumbnail_name):
if thumbnail_name in self.thumbnails:
return self.thumbnails[thumbnail_name]
def _set(self, thumbnail_name, thumbnail):
self.thumbnails[thumbnail_name] = thumbnail
class DjangoCacheBackend(BaseCacheBackend):
def __init__(self):
from django.core.cache import cache # noqa isort:skip
self.cache = cache
def _get(self, thumbnail_name):
return self.cache.get(thumbnail_name.replace('/', ''))
def _set(self, thumbnail_name, thumbnail):
self.cache.set(thumbnail_name.replace('/', ''), thumbnail)
|
# -*- coding: utf-8 -*-
class BaseCacheBackend(object):
def get(self, thumbnail_name):
if isinstance(thumbnail_name, list):
thumbnail_name = ''.join(thumbnail_name)
return self._get(thumbnail_name)
def set(self, thumbnail):
thumbnail_name = thumbnail.name
if isinstance(thumbnail_name, list):
thumbnail_name = ''.join(thumbnail_name)
return self._set(thumbnail_name, thumbnail)
def _get(self, thumbnail_name):
raise NotImplementedError
def _set(self, thumbnail_name, thumbnail):
raise NotImplementedError
class SimpleCacheBackend(BaseCacheBackend):
thumbnails = {}
def _get(self, thumbnail_name):
if thumbnail_name in self.thumbnails:
return self.thumbnails[thumbnail_name]
def _set(self, thumbnail_name, thumbnail):
self.thumbnails[thumbnail_name] = thumbnail
class DjangoCacheBackend(BaseCacheBackend):
def __init__(self):
from django.core.cache import cache # noqa isort:skip
self.cache = cache
def _get(self, thumbnail_name):
return self.cache.get(thumbnail_name.replace('/', ''))
def _set(self, thumbnail_name, thumbnail):
self.cache.set(thumbnail_name.replace('/', ''), thumbnail)
Remove unecessary code in cache backend _set# -*- coding: utf-8 -*-
class BaseCacheBackend(object):
def get(self, thumbnail_name):
if isinstance(thumbnail_name, list):
thumbnail_name = ''.join(thumbnail_name)
return self._get(thumbnail_name)
def set(self, thumbnail):
return self._set(thumbnail.name, thumbnail)
def _get(self, thumbnail_name):
raise NotImplementedError
def _set(self, thumbnail_name, thumbnail):
raise NotImplementedError
class SimpleCacheBackend(BaseCacheBackend):
thumbnails = {}
def _get(self, thumbnail_name):
if thumbnail_name in self.thumbnails:
return self.thumbnails[thumbnail_name]
def _set(self, thumbnail_name, thumbnail):
self.thumbnails[thumbnail_name] = thumbnail
class DjangoCacheBackend(BaseCacheBackend):
def __init__(self):
from django.core.cache import cache # noqa isort:skip
self.cache = cache
def _get(self, thumbnail_name):
return self.cache.get(thumbnail_name.replace('/', ''))
def _set(self, thumbnail_name, thumbnail):
self.cache.set(thumbnail_name.replace('/', ''), thumbnail)
|
<commit_before># -*- coding: utf-8 -*-
class BaseCacheBackend(object):
def get(self, thumbnail_name):
if isinstance(thumbnail_name, list):
thumbnail_name = ''.join(thumbnail_name)
return self._get(thumbnail_name)
def set(self, thumbnail):
thumbnail_name = thumbnail.name
if isinstance(thumbnail_name, list):
thumbnail_name = ''.join(thumbnail_name)
return self._set(thumbnail_name, thumbnail)
def _get(self, thumbnail_name):
raise NotImplementedError
def _set(self, thumbnail_name, thumbnail):
raise NotImplementedError
class SimpleCacheBackend(BaseCacheBackend):
thumbnails = {}
def _get(self, thumbnail_name):
if thumbnail_name in self.thumbnails:
return self.thumbnails[thumbnail_name]
def _set(self, thumbnail_name, thumbnail):
self.thumbnails[thumbnail_name] = thumbnail
class DjangoCacheBackend(BaseCacheBackend):
def __init__(self):
from django.core.cache import cache # noqa isort:skip
self.cache = cache
def _get(self, thumbnail_name):
return self.cache.get(thumbnail_name.replace('/', ''))
def _set(self, thumbnail_name, thumbnail):
self.cache.set(thumbnail_name.replace('/', ''), thumbnail)
<commit_msg>Remove unecessary code in cache backend _set<commit_after># -*- coding: utf-8 -*-
class BaseCacheBackend(object):
def get(self, thumbnail_name):
if isinstance(thumbnail_name, list):
thumbnail_name = ''.join(thumbnail_name)
return self._get(thumbnail_name)
def set(self, thumbnail):
return self._set(thumbnail.name, thumbnail)
def _get(self, thumbnail_name):
raise NotImplementedError
def _set(self, thumbnail_name, thumbnail):
raise NotImplementedError
class SimpleCacheBackend(BaseCacheBackend):
thumbnails = {}
def _get(self, thumbnail_name):
if thumbnail_name in self.thumbnails:
return self.thumbnails[thumbnail_name]
def _set(self, thumbnail_name, thumbnail):
self.thumbnails[thumbnail_name] = thumbnail
class DjangoCacheBackend(BaseCacheBackend):
def __init__(self):
from django.core.cache import cache # noqa isort:skip
self.cache = cache
def _get(self, thumbnail_name):
return self.cache.get(thumbnail_name.replace('/', ''))
def _set(self, thumbnail_name, thumbnail):
self.cache.set(thumbnail_name.replace('/', ''), thumbnail)
|
1f4d8b5f5f35b189aab5ff9e10d3ac2386124443
|
behave/contrib/substep_dirs.py
|
behave/contrib/substep_dirs.py
|
# -*- coding: UTF-8 -*-
"""
Recipe for loading additional step definitions from sub-directories
in the "features/steps" directory.
.. code-block::
# -- FILE: features/steps/use_substep_dirs.py
# REQUIRES: path.py
from behave.runner_util import load_step_modules
from path import Path
HERE = Path(__file__).dirname
SUBSTEP_DIRS = list(HERE.walkdirs())
load_step_modules(SUBSTEP_DIRS)
"""
|
# -*- coding: UTF-8 -*-
"""
Recipe for loading additional step definitions from sub-directories
in the "features/steps" directory.
.. code-block::
# -- FILE: features/steps/use_substep_dirs.py
# REQUIRES: path.py
from behave.runner_util import load_step_modules
from path import Path
HERE = Path(__file__).dirname()
SUBSTEP_DIRS = list(HERE.walkdirs())
load_step_modules(SUBSTEP_DIRS)
"""
|
FIX TYPO: Uncovered by NaveenKVN
|
FIX TYPO: Uncovered by NaveenKVN
|
Python
|
bsd-2-clause
|
jenisys/behave,jenisys/behave
|
# -*- coding: UTF-8 -*-
"""
Recipe for loading additional step definitions from sub-directories
in the "features/steps" directory.
.. code-block::
# -- FILE: features/steps/use_substep_dirs.py
# REQUIRES: path.py
from behave.runner_util import load_step_modules
from path import Path
HERE = Path(__file__).dirname
SUBSTEP_DIRS = list(HERE.walkdirs())
load_step_modules(SUBSTEP_DIRS)
"""
FIX TYPO: Uncovered by NaveenKVN
|
# -*- coding: UTF-8 -*-
"""
Recipe for loading additional step definitions from sub-directories
in the "features/steps" directory.
.. code-block::
# -- FILE: features/steps/use_substep_dirs.py
# REQUIRES: path.py
from behave.runner_util import load_step_modules
from path import Path
HERE = Path(__file__).dirname()
SUBSTEP_DIRS = list(HERE.walkdirs())
load_step_modules(SUBSTEP_DIRS)
"""
|
<commit_before># -*- coding: UTF-8 -*-
"""
Recipe for loading additional step definitions from sub-directories
in the "features/steps" directory.
.. code-block::
# -- FILE: features/steps/use_substep_dirs.py
# REQUIRES: path.py
from behave.runner_util import load_step_modules
from path import Path
HERE = Path(__file__).dirname
SUBSTEP_DIRS = list(HERE.walkdirs())
load_step_modules(SUBSTEP_DIRS)
"""
<commit_msg>FIX TYPO: Uncovered by NaveenKVN<commit_after>
|
# -*- coding: UTF-8 -*-
"""
Recipe for loading additional step definitions from sub-directories
in the "features/steps" directory.
.. code-block::
# -- FILE: features/steps/use_substep_dirs.py
# REQUIRES: path.py
from behave.runner_util import load_step_modules
from path import Path
HERE = Path(__file__).dirname()
SUBSTEP_DIRS = list(HERE.walkdirs())
load_step_modules(SUBSTEP_DIRS)
"""
|
# -*- coding: UTF-8 -*-
"""
Recipe for loading additional step definitions from sub-directories
in the "features/steps" directory.
.. code-block::
# -- FILE: features/steps/use_substep_dirs.py
# REQUIRES: path.py
from behave.runner_util import load_step_modules
from path import Path
HERE = Path(__file__).dirname
SUBSTEP_DIRS = list(HERE.walkdirs())
load_step_modules(SUBSTEP_DIRS)
"""
FIX TYPO: Uncovered by NaveenKVN# -*- coding: UTF-8 -*-
"""
Recipe for loading additional step definitions from sub-directories
in the "features/steps" directory.
.. code-block::
# -- FILE: features/steps/use_substep_dirs.py
# REQUIRES: path.py
from behave.runner_util import load_step_modules
from path import Path
HERE = Path(__file__).dirname()
SUBSTEP_DIRS = list(HERE.walkdirs())
load_step_modules(SUBSTEP_DIRS)
"""
|
<commit_before># -*- coding: UTF-8 -*-
"""
Recipe for loading additional step definitions from sub-directories
in the "features/steps" directory.
.. code-block::
# -- FILE: features/steps/use_substep_dirs.py
# REQUIRES: path.py
from behave.runner_util import load_step_modules
from path import Path
HERE = Path(__file__).dirname
SUBSTEP_DIRS = list(HERE.walkdirs())
load_step_modules(SUBSTEP_DIRS)
"""
<commit_msg>FIX TYPO: Uncovered by NaveenKVN<commit_after># -*- coding: UTF-8 -*-
"""
Recipe for loading additional step definitions from sub-directories
in the "features/steps" directory.
.. code-block::
# -- FILE: features/steps/use_substep_dirs.py
# REQUIRES: path.py
from behave.runner_util import load_step_modules
from path import Path
HERE = Path(__file__).dirname()
SUBSTEP_DIRS = list(HERE.walkdirs())
load_step_modules(SUBSTEP_DIRS)
"""
|
b8e9a572098a5eaccf5aadde1b46bfc51da2face
|
tests/test_check_step_UDFs.py
|
tests/test_check_step_UDFs.py
|
from scripts.check_step_UDFs import CheckStepUDFs
from tests.test_common import TestEPP
from unittest.mock import Mock, patch, PropertyMock
class TestCheckStepUDFs(TestEPP):
def setUp(self):
self.patched_process = patch.object(
CheckStepUDFs,
'process',
new_callable=PropertyMock(return_value=Mock(udf={
'udfname1': 'a',
'udfname2': 'a'
}))
)
self.epp = CheckStepUDFs(
'http://server:8080/a_step_uri',
'a_user',
'a_password',
['udfname1', 'udfname2'],
self.log_file
)
def test_check_step_UDFs(self):
with self.patched_process:
self.epp._run()
|
from scripts.check_step_UDFs import CheckStepUDFs
from tests.test_common import TestEPP
from unittest.mock import Mock, patch, PropertyMock
class TestCheckStepUDFs(TestEPP):
def setUp(self):
self.patched_process = patch.object(
CheckStepUDFs,
'process',
new_callable=PropertyMock(return_value=Mock(udf={
'udfname1': 'a',
'udfname2': 'a'
}))
)
self.epp = CheckStepUDFs(
'http://server:8080/a_step_uri',
'a_user',
'a_password',
['udfname1', 'udfname2'],
self.log_file
)
self.epp2 = CheckStepUDFs(
'http://server:8080/a_step_uri',
'a_user',
'a_password',
['udfname1', 'udfname2', 'udfname3'],
self.log_file
)
def test_check_step_UDFs(self):
with self.patched_process:
# Both UDFs are present so run does not execute sys.exit
assert self.epp._run() is None
def test_check_step_UDFs(self):
with self.patched_process, patch('scripts.check_step_UDFs.exit') as mexit:
# One UDF is missing so run will execute sys.exit
self.epp2._run()
mexit.assert_called_once_with(1)
|
Add test to check sys.exit was called with the expected exit status
|
Add test to check sys.exit was called with the expected exit status
|
Python
|
mit
|
EdinburghGenomics/clarity_scripts,EdinburghGenomics/clarity_scripts
|
from scripts.check_step_UDFs import CheckStepUDFs
from tests.test_common import TestEPP
from unittest.mock import Mock, patch, PropertyMock
class TestCheckStepUDFs(TestEPP):
def setUp(self):
self.patched_process = patch.object(
CheckStepUDFs,
'process',
new_callable=PropertyMock(return_value=Mock(udf={
'udfname1': 'a',
'udfname2': 'a'
}))
)
self.epp = CheckStepUDFs(
'http://server:8080/a_step_uri',
'a_user',
'a_password',
['udfname1', 'udfname2'],
self.log_file
)
def test_check_step_UDFs(self):
with self.patched_process:
self.epp._run()
Add test to check sys.exit was called with the expected exit status
|
from scripts.check_step_UDFs import CheckStepUDFs
from tests.test_common import TestEPP
from unittest.mock import Mock, patch, PropertyMock
class TestCheckStepUDFs(TestEPP):
def setUp(self):
self.patched_process = patch.object(
CheckStepUDFs,
'process',
new_callable=PropertyMock(return_value=Mock(udf={
'udfname1': 'a',
'udfname2': 'a'
}))
)
self.epp = CheckStepUDFs(
'http://server:8080/a_step_uri',
'a_user',
'a_password',
['udfname1', 'udfname2'],
self.log_file
)
self.epp2 = CheckStepUDFs(
'http://server:8080/a_step_uri',
'a_user',
'a_password',
['udfname1', 'udfname2', 'udfname3'],
self.log_file
)
def test_check_step_UDFs(self):
with self.patched_process:
# Both UDFs are present so run does not execute sys.exit
assert self.epp._run() is None
def test_check_step_UDFs(self):
with self.patched_process, patch('scripts.check_step_UDFs.exit') as mexit:
# One UDF is missing so run will execute sys.exit
self.epp2._run()
mexit.assert_called_once_with(1)
|
<commit_before>from scripts.check_step_UDFs import CheckStepUDFs
from tests.test_common import TestEPP
from unittest.mock import Mock, patch, PropertyMock
class TestCheckStepUDFs(TestEPP):
def setUp(self):
self.patched_process = patch.object(
CheckStepUDFs,
'process',
new_callable=PropertyMock(return_value=Mock(udf={
'udfname1': 'a',
'udfname2': 'a'
}))
)
self.epp = CheckStepUDFs(
'http://server:8080/a_step_uri',
'a_user',
'a_password',
['udfname1', 'udfname2'],
self.log_file
)
def test_check_step_UDFs(self):
with self.patched_process:
self.epp._run()
<commit_msg>Add test to check sys.exit was called with the expected exit status<commit_after>
|
from scripts.check_step_UDFs import CheckStepUDFs
from tests.test_common import TestEPP
from unittest.mock import Mock, patch, PropertyMock
class TestCheckStepUDFs(TestEPP):
def setUp(self):
self.patched_process = patch.object(
CheckStepUDFs,
'process',
new_callable=PropertyMock(return_value=Mock(udf={
'udfname1': 'a',
'udfname2': 'a'
}))
)
self.epp = CheckStepUDFs(
'http://server:8080/a_step_uri',
'a_user',
'a_password',
['udfname1', 'udfname2'],
self.log_file
)
self.epp2 = CheckStepUDFs(
'http://server:8080/a_step_uri',
'a_user',
'a_password',
['udfname1', 'udfname2', 'udfname3'],
self.log_file
)
def test_check_step_UDFs(self):
with self.patched_process:
# Both UDFs are present so run does not execute sys.exit
assert self.epp._run() is None
def test_check_step_UDFs(self):
with self.patched_process, patch('scripts.check_step_UDFs.exit') as mexit:
# One UDF is missing so run will execute sys.exit
self.epp2._run()
mexit.assert_called_once_with(1)
|
from scripts.check_step_UDFs import CheckStepUDFs
from tests.test_common import TestEPP
from unittest.mock import Mock, patch, PropertyMock
class TestCheckStepUDFs(TestEPP):
def setUp(self):
self.patched_process = patch.object(
CheckStepUDFs,
'process',
new_callable=PropertyMock(return_value=Mock(udf={
'udfname1': 'a',
'udfname2': 'a'
}))
)
self.epp = CheckStepUDFs(
'http://server:8080/a_step_uri',
'a_user',
'a_password',
['udfname1', 'udfname2'],
self.log_file
)
def test_check_step_UDFs(self):
with self.patched_process:
self.epp._run()
Add test to check sys.exit was called with the expected exit statusfrom scripts.check_step_UDFs import CheckStepUDFs
from tests.test_common import TestEPP
from unittest.mock import Mock, patch, PropertyMock
class TestCheckStepUDFs(TestEPP):
def setUp(self):
self.patched_process = patch.object(
CheckStepUDFs,
'process',
new_callable=PropertyMock(return_value=Mock(udf={
'udfname1': 'a',
'udfname2': 'a'
}))
)
self.epp = CheckStepUDFs(
'http://server:8080/a_step_uri',
'a_user',
'a_password',
['udfname1', 'udfname2'],
self.log_file
)
self.epp2 = CheckStepUDFs(
'http://server:8080/a_step_uri',
'a_user',
'a_password',
['udfname1', 'udfname2', 'udfname3'],
self.log_file
)
def test_check_step_UDFs(self):
with self.patched_process:
# Both UDFs are present so run does not execute sys.exit
assert self.epp._run() is None
def test_check_step_UDFs(self):
with self.patched_process, patch('scripts.check_step_UDFs.exit') as mexit:
# One UDF is missing so run will execute sys.exit
self.epp2._run()
mexit.assert_called_once_with(1)
|
<commit_before>from scripts.check_step_UDFs import CheckStepUDFs
from tests.test_common import TestEPP
from unittest.mock import Mock, patch, PropertyMock
class TestCheckStepUDFs(TestEPP):
def setUp(self):
self.patched_process = patch.object(
CheckStepUDFs,
'process',
new_callable=PropertyMock(return_value=Mock(udf={
'udfname1': 'a',
'udfname2': 'a'
}))
)
self.epp = CheckStepUDFs(
'http://server:8080/a_step_uri',
'a_user',
'a_password',
['udfname1', 'udfname2'],
self.log_file
)
def test_check_step_UDFs(self):
with self.patched_process:
self.epp._run()
<commit_msg>Add test to check sys.exit was called with the expected exit status<commit_after>from scripts.check_step_UDFs import CheckStepUDFs
from tests.test_common import TestEPP
from unittest.mock import Mock, patch, PropertyMock
class TestCheckStepUDFs(TestEPP):
def setUp(self):
self.patched_process = patch.object(
CheckStepUDFs,
'process',
new_callable=PropertyMock(return_value=Mock(udf={
'udfname1': 'a',
'udfname2': 'a'
}))
)
self.epp = CheckStepUDFs(
'http://server:8080/a_step_uri',
'a_user',
'a_password',
['udfname1', 'udfname2'],
self.log_file
)
self.epp2 = CheckStepUDFs(
'http://server:8080/a_step_uri',
'a_user',
'a_password',
['udfname1', 'udfname2', 'udfname3'],
self.log_file
)
def test_check_step_UDFs(self):
with self.patched_process:
# Both UDFs are present so run does not execute sys.exit
assert self.epp._run() is None
def test_check_step_UDFs(self):
with self.patched_process, patch('scripts.check_step_UDFs.exit') as mexit:
# One UDF is missing so run will execute sys.exit
self.epp2._run()
mexit.assert_called_once_with(1)
|
43fc2f23b80083f89ae1e982bfdee5d4e0322556
|
tests/test_command_version.py
|
tests/test_command_version.py
|
import sys
from twisted.trial import unittest
from twisted.internet import defer
import scrapy
from scrapy.utils.testproc import ProcessTest
class VersionTest(ProcessTest, unittest.TestCase):
command = 'version'
@defer.inlineCallbacks
def test_output(self):
encoding = getattr(sys.stdout, 'encoding') or 'utf-8'
_, out, _ = yield self.execute([])
self.assertEqual(out.strip().decode(encoding), "Scrapy %s" % scrapy.__version__)
|
import sys
from twisted.trial import unittest
from twisted.internet import defer
import scrapy
from scrapy.utils.testproc import ProcessTest
class VersionTest(ProcessTest, unittest.TestCase):
command = 'version'
@defer.inlineCallbacks
def test_output(self):
encoding = getattr(sys.stdout, 'encoding') or 'utf-8'
_, out, _ = yield self.execute([])
self.assertEqual(
out.strip().decode(encoding),
"Scrapy %s" % scrapy.__version__,
)
@defer.inlineCallbacks
def test_verbose_output(self):
encoding = getattr(sys.stdout, 'encoding') or 'utf-8'
_, out, _ = yield self.execute(['-v'])
headers = [l.partition(":")[0].strip()
for l in out.strip().decode(encoding).splitlines()]
self.assertEqual(headers, ['Scrapy', 'lxml', 'libxml2', 'Twisted',
'Python', 'pyOpenSSL', 'Platform'])
|
Increase coverage of version command
|
Increase coverage of version command
|
Python
|
bsd-3-clause
|
tagatac/scrapy,nowopen/scrapy,hwsyy/scrapy,Lucifer-Kim/scrapy,mlyundin/scrapy,elacuesta/scrapy,KublaikhanGeek/scrapy,Ryezhang/scrapy,github-account-because-they-want-it/scrapy,ENjOyAbLE1991/scrapy,yidongliu/scrapy,famorted/scrapy,avtoritet/scrapy,Preetwinder/scrapy,eLRuLL/scrapy,foromer4/scrapy,godfreyy/scrapy,KublaikhanGeek/scrapy,olafdietsche/scrapy,Adai0808/scrapy-1,zjuwangg/scrapy,YeelerG/scrapy,songfj/scrapy,mgedmin/scrapy,rootAvish/scrapy,arush0311/scrapy,cyrixhero/scrapy,cursesun/scrapy,zhangtao11/scrapy,kazitanvirahsan/scrapy,tliber/scrapy,taito/scrapy,haiiiiiyun/scrapy,irwinlove/scrapy,jeffreyjinfeng/scrapy,eliasdorneles/scrapy,zorojean/scrapy,nfunato/scrapy,dgillis/scrapy,yarikoptic/scrapy,Allianzcortex/scrapy,nowopen/scrapy,kashyap32/scrapy,cyberplant/scrapy,kazitanvirahsan/scrapy,pablohoffman/scrapy,shaform/scrapy,rolando-contrib/scrapy,JacobStevenR/scrapy,Parlin-Galanodel/scrapy,godfreyy/scrapy,yarikoptic/scrapy,zjuwangg/scrapy,cyrixhero/scrapy,eLRuLL/scrapy,fafaman/scrapy,ArturGaspar/scrapy,agreen/scrapy,pablohoffman/scrapy,jeffreyjinfeng/scrapy,Parlin-Galanodel/scrapy,fontenele/scrapy,darkrho/scrapy-scrapy,yidongliu/scrapy,pombredanne/scrapy,yarikoptic/scrapy,Allianzcortex/scrapy,cursesun/scrapy,kmike/scrapy,livepy/scrapy,cleydson/scrapy,rolando-contrib/scrapy,github-account-because-they-want-it/scrapy,dangra/scrapy,darkrho/scrapy-scrapy,zackslash/scrapy,JacobStevenR/scrapy,kimimj/scrapy,bmess/scrapy,w495/scrapy,redapple/scrapy,moraesnicol/scrapy,crasker/scrapy,eliasdorneles/scrapy,rolando/scrapy,farhan0581/scrapy,hectoruelo/scrapy,Cnfc19932/scrapy,z-fork/scrapy,hyrole/scrapy,hwsyy/scrapy,tagatac/scrapy,Bourneer/scrapy,jdemaeyer/scrapy,taito/scrapy,pombredanne/scrapy,scrapy/scrapy,starrify/scrapy,famorted/scrapy,Cnfc19932/scrapy,nikgr95/scrapy,tliber/scrapy,arush0311/scrapy,xiao26/scrapy,dgillis/scrapy,aivarsk/scrapy,nfunato/scrapy,Parlin-Galanodel/scrapy,tliber/scrapy,zjuwangg/scrapy,dangra/scrapy,wangjun/scrapy,Ryezhang/scrapy,agreen/scrapy,1yvT0s/scrapy,dracony/scrapy,kimimj/scrapy,johnardavies/scrapy,hyrole/scrapy,cursesun/scrapy,nikgr95/scrapy,kimimj/scrapy,ylcolala/scrapy,csalazar/scrapy,wujuguang/scrapy,hectoruelo/scrapy,foromer4/scrapy,wenyu1001/scrapy,carlosp420/scrapy,jc0n/scrapy,bmess/scrapy,Preetwinder/scrapy,crasker/scrapy,cyberplant/scrapy,stenskjaer/scrapy,ENjOyAbLE1991/scrapy,jiezhu2007/scrapy,carlosp420/scrapy,Lucifer-Kim/scrapy,johnardavies/scrapy,zorojean/scrapy,eLRuLL/scrapy,umrashrf/scrapy,z-fork/scrapy,hectoruelo/scrapy,zhangtao11/scrapy,rklabs/scrapy,nfunato/scrapy,agreen/scrapy,irwinlove/scrapy,umrashrf/scrapy,1yvT0s/scrapy,legendtkl/scrapy,mgedmin/scrapy,kazitanvirahsan/scrapy,nowopen/scrapy,jc0n/scrapy,Chenmxs/scrapy,Zephor5/scrapy,godfreyy/scrapy,elacuesta/scrapy,w495/scrapy,hansenDise/scrapy,fpy171/scrapy,olafdietsche/scrapy,GregoryVigoTorres/scrapy,finfish/scrapy,Adai0808/scrapy-1,Timeship/scrapy,raphaelfruneaux/scrapy,Allianzcortex/scrapy,rahulsharma1991/scrapy,fafaman/scrapy,ENjOyAbLE1991/scrapy,wzyuliyang/scrapy,johnardavies/scrapy,haiiiiiyun/scrapy,wzyuliyang/scrapy,Bourneer/scrapy,huoxudong125/scrapy,GregoryVigoTorres/scrapy,legendtkl/scrapy,KublaikhanGeek/scrapy,darkrho/scrapy-scrapy,eliasdorneles/scrapy,wenyu1001/scrapy,redapple/scrapy,legendtkl/scrapy,Adai0808/scrapy-1,kmike/scrapy,Lucifer-Kim/scrapy,barraponto/scrapy,fontenele/scrapy,wzyuliyang/scrapy,zhangtao11/scrapy,redapple/scrapy,umrashrf/scrapy,Preetwinder/scrapy,fpy171/scrapy,csalazar/scrapy,scrapy/scrapy,moraesnicol/scrapy,Zephor5/scrapy,xiao26/scrapy,JacobStevenR/scrapy,lacrazyboy/scrapy,foromer4/scrapy,zackslash/scrapy,wujuguang/scrapy,jiezhu2007/scrapy,xiao26/scrapy,zackslash/scrapy,dangra/scrapy,nikgr95/scrapy,irwinlove/scrapy,cleydson/scrapy,pawelmhm/scrapy,ylcolala/scrapy,rolando/scrapy,z-fork/scrapy,Digenis/scrapy,livepy/scrapy,zorojean/scrapy,avtoritet/scrapy,dracony/scrapy,Bourneer/scrapy,pablohoffman/scrapy,raphaelfruneaux/scrapy,ssteo/scrapy,pombredanne/scrapy,dacjames/scrapy,rklabs/scrapy,jdemaeyer/scrapy,barraponto/scrapy,ssh-odoo/scrapy,cyrixhero/scrapy,dacjames/scrapy,pranjalpatil/scrapy,wangjun/scrapy,huoxudong125/scrapy,Chenmxs/scrapy,hwsyy/scrapy,farhan0581/scrapy,Chenmxs/scrapy,huoxudong125/scrapy,TarasRudnyk/scrapy,fontenele/scrapy,jiezhu2007/scrapy,hyrole/scrapy,pawelmhm/scrapy,ssh-odoo/scrapy,jdemaeyer/scrapy,moraesnicol/scrapy,rahulsharma1991/scrapy,GregoryVigoTorres/scrapy,aivarsk/scrapy,wangjun/scrapy,finfish/scrapy,elacuesta/scrapy,Digenis/scrapy,cleydson/scrapy,mlyundin/scrapy,rahulsharma1991/scrapy,kashyap32/scrapy,YeelerG/scrapy,cyberplant/scrapy,tagatac/scrapy,jc0n/scrapy,rolando/scrapy,Digenis/scrapy,ylcolala/scrapy,Ryezhang/scrapy,stenskjaer/scrapy,mgedmin/scrapy,lacrazyboy/scrapy,dacjames/scrapy,Cnfc19932/scrapy,kmike/scrapy,raphaelfruneaux/scrapy,finfish/scrapy,fafaman/scrapy,scrapy/scrapy,livepy/scrapy,rootAvish/scrapy,shaform/scrapy,yidongliu/scrapy,starrify/scrapy,stenskjaer/scrapy,hansenDise/scrapy,ArturGaspar/scrapy,crasker/scrapy,aivarsk/scrapy,wenyu1001/scrapy,TarasRudnyk/scrapy,w495/scrapy,csalazar/scrapy,Timeship/scrapy,TarasRudnyk/scrapy,songfj/scrapy,farhan0581/scrapy,kashyap32/scrapy,hansenDise/scrapy,starrify/scrapy,Timeship/scrapy,Zephor5/scrapy,1yvT0s/scrapy,lacrazyboy/scrapy,dgillis/scrapy,ssteo/scrapy,taito/scrapy,rklabs/scrapy,olafdietsche/scrapy,ssh-odoo/scrapy,github-account-because-they-want-it/scrapy,rolando-contrib/scrapy,famorted/scrapy,avtoritet/scrapy,wujuguang/scrapy,arush0311/scrapy,rootAvish/scrapy,ArturGaspar/scrapy,ssteo/scrapy,barraponto/scrapy,haiiiiiyun/scrapy,fpy171/scrapy,pranjalpatil/scrapy,bmess/scrapy,pawelmhm/scrapy,carlosp420/scrapy,YeelerG/scrapy,shaform/scrapy,pranjalpatil/scrapy,dracony/scrapy,mlyundin/scrapy,songfj/scrapy,jeffreyjinfeng/scrapy
|
import sys
from twisted.trial import unittest
from twisted.internet import defer
import scrapy
from scrapy.utils.testproc import ProcessTest
class VersionTest(ProcessTest, unittest.TestCase):
command = 'version'
@defer.inlineCallbacks
def test_output(self):
encoding = getattr(sys.stdout, 'encoding') or 'utf-8'
_, out, _ = yield self.execute([])
self.assertEqual(out.strip().decode(encoding), "Scrapy %s" % scrapy.__version__)
Increase coverage of version command
|
import sys
from twisted.trial import unittest
from twisted.internet import defer
import scrapy
from scrapy.utils.testproc import ProcessTest
class VersionTest(ProcessTest, unittest.TestCase):
command = 'version'
@defer.inlineCallbacks
def test_output(self):
encoding = getattr(sys.stdout, 'encoding') or 'utf-8'
_, out, _ = yield self.execute([])
self.assertEqual(
out.strip().decode(encoding),
"Scrapy %s" % scrapy.__version__,
)
@defer.inlineCallbacks
def test_verbose_output(self):
encoding = getattr(sys.stdout, 'encoding') or 'utf-8'
_, out, _ = yield self.execute(['-v'])
headers = [l.partition(":")[0].strip()
for l in out.strip().decode(encoding).splitlines()]
self.assertEqual(headers, ['Scrapy', 'lxml', 'libxml2', 'Twisted',
'Python', 'pyOpenSSL', 'Platform'])
|
<commit_before>import sys
from twisted.trial import unittest
from twisted.internet import defer
import scrapy
from scrapy.utils.testproc import ProcessTest
class VersionTest(ProcessTest, unittest.TestCase):
command = 'version'
@defer.inlineCallbacks
def test_output(self):
encoding = getattr(sys.stdout, 'encoding') or 'utf-8'
_, out, _ = yield self.execute([])
self.assertEqual(out.strip().decode(encoding), "Scrapy %s" % scrapy.__version__)
<commit_msg>Increase coverage of version command<commit_after>
|
import sys
from twisted.trial import unittest
from twisted.internet import defer
import scrapy
from scrapy.utils.testproc import ProcessTest
class VersionTest(ProcessTest, unittest.TestCase):
command = 'version'
@defer.inlineCallbacks
def test_output(self):
encoding = getattr(sys.stdout, 'encoding') or 'utf-8'
_, out, _ = yield self.execute([])
self.assertEqual(
out.strip().decode(encoding),
"Scrapy %s" % scrapy.__version__,
)
@defer.inlineCallbacks
def test_verbose_output(self):
encoding = getattr(sys.stdout, 'encoding') or 'utf-8'
_, out, _ = yield self.execute(['-v'])
headers = [l.partition(":")[0].strip()
for l in out.strip().decode(encoding).splitlines()]
self.assertEqual(headers, ['Scrapy', 'lxml', 'libxml2', 'Twisted',
'Python', 'pyOpenSSL', 'Platform'])
|
import sys
from twisted.trial import unittest
from twisted.internet import defer
import scrapy
from scrapy.utils.testproc import ProcessTest
class VersionTest(ProcessTest, unittest.TestCase):
command = 'version'
@defer.inlineCallbacks
def test_output(self):
encoding = getattr(sys.stdout, 'encoding') or 'utf-8'
_, out, _ = yield self.execute([])
self.assertEqual(out.strip().decode(encoding), "Scrapy %s" % scrapy.__version__)
Increase coverage of version commandimport sys
from twisted.trial import unittest
from twisted.internet import defer
import scrapy
from scrapy.utils.testproc import ProcessTest
class VersionTest(ProcessTest, unittest.TestCase):
command = 'version'
@defer.inlineCallbacks
def test_output(self):
encoding = getattr(sys.stdout, 'encoding') or 'utf-8'
_, out, _ = yield self.execute([])
self.assertEqual(
out.strip().decode(encoding),
"Scrapy %s" % scrapy.__version__,
)
@defer.inlineCallbacks
def test_verbose_output(self):
encoding = getattr(sys.stdout, 'encoding') or 'utf-8'
_, out, _ = yield self.execute(['-v'])
headers = [l.partition(":")[0].strip()
for l in out.strip().decode(encoding).splitlines()]
self.assertEqual(headers, ['Scrapy', 'lxml', 'libxml2', 'Twisted',
'Python', 'pyOpenSSL', 'Platform'])
|
<commit_before>import sys
from twisted.trial import unittest
from twisted.internet import defer
import scrapy
from scrapy.utils.testproc import ProcessTest
class VersionTest(ProcessTest, unittest.TestCase):
command = 'version'
@defer.inlineCallbacks
def test_output(self):
encoding = getattr(sys.stdout, 'encoding') or 'utf-8'
_, out, _ = yield self.execute([])
self.assertEqual(out.strip().decode(encoding), "Scrapy %s" % scrapy.__version__)
<commit_msg>Increase coverage of version command<commit_after>import sys
from twisted.trial import unittest
from twisted.internet import defer
import scrapy
from scrapy.utils.testproc import ProcessTest
class VersionTest(ProcessTest, unittest.TestCase):
command = 'version'
@defer.inlineCallbacks
def test_output(self):
encoding = getattr(sys.stdout, 'encoding') or 'utf-8'
_, out, _ = yield self.execute([])
self.assertEqual(
out.strip().decode(encoding),
"Scrapy %s" % scrapy.__version__,
)
@defer.inlineCallbacks
def test_verbose_output(self):
encoding = getattr(sys.stdout, 'encoding') or 'utf-8'
_, out, _ = yield self.execute(['-v'])
headers = [l.partition(":")[0].strip()
for l in out.strip().decode(encoding).splitlines()]
self.assertEqual(headers, ['Scrapy', 'lxml', 'libxml2', 'Twisted',
'Python', 'pyOpenSSL', 'Platform'])
|
3a3cb923babfbba4234e646dc40c0a9b6364d207
|
apps/announcements/management/commands/tweetannouncements.py
|
apps/announcements/management/commands/tweetannouncements.py
|
"""
Management command to cross-publish announcements on Twitter.
"""
from django.core.management.base import NoArgsCommand
from ...models import AnnouncementTwitterCrossPublication
class Command(NoArgsCommand):
"""
A management command which cross-publish on Twitter any pending announcements
currently published on the site but not on Twitter yet. Simply call the ``publish_pending_announcements``of
the ``AnnouncementTwitterCrossPublication`` class to do the job.
"""
help = "Cross-publish pending announcements on Twitter"
def handle_noargs(self, **options):
"""
Command handler.
:param options: Not used.
:return: None.
"""
AnnouncementTwitterCrossPublication.objects.publish_pending_announcements()
|
"""
Management command to cross-publish announcements on Twitter.
"""
from django.core.management.base import NoArgsCommand
from apps.dbmutex import MutexLock,AlreadyLockedError, LockTimeoutError
from ...models import AnnouncementTwitterCrossPublication
class Command(NoArgsCommand):
"""
A management command which cross-publish on Twitter any pending announcements
currently published on the site but not on Twitter yet. Simply call the ``publish_pending_announcements``of
the ``AnnouncementTwitterCrossPublication`` class to do the job. Use the ``dbmutex`` app to avoid concurrent
execution of the code.
"""
help = "Cross-publish pending announcements on Twitter"
def handle_noargs(self, **options):
"""
Command handler.
:param options: Not used.
:return: None.
"""
# Lock a critical section of code
try:
with MutexLock('twitter_announcements'):
# Do the job
AnnouncementTwitterCrossPublication.objects.publish_pending_announcements()
except AlreadyLockedError:
print('Could not obtain lock (another instance of the script running?)')
except LockTimeoutError:
print('Task completed but the lock timed out')
|
Add mutex to the "tweetannouncement" management command.
|
Add mutex to the "tweetannouncement" management command.
|
Python
|
agpl-3.0
|
TamiaLab/carnetdumaker,TamiaLab/carnetdumaker,TamiaLab/carnetdumaker,TamiaLab/carnetdumaker
|
"""
Management command to cross-publish announcements on Twitter.
"""
from django.core.management.base import NoArgsCommand
from ...models import AnnouncementTwitterCrossPublication
class Command(NoArgsCommand):
"""
A management command which cross-publish on Twitter any pending announcements
currently published on the site but not on Twitter yet. Simply call the ``publish_pending_announcements``of
the ``AnnouncementTwitterCrossPublication`` class to do the job.
"""
help = "Cross-publish pending announcements on Twitter"
def handle_noargs(self, **options):
"""
Command handler.
:param options: Not used.
:return: None.
"""
AnnouncementTwitterCrossPublication.objects.publish_pending_announcements()
Add mutex to the "tweetannouncement" management command.
|
"""
Management command to cross-publish announcements on Twitter.
"""
from django.core.management.base import NoArgsCommand
from apps.dbmutex import MutexLock,AlreadyLockedError, LockTimeoutError
from ...models import AnnouncementTwitterCrossPublication
class Command(NoArgsCommand):
"""
A management command which cross-publish on Twitter any pending announcements
currently published on the site but not on Twitter yet. Simply call the ``publish_pending_announcements``of
the ``AnnouncementTwitterCrossPublication`` class to do the job. Use the ``dbmutex`` app to avoid concurrent
execution of the code.
"""
help = "Cross-publish pending announcements on Twitter"
def handle_noargs(self, **options):
"""
Command handler.
:param options: Not used.
:return: None.
"""
# Lock a critical section of code
try:
with MutexLock('twitter_announcements'):
# Do the job
AnnouncementTwitterCrossPublication.objects.publish_pending_announcements()
except AlreadyLockedError:
print('Could not obtain lock (another instance of the script running?)')
except LockTimeoutError:
print('Task completed but the lock timed out')
|
<commit_before>"""
Management command to cross-publish announcements on Twitter.
"""
from django.core.management.base import NoArgsCommand
from ...models import AnnouncementTwitterCrossPublication
class Command(NoArgsCommand):
"""
A management command which cross-publish on Twitter any pending announcements
currently published on the site but not on Twitter yet. Simply call the ``publish_pending_announcements``of
the ``AnnouncementTwitterCrossPublication`` class to do the job.
"""
help = "Cross-publish pending announcements on Twitter"
def handle_noargs(self, **options):
"""
Command handler.
:param options: Not used.
:return: None.
"""
AnnouncementTwitterCrossPublication.objects.publish_pending_announcements()
<commit_msg>Add mutex to the "tweetannouncement" management command.<commit_after>
|
"""
Management command to cross-publish announcements on Twitter.
"""
from django.core.management.base import NoArgsCommand
from apps.dbmutex import MutexLock,AlreadyLockedError, LockTimeoutError
from ...models import AnnouncementTwitterCrossPublication
class Command(NoArgsCommand):
"""
A management command which cross-publish on Twitter any pending announcements
currently published on the site but not on Twitter yet. Simply call the ``publish_pending_announcements``of
the ``AnnouncementTwitterCrossPublication`` class to do the job. Use the ``dbmutex`` app to avoid concurrent
execution of the code.
"""
help = "Cross-publish pending announcements on Twitter"
def handle_noargs(self, **options):
"""
Command handler.
:param options: Not used.
:return: None.
"""
# Lock a critical section of code
try:
with MutexLock('twitter_announcements'):
# Do the job
AnnouncementTwitterCrossPublication.objects.publish_pending_announcements()
except AlreadyLockedError:
print('Could not obtain lock (another instance of the script running?)')
except LockTimeoutError:
print('Task completed but the lock timed out')
|
"""
Management command to cross-publish announcements on Twitter.
"""
from django.core.management.base import NoArgsCommand
from ...models import AnnouncementTwitterCrossPublication
class Command(NoArgsCommand):
"""
A management command which cross-publish on Twitter any pending announcements
currently published on the site but not on Twitter yet. Simply call the ``publish_pending_announcements``of
the ``AnnouncementTwitterCrossPublication`` class to do the job.
"""
help = "Cross-publish pending announcements on Twitter"
def handle_noargs(self, **options):
"""
Command handler.
:param options: Not used.
:return: None.
"""
AnnouncementTwitterCrossPublication.objects.publish_pending_announcements()
Add mutex to the "tweetannouncement" management command."""
Management command to cross-publish announcements on Twitter.
"""
from django.core.management.base import NoArgsCommand
from apps.dbmutex import MutexLock,AlreadyLockedError, LockTimeoutError
from ...models import AnnouncementTwitterCrossPublication
class Command(NoArgsCommand):
"""
A management command which cross-publish on Twitter any pending announcements
currently published on the site but not on Twitter yet. Simply call the ``publish_pending_announcements``of
the ``AnnouncementTwitterCrossPublication`` class to do the job. Use the ``dbmutex`` app to avoid concurrent
execution of the code.
"""
help = "Cross-publish pending announcements on Twitter"
def handle_noargs(self, **options):
"""
Command handler.
:param options: Not used.
:return: None.
"""
# Lock a critical section of code
try:
with MutexLock('twitter_announcements'):
# Do the job
AnnouncementTwitterCrossPublication.objects.publish_pending_announcements()
except AlreadyLockedError:
print('Could not obtain lock (another instance of the script running?)')
except LockTimeoutError:
print('Task completed but the lock timed out')
|
<commit_before>"""
Management command to cross-publish announcements on Twitter.
"""
from django.core.management.base import NoArgsCommand
from ...models import AnnouncementTwitterCrossPublication
class Command(NoArgsCommand):
"""
A management command which cross-publish on Twitter any pending announcements
currently published on the site but not on Twitter yet. Simply call the ``publish_pending_announcements``of
the ``AnnouncementTwitterCrossPublication`` class to do the job.
"""
help = "Cross-publish pending announcements on Twitter"
def handle_noargs(self, **options):
"""
Command handler.
:param options: Not used.
:return: None.
"""
AnnouncementTwitterCrossPublication.objects.publish_pending_announcements()
<commit_msg>Add mutex to the "tweetannouncement" management command.<commit_after>"""
Management command to cross-publish announcements on Twitter.
"""
from django.core.management.base import NoArgsCommand
from apps.dbmutex import MutexLock,AlreadyLockedError, LockTimeoutError
from ...models import AnnouncementTwitterCrossPublication
class Command(NoArgsCommand):
"""
A management command which cross-publish on Twitter any pending announcements
currently published on the site but not on Twitter yet. Simply call the ``publish_pending_announcements``of
the ``AnnouncementTwitterCrossPublication`` class to do the job. Use the ``dbmutex`` app to avoid concurrent
execution of the code.
"""
help = "Cross-publish pending announcements on Twitter"
def handle_noargs(self, **options):
"""
Command handler.
:param options: Not used.
:return: None.
"""
# Lock a critical section of code
try:
with MutexLock('twitter_announcements'):
# Do the job
AnnouncementTwitterCrossPublication.objects.publish_pending_announcements()
except AlreadyLockedError:
print('Could not obtain lock (another instance of the script running?)')
except LockTimeoutError:
print('Task completed but the lock timed out')
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.