Merge pull request #2 from dave-shawley/rm-python3-memcached

Remove python3 memcached
This commit is contained in:
Edward F. Long, Jr 2018-01-09 14:45:28 -05:00 committed by GitHub
commit 6ba8b52020
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 43 additions and 51 deletions

View file

@ -2,17 +2,13 @@
--- ---
language: python language: python
python: python:
- 2.6
- 2.7 - 2.7
- pypy - pypy
- 3.2 - 3.2
- 3.3 - 3.3
- 3.4 - 3.4
install: install:
- if [[ $TRAVIS_PYTHON_VERSION == '2.6' ]]; then pip install unittest2; fi - pip install -e .
- if [[ $TRAVIS_PYTHON_VERSION == 2* ]]; then pip install -r requirements2.txt; fi
- if [[ $TRAVIS_PYTHON_VERSION == pypy ]]; then pip install -r requirements2.txt; fi
- if [[ $TRAVIS_PYTHON_VERSION == 3* ]]; then pip install -r requirements3.txt; fi
- pip install -r test-requirements.txt - pip install -r test-requirements.txt
script: nosetests script: nosetests
after_success: after_success:

View file

@ -1,4 +1,4 @@
Copyright (c) 2014 AWeber Communications Copyright (c) 2014-2018 AWeber Communications
All rights reserved. All rights reserved.
Redistribution and use in source and binary forms, with or without modification, Redistribution and use in source and binary forms, with or without modification,
@ -22,4 +22,4 @@ 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 DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE 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 OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

View file

@ -1,2 +1,5 @@
include LICENSE include LICENSE
include README.rst include requirements.txt
include test-requirements.txt
include dev-requirements.txt
include tests.py

View file

@ -2,7 +2,7 @@ sprockets.clients.memcached
=========================== ===========================
Memcached client wrapper that is configured via environment variables. Memcached client wrapper that is configured via environment variables.
|Version| |Downloads| |Status| |Coverage| |License| |Version| |Status| |Coverage| |License|
Installation Installation
------------ ------------
@ -20,8 +20,7 @@ https://sprocketsclientsmemcached.readthedocs.org
Requirements Requirements
------------ ------------
- `python-memcached <https://pypi.python.org/pypi/python-memcached>`_ (Python 2) - `python-memcached <https://pypi.python.org/pypi/python-memcached>`_
- `python3-memcached <https://pypi.python.org/pypi/python3-memcached>`_ (Python 3)
Example Example
------- -------
@ -45,7 +44,7 @@ memcached commands:
Version History Version History
--------------- ---------------
Available at https://sprocketsclientsmemcached.readthedocs.org/en/latest/history.html Available at https://sprocketsclientsmemcached.readthedocs.io/en/latest/history.html
.. |Version| image:: https://badge.fury.io/py/sprockets.clients.memcached.svg? .. |Version| image:: https://badge.fury.io/py/sprockets.clients.memcached.svg?
:target: http://badge.fury.io/py/sprockets.clients.memcached :target: http://badge.fury.io/py/sprockets.clients.memcached
@ -56,8 +55,5 @@ Available at https://sprocketsclientsmemcached.readthedocs.org/en/latest/history
.. |Coverage| image:: https://img.shields.io/coveralls/sprockets/sprockets.clients.memcached.svg? .. |Coverage| image:: https://img.shields.io/coveralls/sprockets/sprockets.clients.memcached.svg?
:target: https://coveralls.io/r/sprockets/sprockets.clients.memcached :target: https://coveralls.io/r/sprockets/sprockets.clients.memcached
.. |Downloads| image:: https://pypip.in/d/sprockets.clients.memcached/badge.svg? .. |License| image:: https://img.shields.io/github/license/sprockets/sprockets.clients.memcached.svg
:target: https://pypi.python.org/pypi/sprockets.clients.memcached :target: https://sprocketsclientsmemcached.readthedocs.io
.. |License| image:: https://pypip.in/license/sprockets.clients.memcached/badge.svg?
:target: https://sprocketsclientsmemcached.readthedocs.org

View file

@ -1,5 +1,3 @@
# Include this version only for documentation building purposes, normally ignored
-e git://github.com/gmr/python-memcached.git@docstring-update#egg=python-memcached
sphinx>=1.2,<2 sphinx>=1.2,<2
sphinx-rtd-theme>=0.1,<1.0 sphinx-rtd-theme>=0.1,<1.0
sphinxcontrib-httpdomain>=1.2,<2 sphinxcontrib-httpdomain>=1.2,<2

View file

@ -1,8 +1,6 @@
#!/usr/bin/env python #!/usr/bin/env python
import sphinx_rtd_theme import sphinx_rtd_theme
from sprockets.clients.memcached import version_info, __version__
needs_sphinx = '1.0' needs_sphinx = '1.0'
extensions = [ extensions = [
'sphinx.ext.autodoc', 'sphinx.ext.autodoc',
@ -14,15 +12,11 @@ templates_path = []
source_suffix = '.rst' source_suffix = '.rst'
master_doc = 'index' master_doc = 'index'
project = 'sprockets.clients.memcached' project = 'sprockets.clients.memcached'
copyright = '2014, AWeber Communications' copyright = '2014-2018, AWeber Communications'
version = '.'.join(__version__.split('.')[0:1]) version = '1.0.1'
release = __version__ release = '1.0'
if len(version_info) > 3:
release += '-{0}'.format(str(v) for v in version_info[3:])
exclude_patterns = [] exclude_patterns = []
pygments_style = 'sphinx' pygments_style = 'sphinx'
html_theme = 'sphinx_rtd_theme' html_theme = 'sphinx_rtd_theme'
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()] html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
intersphinx_mapping = { intersphinx_mapping = {'python': ('https://docs.python.org/2/', None)}
'python': ('https://docs.python.org/2/', None)
}

View file

@ -1,4 +1,11 @@
Version History Version History
--------------- ---------------
- Next Release
- Remove usage of python3-memcached since python-memcached supports
both Python2 & Python3
- Drop support for Python 2.6
- 1.0.0 [2014-09-03] - 1.0.0 [2014-09-03]
- Initial release
- Initial release

View file

@ -2,7 +2,7 @@ sprockets.clients.memcached
=========================== ===========================
Memcached client wrapper that is configured via environment variables Memcached client wrapper that is configured via environment variables
|Version| |Downloads| |Status| |Coverage| |License| |Version| |Status| |Coverage| |License|
Installation Installation
------------ ------------
@ -12,12 +12,11 @@ and can be installed via ``pip`` or ``easy_install``:
.. code:: bash .. code:: bash
pip install sprockets.clients.memcached pip install sprockets.clients.memcached
Requirements Requirements
------------ ------------
- `python-memcached <https://pypi.python.org/pypi/python-memcached>`_ (Python 2) - `python-memcached <https://pypi.python.org/pypi/python-memcached>`_
- `python3-memcached <https://pypi.python.org/pypi/python3-memcached>`_ (Python 3)
API Documentation API Documentation
----------------- -----------------
@ -26,6 +25,7 @@ API Documentation
api api
examples examples
history
Version History Version History
--------------- ---------------
@ -59,8 +59,5 @@ Indices and tables
.. |Coverage| image:: https://img.shields.io/coveralls/sprockets/sprockets.clients.memcached.svg? .. |Coverage| image:: https://img.shields.io/coveralls/sprockets/sprockets.clients.memcached.svg?
:target: https://coveralls.io/r/sprockets/sprockets.clients.memcached :target: https://coveralls.io/r/sprockets/sprockets.clients.memcached
.. |Downloads| image:: https://pypip.in/d/sprockets.clients.memcached/badge.svg? .. |License| image:: https://img.shields.io/github/license/sprockets/sprockets.clients.memcached.svg
:target: https://pypi.python.org/pypi/sprockets.clients.memcached :target: https://sprocketsclientsmemcached.readthedocs.io
.. |License| image:: https://pypip.in/license/sprockets.clients.memcached/badge.svg?
:target: https://sprocketsclientsmemcached.readthedocs.org

1
requirements.txt Normal file
View file

@ -0,0 +1 @@
python-memcached>=1.59,<2

View file

@ -1 +0,0 @@
python-memcached

View file

@ -1 +0,0 @@
python3-memcached

View file

@ -3,12 +3,15 @@ import sys
import setuptools import setuptools
install_requires = ['sprockets']
if sys.version_info < (3, 0): def read_requirements(name):
install_requires.append('python-memcached') requirements = []
if sys.version_info >= (3, 0): with open(name) as req_file:
install_requires.append('python3-memcached') for line in req_file:
if '#' in line:
line = line[:line.index('#')]
requirements.append(line.strip())
return requirements
setuptools.setup( setuptools.setup(
@ -22,13 +25,12 @@ setuptools.setup(
author_email='api@aweber.com', author_email='api@aweber.com',
license=codecs.open('LICENSE', encoding='utf-8').read(), license=codecs.open('LICENSE', encoding='utf-8').read(),
classifiers=[ classifiers=[
'Development Status :: 4 - Beta', 'Development Status :: 5 - Production',
'Intended Audience :: Developers', 'Intended Audience :: Developers',
'License :: OSI Approved :: BSD License', 'License :: OSI Approved :: BSD License',
'Natural Language :: English', 'Natural Language :: English',
'Operating System :: OS Independent', 'Operating System :: OS Independent',
'Programming Language :: Python :: 2', 'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.6',
'Programming Language :: Python :: 2.7', 'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3', 'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.2', 'Programming Language :: Python :: 3.2',
@ -44,7 +46,7 @@ setuptools.setup(
'sprockets.clients.memcached'], 'sprockets.clients.memcached'],
package_data={'': ['LICENSE', 'README.rst']}, package_data={'': ['LICENSE', 'README.rst']},
include_package_data=True, include_package_data=True,
namespace_packages=['sprockets', namespace_packages=['sprockets', 'sprockets.clients'],
'sprockets.clients'], install_requires=read_requirements('requirements.txt'),
install_requires=install_requires, tests_require=read_requirements('test-requirements.txt'),
zip_safe=False) zip_safe=False)