8 new commits in pytest:

https://bitbucket.org/pytest-dev/pytest/commits/8e1d89a270a7/
Changeset:   8e1d89a270a7
Branch:      pytest-2.7
User:        ionelmc
Date:        2015-04-10 18:08:50+00:00
Summary:     Add support for building proper wheels (universal and proper 
dependency evnironment markers for argparse/colorama if setuptools is new-ish).
Affected #:  2 files

diff -r 0b48b3b5156a55a09f3c27ce25beaeb156b56173 -r 
8e1d89a270a72fae6b7915afdd6f0cc5c9759fd5 setup.cfg
--- a/setup.cfg
+++ b/setup.cfg
@@ -6,3 +6,5 @@
 [upload_sphinx]
 upload-dir = doc/en/build/html
 
+[bdist_wheel]
+universal = 1

diff -r 0b48b3b5156a55a09f3c27ce25beaeb156b56173 -r 
8e1d89a270a72fae6b7915afdd6f0cc5c9759fd5 setup.py
--- a/setup.py
+++ b/setup.py
@@ -26,12 +26,25 @@
     raise ValueError("could not read version")
 
 
+def has_newish_setuptools():
+    try:
+        import setuptools
+        return tuple(int(i) for i in str(setuptools.__version__).split('.')) > 
(0, 7)
+    except Exception:
+        return False
+
+
 def main():
     install_requires = ['py>=1.4.25']
-    if sys.version_info < (2, 7) or (3,) <= sys.version_info < (3, 2):
-        install_requires.append('argparse')
-    if sys.platform == 'win32':
-        install_requires.append('colorama')
+    extras_require = {}
+    if has_newish_setuptools():
+        extras_require[':python_version=="2.6"'] = ['argparse']
+        extras_require[':sys_platform=="win32"'] = ['colorama']
+    else:
+        if sys.version_info < (2, 7) or (3,) <= sys.version_info < (3, 2):
+            install_requires.append('argparse')
+        if sys.platform == 'win32':
+            install_requires.append('colorama')
 
     setup(
         name='pytest',
@@ -48,6 +61,7 @@
         cmdclass={'test': PyTest},
         # the following should be enabled for release
         install_requires=install_requires,
+        extras_require=extras_require,
         packages=['_pytest', '_pytest.assertion'],
         py_modules=['pytest'],
         zip_safe=False,


https://bitbucket.org/pytest-dev/pytest/commits/2880968b7204/
Changeset:   2880968b7204
Branch:      pytest-2.7
User:        ionelmc
Date:        2015-04-10 18:44:27+00:00
Summary:     Improve version test (use pkg_resources to compare versions). Also 
log failures to stderr.
Affected #:  1 file

diff -r 8e1d89a270a72fae6b7915afdd6f0cc5c9759fd5 -r 
2880968b7204b390f858f9a7129d34614bacd8d3 setup.py
--- a/setup.py
+++ b/setup.py
@@ -29,8 +29,10 @@
 def has_newish_setuptools():
     try:
         import setuptools
-        return tuple(int(i) for i in str(setuptools.__version__).split('.')) > 
(0, 7)
-    except Exception:
+        import pkg_resources
+        return pkg_resources.parse_version(setuptools.__version__) >= 
pkg_resources.parse_version('0.7')
+    except Exception as exc:
+        sys.stderr.write("Could not test setuptool's version: %s\n" % exc)
         return False
 
 


https://bitbucket.org/pytest-dev/pytest/commits/20cf57bd6df5/
Changeset:   20cf57bd6df5
Branch:      pytest-2.7
User:        ionelmc
Date:        2015-04-10 18:58:59+00:00
Summary:     Test for setuptools 0.7.2, turns out there's no 0.7 release on 
pypi.
Affected #:  1 file

diff -r 2880968b7204b390f858f9a7129d34614bacd8d3 -r 
20cf57bd6df5dd62f156f60c43eb2478ea38b316 setup.py
--- a/setup.py
+++ b/setup.py
@@ -30,7 +30,7 @@
     try:
         import setuptools
         import pkg_resources
-        return pkg_resources.parse_version(setuptools.__version__) >= 
pkg_resources.parse_version('0.7')
+        return pkg_resources.parse_version(setuptools.__version__) >= 
pkg_resources.parse_version('0.7.2')
     except Exception as exc:
         sys.stderr.write("Could not test setuptool's version: %s\n" % exc)
         return False


https://bitbucket.org/pytest-dev/pytest/commits/119223095bfa/
Changeset:   119223095bfa
Branch:      pytest-2.7
User:        ionelmc
Date:        2015-04-10 18:59:47+00:00
Summary:     Make argpase a dependency for python 3.0 and 3.1 too.
Affected #:  1 file

diff -r 20cf57bd6df5dd62f156f60c43eb2478ea38b316 -r 
119223095bfaba7d5b7be672b4797fcc6f113536 setup.py
--- a/setup.py
+++ b/setup.py
@@ -40,7 +40,7 @@
     install_requires = ['py>=1.4.25']
     extras_require = {}
     if has_newish_setuptools():
-        extras_require[':python_version=="2.6"'] = ['argparse']
+        extras_require[':python_version=="2.6" or python_version=="3.0" or 
python_version=="3.1"'] = ['argparse']
         extras_require[':sys_platform=="win32"'] = ['colorama']
     else:
         if sys.version_info < (2, 7) or (3,) <= sys.version_info < (3, 2):


https://bitbucket.org/pytest-dev/pytest/commits/4851f41d56ee/
Changeset:   4851f41d56ee
Branch:      pytest-2.7
User:        ionelmc
Date:        2015-04-10 19:11:17+00:00
Summary:     Rename function and add nice docstring.
Affected #:  1 file

diff -r 119223095bfaba7d5b7be672b4797fcc6f113536 -r 
4851f41d56ee2e29da807c22154cf7f9342fa52c setup.py
--- a/setup.py
+++ b/setup.py
@@ -26,7 +26,18 @@
     raise ValueError("could not read version")
 
 
-def has_newish_setuptools():
+def has_environment_marker_support():
+    """
+    Tests that setuptools has support for PEP-426 environment marker support.
+    
+    The first known release to support it is 0.7 (and the earliest on PyPI 
seems to be 0.7.2 
+    so we're using that), see: 
http://pythonhosted.org/setuptools/history.html#id142
+    
+    References:
+    
+    * 
https://wheel.readthedocs.org/en/latest/index.html#defining-conditional-dependencies
+    * https://www.python.org/dev/peps/pep-0426/#environment-markers
+    """
     try:
         import setuptools
         import pkg_resources
@@ -39,7 +50,7 @@
 def main():
     install_requires = ['py>=1.4.25']
     extras_require = {}
-    if has_newish_setuptools():
+    if has_environment_marker_support():
         extras_require[':python_version=="2.6" or python_version=="3.0" or 
python_version=="3.1"'] = ['argparse']
         extras_require[':sys_platform=="win32"'] = ['colorama']
     else:


https://bitbucket.org/pytest-dev/pytest/commits/c8996a674862/
Changeset:   c8996a674862
Branch:      pytest-2.7
User:        flub
Date:        2015-04-12 22:36:28+00:00
Summary:     Do imports at the head of the file
Affected #:  1 file

diff -r 4851f41d56ee2e29da807c22154cf7f9342fa52c -r 
c8996a674862ac6ebfe04e89949ee2131454cacc setup.py
--- a/setup.py
+++ b/setup.py
@@ -1,4 +1,6 @@
 import os, sys
+import setuptools
+import pkg_resources
 from setuptools import setup, Command
 
 classifiers = ['Development Status :: 6 - Mature',
@@ -39,8 +41,6 @@
     * https://www.python.org/dev/peps/pep-0426/#environment-markers
     """
     try:
-        import setuptools
-        import pkg_resources
         return pkg_resources.parse_version(setuptools.__version__) >= 
pkg_resources.parse_version('0.7.2')
     except Exception as exc:
         sys.stderr.write("Could not test setuptool's version: %s\n" % exc)


https://bitbucket.org/pytest-dev/pytest/commits/88a88d3d42b0/
Changeset:   88a88d3d42b0
Branch:      pytest-2.7
User:        flub
Date:        2015-04-12 22:36:43+00:00
Summary:     Add wheel support in the changelog
Affected #:  1 file

diff -r c8996a674862ac6ebfe04e89949ee2131454cacc -r 
88a88d3d42b01da075dc8e4fcf140e15d723d880 CHANGELOG
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -8,6 +8,9 @@
 - fixed docs to remove the notion that yield-fixtures are experimental.
   They are here to stay :)  Thanks Bruno Oliveira.
 
+- Support building wheels by using environment markers for the
+  requirements.  Thanks Ionel Maries Cristian.
+
 2.7.0 (compared to 2.6.4)
 -----------------------------
 


https://bitbucket.org/pytest-dev/pytest/commits/988ffd1be9ea/
Changeset:   988ffd1be9ea
User:        flub
Date:        2015-04-12 22:47:10+00:00
Summary:     Merge wheel support from pytest-2.7 branch

Merged in pytest-2.7 (pull request #269).
Affected #:  3 files

diff -r 65a7f821cb6e582ef5b295e458dae90508e7a4c8 -r 
988ffd1be9ea48576af7ae42048ab372b7af26db CHANGELOG
--- a/CHANGELOG
+++ b/CHANGELOG
@@ -3,6 +3,9 @@
 
 
 
+- Support building wheels by using environment markers for the
+  requirements.  Thanks Ionel Maries Cristian.
+
 2.7.0 (compared to 2.6.4)
 -----------------------------
 

diff -r 65a7f821cb6e582ef5b295e458dae90508e7a4c8 -r 
988ffd1be9ea48576af7ae42048ab372b7af26db setup.cfg
--- a/setup.cfg
+++ b/setup.cfg
@@ -6,3 +6,5 @@
 [upload_sphinx]
 upload-dir = doc/en/build/html
 
+[bdist_wheel]
+universal = 1

diff -r 65a7f821cb6e582ef5b295e458dae90508e7a4c8 -r 
988ffd1be9ea48576af7ae42048ab372b7af26db setup.py
--- a/setup.py
+++ b/setup.py
@@ -1,4 +1,6 @@
 import os, sys
+import setuptools
+import pkg_resources
 from setuptools import setup, Command
 
 classifiers = ['Development Status :: 6 - Mature',
@@ -26,12 +28,36 @@
     raise ValueError("could not read version")
 
 
+def has_environment_marker_support():
+    """
+    Tests that setuptools has support for PEP-426 environment marker support.
+    
+    The first known release to support it is 0.7 (and the earliest on PyPI 
seems to be 0.7.2 
+    so we're using that), see: 
http://pythonhosted.org/setuptools/history.html#id142
+    
+    References:
+    
+    * 
https://wheel.readthedocs.org/en/latest/index.html#defining-conditional-dependencies
+    * https://www.python.org/dev/peps/pep-0426/#environment-markers
+    """
+    try:
+        return pkg_resources.parse_version(setuptools.__version__) >= 
pkg_resources.parse_version('0.7.2')
+    except Exception as exc:
+        sys.stderr.write("Could not test setuptool's version: %s\n" % exc)
+        return False
+
+
 def main():
     install_requires = ['py>=1.4.25']
-    if sys.version_info < (2, 7) or (3,) <= sys.version_info < (3, 2):
-        install_requires.append('argparse')
-    if sys.platform == 'win32':
-        install_requires.append('colorama')
+    extras_require = {}
+    if has_environment_marker_support():
+        extras_require[':python_version=="2.6" or python_version=="3.0" or 
python_version=="3.1"'] = ['argparse']
+        extras_require[':sys_platform=="win32"'] = ['colorama']
+    else:
+        if sys.version_info < (2, 7) or (3,) <= sys.version_info < (3, 2):
+            install_requires.append('argparse')
+        if sys.platform == 'win32':
+            install_requires.append('colorama')
 
     setup(
         name='pytest',
@@ -48,6 +74,7 @@
         cmdclass={'test': PyTest},
         # the following should be enabled for release
         install_requires=install_requires,
+        extras_require=extras_require,
         packages=['_pytest', '_pytest.assertion'],
         py_modules=['pytest'],
         zip_safe=False,

Repository URL: https://bitbucket.org/pytest-dev/pytest/

--

This is a commit notification from bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.
_______________________________________________
pytest-commit mailing list
pytest-commit@python.org
https://mail.python.org/mailman/listinfo/pytest-commit

Reply via email to