<commit_before>#
# to build the distrubution @ tor_async_util-*.*.*.tar.gz
#
#   >git clone https://github.com/simonsdave/tor-async-util.git
#   >cd tor-async-util
#   >source cfg4dev
#   >python setup.py bdist_wheel sdist --formats=gztar
#
# update pypitest with both meta data and source distribution (FYI ...
# use of pandoc is as per https://github.com/pypa/pypi-legacy/issues/148#issuecomment-226939424
# since PyPI requires long description in RST but the repo's readme is in
# markdown)
#
#   >pandoc README.md -o README.rst
#   >twine upload dist/* -r testpypi
#
# you will be able to find the packaage at
#
#   https://test.pypi.org/project/tor-async-util
#
# use the package uploaded to pypitest
#
#   >pip install -i https://testpypi.python.org/pypi tor-async-util
#
import re
from setuptools import setup

#
# this approach used below to determine ```version``` was inspired by
# https://github.com/kennethreitz/requests/blob/master/setup.py#L31
#
# why the complexity? wanted a single spot for the version number
#
# the code below assumes the distribution is being built with the
# current directory being the directory in which setup.py is stored
# which should be totally fine 99.9% of the time. not going to add
# the coode complexity to deal with other scenarios
#
reg_ex_pattern = r"__version__\s*=\s*['\"](?P<version>[^'\"]*)['\"]"
reg_ex = re.compile(reg_ex_pattern)
version = ""
with open("tor_async_util/__init__.py", "r") as fd:
    for line in fd:
        match = reg_ex.match(line)
        if match:
            version = match.group("version")
            break
if not version:
    raise Exception("Can't locate tor_async_util's version number")

def _long_description():
    try:
        with open('README.rst', 'r') as f:
            return f.read()
    except IOError:
        # simple fix to avoid failure on 'source cfg4dev'
        return "a long description"

_author = "Dave Simons"
_author_email = "simonsdave@gmail.com"

_keywords = [
    'tornado',
]

# list of valid classifiers @ https://pypi.python.org/pypi?%3Aaction=list_classifiers
_classifiers = [
    "Development Status :: 5 - Production/Stable",
    "Intended Audience :: Developers",
    "Natural Language :: English",
    "License :: OSI Approved :: MIT License",
    "Operating System :: OS Independent",
    "Programming Language :: Python",
    "Programming Language :: Python :: 2.7",
    "Programming Language :: Python :: Implementation :: CPython",
    "Topic :: Software Development :: Libraries :: Python Modules",
]

setup(
    name="tor_async_util",
    packages=[
        "tor_async_util",
    ],
    scripts=[
        "bin/tor_async_util_nosetests.py",
    ],
    install_requires=[
        "jsonschema>=2.5.0",
        "python-keyczar==0.716",
        "tornado>=4.0.0",
    ],
    include_package_data=True,
    version=version,
    description="Tornado Async Utilities",
    long_description=_long_description(),
    author=_author,
    author_email=_author_email,
    maintainer=_author,
    maintainer_email=_author_email,
    license="MIT",
    url="https://github.com/simonsdave/tor-async-util",
    download_url="https://github.com/simonsdave/tor-async-util/tarball/v%s" % version,
    keywords=_keywords,
    classifiers=_classifiers,
)
<commit_msg>tornado 4.0.0 -> <5.0.0<commit_after>#
# to build the distrubution @ tor_async_util-*.*.*.tar.gz
#
#   >git clone https://github.com/simonsdave/tor-async-util.git
#   >cd tor-async-util
#   >source cfg4dev
#   >python setup.py bdist_wheel sdist --formats=gztar
#
# update pypitest with both meta data and source distribution (FYI ...
# use of pandoc is as per https://github.com/pypa/pypi-legacy/issues/148#issuecomment-226939424
# since PyPI requires long description in RST but the repo's readme is in
# markdown)
#
#   >pandoc README.md -o README.rst
#   >twine upload dist/* -r testpypi
#
# you will be able to find the packaage at
#
#   https://test.pypi.org/project/tor-async-util
#
# use the package uploaded to pypitest
#
#   >pip install -i https://testpypi.python.org/pypi tor-async-util
#
import re
from setuptools import setup

#
# this approach used below to determine ```version``` was inspired by
# https://github.com/kennethreitz/requests/blob/master/setup.py#L31
#
# why the complexity? wanted a single spot for the version number
#
# the code below assumes the distribution is being built with the
# current directory being the directory in which setup.py is stored
# which should be totally fine 99.9% of the time. not going to add
# the coode complexity to deal with other scenarios
#
reg_ex_pattern = r"__version__\s*=\s*['\"](?P<version>[^'\"]*)['\"]"
reg_ex = re.compile(reg_ex_pattern)
version = ""
with open("tor_async_util/__init__.py", "r") as fd:
    for line in fd:
        match = reg_ex.match(line)
        if match:
            version = match.group("version")
            break
if not version:
    raise Exception("Can't locate tor_async_util's version number")

def _long_description():
    try:
        with open('README.rst', 'r') as f:
            return f.read()
    except IOError:
        # simple fix to avoid failure on 'source cfg4dev'
        return "a long description"

_author = "Dave Simons"
_author_email = "simonsdave@gmail.com"

_keywords = [
    'tornado',
]

# list of valid classifiers @ https://pypi.python.org/pypi?%3Aaction=list_classifiers
_classifiers = [
    "Development Status :: 5 - Production/Stable",
    "Intended Audience :: Developers",
    "Natural Language :: English",
    "License :: OSI Approved :: MIT License",
    "Operating System :: OS Independent",
    "Programming Language :: Python",
    "Programming Language :: Python :: 2.7",
    "Programming Language :: Python :: Implementation :: CPython",
    "Topic :: Software Development :: Libraries :: Python Modules",
]

setup(
    name="tor_async_util",
    packages=[
        "tor_async_util",
    ],
    scripts=[
        "bin/tor_async_util_nosetests.py",
    ],
    install_requires=[
        "jsonschema>=2.5.0",
        "python-keyczar==0.716",
        "tornado<5.0.0",
    ],
    include_package_data=True,
    version=version,
    description="Tornado Async Utilities",
    long_description=_long_description(),
    author=_author,
    author_email=_author_email,
    maintainer=_author,
    maintainer_email=_author_email,
    license="MIT",
    url="https://github.com/simonsdave/tor-async-util",
    download_url="https://github.com/simonsdave/tor-async-util/tarball/v%s" % version,
    keywords=_keywords,
    classifiers=_classifiers,
)
<|endoftext|>


<commit_before># -*- coding: utf-8 -*-

import sys

from setuptools import setup

py_version = sys.version_info[:2]

install_requires = ['sqlalchemy', ]

tests_require = ['mock', ]
if py_version == (2, 6):
    tests_require.append('unittest2')
    install_requires.append('argparse')

setup(name='crawlcrunch',
      version='0.2',
      packages=['crawlcrunch'],
      description='Crawl crunchbase.com for companies information.',
      author='Thomas Bach',
      install_requires=install_requires,
      tests_require=tests_require,
      test_suite='crawlcrunch.tests',
      entry_points={
        'console_scripts':
            ['cc_update=crawlcrunch.scripts.cc_update:main', ],
        },
      )
<commit_msg>we provide all modules<commit_after># -*- coding: utf-8 -*-

import sys

from setuptools import find_packages
from setuptools import setup

py_version = sys.version_info[:2]

install_requires = ['sqlalchemy', ]

tests_require = ['mock', ]
if py_version == (2, 6):
    tests_require.append('unittest2')
    install_requires.append('argparse')

setup(name='crawlcrunch',
      version='0.2',
      packages=find_packages(),
      description='Crawl crunchbase.com for companies information.',
      author='Thomas Bach',
      install_requires=install_requires,
      tests_require=tests_require,
      test_suite='crawlcrunch.tests',
      entry_points={
        'console_scripts':
            ['cc_update=crawlcrunch.scripts.cc_update:main', ],
        },
      )
<|endoftext|>


<commit_before>"""
.. codeauthor:: Tsuyoshi Hombashi <tsuyoshi.hombashi@gmail.com>
"""

import os.path

import setuptools

MODULE_NAME = "DataProperty"
REPOSITORY_URL = "https://github.com/thombashi/{:s}".format(MODULE_NAME)
MISC_DIR = "misc"
REQUIREMENT_DIR = "requirements"

pkg_info = {}

def get_release_command_class():
    try:
        from releasecmd import ReleaseCommand
    except ImportError:
        return {}

    return {"release": ReleaseCommand}

with open(os.path.join(MODULE_NAME.lower(), "__version__.py")) as f:
    exec(f.read(), pkg_info)

with open("README.rst", encoding="utf8") as f:
    long_description = f.read()

with open(os.path.join(MISC_DIR, "summary.txt"), encoding="utf8") as f:
    summary = f.read().strip()

with open(os.path.join(REQUIREMENT_DIR, "requirements.txt")) as f:
    install_requires = [line.strip() for line in f if line.strip()]

with open(os.path.join(REQUIREMENT_DIR, "test_requirements.txt")) as f:
    tests_requires = [line.strip() for line in f if line.strip()]

setuptools_require = ["setuptools>=38.3.0"]

setuptools.setup(
    name=MODULE_NAME,
    version=pkg_info["__version__"],
    url=REPOSITORY_URL,
    author=pkg_info["__author__"],
    author_email=pkg_info["__email__"],
    description=summary,
    include_package_data=True,
    keywords=["data", "property"],
    license=pkg_info["__license__"],
    long_description=long_description,
    long_description_content_type="text/x-rst",
    maintainer=pkg_info["__author__"],
    maintainer_email=pkg_info["__email__"],
    packages=setuptools.find_packages(exclude=["test*"]),
    project_urls={"Source": REPOSITORY_URL, "Tracker": "{:s}/issues".format(REPOSITORY_URL)},
    python_requires=">=3.5",
    install_requires=setuptools_require + install_requires,
    setup_requires=setuptools_require,
    extras_require={"logging": ["loguru>=0.4.1,<1"], "test": tests_requires},
    classifiers=[
        "Development Status :: 4 - Beta",
        "Intended Audience :: Developers",
        "Intended Audience :: Information Technology",
        "License :: OSI Approved :: MIT License",
        "Operating System :: OS Independent",
        "Programming Language :: Python :: 3",
        "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 :: Implementation :: CPython",
        "Programming Language :: Python :: Implementation :: PyPy",
        "Topic :: Software Development :: Libraries",
        "Topic :: Software Development :: Libraries :: Python Modules",
    ],
    cmdclass=get_release_command_class(),
)
<commit_msg>Add type annotations<commit_after>"""
.. codeauthor:: Tsuyoshi Hombashi <tsuyoshi.hombashi@gmail.com>
"""

import os.path
from typing import Dict

import setuptools

MODULE_NAME = "DataProperty"
REPOSITORY_URL = "https://github.com/thombashi/{:s}".format(MODULE_NAME)
MISC_DIR = "misc"
REQUIREMENT_DIR = "requirements"

pkg_info = {}  # type: Dict[str, str]

def get_release_command_class() -> Dict[str, setuptools.Command]:
    try:
        from releasecmd import ReleaseCommand
    except ImportError:
        return {}

    return {"release": ReleaseCommand}

with open(os.path.join(MODULE_NAME.lower(), "__version__.py")) as f:
    exec(f.read(), pkg_info)

with open("README.rst", encoding="utf8") as f:
    long_description = f.read()

with open(os.path.join(MISC_DIR, "summary.txt"), encoding="utf8") as f:
    summary = f.read().strip()

with open(os.path.join(REQUIREMENT_DIR, "requirements.txt")) as f:
    install_requires = [line.strip() for line in f if line.strip()]

with open(os.path.join(REQUIREMENT_DIR, "test_requirements.txt")) as f:
    tests_requires = [line.strip() for line in f if line.strip()]

setuptools_require = ["setuptools>=38.3.0"]

setuptools.setup(
    name=MODULE_NAME,
    version=pkg_info["__version__"],
    url=REPOSITORY_URL,
    author=pkg_info["__author__"],
    author_email=pkg_info["__email__"],
    description=summary,
    include_package_data=True,
    keywords=["data", "property"],
    license=pkg_info["__license__"],
    long_description=long_description,
    long_description_content_type="text/x-rst",
    maintainer=pkg_info["__author__"],
    maintainer_email=pkg_info["__email__"],
    packages=setuptools.find_packages(exclude=["test*"]),
    project_urls={"Source": REPOSITORY_URL, "Tracker": "{:s}/issues".format(REPOSITORY_URL)},
    python_requires=">=3.5",
    install_requires=setuptools_require + install_requires,
    setup_requires=setuptools_require,
    extras_require={"logging": ["loguru>=0.4.1,<1"], "test": tests_requires},
    classifiers=[
        "Development Status :: 4 - Beta",
        "Intended Audience :: Developers",
        "Intended Audience :: Information Technology",
        "License :: OSI Approved :: MIT License",
        "Operating System :: OS Independent",
        "Programming Language :: Python :: 3",
        "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 :: Implementation :: CPython",
        "Programming Language :: Python :: Implementation :: PyPy",
        "Topic :: Software Development :: Libraries",
        "Topic :: Software Development :: Libraries :: Python Modules",
    ],
    cmdclass=get_release_command_class(),
)
<|endoftext|>


<commit_before>#!/usr/bin/env python3
"""A setuptools based setup module.

See:
https://packaging.python.org/en/latest/distributing.html
https://github.com/pypa/sampleproject

Extra supported commands are:
* gen_tl, to generate the classes required for Telethon to run
* clean_tl, to clean these generated classes
* pypi, to generate sdist, bdist_wheel, and push to PyPi
"""

# To use a consistent encoding
from codecs import open
from sys import argv
from os import path

# Always prefer setuptools over distutils
from setuptools import find_packages, setup

try:
    from telethon import TelegramClient
except Exception as e:
    print('Failed to import TelegramClient due to', e)
    TelegramClient = None

if __name__ == '__main__':
    if len(argv) >= 2 and argv[1] == 'gen_tl':
        from telethon_generator.tl_generator import TLGenerator
        generator = TLGenerator('telethon/tl')
        if generator.tlobjects_exist():
            print('Detected previous TLObjects. Cleaning...')
            generator.clean_tlobjects()

        print('Generating TLObjects...')
        generator.generate_tlobjects(
            'telethon_generator/scheme.tl', import_depth=2
        )
        print('Done.')

    elif len(argv) >= 2 and argv[1] == 'clean_tl':
        from telethon_generator.tl_generator import TLGenerator
        print('Cleaning...')
        TLGenerator('telethon/tl').clean_tlobjects()
        print('Done.')

    elif len(argv) >= 2 and argv[1] == 'pypi':
        # Need python3.5 or higher, but Telethon is supposed to support 3.x
        # Place it here since noone should be running ./setup.py pypi anyway
        from subprocess import run
        from shutil import rmtree

        for x in ('build', 'dist', 'Telethon.egg-info'):
            rmtree(x, ignore_errors=True)
        run('python3 setup.py sdist', shell=True)
        run('python3 setup.py bdist_wheel', shell=True)
        run('twine upload dist/*', shell=True)
        for x in ('build', 'dist', 'Telethon.egg-info'):
            rmtree(x, ignore_errors=True)

    else:
        if not TelegramClient:
            print('Run `python3', argv[0], 'gen_tl` first.')
            quit()

        here = path.abspath(path.dirname(__file__))

        # Get the long description from the README file
        with open(path.join(here, 'README.rst'), encoding='utf-8') as f:
            long_description = f.read()

        setup(
            name='Telethon',

            # Versions should comply with PEP440.
            version=TelegramClient.__version__,
            description="Full-featured Telegram client library for Python 3",
            long_description=long_description,

            url='https://github.com/LonamiWebs/Telethon',
            download_url='https://github.com/LonamiWebs/Telethon/releases',

            author='Lonami Exo',
            author_email='totufals@hotmail.com',

            license='MIT',

            # See https://pypi.python.org/pypi?%3Aaction=list_classifiers
            classifiers=[
                #   3 - Alpha
                #   4 - Beta
                #   5 - Production/Stable
                'Development Status :: 3 - Alpha',

                'Intended Audience :: Developers',
                'Topic :: Communications :: Chat',

                'License :: OSI Approved :: MIT License',

                'Programming Language :: Python :: 3',
                'Programming Language :: Python :: 3.3',
                'Programming Language :: Python :: 3.4',
                'Programming Language :: Python :: 3.5',
                'Programming Language :: Python :: 3.6'
            ],
            keywords='telegram api chat client library messaging mtproto',
            packages=find_packages(exclude=[
                'telethon_generator', 'telethon_tests', 'run_tests.py',
                'try_telethon.py'
            ]),
            install_requires=['pyaes', 'rsa']
        )
<commit_msg>Allow running setup.py from other directories<commit_after>#!/usr/bin/env python3
"""A setuptools based setup module.

See:
https://packaging.python.org/en/latest/distributing.html
https://github.com/pypa/sampleproject

Extra supported commands are:
* gen_tl, to generate the classes required for Telethon to run
* clean_tl, to clean these generated classes
* pypi, to generate sdist, bdist_wheel, and push to PyPi
"""

# To use a consistent encoding
from codecs import open
from sys import argv
import os

# Always prefer setuptools over distutils
from setuptools import find_packages, setup

try:
    from telethon import TelegramClient
except Exception as e:
    print('Failed to import TelegramClient due to', e)
    TelegramClient = None

class TempWorkDir:
    """Switches the working directory to be the one on which this file lives,
       while within the 'with' block.
    """
    def __init__(self):
        self.original = None

    def __enter__(self):
        self.original = os.path.abspath(os.path.curdir)
        os.chdir(os.path.abspath(os.path.dirname(__file__)))
        return self

    def __exit__(self, *args):
        os.chdir(self.original)

def main():
    if len(argv) >= 2 and argv[1] == 'gen_tl':
        from telethon_generator.tl_generator import TLGenerator
        generator = TLGenerator('telethon/tl')
        if generator.tlobjects_exist():
            print('Detected previous TLObjects. Cleaning...')
            generator.clean_tlobjects()

        print('Generating TLObjects...')
        generator.generate_tlobjects(
            'telethon_generator/scheme.tl', import_depth=2
        )
        print('Done.')

    elif len(argv) >= 2 and argv[1] == 'clean_tl':
        from telethon_generator.tl_generator import TLGenerator
        print('Cleaning...')
        TLGenerator('telethon/tl').clean_tlobjects()
        print('Done.')

    elif len(argv) >= 2 and argv[1] == 'pypi':
        # Need python3.5 or higher, but Telethon is supposed to support 3.x
        # Place it here since noone should be running ./setup.py pypi anyway
        from subprocess import run
        from shutil import rmtree

        for x in ('build', 'dist', 'Telethon.egg-info'):
            rmtree(x, ignore_errors=True)
        run('python3 setup.py sdist', shell=True)
        run('python3 setup.py bdist_wheel', shell=True)
        run('twine upload dist/*', shell=True)
        for x in ('build', 'dist', 'Telethon.egg-info'):
            rmtree(x, ignore_errors=True)

    else:
        if not TelegramClient:
            print('Run `python3', argv[0], 'gen_tl` first.')
            quit()

        # Get the long description from the README file
        with open('README.rst', encoding='utf-8') as f:
            long_description = f.read()

        setup(
            name='Telethon',

            # Versions should comply with PEP440.
            version=TelegramClient.__version__,
            description="Full-featured Telegram client library for Python 3",
            long_description=long_description,

            url='https://github.com/LonamiWebs/Telethon',
            download_url='https://github.com/LonamiWebs/Telethon/releases',

            author='Lonami Exo',
            author_email='totufals@hotmail.com',

            license='MIT',

            # See https://pypi.python.org/pypi?%3Aaction=list_classifiers
            classifiers=[
                #   3 - Alpha
                #   4 - Beta
                #   5 - Production/Stable
                'Development Status :: 3 - Alpha',

                'Intended Audience :: Developers',
                'Topic :: Communications :: Chat',

                'License :: OSI Approved :: MIT License',

                'Programming Language :: Python :: 3',
                'Programming Language :: Python :: 3.3',
                'Programming Language :: Python :: 3.4',
                'Programming Language :: Python :: 3.5',
                'Programming Language :: Python :: 3.6'
            ],
            keywords='telegram api chat client library messaging mtproto',
            packages=find_packages(exclude=[
                'telethon_generator', 'telethon_tests', 'run_tests.py',
                'try_telethon.py'
            ]),
            install_requires=['pyaes', 'rsa']
        )

if __name__ == '__main__':
    with TempWorkDir():  # Could just use a try/finally but this is + reusable
        main()
<|endoftext|>


<commit_before>#!/usr/bin/env python
# -*- coding: utf-8 -*-

"""
Copyright 2017 Fedele Mantuano (https://twitter.com/fedelemantuano)

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 argparse
import logging
import os
import runpy
import sys
import time

from elasticsearch import Elasticsearch
from elasticsearch.exceptions import ConnectionError

current = os.path.realpath(os.path.dirname(__file__))
__version__ = runpy.run_path(
    os.path.join(current, "..", "options.py"))["__version__"]

# Logger
log = logging.getLogger(__name__)
log.setLevel(logging.INFO)
ch = logging.StreamHandler(sys.stdout)
ch.setLevel(logging.DEBUG)
formatter = logging.Formatter(
    "%(asctime)s - %(funcName)s - %(levelname)s - %(message)s")
ch.setFormatter(formatter)
log.addHandler(ch)

def get_args():
    parser = argparse.ArgumentParser(
        description="It manages SpamScope topologies",
        formatter_class=argparse.ArgumentDefaultsHelpFormatter)

    subparsers = parser.add_subparsers(help="sub-commands", dest="subparser")

    # Common args
    parser.add_argument(
        "-c",
        "--client-host",
        default="elasticsearch",
        help="Elasticsearch client host",
        dest="client_host")

    # Common args
    parser.add_argument(
        "-m",
        "--max-retry",
        default=10,
        type=int,
        help="Max retry for action",
        dest="max_retry")

    parser.add_argument(
        '-v',
        '--version',
        action='version',
        version='%(prog)s {}'.format(__version__))

    # Replicas args
    replicas = subparsers.add_parser(
        "replicas", help="Update the number of replicas")

    replicas.add_argument(
        "-n",
        "--nr-replicas",
        default=0,
        type=int,
        help="Number of replicas.",
        dest="nr_replicas")

    replicas.add_argument(
        "-i",
        "--index",
        default="_all",
        help=("A comma-separated list of index names; use _all "
              "or empty string to perform the operation on all indices."),
        dest="index")

    # Template args
    template = subparsers.add_parser(
        "template", help="Update/add template")

    template.add_argument(
        "-p",
        "--template-path",
        required=True,
        help="Path of template.",
        dest="template_path")

    template.add_argument(
        "-n",
        "--template-name",
        required=True,
        help="Template name",
        dest="template_name")

    return parser.parse_args()

def update_nr_replicas(client_host, max_retry, nr_replicas, index):
    es = Elasticsearch(hosts=client_host)

    for i in range(1, max_retry):
        try:
            es.indices.put_settings(
                body={"index": {"number_of_replicas": int(nr_replicas)}},
                index=index)
            log.info("Updating replicas done")
            return

        except ConnectionError:
            log.warning(
                "Updating replicas failed. Waiting for {} sec".format(i))
            time.sleep(i)

    log.error("Updating replicas definitely failed")

def update_template(client_host, max_retry, template_path, template_name):
    es = Elasticsearch(hosts=client_host)

    with open(template_path) as f:
        body = f.read()

    for i in range(1, max_retry):
        try:
            es.indices.put_template(name=template_name, body=body)
            log.info("Updating template done")
            return

        except ConnectionError:
            log.warning(
                "Updating template failed. Waiting for {} sec".format(i))
            time.sleep(i)

    log.error("Updating template definitely failed")

def main():
    # Command line args
    args = get_args()

    # replicas
    if args.subparser == "replicas":
        update_nr_replicas(
            client_host=args.client_host,
            max_retry=args.max_retry,
            nr_replicas=args.nr_replicas,
            index=args.index)

    # template
    if args.subparser == "template":
        update_template(
            client_host=args.client_host,
            max_retry=args.max_retry,
            template_path=args.template_path,
            template_name=args.template_name)

if __name__ == "__main__":
    main()
<commit_msg>Added NotFoundError in catch exceptions cli tools<commit_after>#!/usr/bin/env python
# -*- coding: utf-8 -*-

"""
Copyright 2017 Fedele Mantuano (https://twitter.com/fedelemantuano)

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 argparse
import logging
import os
import runpy
import sys
import time

from elasticsearch import Elasticsearch
from elasticsearch.exceptions import ConnectionError, NotFoundError

current = os.path.realpath(os.path.dirname(__file__))
__version__ = runpy.run_path(
    os.path.join(current, "..", "options.py"))["__version__"]

# Logger
log = logging.getLogger(__name__)
log.setLevel(logging.INFO)
ch = logging.StreamHandler(sys.stdout)
ch.setLevel(logging.DEBUG)
formatter = logging.Formatter(
    "%(asctime)s - %(funcName)s - %(levelname)s - %(message)s")
ch.setFormatter(formatter)
log.addHandler(ch)

def get_args():
    parser = argparse.ArgumentParser(
        description="It manages SpamScope topologies",
        formatter_class=argparse.ArgumentDefaultsHelpFormatter)

    subparsers = parser.add_subparsers(help="sub-commands", dest="subparser")

    # Common args
    parser.add_argument(
        "-c",
        "--client-host",
        default="elasticsearch",
        help="Elasticsearch client host",
        dest="client_host")

    # Common args
    parser.add_argument(
        "-m",
        "--max-retry",
        default=10,
        type=int,
        help="Max retry for action",
        dest="max_retry")

    parser.add_argument(
        '-v',
        '--version',
        action='version',
        version='%(prog)s {}'.format(__version__))

    # Replicas args
    replicas = subparsers.add_parser(
        "replicas", help="Update the number of replicas")

    replicas.add_argument(
        "-n",
        "--nr-replicas",
        default=0,
        type=int,
        help="Number of replicas.",
        dest="nr_replicas")

    replicas.add_argument(
        "-i",
        "--index",
        default="_all",
        help=("A comma-separated list of index names; use _all "
              "or empty string to perform the operation on all indices."),
        dest="index")

    # Template args
    template = subparsers.add_parser(
        "template", help="Update/add template")

    template.add_argument(
        "-p",
        "--template-path",
        required=True,
        help="Path of template.",
        dest="template_path")

    template.add_argument(
        "-n",
        "--template-name",
        required=True,
        help="Template name",
        dest="template_name")

    return parser.parse_args()

def update_nr_replicas(client_host, max_retry, nr_replicas, index):
    es = Elasticsearch(hosts=client_host)

    for i in range(1, max_retry):
        try:
            es.indices.put_settings(
                body={"index": {"number_of_replicas": int(nr_replicas)}},
                index=index)
            log.info("Updating replicas done")
            return

        except (ConnectionError, NotFoundError):
            log.warning(
                "Updating replicas failed. Waiting for {} sec".format(i))
            time.sleep(i)

    log.error("Updating replicas definitely failed")

def update_template(client_host, max_retry, template_path, template_name):
    es = Elasticsearch(hosts=client_host)

    with open(template_path) as f:
        body = f.read()

    for i in range(1, max_retry):
        try:
            es.indices.put_template(name=template_name, body=body)
            log.info("Updating template done")
            return

        except (ConnectionError, NotFoundError):
            log.warning(
                "Updating template failed. Waiting for {} sec".format(i))
            time.sleep(i)

    log.error("Updating template definitely failed")

def main():
    # Command line args
    args = get_args()

    # replicas
    if args.subparser == "replicas":
        update_nr_replicas(
            client_host=args.client_host,
            max_retry=args.max_retry,
            nr_replicas=args.nr_replicas,
            index=args.index)

    # template
    if args.subparser == "template":
        update_template(
            client_host=args.client_host,
            max_retry=args.max_retry,
            template_path=args.template_path,
            template_name=args.template_name)

if __name__ == "__main__":
    main()
<|endoftext|>


<commit_before>#!/usr/bin/env python

#  _______  _______  __   __  _______  __   __  _______
# |  _    ||       ||  |_|  ||       ||  | |  ||  _    |
# | |_|   ||   _   ||       ||    _  ||  | |  || |_|   |
# |       ||  | |  ||       ||   |_| ||  |_|  ||       |
# |  _   | |  |_|  | |     | |    ___||       ||  _   |
# | |_|   ||       ||   _   ||   |    |       || |_|   |
# |_______||_______||__| |__||___|    |_______||_______|

# Copyright (c) 2014 Steve Ivy <steveivy@gmail.com>
#

import os

from distutils.core import setup

with open('README.md') as f:
    README = f.read()

with open('requirements.txt') as f:
    REQUIREMENTS = f.read()
    REQUIREMENTS = REQUIREMENTS.split('\n')

setup (
    name='boxpub',
    version='0.1',
    description='basic dropbox web publisher',
    long_description=README,
    author='Steve Ivy',
    author_email='steveivy@gmail.com',
    url='http://monkinetic.com',
    packages=['boxpub'],
    include_package_data=True,
    install_requires=REQUIREMENTS,
    data_files=[
        ('/etc/boxpub', ['files/config.py']),
        ('/etc/supervisor/conf.d', ['files/supervisord.conf']),
        ],
    )<commit_msg>fix supervisor conf filename<commit_after>#!/usr/bin/env python

#  _______  _______  __   __  _______  __   __  _______
# |  _    ||       ||  |_|  ||       ||  | |  ||  _    |
# | |_|   ||   _   ||       ||    _  ||  | |  || |_|   |
# |       ||  | |  ||       ||   |_| ||  |_|  ||       |
# |  _   | |  |_|  | |     | |    ___||       ||  _   |
# | |_|   ||       ||   _   ||   |    |       || |_|   |
# |_______||_______||__| |__||___|    |_______||_______|

# Copyright (c) 2014 Steve Ivy <steveivy@gmail.com>
#

import os

from distutils.core import setup

with open('README.md') as f:
    README = f.read()

with open('requirements.txt') as f:
    REQUIREMENTS = f.read()
    REQUIREMENTS = REQUIREMENTS.split('\n')

setup (
    name='boxpub',
    version='0.1',
    description='basic dropbox web publisher',
    long_description=README,
    author='Steve Ivy',
    author_email='steveivy@gmail.com',
    url='http://monkinetic.com',
    packages=['boxpub'],
    include_package_data=True,
    install_requires=REQUIREMENTS,
    data_files=[
        ('/etc/boxpub', ['files/config.py']),
        ('/etc/supervisor/conf.d', ['files/boxpub.conf']),
        ],
    )<|endoftext|>


<commit_before># -*- coding: utf-8 -*-
"""
django-cache-url
~~~~~~~~~~~~~~~~

This simple Django utility allows you to utilize the
`12factor <http://www.12factor.net/backing-services>`_ inspired
``CACHE_URL`` environment variable to configure your Django application.

Usage
-----

Configure your cache in ``settings.py``::

    CACHES = {'default': django_cache_url.config()}

Nice and simple.
"""
from setuptools import setup

setup(
    name = 'django-cache-url',
    version = '0.6.0',
    url = 'http://github.com/ghickman/django-cache-url',
    license = 'MIT',
    author = 'George Hickman',
    author_email = 'george@ghickman.co.uk',
    description = 'Use Cache URLs in your Django application.',
    long_description = __doc__,
    py_modules = ('django_cache_url',),
)

<commit_msg>Fix some linting issues<commit_after># -*- coding: utf-8 -*-
"""
django-cache-url
~~~~~~~~~~~~~~~~

This simple Django utility allows you to utilize the
`12factor <http://www.12factor.net/backing-services>`_ inspired
``CACHE_URL`` environment variable to configure your Django application.

Usage
-----

Configure your cache in ``settings.py``::

    CACHES={'default': django_cache_url.config()}

Nice and simple.
"""
from setuptools import setup

setup(
    name='django-cache-url',
    version='0.6.0',
    url='http://github.com/ghickman/django-cache-url',
    license='MIT',
    author='George Hickman',
    author_email='george@ghickman.co.uk',
    description='Use Cache URLs in your Django application.',
    long_description=__doc__,
    py_modules=('django_cache_url',),
)
<|endoftext|>


<commit_before>#!/usr/bin/python
# -*- coding: utf-8 -*-

# thumbor imaging service
# https://github.com/thumbor/thumbor/wiki

# Licensed under the MIT license:
# http://www.opensource.org/licenses/mit-license
# Copyright (c) 2011 globo.com thumbor@googlegroups.com

from setuptools import setup, Extension
from thumbor import __version__

import glob
import os
import logging

tests_require = [
    "redis>=2.4.9,<3.0.0",
    "coverage>=4.4.1",
    "mock>=1.0.1,<3.0.0",
    "raven",
    "nose",
    "nose-focus",
    "colorama",
    "numpy",
    "flake8",
    "yanc",
    "remotecv",
    "pyssim>=0.4.0",
    "cairosvg>=1.0.0,<2.0.0,!=1.0.21",
    "preggy>=1.3.0",
    "opencv-python",
    "yanc>=0.3.3",
]

def filter_extension_module(name, lib_objs, lib_headers):
    return Extension(
        'thumbor.ext.filters.%s' % name,
        ['thumbor/ext/filters/%s.c' % name] + lib_objs,
        libraries=['m'],
        include_dirs=['thumbor/ext/filters/lib'],
        depends=['setup.py'] + lib_objs + lib_headers,
        extra_compile_args=['-Wall', '-Wextra', '-Werror', '-Wno-unused-parameter'])

def gather_filter_extensions():
    files = glob.glob('thumbor/ext/filters/_*.c')
    lib_objs = glob.glob('thumbor/ext/filters/lib/*.c')
    lib_headers = glob.glob('thumbor/ext/filters/lib/*.h')

    return [filter_extension_module(f[0:-2].split('/')[-1], lib_objs, lib_headers) for f in files]

def run_setup(extension_modules=[]):
    if 'CFLAGS' not in os.environ:
        os.environ['CFLAGS'] = ''
    setup(
        name='thumbor',
        version=__version__,
        description="thumbor is an open-source photo thumbnail service by globo.com",
        long_description="""
Thumbor is a smart imaging service. It enables on-demand crop, resizing and flipping of images.

It also features a VERY smart detection of important points in the image for better cropping and
resizing, using state-of-the-art face and feature detection algorithms (more on that in Detection Algorithms).

Using thumbor is very easy (after it is running). All you have to do is access it using an url for an image, like this:

http://<thumbor-server>/300x200/smart/s.glbimg.com/et/bb/f/original/2011/03/24/VN0JiwzmOw0b0lg.jpg
""",
        keywords='imaging face detection feature thumbnail imagemagick pil opencv',
        author='globo.com',
        author_email='thumbor@googlegroups.com',
        url='https://github.com/thumbor/thumbor/wiki',
        license='MIT',
        classifiers=[
            'Development Status :: 4 - Beta',
            'Intended Audience :: Developers',
            'License :: OSI Approved :: MIT License',
            'Natural Language :: English',
            'Operating System :: MacOS',
            'Operating System :: POSIX :: Linux',
            'Programming Language :: Python :: 2.7',
            'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
            'Topic :: Multimedia :: Graphics :: Presentation'
        ],
        packages=['thumbor'],
        package_dir={"thumbor": "thumbor"},
        include_package_data=True,
        package_data={
            '': ['*.xml'],
        },

        install_requires=[
            "tornado>=4.1.0,<6.0.0",
            "pycryptodomex >= 3.4.7",
            "pycurl>=7.19.0,<7.44.0",
            "Pillow>=4.3.0,<6.0.0",
            "derpconf>=0.2.0",
            "piexif>=1.0.13,<2.0.0",
            "statsd>=3.0.1",
            "libthumbor>=1.3.2",
            "futures",
            "argparse",
            "pytz",
            "six",
            "webcolors",
        ],

        extras_require={
            'tests': tests_require,
        },

        entry_points={
            'console_scripts': [
                'thumbor=thumbor.server:main',
                'thumbor-url=thumbor.url_composer:main',
                'thumbor-config=thumbor.config:generate_config'
            ],
        },

        ext_modules=extension_modules
    )

try:
    run_setup(gather_filter_extensions())
except SystemExit as exit:
    print("\n\n*******************************************************************")
    logging.exception(exit)
    print("\n\n*******************************************************************")
    print("Couldn't build one or more native extensions, skipping compilation.\n\n")
    run_setup()
<commit_msg>Fixes #1212 allow Pillow 6.1.0<commit_after>#!/usr/bin/python
# -*- coding: utf-8 -*-

# thumbor imaging service
# https://github.com/thumbor/thumbor/wiki

# Licensed under the MIT license:
# http://www.opensource.org/licenses/mit-license
# Copyright (c) 2011 globo.com thumbor@googlegroups.com

from setuptools import setup, Extension
from thumbor import __version__

import glob
import os
import logging

tests_require = [
    "redis>=2.4.9,<3.0.0",
    "coverage>=4.4.1",
    "mock>=1.0.1,<3.0.0",
    "raven",
    "nose",
    "nose-focus",
    "colorama",
    "numpy",
    "flake8",
    "yanc",
    "remotecv",
    "pyssim>=0.4.0",
    "cairosvg>=1.0.0,<2.0.0,!=1.0.21",
    "preggy>=1.3.0",
    "opencv-python",
    "yanc>=0.3.3",
]

def filter_extension_module(name, lib_objs, lib_headers):
    return Extension(
        'thumbor.ext.filters.%s' % name,
        ['thumbor/ext/filters/%s.c' % name] + lib_objs,
        libraries=['m'],
        include_dirs=['thumbor/ext/filters/lib'],
        depends=['setup.py'] + lib_objs + lib_headers,
        extra_compile_args=['-Wall', '-Wextra', '-Werror', '-Wno-unused-parameter'])

def gather_filter_extensions():
    files = glob.glob('thumbor/ext/filters/_*.c')
    lib_objs = glob.glob('thumbor/ext/filters/lib/*.c')
    lib_headers = glob.glob('thumbor/ext/filters/lib/*.h')

    return [filter_extension_module(f[0:-2].split('/')[-1], lib_objs, lib_headers) for f in files]

def run_setup(extension_modules=[]):
    if 'CFLAGS' not in os.environ:
        os.environ['CFLAGS'] = ''
    setup(
        name='thumbor',
        version=__version__,
        description="thumbor is an open-source photo thumbnail service by globo.com",
        long_description="""
Thumbor is a smart imaging service. It enables on-demand crop, resizing and flipping of images.

It also features a VERY smart detection of important points in the image for better cropping and
resizing, using state-of-the-art face and feature detection algorithms (more on that in Detection Algorithms).

Using thumbor is very easy (after it is running). All you have to do is access it using an url for an image, like this:

http://<thumbor-server>/300x200/smart/s.glbimg.com/et/bb/f/original/2011/03/24/VN0JiwzmOw0b0lg.jpg
""",
        keywords='imaging face detection feature thumbnail imagemagick pil opencv',
        author='globo.com',
        author_email='thumbor@googlegroups.com',
        url='https://github.com/thumbor/thumbor/wiki',
        license='MIT',
        classifiers=[
            'Development Status :: 4 - Beta',
            'Intended Audience :: Developers',
            'License :: OSI Approved :: MIT License',
            'Natural Language :: English',
            'Operating System :: MacOS',
            'Operating System :: POSIX :: Linux',
            'Programming Language :: Python :: 2.7',
            'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
            'Topic :: Multimedia :: Graphics :: Presentation'
        ],
        packages=['thumbor'],
        package_dir={"thumbor": "thumbor"},
        include_package_data=True,
        package_data={
            '': ['*.xml'],
        },

        install_requires=[
            "tornado>=4.1.0,<6.0.0",
            "pycryptodomex >= 3.4.7",
            "pycurl>=7.19.0,<7.44.0",
            "Pillow>=4.3.0,<=6.1.0",
            "derpconf>=0.2.0",
            "piexif>=1.0.13,<2.0.0",
            "statsd>=3.0.1",
            "libthumbor>=1.3.2",
            "futures",
            "argparse",
            "pytz",
            "six",
            "webcolors",
        ],

        extras_require={
            'tests': tests_require,
        },

        entry_points={
            'console_scripts': [
                'thumbor=thumbor.server:main',
                'thumbor-url=thumbor.url_composer:main',
                'thumbor-config=thumbor.config:generate_config'
            ],
        },

        ext_modules=extension_modules
    )

try:
    run_setup(gather_filter_extensions())
except SystemExit as exit:
    print("\n\n*******************************************************************")
    logging.exception(exit)
    print("\n\n*******************************************************************")
    print("Couldn't build one or more native extensions, skipping compilation.\n\n")
    run_setup()
<|endoftext|>


<commit_before>#!/usr/bin/env python

from distutils.core import setup

dependencies = ['hyper']

try:
    # noinspection PyUnresolvedReferences
    import enum
except ImportError:
    dependencies.append('enum34')

setup(
    name='apns2',
    version='0.1.1',
    packages=['apns2'],
    install_requires=dependencies,
    url='https://github.com/Pr0Ger/PyAPNs2',
    license='MIT',
    author='Sergey Petrov',
    author_email='me@pr0ger.prg',
    classifiers=[
        'Development Status :: 4 - Beta',
        'License :: OSI Approved :: MIT License',
        'Programming Language :: Python :: 3.3',
        'Programming Language :: Python :: 3.4',
        'Programming Language :: Python :: 3.5',
        'Topic :: Software Development :: Libraries',
    ],
    description='A python library for interacting with the Apple Push Notification Service via HTTP/2 protocol'
)
<commit_msg>version bump -> 0.1.2<commit_after>#!/usr/bin/env python

from distutils.core import setup

dependencies = ['hyper']

try:
    # noinspection PyUnresolvedReferences
    import enum
except ImportError:
    dependencies.append('enum34')

setup(
    name='apns2',
    version='0.1.2',
    packages=['apns2'],
    install_requires=dependencies,
    url='https://github.com/Pr0Ger/PyAPNs2',
    license='MIT',
    author='Sergey Petrov',
    author_email='me@pr0ger.prg',
    classifiers=[
        'Development Status :: 4 - Beta',
        'License :: OSI Approved :: MIT License',
        'Programming Language :: Python :: 3.3',
        'Programming Language :: Python :: 3.4',
        'Programming Language :: Python :: 3.5',
        'Topic :: Software Development :: Libraries',
    ],
    description='A python library for interacting with the Apple Push Notification Service via HTTP/2 protocol'
)
<|endoftext|>


<commit_before>from setuptools import setup

setup(
    name='geotweet',
    version='0.1.21',
    description='Fetch geographic tweets from Twitter Streaming API',
    author='Jeffrey Alan Meyers',
    author_email='jeffrey.alan.meyers@gmail.com',
    url='https://github.com/meyersj/geotweet',
    packages=[
        'geotweet',
        'geotweet.twitter',
        'geotweet.geomongo',
        'geotweet.mapreduce',
        'geotweet.mapreduce.utils'
    ],
    scripts=['bin/geotweet'],
    include_package_data=True,
    install_requires=[
        'setuptools>=7.0',
        'argparse',
        'boto3',
        'mrjob',
        'python-twitter',
        'pymongo',
        'Geohash',
        'Shapely',
        'Rtree',
        'pyproj',
        'imposm.parser'
    ]
)
<commit_msg>update version<commit_after>from setuptools import setup

setup(
    name='geotweet',
    version='0.1.22',
    description='Fetch geographic tweets from Twitter Streaming API',
    author='Jeffrey Alan Meyers',
    author_email='jeffrey.alan.meyers@gmail.com',
    url='https://github.com/meyersj/geotweet',
    packages=[
        'geotweet',
        'geotweet.twitter',
        'geotweet.geomongo',
        'geotweet.mapreduce',
        'geotweet.mapreduce.utils'
    ],
    scripts=['bin/geotweet'],
    include_package_data=True,
    install_requires=[
        'setuptools>=7.0',
        'argparse',
        'boto3',
        'mrjob',
        'python-twitter',
        'pymongo',
        'Geohash',
        'Shapely',
        'Rtree',
        'pyproj',
        'imposm.parser'
    ]
)
<|endoftext|>


<commit_before># -*- coding: utf-8 -*-
#
# Copyright (c), 2018, SISSA (International School for Advanced Studies).
# All rights reserved.
# This file is distributed under the terms of the MIT License.
# See the file 'LICENSE' in the root directory of the present
# distribution, or http://opensource.org/licenses/MIT.
#
# @author Davide Brunato <brunato@sissa.it>
#
from setuptools import setup

with open("README.rst") as readme:
    long_description = readme.read()

setup(
    name='elementpath',
    version='1.0.6',
    packages=['elementpath'],
    author='Davide Brunato',
    author_email='brunato@sissa.it',
    url='https://github.com/brunato/elementpath',
    license='MIT',
    description='XPath 1.0/2.0 parsers and selectors for ElementTree.',
    long_description=long_description,
    classifiers=[
        'Development Status :: 5 - Production/Stable',
        'Intended Audience :: Developers',
        'Intended Audience :: Information Technology',
        'Intended Audience :: Science/Research',
        'License :: OSI Approved :: MIT License',
        'Operating System :: OS Independent',
        '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 :: CPython',
        'Topic :: Software Development :: Libraries'
    ]
)
<commit_msg>Add Python 3.7 to setup.py's classifiers<commit_after># -*- coding: utf-8 -*-
#
# Copyright (c), 2018, SISSA (International School for Advanced Studies).
# All rights reserved.
# This file is distributed under the terms of the MIT License.
# See the file 'LICENSE' in the root directory of the present
# distribution, or http://opensource.org/licenses/MIT.
#
# @author Davide Brunato <brunato@sissa.it>
#
from setuptools import setup

with open("README.rst") as readme:
    long_description = readme.read()

setup(
    name='elementpath',
    version='1.0.6',
    packages=['elementpath'],
    author='Davide Brunato',
    author_email='brunato@sissa.it',
    url='https://github.com/brunato/elementpath',
    license='MIT',
    description='XPath 1.0/2.0 parsers and selectors for ElementTree.',
    long_description=long_description,
    classifiers=[
        'Development Status :: 5 - Production/Stable',
        'Intended Audience :: Developers',
        'Intended Audience :: Information Technology',
        'Intended Audience :: Science/Research',
        'License :: OSI Approved :: MIT License',
        'Operating System :: OS Independent',
        '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 :: 3.7',
        'Programming Language :: Python :: Implementation :: CPython',
        'Topic :: Software Development :: Libraries'
    ]
)
<|endoftext|>


<commit_before>#!/usr/bin/env python
# -*- coding: utf-8 -*-

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('HISTORY.rst') as history_file:
    history = history_file.read()

requirements = [
    'requests',
]

test_requirements = [
    # TODO: put package test requirements here
]

setup(
    name='fulfil_client',
    version='0.2.1',
    description="Fulfil REST API Client in Python",
    long_description=readme + '\n\n' + history,
    author="Fulfil.IO Inc.",
    author_email='hello@fulfil.io',
    url='https://github.com/fulfilio/fulfil-python-api',
    packages=[
        'fulfil_client',
    ],
    package_dir={
        'fulfil_client': 'fulfil_client'
    },
    include_package_data=True,
    install_requires=requirements,
    license="ISCL",
    zip_safe=False,
    keywords='fulfil_client',
    classifiers=[
        'Development Status :: 2 - Pre-Alpha',
        'Intended Audience :: Developers',
        'License :: OSI Approved :: ISC License (ISCL)',
        'Natural Language :: English',
        "Programming Language :: Python :: 2",
        'Programming Language :: Python :: 2.6',
        'Programming Language :: Python :: 2.7',
        'Programming Language :: Python :: 3',
        'Programming Language :: Python :: 3.3',
        'Programming Language :: Python :: 3.4',
        'Programming Language :: Python :: 3.5',
    ],
    test_suite='tests',
    tests_require=test_requirements
)
<commit_msg>Released version 0.3.0<commit_after>#!/usr/bin/env python
# -*- coding: utf-8 -*-

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('HISTORY.rst') as history_file:
    history = history_file.read()

requirements = [
    'requests',
]

test_requirements = [
    # TODO: put package test requirements here
]

setup(
    name='fulfil_client',
    version='0.3.0',
    description="Fulfil REST API Client in Python",
    long_description=readme + '\n\n' + history,
    author="Fulfil.IO Inc.",
    author_email='hello@fulfil.io',
    url='https://github.com/fulfilio/fulfil-python-api',
    packages=[
        'fulfil_client',
    ],
    package_dir={
        'fulfil_client': 'fulfil_client'
    },
    include_package_data=True,
    install_requires=requirements,
    license="ISCL",
    zip_safe=False,
    keywords='fulfil_client',
    classifiers=[
        'Development Status :: 2 - Pre-Alpha',
        'Intended Audience :: Developers',
        'License :: OSI Approved :: ISC License (ISCL)',
        'Natural Language :: English',
        "Programming Language :: Python :: 2",
        'Programming Language :: Python :: 2.6',
        'Programming Language :: Python :: 2.7',
        'Programming Language :: Python :: 3',
        'Programming Language :: Python :: 3.3',
        'Programming Language :: Python :: 3.4',
        'Programming Language :: Python :: 3.5',
    ],
    test_suite='tests',
    tests_require=test_requirements
)
<|endoftext|>


<commit_before>from setuptools import setup
import sys
import os

version = None

if sys.argv[-2] == '--version' and sys.argv[-3] == 'sdist':
    version = sys.argv[-1]
    sys.argv.pop()
    sys.argv.pop()

if sys.argv[1] == 'sdist' and not version:
    raise Exception("Please set a version with --version x.y.z")

if not version:
    if sys.argv[1] == 'sdist':
        raise Exception("Please set a version with --version x.y.z")
    else:
        path_pkg_info = os.path.join(os.path.dirname(os.path.realpath(__file__)), 'PKG-INFO')
        if os.path.isfile(path_pkg_info):
            with open(path_pkg_info, 'r')as f:
                for l in f.readlines():
                    if 'Version' in l:
                        _, version = l.split(' ')
        else:
            print("WARNING: cannot set version in custom setup.py")

print("version: %s" % version)

setup(name='klue-client-server',
      version='0.0.1',
      url='https://github.com/erwan-lemonnier/klue-client-server',
      license='BSD',
      author='Erwan Lemonnier',
    author_email='erwan@lemonnier.se',
    description='Swagger + Flask + Grequests + Bravado = Client/Server auto-spawning',
    install_requires=[
        'flask',
        'grequests',
        'bravado-core',
        'pyyaml'
    ],
    tests_require = [
        'nose',
        'mock',
        'responses',
        'pep8'
    ],
    test_suite = 'nose.collector',
    packages=['klue', 'klue.swagger'],
    zip_safe=False,
    include_package_data=True,
    platforms='any',
    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'
    ]
)
<commit_msg>Removed legacy custom code from setup.py<commit_after>from setuptools import setup

setup(name='klue-client-server',
      version='0.0.1',
      url='https://github.com/erwan-lemonnier/klue-client-server',
      license='BSD',
      author='Erwan Lemonnier',
    author_email='erwan@lemonnier.se',
    description='Swagger + Flask + Grequests + Bravado = Client/Server auto-spawning',
    install_requires=[
        'flask',
        'grequests',
        'bravado-core',
        'pyyaml'
    ],
    tests_require = [
        'nose',
        'mock',
        'responses',
        'pep8'
    ],
    test_suite = 'nose.collector',
    packages=['klue', 'klue.swagger'],
    zip_safe=False,
    include_package_data=True,
    platforms='any',
    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'
    ]
)
<|endoftext|>


<commit_before>#!/usr/bin/env python

# Copyright (C) 2006, 2007, 2008, 2009  Andrey Golovizin
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program 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 General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program.  If not, see <http://www.gnu.org/licenses/>.

import sys
import os
from glob import glob1
from setuptools import setup, find_packages
from distutils.command.sdist import sdist
from distutils.dep_util import newer

progname = 'pybtex'
from pybtex.__version__ import version

class Sdist(sdist):
    def run(self):
        from pybtex.database.convert import convert
        bibtex_yaml = os.path.join('examples', 'foo.yaml')
        bibtexml = os.path.join('examples', 'foo.bibtexml')
        bibtex = os.path.join('examples', 'foo.bib')
        if not os.path.exists(bibtex) or newer(bibtex_yaml, bibtex):
            convert(bibtex_yaml, bibtex)
        if not os.path.exists(bibtexml) or newer(bibtex_yaml, bibtexml):
            convert(bibtex_yaml, bibtexml)

        from pybtex.docgen import generate_docs
        generate_docs(os.path.join(ROOT, 'docs'), ('html', 'manpages'))

        sdist.run(self)

ROOT = os.path.abspath(os.path.dirname(__file__))
README = open(os.path.join(ROOT, 'README')).read()

if sys.version_info >= (3, 0):
    extra = {
        'use_2to3': True,
        'use_2to3_fixers': ['custom_fixers'],
    }
else:
    extra = {}

setup(name=progname,
    version=version,
    description='A BibTeX-compatible bibliography processor in Python',
    long_description=README,
    author='Andrey Golovizin',
    author_email='golovizin@gmail.com',
    url='http://pybtex.sourceforge.net/',
    license='MIT',
    platforms=['platform-independent'],
    classifiers=[
        'Development Status :: 4 - Beta',
        'Environment :: Console',
        'Intended Audience :: End Users/Desktop',
        'License :: OSI Approved :: MIT License',
        'Operating System :: OS Independent',
        'Programming Language :: Python',
        'Topic :: Text Editors :: Text Processing',
        'Topic :: Text Processing :: Markup :: LaTeX',
        'Topic :: Text Processing :: Markup :: XML'
    ],
    install_requires = [
        'pyparsing>=1.4.5',
        'PyYAML>=3.01'
    ],
    packages=find_packages(exclude=['docs']),
    scripts=[os.path.join('scripts', progname), os.path.join('scripts', progname + "-convert")],
    include_package_data=True,
    cmdclass={'sdist' : Sdist},
    zip_safe=True,
    **extra
    )
<commit_msg>Remove pyparsing from install_requires.<commit_after>#!/usr/bin/env python

# Copyright (C) 2006, 2007, 2008, 2009  Andrey Golovizin
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program 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 General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program.  If not, see <http://www.gnu.org/licenses/>.

import sys
import os
from glob import glob1
from setuptools import setup, find_packages
from distutils.command.sdist import sdist
from distutils.dep_util import newer

progname = 'pybtex'
from pybtex.__version__ import version

class Sdist(sdist):
    def run(self):
        from pybtex.database.convert import convert
        bibtex_yaml = os.path.join('examples', 'foo.yaml')
        bibtexml = os.path.join('examples', 'foo.bibtexml')
        bibtex = os.path.join('examples', 'foo.bib')
        if not os.path.exists(bibtex) or newer(bibtex_yaml, bibtex):
            convert(bibtex_yaml, bibtex)
        if not os.path.exists(bibtexml) or newer(bibtex_yaml, bibtexml):
            convert(bibtex_yaml, bibtexml)

        from pybtex.docgen import generate_docs
        generate_docs(os.path.join(ROOT, 'docs'), ('html', 'manpages'))

        sdist.run(self)

ROOT = os.path.abspath(os.path.dirname(__file__))
README = open(os.path.join(ROOT, 'README')).read()

if sys.version_info >= (3, 0):
    extra = {
        'use_2to3': True,
        'use_2to3_fixers': ['custom_fixers'],
    }
else:
    extra = {}

setup(name=progname,
    version=version,
    description='A BibTeX-compatible bibliography processor in Python',
    long_description=README,
    author='Andrey Golovizin',
    author_email='golovizin@gmail.com',
    url='http://pybtex.sourceforge.net/',
    license='MIT',
    platforms=['platform-independent'],
    classifiers=[
        'Development Status :: 4 - Beta',
        'Environment :: Console',
        'Intended Audience :: End Users/Desktop',
        'License :: OSI Approved :: MIT License',
        'Operating System :: OS Independent',
        'Programming Language :: Python',
        'Topic :: Text Editors :: Text Processing',
        'Topic :: Text Processing :: Markup :: LaTeX',
        'Topic :: Text Processing :: Markup :: XML'
    ],
    install_requires = [
        'PyYAML>=3.01'
    ],
    packages=find_packages(exclude=['docs']),
    scripts=[os.path.join('scripts', progname), os.path.join('scripts', progname + "-convert")],
    include_package_data=True,
    cmdclass={'sdist' : Sdist},
    zip_safe=True,
    **extra
    )
<|endoftext|>


<commit_before>from setuptools import setup, find_packages

setup(
    name='pyop',
    version='2.0.8',
    packages=find_packages('src'),
    package_dir={'': 'src'},
    url='https://github.com/IdentityPython/pyop',
    license='Apache 2.0',
    author='Rebecka Gulliksson',
    author_email='satosa-dev@lists.sunet.se',
    description='OpenID Connect Provider (OP) library in Python.',
    install_requires=[
        'oic>0.13.1',
        'pymongo'
    ]
)
<commit_msg>Bump version to 2.1.0<commit_after>from setuptools import setup, find_packages

setup(
    name='pyop',
    version='2.1.0',
    packages=find_packages('src'),
    package_dir={'': 'src'},
    url='https://github.com/IdentityPython/pyop',
    license='Apache 2.0',
    author='Rebecka Gulliksson',
    author_email='satosa-dev@lists.sunet.se',
    description='OpenID Connect Provider (OP) library in Python.',
    install_requires=[
        'oic>0.13.1',
        'pymongo'
    ]
)
<|endoftext|>


<commit_before>#!/usr/bin/python
import os
import sys
from setuptools import setup, find_packages
from setuptools.command.test import test as TestCommand

requirements_path = os.path.join(
    os.path.dirname(__file__),
    'requirements.txt',
)
try:
    from pip.req import parse_requirements
    requirements = [
        str(req.req) for req in parse_requirements(requirements_path)
    ]
except ImportError:
    requirements = []
    with open(requirements_path, 'r') as in_:
        requirements = [
            req for req in in_.readlines()
            if not req.startswith('-')
            and not req.startswith('#')
        ]

# Python 2.6 does not come with importlib pre-installed
if sys.version_info < (2, 7):
    requirements.append('importlib>=1.0.1')

class Tox(TestCommand):
    def finalize_options(self):
        TestCommand.finalize_options(self)
        self.test_args = []
        self.test_suite = True

    def run_tests(self):
        import tox
        errno = tox.cmdline(self.test_args)
        sys.exit(errno)

here = os.path.abspath(os.path.dirname(__file__))
try:
    README = open(os.path.join(here, 'README.rst')).read()
    CHANGES = open(os.path.join(here, 'CHANGES.txt')).read()
except IOError:
    README = CHANGES = ''

setup(
    name="ircpdb",
    version="1.4.1",
    description=(
        "Remotely and collaboratively debug your Python application via IRC"
    ),
    long_description=README + "\n\n" + CHANGES,
    author="Adam Coddington",
    author_email="me@adamcoddington.net",
    url="http://github.com/coddingtonbear/ircpdb",
    packages=find_packages(),
    install_requires=requirements,
    tests_require=['tox', 'pytest', 'mock'],
    cmdclass = {'test': Tox},
    classifiers=[
        "Development Status :: 4 - Beta",
        "Intended Audience :: Developers",
        "License :: OSI Approved :: ISC License (ISCL)",
        "Operating System :: MacOS :: MacOS X",
        "Operating System :: Microsoft :: Windows",
        "Operating System :: POSIX",
        "Programming Language :: Python :: 2.5",
        "Programming Language :: Python :: 2.6",
        "Programming Language :: Python :: 2.7",
        "Programming Language :: Python :: 3.0",
        "Programming Language :: Python :: 3.1",
        "Topic :: Software Development :: Debuggers",
    ]
)
<commit_msg>Removing explicit long description; setuptools will figure it out for us now.<commit_after>#!/usr/bin/python
import os
import sys
from setuptools import setup, find_packages
from setuptools.command.test import test as TestCommand

requirements_path = os.path.join(
    os.path.dirname(__file__),
    'requirements.txt',
)
try:
    from pip.req import parse_requirements
    requirements = [
        str(req.req) for req in parse_requirements(requirements_path)
    ]
except ImportError:
    requirements = []
    with open(requirements_path, 'r') as in_:
        requirements = [
            req for req in in_.readlines()
            if not req.startswith('-')
            and not req.startswith('#')
        ]

# Python 2.6 does not come with importlib pre-installed
if sys.version_info < (2, 7):
    requirements.append('importlib>=1.0.1')

class Tox(TestCommand):
    def finalize_options(self):
        TestCommand.finalize_options(self)
        self.test_args = []
        self.test_suite = True

    def run_tests(self):
        import tox
        errno = tox.cmdline(self.test_args)
        sys.exit(errno)

setup(
    name="ircpdb",
    version="1.4.1",
    description=(
        "Remotely and collaboratively debug your Python application via IRC"
    ),
    author="Adam Coddington",
    author_email="me@adamcoddington.net",
    url="http://github.com/coddingtonbear/ircpdb",
    packages=find_packages(),
    install_requires=requirements,
    tests_require=['tox', 'pytest', 'mock'],
    cmdclass = {'test': Tox},
    classifiers=[
        "Development Status :: 4 - Beta",
        "Intended Audience :: Developers",
        "License :: OSI Approved :: ISC License (ISCL)",
        "Operating System :: MacOS :: MacOS X",
        "Operating System :: Microsoft :: Windows",
        "Operating System :: POSIX",
        "Programming Language :: Python :: 2.5",
        "Programming Language :: Python :: 2.6",
        "Programming Language :: Python :: 2.7",
        "Programming Language :: Python :: 3.0",
        "Programming Language :: Python :: 3.1",
        "Topic :: Software Development :: Debuggers",
    ]
)
<|endoftext|>


<commit_before>#!/usr/bin/env python
#
# Copyright (c) 2008-2011 by Enthought, Inc.
# All rights reserved.

"""
Interactive 2-Dimensional Plotting

Chaco is a Python plotting application toolkit that facilitates writing
plotting applications at all levels of complexity, from simple scripts with
hard-coded data to large plotting programs with complex data interrelationships
and a multitude of interactive tools. While Chaco generates attractive static
plots for publication and presentation, it also works well for interactive data
visualization and exploration.

Features
--------
- **Flexible drawing and layout**: Plots consist of graphical components which
  can be placed inside nestable containers for layout, positioning, and event
  dispatch. Every component has a configurable rendering loop with distinct
  layers and backbuffering. Containers can draw cooperatively so that layers
  span across the containment hierarchy.
- **Modular and extensible architecture**: Chaco is object-oriented from the
  ground up for ease of extension and customization. There are clear interfaces
  and abstract classes defining extension points for writing your own custom
  behaviors, from custom tools, plot types, layouts, etc. Most classes are
  also "subclass-friendly", so that subclasses can override one or two methods
  and everything else just works.
- **Data model for ease of extension and embedding**: Chaco separates the data
  from any transformations of the data that are needed for displaying it. This
  separation makes it easier to extend Chaco, or embed it in applications.

Prerequisites
-------------
You must have the following libraries installed before building or installing
Chaco:

* `Numpy <http://pypi.python.org/pypi/numpy/1.1.1>`_ version 1.1.0 or later is
  preferred. Version 1.0.4 will work, but some tests may fail.
* `setuptools <http://pypi.python.org/pypi/setuptools/0.6c8>`_

"""

from numpy import get_include
from setuptools import setup, Extension, find_packages

# FIXME: This works around a setuptools bug which gets setup_data.py metadata
# from incorrect packages. Ticket #1592
#from setup_data import INFO
setup_data = dict(__name__='', __file__='setup_data.py')
execfile('setup_data.py', setup_data)
INFO = setup_data['INFO']

# Pull the description values for the setup keywords from our file docstring.
DOCLINES = __doc__.split("\n")

# Register Python extensions
contour = Extension(
    'chaco.contour.contour',
    sources=['chaco/contour/cntr.c'],
    include_dirs=[get_include()],
    define_macros=[('NUMPY', None)]
    )

# Commenting this out for now, until we get the module fully tested and working
#speedups = Extension(
#    'chaco._speedups',
#    sources = ['chaco/_speedups.cpp'],
#    include_dirs = [get_include()],
#    define_macros=[('NUMPY', None)]
#    )

# The actual setup call.
setup(
    author = 'Peter Wang, et. al.',
    author_email = 'pwang@enthought.com',
    classifiers = [c.strip() for c in """\
        Development Status :: 5 - Production/Stable
        Intended Audience :: Developers
        Intended Audience :: Science/Research
        License :: OSI Approved :: BSD License
        Operating System :: MacOS
        Operating System :: Microsoft :: Windows
        Operating System :: OS Independent
        Operating System :: POSIX
        Operating System :: Unix
        Programming Language :: C
        Programming Language :: Python
        Topic :: Scientific/Engineering
        Topic :: Software Development
        Topic :: Software Development :: Libraries
        """.splitlines() if len(c.strip()) > 0],
    data_files=[('chaco/layers/data',
        ['chaco/layers/data/Dialog-error.svg',
         'chaco/layers/data/Dialog-warning.svg',
         'chaco/layers/data/range_selection.svg'])],
    package_data={'chaco': ['tools/toolbars/images/*.png']},
    description = DOCLINES[1],
    download_url = ('http://www.enthought.com/repo/ets/chaco-%s.tar.gz' %
                    INFO['version']),
    ext_modules = [contour],
    html_doc_repo = 'https://svn.enthought.com/svn/cec/trunk/projects/chaco/docs/',
    include_package_data = True,
    install_requires = INFO["install_requires"],
    license = 'BSD',
    long_description = '\n'.join(DOCLINES[3:]),
    maintainer = 'ETS Developers',
    maintainer_email = 'enthought-dev@enthought.com',
    name = INFO["name"],
    packages = find_packages(exclude=[
        'docs',
        'examples',
        'examples.zoomed_plot'
        ]),
    platforms = ["Windows", "Linux", "Mac OS-X", "Unix", "Solaris"],
    ssh_server = 'code.enthought.com',
    ssh_remote_dir = '/www/htdocs/code.enthought.com/projects/chaco/',
    tests_require = [
        'nose >= 0.10.3',
        ],
    test_suite = 'nose.collector',
    url = 'http://code.enthought.com/projects/chaco',
    version = INFO["version"],
    zip_safe = False,
)
<commit_msg>DOC: update prerequisites<commit_after>#!/usr/bin/env python
#
# Copyright (c) 2008-2011 by Enthought, Inc.
# All rights reserved.

"""
Interactive 2-Dimensional Plotting

Chaco is a Python plotting application toolkit that facilitates writing
plotting applications at all levels of complexity, from simple scripts with
hard-coded data to large plotting programs with complex data interrelationships
and a multitude of interactive tools. While Chaco generates attractive static
plots for publication and presentation, it also works well for interactive data
visualization and exploration.

Features
--------
- **Flexible drawing and layout**: Plots consist of graphical components which
  can be placed inside nestable containers for layout, positioning, and event
  dispatch. Every component has a configurable rendering loop with distinct
  layers and backbuffering. Containers can draw cooperatively so that layers
  span across the containment hierarchy.
- **Modular and extensible architecture**: Chaco is object-oriented from the
  ground up for ease of extension and customization. There are clear interfaces
  and abstract classes defining extension points for writing your own custom
  behaviors, from custom tools, plot types, layouts, etc. Most classes are
  also "subclass-friendly", so that subclasses can override one or two methods
  and everything else just works.
- **Data model for ease of extension and embedding**: Chaco separates the data
  from any transformations of the data that are needed for displaying it. This
  separation makes it easier to extend Chaco, or embed it in applications.

Prerequisites
-------------
You must have the following libraries installed before building or installing
Chaco:

* `Numpy <http://pypi.python.org/pypi/numpy/1.1.1>`_ version 1.1.1
* `distribute <http://pypi.python.org/pypi/distribute>`_
"""

from numpy import get_include
from setuptools import setup, Extension, find_packages

# FIXME: This works around a setuptools bug which gets setup_data.py metadata
# from incorrect packages. Ticket #1592
#from setup_data import INFO
setup_data = dict(__name__='', __file__='setup_data.py')
execfile('setup_data.py', setup_data)
INFO = setup_data['INFO']

# Pull the description values for the setup keywords from our file docstring.
DOCLINES = __doc__.split("\n")

# Register Python extensions
contour = Extension(
    'chaco.contour.contour',
    sources=['chaco/contour/cntr.c'],
    include_dirs=[get_include()],
    define_macros=[('NUMPY', None)]
    )

# Commenting this out for now, until we get the module fully tested and working
#speedups = Extension(
#    'chaco._speedups',
#    sources = ['chaco/_speedups.cpp'],
#    include_dirs = [get_include()],
#    define_macros=[('NUMPY', None)]
#    )

# The actual setup call.
setup(
    author = 'Peter Wang, et. al.',
    author_email = 'pwang@enthought.com',
    classifiers = [c.strip() for c in """\
        Development Status :: 5 - Production/Stable
        Intended Audience :: Developers
        Intended Audience :: Science/Research
        License :: OSI Approved :: BSD License
        Operating System :: MacOS
        Operating System :: Microsoft :: Windows
        Operating System :: OS Independent
        Operating System :: POSIX
        Operating System :: Unix
        Programming Language :: C
        Programming Language :: Python
        Topic :: Scientific/Engineering
        Topic :: Software Development
        Topic :: Software Development :: Libraries
        """.splitlines() if len(c.strip()) > 0],
    data_files=[('chaco/layers/data',
        ['chaco/layers/data/Dialog-error.svg',
         'chaco/layers/data/Dialog-warning.svg',
         'chaco/layers/data/range_selection.svg'])],
    package_data={'chaco': ['tools/toolbars/images/*.png']},
    description = DOCLINES[1],
    download_url = ('http://www.enthought.com/repo/ets/chaco-%s.tar.gz' %
                    INFO['version']),
    ext_modules = [contour],
    html_doc_repo = 'https://svn.enthought.com/svn/cec/trunk/projects/chaco/docs/',
    include_package_data = True,
    install_requires = INFO["install_requires"],
    license = 'BSD',
    long_description = '\n'.join(DOCLINES[3:]),
    maintainer = 'ETS Developers',
    maintainer_email = 'enthought-dev@enthought.com',
    name = INFO["name"],
    packages = find_packages(exclude=[
        'docs',
        'examples',
        'examples.zoomed_plot'
        ]),
    platforms = ["Windows", "Linux", "Mac OS-X", "Unix", "Solaris"],
    ssh_server = 'code.enthought.com',
    ssh_remote_dir = '/www/htdocs/code.enthought.com/projects/chaco/',
    tests_require = [
        'nose >= 0.10.3',
        ],
    test_suite = 'nose.collector',
    url = 'http://code.enthought.com/projects/chaco',
    version = INFO["version"],
    zip_safe = False,
)
<|endoftext|>


<commit_before>#!/usr/bin/env python

from setuptools import setup, find_packages
from setuptools.command.test import test as TestCommand
from feedly import __version__, __maintainer__, __email__
import sys

long_description = open('README.md').read()

tests_require = [
    'Django>=1.3',
    'mock',
    'pep8',
    'unittest2',
    'pytest',
]

install_requires = [
    'nydus==10.1.0',
    'cqlengine==0.8.7',
    'redis>=2.8.0',
    'celery',
]

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
        errno = pytest.main(self.test_args)
        sys.exit(errno)

setup(
    name='feedly',
    version=__version__,
    author=__maintainer__,
    author_email=__email__,
    url='http://github.com/tschellenbach/feedly',
    description='Feedly allows you to build complex feed and caching structures using Redis.',
    long_description=long_description,
    packages=find_packages(),
    zip_safe=False,
    install_requires=install_requires,
    extras_require={'test': tests_require},
    cmdclass={'test': PyTest},
    tests_require=tests_require,
    include_package_data=True,
    dependency_links=[
        'https://github.com/tschellenbach/nydus/tarball/v10.1.0#egg=nydus==10.1.0',
        'https://github.com/tbarbugli/cqlengine/tarball/69f034e666af753d008364ad17c27f5ce9cc637e#egg=cqlengine==0.8.7',
    ],
    classifiers=[
        'Intended Audience :: Developers',
        'Intended Audience :: System Administrators',
        'Operating System :: OS Independent',
        'Topic :: Software Development',
        'Development Status :: 5 - Production/Stable',
        'License :: OSI Approved :: GNU General Public License (GPL)',
        'Natural Language :: English',
        'Programming Language :: Python',
        'Topic :: Scientific/Engineering :: Mathematics',
        'Topic :: Software Development :: Libraries :: Python Modules',
        'Framework :: Django'
    ],
)
<commit_msg>yet another attempt to make setup working<commit_after>#!/usr/bin/env python

from setuptools import setup, find_packages
from setuptools.command.test import test as TestCommand
from feedly import __version__, __maintainer__, __email__
import sys

long_description = open('README.md').read()

tests_require = [
    'Django>=1.3',
    'mock',
    'pep8',
    'unittest2',
    'pytest',
]

install_requires = [
    'nydus==10.1.0',
    'cqlengine==0.8.7',
    'redis>=2.8.0',
    'celery',
]

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
        errno = pytest.main(self.test_args)
        sys.exit(errno)

setup(
    name='feedly',
    version=__version__,
    author=__maintainer__,
    author_email=__email__,
    url='http://github.com/tschellenbach/feedly',
    description='Feedly allows you to build complex feed and caching structures using Redis.',
    long_description=long_description,
    packages=find_packages(),
    zip_safe=False,
    install_requires=install_requires,
    extras_require={'test': tests_require},
    cmdclass={'test': PyTest},
    tests_require=tests_require,
    include_package_data=True,
    dependency_links=[
        'https://github.com/tschellenbach/nydus/tarball/v10.1.0#egg=nydus-10.1.0',
        'https://github.com/tbarbugli/cqlengine/tarball/69f034e666af753d008364ad17c27f5ce9cc637e#egg=cqlengine-0.8.7',
    ],
    classifiers=[
        'Intended Audience :: Developers',
        'Intended Audience :: System Administrators',
        'Operating System :: OS Independent',
        'Topic :: Software Development',
        'Development Status :: 5 - Production/Stable',
        'License :: OSI Approved :: GNU General Public License (GPL)',
        'Natural Language :: English',
        'Programming Language :: Python',
        'Topic :: Scientific/Engineering :: Mathematics',
        'Topic :: Software Development :: Libraries :: Python Modules',
        'Framework :: Django'
    ],
)
<|endoftext|>


<commit_before># ***** BEGIN LICENSE BLOCK *****
#
# For copyright and licensing please refer to LICENSE.
#
# ***** END LICENSE BLOCK *****
from setuptools import setup

long_description = ('Ariane Plugin PROCOS map your operating process interactions and more.'
                    'Where you can get more informations : '
                    '   + http://ariane.echinopsii.net'
                    '   + http://confluence.echinopsii.net/confluence/display/AD/Ariane+Documentation+Home'
                    '   + IRC on freenode #ariane.echinopsii')

setup(name='ariane_procos',
      version='0.1.5-b01',
      description='Ariane Plugin ProcOS',
      long_description=long_description,
      author='Mathilde Ffrench',
      author_email='mathilde.ffrench@echinopsii.net',
      maintainer='Mathilde Ffrench',
      maintainer_email='mathilde.ffrench@echinopsii.net',
      url='https://github.com/echinopsii/net.echinopsii.ariane.community.plugin.procos.git',
      download_url='https://github.com/echinopsii/net.echinopsii.ariane.community.plugin.procos.git/tarball/0.1.5-b01',
      packages=['ariane_procos'],
      license='AGPLv3',
      install_requires=['netifaces>=0.10.4', 'psutil>=3.3.0,<4.0', 'pykka>=1.2.1', 'ariane_clip3==0.1.6-b01'],
      package_data={'': ['LICENSE', 'README.md']},
      classifiers=[
          'Development Status :: 4 - Beta',
          'Intended Audience :: Developers',
          'License :: OSI Approved :: GNU Affero General Public License v3',
          'License :: OSI Approved :: GNU Affero General Public License v3 or later (AGPLv3+)',
          'Natural Language :: English',
          'Operating System :: OS Independent',
          'Programming Language :: Python :: 3.4',
          'Programming Language :: Python :: Implementation :: CPython',
          'Topic :: Communications',
          'Topic :: Internet',
          'Topic :: Software Development :: Libraries',
          'Topic :: Software Development :: Libraries :: Python Modules',
          'Topic :: System :: Monitoring',
          'Topic :: System :: Networking'],
      zip_safe=True)
<commit_msg>new beta<commit_after># ***** BEGIN LICENSE BLOCK *****
#
# For copyright and licensing please refer to LICENSE.
#
# ***** END LICENSE BLOCK *****
from setuptools import setup

long_description = ('Ariane Plugin PROCOS map your operating process interactions and more.'
                    'Where you can get more informations : '
                    '   + http://ariane.echinopsii.net'
                    '   + http://confluence.echinopsii.net/confluence/display/AD/Ariane+Documentation+Home'
                    '   + IRC on freenode #ariane.echinopsii')

setup(name='ariane_procos',
      version='0.1.5-b02',
      description='Ariane Plugin ProcOS',
      long_description=long_description,
      author='Mathilde Ffrench',
      author_email='mathilde.ffrench@echinopsii.net',
      maintainer='Mathilde Ffrench',
      maintainer_email='mathilde.ffrench@echinopsii.net',
      url='https://github.com/echinopsii/net.echinopsii.ariane.community.plugin.procos.git',
      download_url='https://github.com/echinopsii/net.echinopsii.ariane.community.plugin.procos.git/tarball/0.1.5-b02',
      packages=['ariane_procos'],
      license='AGPLv3',
      install_requires=['netifaces>=0.10.4', 'psutil>=3.3.0,<4.0', 'pykka>=1.2.1', 'ariane_clip3==0.1.6-b02'],
      package_data={'': ['LICENSE', 'README.md']},
      classifiers=[
          'Development Status :: 4 - Beta',
          'Intended Audience :: Developers',
          'License :: OSI Approved :: GNU Affero General Public License v3',
          'License :: OSI Approved :: GNU Affero General Public License v3 or later (AGPLv3+)',
          'Natural Language :: English',
          'Operating System :: OS Independent',
          'Programming Language :: Python :: 3.4',
          'Programming Language :: Python :: Implementation :: CPython',
          'Topic :: Communications',
          'Topic :: Internet',
          'Topic :: Software Development :: Libraries',
          'Topic :: Software Development :: Libraries :: Python Modules',
          'Topic :: System :: Monitoring',
          'Topic :: System :: Networking'],
      zip_safe=True)
<|endoftext|>


<commit_before>import os
import sys

from setuptools import setup, find_packages

try:
    from babel.messages import frontend as babel
except ImportError:
    print "Babel is not installed, you can't localize this package"
    cmdclass = {}
else:
    cmdclass = {
        'compile_catalog': babel.compile_catalog,
        'extract_messages': babel.extract_messages,
        'init_catalog': babel.init_catalog,
        'update_catalog': babel.update_catalog
    }

here = os.path.abspath(os.path.dirname(__file__))
README = open(os.path.join(here, 'README.rst')).read()
CHANGES = open(os.path.join(here, 'CHANGES.rst')).read()

version = '0.4.6b4'

requires = [
    'eduid_am >= 0.6.0, < 0.7.0',
    'vccs_client >= 0.4.1, < 0.5.0',
    'wsgi_ratelimit >= 0.1',
    'eduid_userdb >= 0.2.1b0',
    'eduid_common[webapp]>=0.1.3b5',
    'pyramid == 1.5.4',
    'pyramid_debugtoolbar == 2.3',
    'pyramid_jinja2 == 2.3.3',
    'pyramid_mailer == 0.14',
    'pyramid_tm == 0.11',
    'pyramid_sna == 0.3.1',
    'waitress == 0.8.9',
    'recaptcha-client == 1.0.6',
    'pwgen == 0.4',
    'proquint == 0.1.0',
    'gunicorn == 19.3.0',
]

if sys.version_info[0] < 3:
    # Babel does not work with Python 3
    requires.append('Babel==1.3')

test_requires = [
    'WebTest==1.4.3',
    'mock==1.0.1',
    'eduid_signup_amp>=0.2.9b0',
]

docs_extras = [
    'Sphinx==1.1.3'
]

testing_extras = test_requires + [
    'nose==1.2.1',
    'coverage==3.6',
    'nosexcover==1.0.8',
]

waitress_extras = requires + [
    'waitress==0.8.2',
]

setup(
    name='eduid_signup',
    version=version,
    description='eduID Sign Up application',
    long_description=README + '\n\n' + CHANGES,
    # TODO: add classifiers
    classifiers=[
        # Get strings from http://pypi.python.org/pypi?%3Aaction=list_classifiers
    ],
    keywords='identity federation saml',
    author='NORDUnet A/S',
    url='https://github.com/SUNET/eduid-signup',
    license='BSD',
    packages=find_packages(),
    include_package_data=True,
    zip_safe=False,
    install_requires=requires,
    tests_require=test_requires,
    extras_require={
        'testing': testing_extras,
        'docs': docs_extras,
        'waitress': waitress_extras,
    },
    test_suite='eduid_signup',
    entry_points="""\
    [paste.app_factory]
    main = eduid_signup:main
    """,
)
<commit_msg>Bumped pyramid_sna version<commit_after>import os
import sys

from setuptools import setup, find_packages

try:
    from babel.messages import frontend as babel
except ImportError:
    print "Babel is not installed, you can't localize this package"
    cmdclass = {}
else:
    cmdclass = {
        'compile_catalog': babel.compile_catalog,
        'extract_messages': babel.extract_messages,
        'init_catalog': babel.init_catalog,
        'update_catalog': babel.update_catalog
    }

here = os.path.abspath(os.path.dirname(__file__))
README = open(os.path.join(here, 'README.rst')).read()
CHANGES = open(os.path.join(here, 'CHANGES.rst')).read()

version = '0.4.6b4'

requires = [
    'eduid_am >= 0.6.0, < 0.7.0',
    'vccs_client >= 0.4.1, < 0.5.0',
    'wsgi_ratelimit >= 0.1',
    'eduid_userdb >= 0.2.1b0',
    'eduid_common[webapp]>=0.1.3b5',
    'pyramid == 1.5.4',
    'pyramid_debugtoolbar == 2.3',
    'pyramid_jinja2 == 2.3.3',
    'pyramid_mailer == 0.14',
    'pyramid_tm == 0.11',
    'pyramid_sna == 0.3.2',
    'waitress == 0.8.9',
    'recaptcha-client == 1.0.6',
    'pwgen == 0.4',
    'proquint == 0.1.0',
    'gunicorn == 19.3.0',
]

if sys.version_info[0] < 3:
    # Babel does not work with Python 3
    requires.append('Babel==1.3')

test_requires = [
    'WebTest==1.4.3',
    'mock==1.0.1',
    'eduid_signup_amp>=0.2.9b0',
]

docs_extras = [
    'Sphinx==1.1.3'
]

testing_extras = test_requires + [
    'nose==1.2.1',
    'coverage==3.6',
    'nosexcover==1.0.8',
]

waitress_extras = requires + [
    'waitress==0.8.2',
]

setup(
    name='eduid_signup',
    version=version,
    description='eduID Sign Up application',
    long_description=README + '\n\n' + CHANGES,
    # TODO: add classifiers
    classifiers=[
        # Get strings from http://pypi.python.org/pypi?%3Aaction=list_classifiers
    ],
    keywords='identity federation saml',
    author='NORDUnet A/S',
    url='https://github.com/SUNET/eduid-signup',
    license='BSD',
    packages=find_packages(),
    include_package_data=True,
    zip_safe=False,
    install_requires=requires,
    tests_require=test_requires,
    extras_require={
        'testing': testing_extras,
        'docs': docs_extras,
        'waitress': waitress_extras,
    },
    test_suite='eduid_signup',
    entry_points="""\
    [paste.app_factory]
    main = eduid_signup:main
    """,
)
<|endoftext|>