[Python-modules-commits] [lazy-object-proxy] 01/07: Import lazy-object-proxy_1.3.1.orig.tar.gz
Sandro Tosi
morph at moszumanska.debian.org
Mon Dec 11 03:38:10 UTC 2017
This is an automated email from the git hooks/post-receive script.
morph pushed a commit to branch master
in repository lazy-object-proxy.
commit 312a818b3dd45be16056cefbfd6e4ac9c17dba61
Author: Sandro Tosi <morph at debian.org>
Date: Sun Dec 10 22:29:27 2017 -0500
Import lazy-object-proxy_1.3.1.orig.tar.gz
---
.bumpversion.cfg | 4 +-
.cookiecutterrc | 4 +-
.coveragerc | 6 ++-
.travis.yml | 93 +++++++++++++++++++++++++-------
AUTHORS.rst | 3 ++
CHANGELOG.rst | 13 ++++-
CONTRIBUTING.rst | 2 +-
LICENSE | 2 +-
MANIFEST.in | 1 -
PKG-INFO | 39 ++++++++++++--
README.rst | 44 ++++++++++-----
appveyor.yml | 72 +++++++++++++++++++------
ci/appveyor-bootstrap.py | 19 ++++---
ci/appveyor-download.py | 6 ++-
ci/appveyor-with-compiler.cmd | 17 +++---
ci/bootstrap.py | 19 +++----
ci/templates/.travis.yml | 38 +++++++++----
ci/templates/appveyor.yml | 9 ++--
ci/templates/tox.ini | 10 ++--
docs/conf.py | 5 +-
setup.cfg | 5 +-
setup.py | 4 +-
src/lazy_object_proxy.egg-info/PKG-INFO | 39 ++++++++++++--
src/lazy_object_proxy/__init__.py | 2 +-
src/lazy_object_proxy/cext.c | 2 +-
tests/test_lazy_object_proxy.py | 95 +++++++++++++++++++++++----------
tox.ini | 60 ++++++++++++++++++---
27 files changed, 450 insertions(+), 163 deletions(-)
diff --git a/.bumpversion.cfg b/.bumpversion.cfg
index 2ee4ce8..05ae976 100644
--- a/.bumpversion.cfg
+++ b/.bumpversion.cfg
@@ -1,10 +1,12 @@
[bumpversion]
-current_version = 1.2.2
+current_version = 1.3.1
commit = True
tag = True
[bumpversion:file:setup.py]
+[bumpversion:file:README.rst]
+
[bumpversion:file:docs/conf.py]
[bumpversion:file:src/lazy_object_proxy/__init__.py]
diff --git a/.cookiecutterrc b/.cookiecutterrc
index da69998..c1baf40 100644
--- a/.cookiecutterrc
+++ b/.cookiecutterrc
@@ -9,7 +9,7 @@ cookiecutter:
codeclimate: 'yes'
codecov: 'yes'
command_line_interface: 'no'
- command_line_interface_bin_name: lazy-object-proxy
+ command_line_interface_bin_name: '-'
coveralls: 'yes'
distribution_name: lazy-object-proxy
email: contact at ionelmc.ro
@@ -31,4 +31,4 @@ cookiecutter:
travis: 'yes'
version: 1.2.2
website: https://blog.ionelmc.ro
- year: 2014-2016
+ year: 2014-2017
diff --git a/.coveragerc b/.coveragerc
index 772866d..770e36e 100644
--- a/.coveragerc
+++ b/.coveragerc
@@ -2,8 +2,10 @@
source = src
[run]
-branch = True
-source = src
+branch = true
+source =
+ src
+ tests
parallel = true
[report]
diff --git a/.travis.yml b/.travis.yml
index 8d84bb6..71a2531 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,6 +1,6 @@
language: python
-python: '3.5'
sudo: false
+cache: pip
env:
global:
- LD_PRELOAD=/lib/x86_64-linux-gnu/libSegFault.so
@@ -8,39 +8,92 @@ env:
matrix:
- TOXENV=check
- TOXENV=docs
-
- - TOXENV=2.6-cover,extension-coveralls,coveralls,codecov
- - TOXENV=2.6-nocov
- - TOXENV=2.7-cover,extension-coveralls,coveralls,codecov
- - TOXENV=2.7-nocov
- - TOXENV=3.3-cover,extension-coveralls,coveralls,codecov
- - TOXENV=3.3-nocov
- - TOXENV=3.4-cover,extension-coveralls,coveralls,codecov
- - TOXENV=3.4-nocov
- - TOXENV=3.5-cover,extension-coveralls,coveralls,codecov
- - TOXENV=3.5-nocov
- - TOXENV=pypy-cover,extension-coveralls,coveralls,codecov
- - TOXENV=pypy-nocov
+matrix:
+ include:
+ - python: '2.6'
+ env:
+ - TOXENV=2.6-cover,report,extension-coveralls,coveralls,codecov
+ - python: '2.6'
+ env:
+ - TOXENV=2.6-nocov
+ - python: '2.7'
+ env:
+ - TOXENV=2.7-cover,report,extension-coveralls,coveralls,codecov
+ - python: '2.7'
+ env:
+ - TOXENV=2.7-nocov
+ - python: '3.3'
+ env:
+ - TOXENV=3.3-cover,report,extension-coveralls,coveralls,codecov
+ - python: '3.3'
+ env:
+ - TOXENV=3.3-nocov
+ - python: '3.4'
+ env:
+ - TOXENV=3.4-cover,report,extension-coveralls,coveralls,codecov
+ - python: '3.4'
+ env:
+ - TOXENV=3.4-nocov
+ - python: '3.5'
+ env:
+ - TOXENV=3.5-cover,report,extension-coveralls,coveralls,codecov
+ - python: '3.5'
+ env:
+ - TOXENV=3.5-nocov
+ - python: '3.6'
+ env:
+ - TOXENV=3.6-cover,report,extension-coveralls,coveralls,codecov
+ - python: '3.6'
+ env:
+ - TOXENV=3.6-nocov
+ - python: 'pypy'
+ env:
+ - TOXENV=pypy-cover,report,extension-coveralls,coveralls,codecov
+ - python: 'pypy'
+ env:
+ - TOXENV=pypy-nocov
+ - python: 'pypy3'
+ env:
+ - TOXENV=pypy3-cover,report,extension-coveralls,coveralls,codecov
+ - python: 'pypy3'
+ env:
+ - TOXENV=pypy3-nocov
before_install:
- python --version
- uname -a
- lsb_release -a
install:
- - pip install tox
+ - pip install -U tox virtualenv
- virtualenv --version
- easy_install --version
- pip --version
- tox --version
+ - |
+ set -ex
+ if [[ $TRAVIS_PYTHON_VERSION == 'pypy' ]]; then
+ (cd $HOME
+ wget https://bitbucket.org/squeaky/portable-pypy/downloads/pypy-5.7.1-linux_x86_64-portable.tar.bz2
+ tar xf pypy-5.7.1-linux_x86_64-portable.tar.bz2
+ pypy-5.7.1-linux_x86_64-portable/bin/pypy -m ensurepip
+ pypy-5.7.1-linux_x86_64-portable/bin/pypy -m pip install -U virtualenv)
+ export PATH=$HOME/pypy-5.7.1-linux_x86_64-portable/bin/:$PATH
+ export TOXPYTHON=$HOME/pypy-5.7.1-linux_x86_64-portable/bin/pypy
+ fi
+ if [[ $TRAVIS_PYTHON_VERSION == 'pypy3' ]]; then
+ (cd $HOME
+ wget https://bitbucket.org/squeaky/portable-pypy/downloads/pypy3.5-5.7.1-beta-linux_x86_64-portable.tar.bz2
+ tar xf pypy3.5-5.7.1-beta-linux_x86_64-portable.tar.bz2
+ pypy3.5-5.7.1-beta-linux_x86_64-portable/bin/pypy3 -m ensurepip
+ pypy3.5-5.7.1-beta-linux_x86_64-portable/bin/pypy3 -m pip install -U virtualenv)
+ export PATH=$HOME/pypy3.5-5.7.1-beta-linux_x86_64-portable/bin/:$PATH
+ export TOXPYTHON=$HOME/pypy3.5-5.7.1-beta-linux_x86_64-portable/bin/pypy3
+ fi
+ set +x
script:
- tox -v
after_failure:
- more .tox/log/* | cat
- more .tox/*/log/* | cat
-before_cache:
- - rm -rf $HOME/.cache/pip/log
-cache:
- directories:
- - $HOME/.cache/pip
notifications:
email:
on_success: never
diff --git a/AUTHORS.rst b/AUTHORS.rst
index d01607a..7ae92eb 100644
--- a/AUTHORS.rst
+++ b/AUTHORS.rst
@@ -3,3 +3,6 @@ Authors
=======
* Ionel Cristian Mărieș - https://blog.ionelmc.ro
+* Alvin Chow - https://github.com/alvinchow86
+* Astrum Kuo - https://github.com/xowenx
+* Erik M. Bray - https://iguananaut.net
diff --git a/CHANGELOG.rst b/CHANGELOG.rst
index 42f5005..99d8d84 100644
--- a/CHANGELOG.rst
+++ b/CHANGELOG.rst
@@ -2,6 +2,16 @@
Changelog
=========
+1.3.1 (2017-05-05)
+------------------
+
+* Fix broken release (``sdist`` had a broken ``MANIFEST.in``).
+
+1.3.0 (2017-05-02)
+------------------
+
+* Speed up arithmetic operations involving ``cext.Proxy`` subclasses.
+
1.2.2 (2016-04-14)
------------------
@@ -25,7 +35,8 @@ Changelog
* Added support for pickling. The pickled value is going to be the wrapped object *without* any Proxy container.
* Fixed a memory management issue in the C extension (reference cycles weren't garbage collected due to improper
- handling in the C extension).
+ handling in the C extension). Contributed by Alvin Chow in
+ `#8 <https://github.com/ionelmc/python-lazy-object-proxy/pull/8>`_.
1.0.2 (2015-04-11)
-----------------------------------------
diff --git a/CONTRIBUTING.rst b/CONTRIBUTING.rst
index 5a269b6..71eaf1e 100644
--- a/CONTRIBUTING.rst
+++ b/CONTRIBUTING.rst
@@ -49,7 +49,7 @@ To set up `python-lazy-object-proxy` for local development:
Now you can make your changes locally.
-4. When you're done making changes, run all the checks, doc builder and spell checker with `tox <http://tox.readthedocs.org/en/latest/install.html>`_ one command::
+4. When you're done making changes, run all the checks, doc builder and spell checker with `tox <http://tox.readthedocs.io/en/latest/install.html>`_ one command::
tox
diff --git a/LICENSE b/LICENSE
index 9ac3fbe..70191e6 100644
--- a/LICENSE
+++ b/LICENSE
@@ -1,4 +1,4 @@
-Copyright (c) 2014-2016, Ionel Cristian Mărieș
+Copyright (c) 2014-2017, Ionel Cristian Mărieș
All rights reserved.
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the
diff --git a/MANIFEST.in b/MANIFEST.in
index 92351c4..1e46002 100644
--- a/MANIFEST.in
+++ b/MANIFEST.in
@@ -1,5 +1,4 @@
graft docs
-graft examples
graft src
graft ci
graft tests
diff --git a/PKG-INFO b/PKG-INFO
index 2240a94..256974c 100644
--- a/PKG-INFO
+++ b/PKG-INFO
@@ -1,6 +1,6 @@
Metadata-Version: 1.1
Name: lazy-object-proxy
-Version: 1.2.2
+Version: 1.3.1
Summary: A fast and thorough lazy object proxy.
Home-page: https://github.com/ionelmc/python-lazy-object-proxy
Author: Ionel Cristian Mărieș
@@ -16,6 +16,22 @@ Description: ========
* Free software: BSD license
+ Note that this is based on `wrapt`_'s ObjectProxy with one big change: it calls a function the first time the proxy object is
+ used, while `wrapt.ObjectProxy` just forwards the method calls to the target object.
+
+ In other words, you use `lazy-object-proxy` when you only have the object way later and you use `wrapt.ObjectProxy` when you
+ want to override few methods (by subclassing) and forward everything else to the target object.
+
+ Example::
+
+ def expensive_func():
+ # create expensive object
+ return stuff
+
+ obj = lazy_object_proxy.Proxy(expensive_func)
+ # function is called only when object is actually used
+ print(obj.foobar) # now expensive_func is called
+
Installation
============
@@ -26,7 +42,7 @@ Description: ========
Documentation
=============
- https://python-lazy-object-proxy.readthedocs.org/
+ https://python-lazy-object-proxy.readthedocs.io/
Development
===========
@@ -38,13 +54,24 @@ Description: ========
Acknowledgements
================
- This project is based on some code from `wrapt <https://github.com/GrahamDumpleton/wrapt>`_
- as you can see in the git history.
+ This project is based on some code from `wrapt`_ as you can see in the git history.
+
+ .. _wrapt: https://github.com/GrahamDumpleton/wrapt
Changelog
=========
+ 1.3.1 (2017-05-05)
+ ------------------
+
+ * Fix broken release (``sdist`` had a broken ``MANIFEST.in``).
+
+ 1.3.0 (2017-05-02)
+ ------------------
+
+ * Speed up arithmetic operations involving ``cext.Proxy`` subclasses.
+
1.2.2 (2016-04-14)
------------------
@@ -68,7 +95,8 @@ Description: ========
* Added support for pickling. The pickled value is going to be the wrapped object *without* any Proxy container.
* Fixed a memory management issue in the C extension (reference cycles weren't garbage collected due to improper
- handling in the C extension).
+ handling in the C extension). Contributed by Alvin Chow in
+ `#8 <https://github.com/ionelmc/python-lazy-object-proxy/pull/8>`_.
1.0.2 (2015-04-11)
-----------------------------------------
@@ -89,6 +117,7 @@ Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.3
Classifier: Programming Language :: Python :: 3.4
Classifier: Programming Language :: Python :: 3.5
+Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Programming Language :: Python :: Implementation :: PyPy
Classifier: Topic :: Utilities
diff --git a/README.rst b/README.rst
index d31886c..45b41a0 100644
--- a/README.rst
+++ b/README.rst
@@ -14,7 +14,8 @@ Overview
| |coveralls| |codecov|
| |landscape| |scrutinizer| |codacy| |codeclimate|
* - package
- - |version| |downloads| |wheel| |supported-versions| |supported-implementations|
+ - | |version| |wheel| |supported-versions| |supported-implementations|
+ | |commits-since|
.. |docs| image:: https://readthedocs.org/projects/python-lazy-object-proxy/badge/?style=flat
:target: https://readthedocs.org/projects/python-lazy-object-proxy
@@ -44,7 +45,7 @@ Overview
:target: https://landscape.io/github/ionelmc/python-lazy-object-proxy/master
:alt: Code Quality Status
-.. |codacy| image:: https://img.shields.io/codacy/REPLACE_WITH_PROJECT_ID.svg?style=flat
+.. |codacy| image:: https://img.shields.io/codacy/REPLACE_WITH_PROJECT_ID.svg
:target: https://www.codacy.com/app/ionelmc/python-lazy-object-proxy
:alt: Codacy Code Quality Status
@@ -52,27 +53,27 @@ Overview
:target: https://codeclimate.com/github/ionelmc/python-lazy-object-proxy
:alt: CodeClimate Quality Status
-.. |version| image:: https://img.shields.io/pypi/v/lazy-object-proxy.svg?style=flat
+.. |version| image:: https://img.shields.io/pypi/v/lazy-object-proxy.svg
:alt: PyPI Package latest release
:target: https://pypi.python.org/pypi/lazy-object-proxy
-.. |downloads| image:: https://img.shields.io/pypi/dm/lazy-object-proxy.svg?style=flat
- :alt: PyPI Package monthly downloads
- :target: https://pypi.python.org/pypi/lazy-object-proxy
+.. |commits-since| image:: https://img.shields.io/github/commits-since/ionelmc/python-lazy-object-proxy/v1.3.1.svg
+ :alt: Commits since latest release
+ :target: https://github.com/ionelmc/python-lazy-object-proxy/compare/v1.3.1...master
-.. |wheel| image:: https://img.shields.io/pypi/wheel/lazy-object-proxy.svg?style=flat
+.. |wheel| image:: https://img.shields.io/pypi/wheel/lazy-object-proxy.svg
:alt: PyPI Wheel
:target: https://pypi.python.org/pypi/lazy-object-proxy
-.. |supported-versions| image:: https://img.shields.io/pypi/pyversions/lazy-object-proxy.svg?style=flat
+.. |supported-versions| image:: https://img.shields.io/pypi/pyversions/lazy-object-proxy.svg
:alt: Supported versions
:target: https://pypi.python.org/pypi/lazy-object-proxy
-.. |supported-implementations| image:: https://img.shields.io/pypi/implementation/lazy-object-proxy.svg?style=flat
+.. |supported-implementations| image:: https://img.shields.io/pypi/implementation/lazy-object-proxy.svg
:alt: Supported implementations
:target: https://pypi.python.org/pypi/lazy-object-proxy
-.. |scrutinizer| image:: https://img.shields.io/scrutinizer/g/ionelmc/python-lazy-object-proxy/master.svg?style=flat
+.. |scrutinizer| image:: https://img.shields.io/scrutinizer/g/ionelmc/python-lazy-object-proxy/master.svg
:alt: Scrutinizer Status
:target: https://scrutinizer-ci.com/g/ionelmc/python-lazy-object-proxy/
@@ -83,6 +84,22 @@ A fast and thorough lazy object proxy.
* Free software: BSD license
+Note that this is based on `wrapt`_'s ObjectProxy with one big change: it calls a function the first time the proxy object is
+used, while `wrapt.ObjectProxy` just forwards the method calls to the target object.
+
+In other words, you use `lazy-object-proxy` when you only have the object way later and you use `wrapt.ObjectProxy` when you
+want to override few methods (by subclassing) and forward everything else to the target object.
+
+Example::
+
+ def expensive_func():
+ # create expensive object
+ return stuff
+
+ obj = lazy_object_proxy.Proxy(expensive_func)
+ # function is called only when object is actually used
+ print(obj.foobar) # now expensive_func is called
+
Installation
============
@@ -93,7 +110,7 @@ Installation
Documentation
=============
-https://python-lazy-object-proxy.readthedocs.org/
+https://python-lazy-object-proxy.readthedocs.io/
Development
===========
@@ -105,5 +122,6 @@ To run the all tests run::
Acknowledgements
================
-This project is based on some code from `wrapt <https://github.com/GrahamDumpleton/wrapt>`_
-as you can see in the git history.
+This project is based on some code from `wrapt`_ as you can see in the git history.
+
+.. _wrapt: https://github.com/GrahamDumpleton/wrapt
diff --git a/appveyor.yml b/appveyor.yml
index 8130a39..a57f985 100644
--- a/appveyor.yml
+++ b/appveyor.yml
@@ -7,17 +7,40 @@ environment:
WITH_COMPILER: 'cmd /E:ON /V:ON /C .\ci\appveyor-with-compiler.cmd'
matrix:
- TOXENV: check
+ TOXPYTHON: C:\Python27\python.exe
PYTHON_HOME: C:\Python27
PYTHON_VERSION: '2.7'
PYTHON_ARCH: '32'
+ - TOXENV: '2.6-cover,report,codecov'
+ TOXPYTHON: C:\Python26\python.exe
+ PYTHON_HOME: C:\Python26
+ PYTHON_VERSION: '2.6'
+ PYTHON_ARCH: '32'
+ - TOXENV: '2.6-cover,report,codecov'
+ TOXPYTHON: C:\Python26-x64\python.exe
+ WINDOWS_SDK_VERSION: v7.0
+ PYTHON_HOME: C:\Python26-x64
+ PYTHON_VERSION: '2.6'
+ PYTHON_ARCH: '64'
+
+ - TOXENV: '2.6-nocov'
+ TOXPYTHON: C:\Python26\python.exe
+ PYTHON_HOME: C:\Python26
+ PYTHON_VERSION: '2.6'
+ PYTHON_ARCH: '32'
+ - TOXENV: '2.6-nocov'
+ TOXPYTHON: C:\Python26-x64\python.exe
+ WINDOWS_SDK_VERSION: v7.0
+ PYTHON_HOME: C:\Python26-x64
+ PYTHON_VERSION: '2.6'
+ PYTHON_ARCH: '64'
- - TOXENV: '2.7-cover,codecov'
+ - TOXENV: '2.7-cover,report,codecov'
TOXPYTHON: C:\Python27\python.exe
PYTHON_HOME: C:\Python27
PYTHON_VERSION: '2.7'
PYTHON_ARCH: '32'
-
- - TOXENV: '2.7-cover,codecov'
+ - TOXENV: '2.7-cover,report,codecov'
TOXPYTHON: C:\Python27-x64\python.exe
WINDOWS_SDK_VERSION: v7.0
PYTHON_HOME: C:\Python27-x64
@@ -29,7 +52,6 @@ environment:
PYTHON_HOME: C:\Python27
PYTHON_VERSION: '2.7'
PYTHON_ARCH: '32'
-
- TOXENV: '2.7-nocov'
TOXPYTHON: C:\Python27-x64\python.exe
WINDOWS_SDK_VERSION: v7.0
@@ -37,13 +59,12 @@ environment:
PYTHON_VERSION: '2.7'
PYTHON_ARCH: '64'
- - TOXENV: '3.3-cover,codecov'
+ - TOXENV: '3.3-cover,report,codecov'
TOXPYTHON: C:\Python33\python.exe
PYTHON_HOME: C:\Python33
PYTHON_VERSION: '3.3'
PYTHON_ARCH: '32'
-
- - TOXENV: '3.3-cover,codecov'
+ - TOXENV: '3.3-cover,report,codecov'
TOXPYTHON: C:\Python33-x64\python.exe
WINDOWS_SDK_VERSION: v7.1
PYTHON_HOME: C:\Python33-x64
@@ -55,7 +76,6 @@ environment:
PYTHON_HOME: C:\Python33
PYTHON_VERSION: '3.3'
PYTHON_ARCH: '32'
-
- TOXENV: '3.3-nocov'
TOXPYTHON: C:\Python33-x64\python.exe
WINDOWS_SDK_VERSION: v7.1
@@ -63,13 +83,12 @@ environment:
PYTHON_VERSION: '3.3'
PYTHON_ARCH: '64'
- - TOXENV: '3.4-cover,codecov'
+ - TOXENV: '3.4-cover,report,codecov'
TOXPYTHON: C:\Python34\python.exe
PYTHON_HOME: C:\Python34
PYTHON_VERSION: '3.4'
PYTHON_ARCH: '32'
-
- - TOXENV: '3.4-cover,codecov'
+ - TOXENV: '3.4-cover,report,codecov'
TOXPYTHON: C:\Python34-x64\python.exe
WINDOWS_SDK_VERSION: v7.1
PYTHON_HOME: C:\Python34-x64
@@ -81,7 +100,6 @@ environment:
PYTHON_HOME: C:\Python34
PYTHON_VERSION: '3.4'
PYTHON_ARCH: '32'
-
- TOXENV: '3.4-nocov'
TOXPYTHON: C:\Python34-x64\python.exe
WINDOWS_SDK_VERSION: v7.1
@@ -89,13 +107,12 @@ environment:
PYTHON_VERSION: '3.4'
PYTHON_ARCH: '64'
- - TOXENV: '3.5-cover,codecov'
+ - TOXENV: '3.5-cover,report,codecov'
TOXPYTHON: C:\Python35\python.exe
PYTHON_HOME: C:\Python35
PYTHON_VERSION: '3.5'
PYTHON_ARCH: '32'
-
- - TOXENV: '3.5-cover,codecov'
+ - TOXENV: '3.5-cover,report,codecov'
TOXPYTHON: C:\Python35-x64\python.exe
PYTHON_HOME: C:\Python35-x64
PYTHON_VERSION: '3.5'
@@ -106,13 +123,36 @@ environment:
PYTHON_HOME: C:\Python35
PYTHON_VERSION: '3.5'
PYTHON_ARCH: '32'
-
- TOXENV: '3.5-nocov'
TOXPYTHON: C:\Python35-x64\python.exe
PYTHON_HOME: C:\Python35-x64
PYTHON_VERSION: '3.5'
PYTHON_ARCH: '64'
+ - TOXENV: '3.6-cover,report,codecov'
+ TOXPYTHON: C:\Python36\python.exe
+ PYTHON_HOME: C:\Python36
+ PYTHON_VERSION: '3.6'
+ PYTHON_ARCH: '32'
+ - TOXENV: '3.6-cover,report,codecov'
+ TOXPYTHON: C:\Python36-x64\python.exe
+ WINDOWS_SDK_VERSION: v7.1
+ PYTHON_HOME: C:\Python36-x64
+ PYTHON_VERSION: '3.6'
+ PYTHON_ARCH: '64'
+
+ - TOXENV: '3.6-nocov'
+ TOXPYTHON: C:\Python36\python.exe
+ PYTHON_HOME: C:\Python36
+ PYTHON_VERSION: '3.6'
+ PYTHON_ARCH: '32'
+ - TOXENV: '3.6-nocov'
+ TOXPYTHON: C:\Python36-x64\python.exe
+ WINDOWS_SDK_VERSION: v7.1
+ PYTHON_HOME: C:\Python36-x64
+ PYTHON_VERSION: '3.6'
+ PYTHON_ARCH: '64'
+
init:
- ps: echo $env:TOXENV
- ps: ls C:\Python*
diff --git a/ci/appveyor-bootstrap.py b/ci/appveyor-bootstrap.py
index bc351bc..1a9d198 100644
--- a/ci/appveyor-bootstrap.py
+++ b/ci/appveyor-bootstrap.py
@@ -20,15 +20,17 @@ GET_PIP_PATH = "C:\get-pip.py"
URLS = {
("2.6", "64"): BASE_URL + "2.6.6/python-2.6.6.amd64.msi",
("2.6", "32"): BASE_URL + "2.6.6/python-2.6.6.msi",
- ("2.7", "64"): BASE_URL + "2.7.10/python-2.7.10.amd64.msi",
- ("2.7", "32"): BASE_URL + "2.7.10/python-2.7.10.msi",
+ ("2.7", "64"): BASE_URL + "2.7.10/python-2.7.13.amd64.msi",
+ ("2.7", "32"): BASE_URL + "2.7.10/python-2.7.13.msi",
# NOTE: no .msi installer for 3.3.6
- ("3.3", "64"): BASE_URL + "3.3.3/python-3.3.3.amd64.msi",
- ("3.3", "32"): BASE_URL + "3.3.3/python-3.3.3.msi",
- ("3.4", "64"): BASE_URL + "3.4.3/python-3.4.3.amd64.msi",
- ("3.4", "32"): BASE_URL + "3.4.3/python-3.4.3.msi",
- ("3.5", "64"): BASE_URL + "3.5.0/python-3.5.0-amd64.exe",
- ("3.5", "32"): BASE_URL + "3.5.0/python-3.5.0.exe",
+ ("3.3", "64"): BASE_URL + "3.3.3/python-3.3.5.amd64.msi",
+ ("3.3", "32"): BASE_URL + "3.3.3/python-3.3.5.msi",
+ ("3.4", "64"): BASE_URL + "3.4.3/python-3.4.6.amd64.msi",
+ ("3.4", "32"): BASE_URL + "3.4.3/python-3.4.6.msi",
+ ("3.5", "64"): BASE_URL + "3.5.0/python-3.5.3-amd64.exe",
+ ("3.5", "32"): BASE_URL + "3.5.0/python-3.5.3.exe",
+ ("3.6", "64"): BASE_URL + "3.6.0/python-3.6.0-amd64.exe",
+ ("3.6", "32"): BASE_URL + "3.6.0/python-3.6.0.exe",
}
INSTALL_CMD = {
# Commands are allowed to fail only if they are not the last command. Eg: uninstall (/x) allowed to fail.
@@ -41,6 +43,7 @@ INSTALL_CMD = {
"3.4": [["msiexec.exe", "/L*+!", "install.log", "/qn", "/x", "{path}"],
["msiexec.exe", "/L*+!", "install.log", "/qn", "/i", "{path}", "TARGETDIR={home}"]],
"3.5": [["{path}", "/quiet", "TargetDir={home}"]],
+ "3.6": [["{path}", "/quiet", "TargetDir={home}"]],
}
diff --git a/ci/appveyor-download.py b/ci/appveyor-download.py
index 97e18a9..440b422 100755
--- a/ci/appveyor-download.py
+++ b/ci/appveyor-download.py
@@ -10,9 +10,10 @@ from __future__ import unicode_literals
import argparse
import os
-import requests
import zipfile
+import requests
+
def make_auth_headers():
"""Make the authentication headers needed to use the Appveyor API."""
@@ -64,7 +65,7 @@ def download_latest_artifacts(account_project, build_id):
def ensure_dirs(filename):
"""Make sure the directories exist for `filename`."""
- dirname, _ = os.path.split(filename)
+ dirname = os.path.dirname(filename)
if dirname and not os.path.exists(dirname):
os.makedirs(dirname)
@@ -90,6 +91,7 @@ def unpack_zipfile(filename):
ensure_dirs(name)
z.extract(name)
+
parser = argparse.ArgumentParser(description='Download artifacts from AppVeyor.')
parser.add_argument('--id',
metavar='PROJECT_ID',
diff --git a/ci/appveyor-with-compiler.cmd b/ci/appveyor-with-compiler.cmd
index 7f82a02..6fb80c5 100644
--- a/ci/appveyor-with-compiler.cmd
+++ b/ci/appveyor-with-compiler.cmd
@@ -23,17 +23,10 @@ SET WIN_WDK="c:\Program Files (x86)\Windows Kits\10\Include\wdf"
ECHO SDK: %WINDOWS_SDK_VERSION% ARCH: %PYTHON_ARCH%
-IF "%PYTHON_VERSION%"=="3.5" (
- IF EXIST %WIN_WDK% (
- REM See: https://connect.microsoft.com/VisualStudio/feedback/details/1610302/
- REN %WIN_WDK% 0wdf
- )
- GOTO main
-)
+IF "%PYTHON_VERSION%"=="3.5" GOTO main
+IF "%PYTHON_VERSION%"=="3.6" GOTO main
+IF "%PYTHON_ARCH%"=="32" GOTO main
-IF "%PYTHON_ARCH%"=="32" (
- GOTO main
-)
SET DISTUTILS_USE_SDK=1
SET MSSdk=1
@@ -41,6 +34,10 @@ SET MSSdk=1
CALL "%WIN_SDK_ROOT%\%WINDOWS_SDK_VERSION%\Bin\SetEnv.cmd" /x64 /release
:main
+IF EXIST %WIN_WDK% (
+ REM See: https://connect.microsoft.com/VisualStudio/feedback/details/1610302/
+ REN %WIN_WDK% 0wdf
+)
ECHO Executing: %COMMAND_TO_RUN%
CALL %COMMAND_TO_RUN% || EXIT 1
diff --git a/ci/bootstrap.py b/ci/bootstrap.py
index fdfbaf6..a5709f9 100755
--- a/ci/bootstrap.py
+++ b/ci/bootstrap.py
@@ -4,10 +4,10 @@ from __future__ import absolute_import, print_function, unicode_literals
import os
import sys
+from os.path import abspath
+from os.path import dirname
from os.path import exists
from os.path import join
-from os.path import dirname
-from os.path import abspath
if __name__ == "__main__":
@@ -20,21 +20,22 @@ if __name__ == "__main__":
bin_path = join(env_path, "bin")
if not exists(env_path):
import subprocess
+
print("Making bootstrap env in: {0} ...".format(env_path))
try:
subprocess.check_call(["virtualenv", env_path])
- except Exception:
+ except subprocess.CalledProcessError:
subprocess.check_call([sys.executable, "-m", "virtualenv", env_path])
- print("Installing `jinja2` and `matrix` into bootstrap environment ...")
+ print("Installing `jinja2` and `matrix` into bootstrap environment...")
subprocess.check_call([join(bin_path, "pip"), "install", "jinja2", "matrix"])
activate = join(bin_path, "activate_this.py")
+ # noinspection PyCompatibility
exec(compile(open(activate, "rb").read(), activate, "exec"), dict(__file__=activate))
import jinja2
import matrix
-
jinja = jinja2.Environment(
loader=jinja2.FileSystemLoader(join(base_path, "ci", "templates")),
trim_blocks=True,
@@ -46,21 +47,17 @@ if __name__ == "__main__":
for (alias, conf) in matrix.from_file(join(base_path, "setup.cfg")).items():
python = conf["python_versions"]
deps = conf["dependencies"]
- if "coverage_flags" in conf:
- cover = {"false": False, "true": True}[conf["coverage_flags"].lower()]
- if "environment_variables" in conf:
- env_vars = conf["environment_variables"]
-
tox_environments[alias] = {
"python": "python" + python if "py" not in python else python,
"deps": deps.split(),
}
if "coverage_flags" in conf:
+ cover = {"false": False, "true": True}[conf["coverage_flags"].lower()]
tox_environments[alias].update(cover=cover)
if "environment_variables" in conf:
+ env_vars = conf["environment_variables"]
tox_environments[alias].update(env_vars=env_vars.split())
-
for name in os.listdir(join("ci", "templates")):
with open(join(base_path, name), "w") as fh:
fh.write(jinja.get_template(name).render(tox_environments=tox_environments))
diff --git a/ci/templates/.travis.yml b/ci/templates/.travis.yml
index b1b016a..b42ec23 100644
--- a/ci/templates/.travis.yml
+++ b/ci/templates/.travis.yml
@@ -1,6 +1,6 @@
language: python
-python: '3.5'
sudo: false
+cache: pip
env:
global:
- LD_PRELOAD=/lib/x86_64-linux-gnu/libSegFault.so
@@ -8,8 +8,12 @@ env:
matrix:
- TOXENV=check
- TOXENV=docs
-{% for env, config in tox_environments|dictsort %}{{ '' }}
- - TOXENV={{ env }}{% if config.cover %},extension-coveralls,coveralls,codecov{% endif -%}
+matrix:
+ include:
+{%- for env, config in tox_environments|dictsort %}{{ '' }}
+ - python: '{{ env.split('-')[0] }}'
+ env:
+ - TOXENV={{ env }}{% if config.cover %},report,extension-coveralls,coveralls,codecov{% endif -%}
{% endfor %}
before_install:
@@ -17,21 +21,37 @@ before_install:
- uname -a
- lsb_release -a
install:
- - pip install tox
+ - pip install -U tox virtualenv
- virtualenv --version
- easy_install --version
- pip --version
- tox --version
+ - |
+ set -ex
+ if [[ $TRAVIS_PYTHON_VERSION == 'pypy' ]]; then
+ (cd $HOME
+ wget https://bitbucket.org/squeaky/portable-pypy/downloads/pypy-5.7.1-linux_x86_64-portable.tar.bz2
+ tar xf pypy-5.7.1-linux_x86_64-portable.tar.bz2
+ pypy-5.7.1-linux_x86_64-portable/bin/pypy -m ensurepip
+ pypy-5.7.1-linux_x86_64-portable/bin/pypy -m pip install -U virtualenv)
+ export PATH=$HOME/pypy-5.7.1-linux_x86_64-portable/bin/:$PATH
+ export TOXPYTHON=$HOME/pypy-5.7.1-linux_x86_64-portable/bin/pypy
+ fi
+ if [[ $TRAVIS_PYTHON_VERSION == 'pypy3' ]]; then
+ (cd $HOME
+ wget https://bitbucket.org/squeaky/portable-pypy/downloads/pypy3.5-5.7.1-beta-linux_x86_64-portable.tar.bz2
+ tar xf pypy3.5-5.7.1-beta-linux_x86_64-portable.tar.bz2
+ pypy3.5-5.7.1-beta-linux_x86_64-portable/bin/pypy3 -m ensurepip
+ pypy3.5-5.7.1-beta-linux_x86_64-portable/bin/pypy3 -m pip install -U virtualenv)
+ export PATH=$HOME/pypy3.5-5.7.1-beta-linux_x86_64-portable/bin/:$PATH
+ export TOXPYTHON=$HOME/pypy3.5-5.7.1-beta-linux_x86_64-portable/bin/pypy3
+ fi
+ set +x
script:
- tox -v
after_failure:
- more .tox/log/* | cat
- more .tox/*/log/* | cat
-before_cache:
- - rm -rf $HOME/.cache/pip/log
-cache:
- directories:
- - $HOME/.cache/pip
notifications:
email:
on_success: never
diff --git a/ci/templates/appveyor.yml b/ci/templates/appveyor.yml
index 2027415..84e8dae 100644
--- a/ci/templates/appveyor.yml
+++ b/ci/templates/appveyor.yml
@@ -7,18 +7,17 @@ environment:
WITH_COMPILER: 'cmd /E:ON /V:ON /C .\ci\appveyor-with-compiler.cmd'
matrix:
- TOXENV: check
+ TOXPYTHON: C:\Python27\python.exe
PYTHON_HOME: C:\Python27
PYTHON_VERSION: '2.7'
PYTHON_ARCH: '32'
-
-{% for env, config in tox_environments|dictsort %}{% if config.python in ('python2.7', 'python3.3', 'python3.4', 'python3.5') %}
- - TOXENV: '{{ env }}{% if config.cover %},codecov{% endif %}'
+{% for env, config in tox_environments|dictsort %}{{ '' }}{% if config.python.startswith('python') %}
+ - TOXENV: '{{ env }}{% if config.cover %},report,codecov{% endif %}'
TOXPYTHON: C:\{{ config.python.replace('.', '').capitalize() }}\python.exe
PYTHON_HOME: C:\{{ config.python.replace('.', '').capitalize() }}
PYTHON_VERSION: '{{ config.python[-3:] }}'
PYTHON_ARCH: '32'
-
- - TOXENV: '{{ env }}{% if config.cover %},codecov{% endif %}'
+ - TOXENV: '{{ env }}{% if config.cover %},report,codecov{% endif %}'
TOXPYTHON: C:\{{ config.python.replace('.', '').capitalize() }}-x64\python.exe
{%- if config.python != 'python3.5' %}
diff --git a/ci/templates/tox.ini b/ci/templates/tox.ini
index 9827b74..daf1b15 100644
--- a/ci/templates/tox.ini
+++ b/ci/templates/tox.ini
@@ -10,8 +10,8 @@ envlist =
[testenv]
basepython =
- {docs,spell}: python2.7
- {clean,check,report,extension-coveralls,coveralls,codecov}: python3.5
+ {docs,spell}: {env:TOXPYTHON:python2.7}
+ {bootstrap,clean,check,report,extension-coveralls,coveralls,codecov}: {env:TOXPYTHON:python3}
setenv =
PYTHONPATH={toxinidir}/tests
PYTHONUNBUFFERED=yes
@@ -78,8 +78,6 @@ deps =
skip_install = true
usedevelop = false
commands =
- coverage combine
- coverage report
coveralls --merge=extension-coveralls.json []
[testenv:codecov]
@@ -88,8 +86,6 @@ deps =
skip_install = true
usedevelop = false
commands =
- coverage combine
- coverage report
coverage xml --ignore-errors
codecov []
@@ -107,7 +103,7 @@ deps = coverage
skip_install = true
usedevelop = false
commands =
- coverage combine
+ coverage combine --append
coverage report
coverage html
diff --git a/docs/conf.py b/docs/conf.py
index 34f712f..8c8952a 100644
--- a/docs/conf.py
+++ b/docs/conf.py
@@ -23,10 +23,10 @@ if os.getenv('SPELLCHECK'):
source_suffix = '.rst'
master_doc = 'index'
project = 'lazy-object-proxy'
-year = '2014-2016'
+year = '2014-2017'
author = 'Ionel Cristian Mărieș'
copyright = '{0}, {1}'.format(year, author)
-version = release = '1.2.2'
+version = release = '1.3.1'
pygments_style = 'trac'
templates_path = ['.']
@@ -34,7 +34,6 @@ extlinks = {
'issue': ('https://github.com/ionelmc/python-lazy-object-proxy/issues/%s', '#'),
'pr': ('https://github.com/ionelmc/python-lazy-object-proxy/pull/%s', 'PR #'),
}
->>>>>>> f0a6974... Upgrade skel.
import sphinx_py3doc_enhanced_theme
html_theme = "sphinx_py3doc_enhanced_theme"
html_theme_path = [sphinx_py3doc_enhanced_theme.get_html_theme_path()]
diff --git a/setup.cfg b/setup.cfg
index 5f6dcdf..56767aa 100644
--- a/setup.cfg
+++ b/setup.cfg
@@ -2,7 +2,7 @@
max-line-length = 140
exclude = tests/*,*/migrations/*,*/south_migrations/*
-[pytest]
+[tool:pytest]
norecursedirs =
.git
.tox
@@ -45,7 +45,9 @@ python_versions =
3.3
3.4
3.5
+ 3.6
pypy
+ pypy3
dependencies =
:Django objproxies==0.9.4 !python_versions[2.6]
: &python_versions[2.6]
@@ -58,5 +60,4 @@ environment_variables =
[egg_info]
tag_build =
... 552 lines suppressed ...
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/python-modules/packages/lazy-object-proxy.git
More information about the Python-modules-commits
mailing list