diff --git a/.hgignore b/.hgignore new file mode 100644 index 0000000..944b63d --- /dev/null +++ b/.hgignore @@ -0,0 +1,12 @@ +syntax: glob + +MANIFEST +build/ +dist/ +libleipzig.egg-info/ +nose-*.egg/ +suds-*.egg/ +manual.html +.test/ +pip-log.txt +*.pyc diff --git a/README.rst b/README.rst index 67065c2..f09b1f5 100644 --- a/README.rst +++ b/README.rst @@ -42,15 +42,24 @@ Baseform(*vectors, **options) .. ** +In Python 3, you omit the unicode prefixes. Python 3 is recommended for better support of extended Latin and other alphabets. + Dependencies ------------ +- Python 2: + * Python 2.5 or later releases + * Setuptools_ + * `suds 0.3.9`_ or later -- Python 2.5 or later 2.x releases -- Setuptools_ -- suds_ 0.3.9 or later +- Python 3: + * Python 3.0 or later + * Distribute_ + * `suds 0.4.2`_ or later .. _Setuptools: http://packages.python.org/distribute/ -.. _suds: https://fedorahosted.org/suds/#Resources +.. _suds 0.3.9: https://fedorahosted.org/suds/#Resources +.. _Distribute: http://packages.python.org/distribute/ +.. _suds 0.4.2: https://bitbucket.org/palday/suds Service calls ------------- @@ -161,6 +170,11 @@ program will terminate with exit code 1. If the remote server reported failure Changelog --------- +1.4 + * Added support for Python 3. + * Now requires suds 0.4.2 or later for Python 3. + * Moved to distribute (Python 3 capable fork of setuptools). + * Updated various classifiers and tags for distribute. 1.3.1 * Added service listing to ``wortschatz`` script. diff --git a/libleipzig/__init__.py b/libleipzig/__init__.py index 49b2245..6498ea0 100644 --- a/libleipzig/__init__.py +++ b/libleipzig/__init__.py @@ -4,4 +4,4 @@ from libleipzig.transport import services from suds import WebFault -__all__ = services.keys() + ['WebFault'] +__all__ = list(services.keys()) + ['WebFault'] diff --git a/setup.py b/setup.py index c8e3cdf..08a15b8 100644 --- a/setup.py +++ b/setup.py @@ -1,29 +1,50 @@ # Copyright (C) 2009, 2010 Robert Lehmann +# Python 3 support via 2to3 added by Phillip Alday from setuptools import setup import os.path setup(name='libleipzig', - version='1.3', - description="wortschatz.uni-leipzig.de binding", + version='1.4', + description='wortschatz.uni-leipzig.de binding', long_description=open(os.path.join(os.path.dirname(__file__), - "README.rst")).read(), - url="http://github.com/lehmannro/libleipzig-python/", + 'README.rst')).read(), + url='http://github.com/palday/libleipzig-python/', + setup_requires=['distribute'], install_requires = ['suds'], tests_require = ['nose'], - test_suite = "nose.collector", - author="Robert Lehmann", - author_email="libleipzig@robertlehmann.de", - license="GPLv3", + test_suite = 'nose.collector', + author='Robert Lehmann', + author_email='libleipzig@robertlehmann.de', + maintainer='Phillip Alday', + maintainer_email='phillip.alday@staff.uni-marburg.de', + license='GPLv3', packages=['libleipzig', 'libleipzig.test'], - package_dir={'libleipzig.test': "tests"}, - package_data={'libleipzig': ["README.rst", "manual.html"]}, + package_dir={'libleipzig.test': 'tests'}, + package_data={'libleipzig': ['README.rst', 'manual.html']}, entry_points={'console_scripts': ['wortschatz = libleipzig.main:main']}, zip_safe=True, + use_2to3 = True, classifiers=[ + 'Development Status :: 5 - Production/Stable', 'Environment :: Web Environment', 'License :: OSI Approved :: GNU General Public License (GPL)', 'Natural Language :: German', 'Topic :: Text Processing :: Linguistic', + 'Operating System :: OS Independent', + 'Programming Language :: Python', + 'Programming Language :: Python :: 2', + 'Programming Language :: Python :: 2.4', + 'Programming Language :: Python :: 2.5', + 'Programming Language :: Python :: 2.6', + 'Programming Language :: Python :: 2.7', + 'Programming Language :: Python :: 3', + 'Programming Language :: Python :: 3.0', + 'Programming Language :: Python :: 3.1', + 'Programming Language :: Python :: 3.2', ], + + # PEP-314 states that if possible license & plaform should be specified + # using 'classifiers'. + platforms=['(specified using classifiers)'], )