Skip to content

Commit

Permalink
Merge pull request #1 from zopefoundation/python3
Browse files Browse the repository at this point in the history
Python 3 and PyPy support.
  • Loading branch information
jamadden committed May 3, 2017
2 parents 1e8482b + 0b0fc12 commit 8c11f64
Show file tree
Hide file tree
Showing 36 changed files with 520 additions and 424 deletions.
8 changes: 8 additions & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
[run]
source = src

[report]
exclude_lines =
pragma: no cover
if __name__ == '__main__':
raise NotImplementedError
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,5 @@ build/
dist/
*.egg-info/
.tox/
.coverage
htmlcov/
27 changes: 22 additions & 5 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,26 @@
language: python
sudo: false
python:
- 2.7
install:
- pip install .
- 2.7
- 3.4
- 3.5
- 3.6
- pypy-5.4.1
script:
- python setup.py test -q
- coverage run -m zope.testrunner --test-path=src --auto-color --auto-progress

after_success:
- coveralls
notifications:
email: false
email: false

install:
- pip install -U pip setuptools
- pip install -U coveralls coverage
- pip install -U -e ".[test]"


cache: pip

before_cache:
- rm -f $HOME/.cache/pip/log/debug.log
11 changes: 9 additions & 2 deletions CHANGES.txt → CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,18 @@
CHANGES
=======

3.5.11 (unreleased)
4.0.0 (unreleased)
-------------------

- TBD
- Add support for Python 3.42 3.5 and 3.6 and PyPy.

- Remove test dependency on ``zope.app.testing`` and
``zope.app.zcmlfiles``, among others.

- Change dependency on ``ZODB3`` to ``ZODB``.

- Remove the ability of ``ZopeVersion`` to parse information from a
subversion checkout. zope.app packages are in git now.

3.5.10 (2011-11-02)
-------------------
Expand Down
81 changes: 0 additions & 81 deletions INSTALL.txt

This file was deleted.

6 changes: 5 additions & 1 deletion MANIFEST.in
Original file line number Diff line number Diff line change
@@ -1,6 +1,10 @@
include *.py
include *.txt
include *.rst
include buildout.cfg
include tox.ini
include .travis.yml
include .coveragerc
recursive-include src *.pt
recursive-include src *.txt
recursive-include src *.rst
recursive-include src *.zcml
File renamed without changes.
2 changes: 2 additions & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[bdist_wheel]
universal = 1
92 changes: 67 additions & 25 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,59 +21,101 @@

from setuptools import setup, find_packages

version = '3.5.11dev'
version = '4.0.0.dev0'

def read(*rnames):
return open(os.path.join(os.path.dirname(__file__), *rnames)).read()
with open(os.path.join(os.path.dirname(__file__), *rnames)) as f:
return f.read()

tests_require = [
'webtest',

'zope.app.appsetup>=4.0.0',
'zope.app.authentication>=4.0.0',
'zope.app.basicskin>=4.0.0',
'zope.app.component>=4.0.0',
'zope.app.container>=4.0.0',
'zope.app.locales>=4.0.0',
'zope.app.pagetemplate>=4.0.0',
'zope.app.publication>=4.2.1',
'zope.app.wsgi>=4.1.0',
'zope.applicationcontrol>=4.0.1',
'zope.authentication>=4.2.1',

'zope.annotation>=4.4.1',
'zope.browser>=2.1.0',
'zope.browsermenu>=4.1.1',
'zope.browserpage>=4.1.0',
'zope.browserresource>=4.1.0',
'zope.container>=4.1.0',
'zope.formlib>=4.3.0',
'zope.i18nmessageid>=4.1.0',
'zope.interface>=4.4.0',
'zope.login>=2.0.0',
'zope.pagetemplate>=4.2.1',
'zope.password>=4.2.0',
'zope.pluggableauth>=2.2.0',
'zope.principalregistry>=4.0.0',
'zope.publisher>=4.3.1',
'zope.schema>=4.4.2',
'zope.securitypolicy>=4.1.0',
'zope.session>=4.1.0',
'zope.site>=4.0.0',
'zope.testbrowser>=5.2',
'zope.testing',
'zope.testrunner',
]

setup(name='zope.app.applicationcontrol',
version = version,
author='Zope Foundation and Contributors',
author_email='zope-dev@zope.org',
description='Zope application control',
long_description=(
read('README.txt')
+ '\n\n' +
read('INSTALL.txt')
read('README.rst')
+ '\n\n' +
read('CHANGES.txt')
read('CHANGES.rst')
),
license='ZPL 2.1',
keywords = "zope3 application control",
classifiers = [
keywords="zope3 application control",
classifiers=[
'Development Status :: 5 - Production/Stable',
'Environment :: Web Environment',
'Intended Audience :: Developers',
'License :: OSI Approved :: Zope Public License',
'Programming Language :: Python',
'Programming Language :: Python :: 2',
'Programming Language :: Python :: 2.7',
'Programming Language :: Python :: 3',
'Programming Language :: Python :: 3.3',
'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: Implementation :: CPython',
'Programming Language :: Python :: Implementation :: PyPy',
'Natural Language :: English',
'Operating System :: OS Independent',
'Topic :: Internet :: WWW/HTTP',
'Framework :: Zope3'],
url='http://cheeseshop.python.org/pypi/zope.app.applicationcontrol',
extras_require=dict(
test=['zope.app.component',
'zope.app.testing',
'zope.app.zcmlfiles',
'zope.login',
'zope.password',
'zope.securitypolicy',
'zope.testbrowser',
]),
package_dir = {'': 'src'},
'Framework :: Zope3',
],
url='http://github.com/zopefoundation/zope.app.applicationcontrol',
extras_require={
'test': tests_require,
},
package_dir={'': 'src'},
packages=find_packages('src'),
namespace_packages=['zope', 'zope.app'],
install_requires=[
'setuptools',
'ZODB3',
'zope.applicationcontrol',
'ZODB',
'zope.applicationcontrol >= 4.0.1',
'zope.component',
'zope.i18n',
'zope.i18nmessageid',
'zope.interface',
'zope.size',
'zope.traversing>=3.7.0',
],
include_package_data = True,
zip_safe = False,
)
include_package_data=True,
zip_safe=False,
)
8 changes: 1 addition & 7 deletions src/zope/__init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1 @@
# this is a namespace package
try:
import pkg_resources
pkg_resources.declare_namespace(__name__)
except ImportError:
import pkgutil
__path__ = pkgutil.extend_path(__path__, __name__)
__import__('pkg_resources').declare_namespace(__name__) # pragma: no cover
8 changes: 1 addition & 7 deletions src/zope/app/__init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1 @@
# this is a namespace package
try:
import pkg_resources
pkg_resources.declare_namespace(__name__)
except ImportError:
import pkgutil
__path__ = pkgutil.extend_path(__path__, __name__)
__import__('pkg_resources').declare_namespace(__name__) # pragma: no cover
2 changes: 1 addition & 1 deletion src/zope/app/applicationcontrol/applicationcontrol.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
##############################################################################
"""Application Control
$Id$"""
"""
__docformat__ = 'restructuredtext'

# BBB
Expand Down
12 changes: 6 additions & 6 deletions src/zope/app/applicationcontrol/browser/configure.zcml
Original file line number Diff line number Diff line change
@@ -1,26 +1,26 @@
<zope:configure
<zope:configure
xmlns:zcml="http://namespaces.zope.org/zcml"
xmlns:zope="http://namespaces.zope.org/zope"
xmlns="http://namespaces.zope.org/browser"
zcml:condition="installed zope.browserpage">

<page
for="zope.app.applicationcontrol.interfaces.IApplicationControl"
for="zope.applicationcontrol.interfaces.IApplicationControl"
name="servercontrol.html"
template="servercontrol.pt"
class=".servercontrol.ServerControlView"
permission="zope.ManageApplication"/>

<page
for="zope.app.applicationcontrol.interfaces.IApplicationControl"
for="zope.applicationcontrol.interfaces.IApplicationControl"
name="index.html"
template="runtimeinfo.pt"
class=".runtimeinfo.RuntimeInfoView"
permission="zope.ManageApplication"/>

<menuItems
menu="zmi_views"
for="zope.app.applicationcontrol.interfaces.IApplicationControl">
for="zope.applicationcontrol.interfaces.IApplicationControl">

<menuItem
order="-2"
Expand All @@ -33,15 +33,15 @@
</menuItems>

<page
for="zope.app.applicationcontrol.interfaces.IApplicationControl"
for="zope.applicationcontrol.interfaces.IApplicationControl"
name="ZODBControl.html"
template="zodbcontrol.pt"
class=".zodbcontrol.ZODBControlView"
permission="zope.ManageApplication"
menu="zmi_views" title="ZODB Control"/>

<page
for="zope.app.applicationcontrol.interfaces.IApplicationControl"
for="zope.applicationcontrol.interfaces.IApplicationControl"
name="TranslationDomain.html"
template="translationdomaincontrol.pt"
class=".translationdomaincontrol.TranslationDomainControlView"
Expand Down

0 comments on commit 8c11f64

Please sign in to comment.