Hello community,

here is the log from the commit of package python-astropy-helpers for 
openSUSE:Factory checked in at 2019-04-02 09:20:43
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-astropy-helpers (Old)
 and      /work/SRC/openSUSE:Factory/.python-astropy-helpers.new.25356 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-astropy-helpers"

Tue Apr  2 09:20:43 2019 rev:4 rq:687597 version:3.1.1

Changes:
--------
--- 
/work/SRC/openSUSE:Factory/python-astropy-helpers/python-astropy-helpers.changes
    2018-12-24 11:47:52.893108038 +0100
+++ 
/work/SRC/openSUSE:Factory/.python-astropy-helpers.new.25356/python-astropy-helpers.changes
 2019-04-02 09:20:44.960624117 +0200
@@ -1,0 +2,8 @@
+Wed Mar 20 17:22:37 CET 2019 - Matej Cepl <[email protected]>
+
+- Update to 3.1.1:
+  - Moved documentation from README to Sphinx.
+  - Fixed broken OpenMP detection when building with
+    ``-coverage``.
+
+-------------------------------------------------------------------

Old:
----
  astropy-helpers-3.1.tar.gz

New:
----
  astropy-helpers-3.1.1.tar.gz

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-astropy-helpers.spec ++++++
--- /var/tmp/diff_new_pack.n6RxH6/_old  2019-04-02 09:20:45.716624826 +0200
+++ /var/tmp/diff_new_pack.n6RxH6/_new  2019-04-02 09:20:45.716624826 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package python-astropy-helpers
 #
-# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -12,21 +12,20 @@
 # license that conforms to the Open Source Definition (Version 1.9)
 # published by the Open Source Initiative.
 
-# Please submit bugfixes or comments via http://bugs.opensuse.org/
+# Please submit bugfixes or comments via https://bugs.opensuse.org/
 #
 
 
-%bcond_without tests
-
 %{?!python_module:%define python_module() python-%{**} python3-%{**}}
 %define         skip_python2 1
+%bcond_without tests
 Name:           python-astropy-helpers
-Version:        3.1
+Version:        3.1.1
 Release:        0
 Summary:        Utilities for building and installing Astropy
 License:        BSD-3-Clause
 Group:          Development/Languages/Python
-Url:            https://github.com/astropy/astropy-helpers
+URL:            https://github.com/astropy/astropy-helpers
 Source:         
https://files.pythonhosted.org/packages/source/a/astropy-helpers/astropy-helpers-%{version}.tar.gz
 Source100:      python-astropy-helpers-rpmlintrc
 BuildRequires:  %{python_module Cython}
@@ -72,8 +71,8 @@
 }
 
 %files %{python_files}
-%defattr(-,root,root,-)
-%doc README.rst LICENSE.rst CHANGES.rst
+%license LICENSE.rst
+%doc README.rst CHANGES.rst
 %{python_sitelib}/*
 
 %changelog

++++++ astropy-helpers-3.1.tar.gz -> astropy-helpers-3.1.1.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/astropy-helpers-3.1/CHANGES.rst 
new/astropy-helpers-3.1.1/CHANGES.rst
--- old/astropy-helpers-3.1/CHANGES.rst 2018-12-05 03:17:31.000000000 +0100
+++ new/astropy-helpers-3.1.1/CHANGES.rst       2019-02-23 07:39:10.000000000 
+0100
@@ -1,6 +1,15 @@
 astropy-helpers Changelog
 *************************
 
+
+3.1.1 (2019-02-22)
+------------------
+
+- Moved documentation from README to Sphinx. [#444]
+
+- Fixed broken OpenMP detection when building with ``-coverage``. [#434]
+
+
 3.1 (2018-12-04)
 ----------------
 
@@ -52,6 +61,17 @@
   with twine and get registered automatically. [#332]
 
 
+2.0.9 (2019-02-22)
+------------------
+
+- Updated bundled version of sphinx-automodapi to v0.10. [#439]
+
+- Updated bundled sphinx extensions version to sphinx-astropy v1.1.1. [#454]
+
+- Include package name in error message for Python version in
+  ``ah_bootstrap.py``. [#441]
+
+
 2.0.8 (2018-12-04)
 ------------------
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/astropy-helpers-3.1/PKG-INFO 
new/astropy-helpers-3.1.1/PKG-INFO
--- old/astropy-helpers-3.1/PKG-INFO    2018-12-05 03:20:31.000000000 +0100
+++ new/astropy-helpers-3.1.1/PKG-INFO  2019-02-23 07:39:23.000000000 +0100
@@ -1,6 +1,6 @@
-Metadata-Version: 1.2
+Metadata-Version: 2.1
 Name: astropy-helpers
-Version: 3.1
+Version: 3.1.1
 Summary: Utilities for building and installing Astropy, Astropy affiliated 
packages, and their respective documentation.
 Home-page:  https://github.com/astropy/astropy-helpers
 Author: The Astropy Developers
@@ -18,342 +18,20 @@
         .. image:: 
https://codecov.io/gh/astropy/astropy-helpers/branch/master/graph/badge.svg
           :target: https://codecov.io/gh/astropy/astropy-helpers
         
-        **Warning:** Please note that version ``v3.0`` and later of 
``astropy-helpers``
-        requires Python 3.5 or later. If you wish to maintain Python 2 support
-        for your package that uses ``astropy-helpers``, then do not upgrade the
-        helpers to ``v3.0+``. We will still provide Python 2.7 compatible
-        releases on the ``v2.0.x`` branch during the lifetime of the 
``astropy``
-        core package LTS of ``v2.0.x``.
-        
-        About
-        -----
-        
-        This project provides a Python package, ``astropy_helpers``, which 
includes
-        many build, installation, and documentation-related tools used by the 
Astropy
-        project, but packaged separately for use by other projects that wish to
-        leverage this work.  The motivation behind this package and details of 
its
-        implementation are in the accepted
+        The **astropy-helpers** package includes many build, installation, and
+        documentation-related tools used by the Astropy project, but packaged 
separately
+        for use by other projects that wish to leverage this work. The 
motivation behind
+        this package and details of its implementation are in the accepted
         `Astropy Proposal for Enhancement (APE) 4 
<https://github.com/astropy/astropy-APEs/blob/master/APE4.rst>`_.
         
-        ``astropy_helpers`` includes a special "bootstrap" module called
-        ``ah_bootstrap.py`` which is intended to be used by a project's 
setup.py in
-        order to ensure that the ``astropy_helpers`` package is available for
-        build/installation.
-        
-        As described in `APE4 
<https://github.com/astropy/astropy-APEs/blob/master/APE4.rst>`_, the version
-        numbers for ``astropy_helpers`` follow the corresponding major/minor 
version of
-        the `astropy core package <http://www.astropy.org/>`_, but with an 
independent
-        sequence of micro (bugfix) version numbers. Hence, the initial release 
is 0.4,
-        in parallel with Astropy v0.4, which will be the first version  of 
Astropy to
-        use ``astropy-helpers``.
-        
-        For examples of how to implement ``astropy-helpers`` in a project,
-        see the ``setup.py`` and ``setup.cfg`` files of the
+        Astropy-helpers is not a traditional package in the sense that it is 
not
+        intended to be installed directly by users or developers. Instead, it 
is meant
+        to be accessed when the ``setup.py`` command is run - see :doc:`using` 
for how
+        to do this. For a real-life example of how to implement 
astropy-helpers in a
+        project, see the ``setup.py`` and ``setup.cfg`` files of the
         `Affiliated package template 
<https://github.com/astropy/package-template>`_.
         
-        What does astropy-helpers provide?
-        ----------------------------------
-        
-        Astropy-helpers' big-picture purpose is to provide customization to 
Python's
-        packaging infrastructure process in ways that the Astropy Project has 
found to
-        help simplifying the developint and releasing packages. This is 
primarily
-        build around ``setup.py`` commands, as outlined below, as well as code 
to help
-        manage version numbers and better control the build process of larger 
packages.
-        
-        Custom setup.py commands
-        ^^^^^^^^^^^^^^^^^^^^^^^^
-        
-        The main part of astropy-helpers is to provide customized setuptools 
commands.
-        For example, in a package that uses astropy-helpers, the following 
command
-        will be available::
-        
-            python setup.py build_docs
-        
-        and this command is implemented in astropy-helpers. To use the custom
-        commands described here, add::
-        
-            from astropy_helpers.setup_helpers import register_commands
-        
-        to your ``setup.py`` file, then do::
-        
-            cmdclassd = register_commands(NAME, VERSION, RELEASE)
-        
-        where ``NAME`` is the name of your package, ``VERSION`` is the full 
version
-        string, and ``RELEASE`` is a boolean value indicating whether the 
version is
-        a stable released version (``True``) or a developer version 
(``False``).
-        Finally, pass ``cmdclassd`` to the ``setup`` function::
-        
-             setup(...,
-                   cmdclass=cmdclassd)
-        
-        The commands we provide or customize are:
-        
-        **python setup.py test**
-        
-        This command will automatically build the package, install it to a 
temporary
-        directory, and run the tests using `pytest <http://pytest.org/>`_ on 
this
-        installed version. Note that the bulk of this command is actually 
defined
-        in ``astropy.tests.command.AstropyTest``, because that allows the test
-        machinery to operate outside a setuptools command. This, here we
-        simply define the custom
-        setuptools command.
-        
-        **python setup.py sdist**
-        
-        We redefine ``sdist`` to use the version from distutils rather than 
from
-        setuptools, as the setuptools version requires duplication of 
information
-        in ``MANIFEST.in``.
-        
-        **python setup.py build_docs**
-        
-        This command will automatically build the package, then run sphinx to 
build
-        the documentation. This makes development much easier because it 
ensures
-        sphinx extensions that use the package's  code to make documentation 
are
-        actually using the in-development version of the code. Sphinx itself
-        provides a custom setuptools command, which we
-        expand with the following options:
-        
-        * ``-w``: set the return code to 1 if there are any warnings during 
the build
-          process.
-        
-        * ``-l``: completely clean previous builds, including files generated 
by
-          the sphinx-automodapi package (which creates API pages for different
-          functions/classes).
-        
-        * ``-n``: disable the intersphinx option.
-        
-        * ``-o``: open the documentation in a browser if a build finishes 
successfully.
-        
-        In addition, ``build_docs`` will automatically download and 
temporarily install
-        sphinx-astropy (which is a meta-package that
-        provides standardized configuration and documentation dependencies for 
astropy
-        packages) if it isn't already installed. Temporary installation means 
that the
-        package will be installed into an ``.eggs`` directory in the current 
working
-        directory, and it will only be available for the duration of the call 
to
-        ``build_docs``.
-        
-        **python setup.py build_ext**
-        
-        This is also used when running ``build`` or ``install``. We add 
several features
-        compared to the default ``build_ext`` command:
-        
-        * For packages with C/Cython extensions, we create a 
``packagename._compiler``
-          submodule that contains information about the compilers used.
-        
-        * Packages that need to build C extensions using the Numpy C API, we 
allow
-          those packages to define the include path as ``'numpy'`` as opposed 
to having
-          to import Numpy and call ``get_include``. The goal is to solve the 
issue that
-          if one has to import Numpy to define extensions, then Numpy has to be
-          installed/available before the package is installed, which means 
that one
-          needs to install Numpy in a separate installation step.
-        
-        * We detect broken compilers and replace them with other compilers 
on-the-fly
-          unless the compiler is explicitly specified with the ``CC`` 
environment
-          variable.
-        
-        * If Cython is not installed, then we automatically check for 
generated C files
-          (which are normally present in the stable releases) and give a nice 
error
-          if these are not found.
-        
-        Version helpers
-        ^^^^^^^^^^^^^^^^
-        
-        Another piece of functionality we provide in astropy-helpers is the 
ability
-        to generate a ``packagename.version`` file that includes functions that
-        automatically set the version string for developer versions, to e.g.
-        ``3.2.dev22213`` so that each developer version has a unique number 
(although
-        note that branches an equal number of commits away from the master 
branch will
-        share the same version number). To use this, import::
-        
-            from astropy_helpers.git_helpers import get_git_devstr
-        
-        in your ``setup.py`` file, and you will then be able to use::
-        
-            VERSION += get_git_devstr()
-        
-        where ``VERSION`` is a version string without any developer version 
suffix.
-        
-        We then also provide a function that generates a ``version.py`` file 
inside your
-        package (which can then be imported as ``packagename.version``) that 
contains
-        variables such as ``major``, ``minor``, and ``bugfix``, as well as
-        ``version_info`` (a tuple of the previous three values), a ``release`` 
flag that
-        indicates whether we are using a stable release, and several other 
complementary
-        variables. To use this, import::
-        
-            from astropy_helpers.version_helpers import generate_version_py
-        
-        in your ``setup.py`` file, and call::
-        
-            generate_version_py(NAME, VERSION, RELEASE, uses_git=not RELEASE)
-        
-        where ``NAME`` is the name of your package, ``VERSION`` is the full 
version string
-        (including any developer suffix), ``RELEASE`` indicates whether the 
version is a
-        stable or developer version, and ``uses_git`` indicates whether we are 
in a git
-        repository (using ``not RELEASE`` is sensible since git is not 
available in a
-        stable release).
-        
-        Collecting package information
-        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-        
-        The ``setup`` function from setuptools can take a number of options 
that indicate
-        for example what extensions to build, and what package data to 
include. However,
-        for large packages this can become cumbersome. We therefore provide a 
mechanism
-        for defining extensions and package data inside individual 
sub-packages. To do
-        this, you can create ``setup_package.py`` files anywhere in your 
package, and
-        these files can include one or more of the following functions:
-        
-        * ``get_package_data``:
-            This function, if defined, should return a dictionary mapping the 
name of
-            the subpackage(s) that need package data to a list of data file 
paths
-            (possibly including wildcards) relative to the path of the 
package's source
-            code.  e.g. if the source distribution has a needed data file
-            ``astropy/wcs/tests/data/3d_cd.hdr``, this function should return
-            ``{'astropy.wcs.tests':['data/3d_cd.hdr']}``. See the 
``package_data``
-            option of the  :func:`distutils.core.setup` function.
-        
-            It is recommended that all such data be in a directory named 
``data`` inside
-            the package within which it is supposed to be used.  This package 
data
-            should be accessed via the 
``astropy.utils.data.get_pkg_data_filename`` and
-            ``astropy.utils.data.get_pkg_data_fileobj`` functions.
-        
-        * ``get_extensions``:
-            This provides information for building C or Cython extensions. If 
defined,
-            it should return a list of ``distutils.core.Extension`` objects.
-        
-        * ``get_build_options``:
-            This function allows a package to add extra build options.  It
-            should return a list of tuples, where each element has:
-        
-            - *name*: The name of the option as it would appear on the
-              commandline or in the ``setup.cfg`` file.
-        
-            - *doc*: A short doc string for the option, displayed by
-              ``setup.py build --help``.
-        
-            - *is_bool* (optional): When `True`, the option is a boolean
-              option and doesn't have an associated value.
-        
-            Once an option has been added, its value can be looked up using
-            ``astropy_helpers.setup_helpers.get_distutils_build_option``.
-        
-        * ``get_external_libraries``:
-            This function declares that the package uses libraries that are
-            included in the astropy distribution that may also be distributed
-            elsewhere on the users system.  It should return a list of library
-            names.  For each library, a new build option is created,
-            ``'--use-system-X'`` which allows the user to request to use the
-            system's copy of the library.  The package would typically call
-            ``astropy_helpers.setup_helpers.use_system_library`` from its
-            ``get_extensions`` function to determine if the package should use
-            the system library or the included one.
-        
-        * ``get_entry_points()``:
-            This function can returns a dict formatted as required by
-            the ``entry_points`` argument to ``setup()``.
-        
-        With these files in place, you can then add the following to your 
``setup.py``
-        file::
-        
-            from astropy_helpers.setup_helpers import get_package_info
-        
-            ...
-        
-            package_info = get_package_info()
-        
-            ...
-        
-            setup(..., **package_info)
-        
-        OpenMP helpers
-        ^^^^^^^^^^^^^^
-        
-        We provide a helper function ``add_openmp_flags_if_available`` that 
can be used
-        to automatically add OpenMP flags for C/Cython extensions, based on 
whether
-        OpenMP is available and produces executable code. To use this, edit the
-        ``setup_package.py`` file where you define a C extension, import the 
helper
-        function::
-        
-            from astropy_helpers.openmp_helpers import 
add_openmp_flags_if_available
-        
-        then once you have defined the extension and before returning it, use 
it as::
-        
-            extension = Extension(...)
-        
-            add_openmp_flags_if_available(extension)
-        
-            return [extension]
-        
-        Using astropy-helpers
-        ---------------------
-        
-        The easiest way to get set up with astropy-helpers in a new package is 
to use
-        the `package-template 
<http://docs.astropy.org/projects/package-template>`_
-        that we provide. This template is specifically designed for use with 
the helpers,
-        so using it avoids some of the tedium of setting up the heleprs.
-        
-        However, we now go through the steps of adding astropy-helpers
-        as a submodule to a package in case you wish to do so manually. First, 
add
-        astropy-helpers as a submodule at the root of your repository::
-        
-            git submodule add git://github.com/astropy/astropy-helpers 
astropy_helpers
-        
-        Then go inside the submodule and check out a stable version of 
astropy-helpers.
-        You can see the available versions by running::
-        
-            $ cd astropy_helpers
-            $ git tag
-            ...
-            v2.0.6
-            v2.0.7
-            ...
-            v3.0.1
-            v3.0.2
-        
-        If you want to support Python 2, pick the latest v2.0.x version (in 
the above
-        case ``v2.0.7``) and if you don't need to support Python 2, just pick 
the latest
-        stable version (in the above case ``v3.0.2``). Check out this version 
with e.g.::
-        
-            $ git checkout v3.0.2
-        
-        Then go back up to the root of your repository and copy the 
``ah_bootstrap.py``
-        file from the submodule to the root of your repository::
-        
-            $ cd ..
-            $ cp astropy_helpers/ah_bootstrap.py .
-        
-        Finally, add::
-        
-            import ah_bootstrap
-        
-        at the top of your ``setup.py`` file. This will ensure that 
``astropy_helpers``
-        is now available to use in your ``setup.py`` file. Finally, add then 
commit your
-        changes::
-        
-            git add astropy_helpers ah_bootstrap.py setup.py
-            git commit -m "Added astropy-helpers"
-        
-        Updating astropy-helpers
-        ------------------------
-        
-        If you would like the Astropy team to automatically open pull requests 
to update
-        astropy-helpers in your package, then see the instructions `here
-        
<https://github.com/astropy/astropy-procedures/blob/master/update-packages/README.md>`_.
-        
-        To instead update astropy-helpers manually, go inside the submodule 
and do::
-        
-            cd astropy_helpers
-            git fetch origin
-        
-        Then checkout the version you want to use, e.g.::
-        
-            git checkout v3.0.3
-        
-        Go back up to the root of the repository and update the 
``ah_bootstap.py`` file
-        too, then add your changes::
-        
-            cp astropy_helpers/ah_bootstrap.py .
-            git add astropy_helpers ah_bootstrap.py
-            git commit ...
+        For more information, see the documentation at 
http://astropy-helpers.readthedocs.io
         
 Platform: UNKNOWN
 Classifier: Development Status :: 5 - Production/Stable
@@ -369,3 +47,4 @@
 Classifier: Topic :: Software Development :: Libraries :: Python Modules
 Classifier: Topic :: System :: Archiving :: Packaging
 Requires-Python: >=3.5
+Provides-Extra: docs
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/astropy-helpers-3.1/README.rst 
new/astropy-helpers-3.1.1/README.rst
--- old/astropy-helpers-3.1/README.rst  2018-12-05 03:10:37.000000000 +0100
+++ new/astropy-helpers-3.1.1/README.rst        2019-02-23 07:39:10.000000000 
+0100
@@ -10,339 +10,17 @@
 .. image:: 
https://codecov.io/gh/astropy/astropy-helpers/branch/master/graph/badge.svg
   :target: https://codecov.io/gh/astropy/astropy-helpers
 
-**Warning:** Please note that version ``v3.0`` and later of ``astropy-helpers``
-requires Python 3.5 or later. If you wish to maintain Python 2 support
-for your package that uses ``astropy-helpers``, then do not upgrade the
-helpers to ``v3.0+``. We will still provide Python 2.7 compatible
-releases on the ``v2.0.x`` branch during the lifetime of the ``astropy``
-core package LTS of ``v2.0.x``.
-
-About
------
-
-This project provides a Python package, ``astropy_helpers``, which includes
-many build, installation, and documentation-related tools used by the Astropy
-project, but packaged separately for use by other projects that wish to
-leverage this work.  The motivation behind this package and details of its
-implementation are in the accepted
+The **astropy-helpers** package includes many build, installation, and
+documentation-related tools used by the Astropy project, but packaged 
separately
+for use by other projects that wish to leverage this work. The motivation 
behind
+this package and details of its implementation are in the accepted
 `Astropy Proposal for Enhancement (APE) 4 
<https://github.com/astropy/astropy-APEs/blob/master/APE4.rst>`_.
 
-``astropy_helpers`` includes a special "bootstrap" module called
-``ah_bootstrap.py`` which is intended to be used by a project's setup.py in
-order to ensure that the ``astropy_helpers`` package is available for
-build/installation.
-
-As described in `APE4 
<https://github.com/astropy/astropy-APEs/blob/master/APE4.rst>`_, the version
-numbers for ``astropy_helpers`` follow the corresponding major/minor version of
-the `astropy core package <http://www.astropy.org/>`_, but with an independent
-sequence of micro (bugfix) version numbers. Hence, the initial release is 0.4,
-in parallel with Astropy v0.4, which will be the first version  of Astropy to
-use ``astropy-helpers``.
-
-For examples of how to implement ``astropy-helpers`` in a project,
-see the ``setup.py`` and ``setup.cfg`` files of the
+Astropy-helpers is not a traditional package in the sense that it is not
+intended to be installed directly by users or developers. Instead, it is meant
+to be accessed when the ``setup.py`` command is run - see :doc:`using` for how
+to do this. For a real-life example of how to implement astropy-helpers in a
+project, see the ``setup.py`` and ``setup.cfg`` files of the
 `Affiliated package template <https://github.com/astropy/package-template>`_.
 
-What does astropy-helpers provide?
-----------------------------------
-
-Astropy-helpers' big-picture purpose is to provide customization to Python's
-packaging infrastructure process in ways that the Astropy Project has found to
-help simplifying the developint and releasing packages. This is primarily
-build around ``setup.py`` commands, as outlined below, as well as code to help
-manage version numbers and better control the build process of larger packages.
-
-Custom setup.py commands
-^^^^^^^^^^^^^^^^^^^^^^^^
-
-The main part of astropy-helpers is to provide customized setuptools commands.
-For example, in a package that uses astropy-helpers, the following command
-will be available::
-
-    python setup.py build_docs
-
-and this command is implemented in astropy-helpers. To use the custom
-commands described here, add::
-
-    from astropy_helpers.setup_helpers import register_commands
-
-to your ``setup.py`` file, then do::
-
-    cmdclassd = register_commands(NAME, VERSION, RELEASE)
-
-where ``NAME`` is the name of your package, ``VERSION`` is the full version
-string, and ``RELEASE`` is a boolean value indicating whether the version is
-a stable released version (``True``) or a developer version (``False``).
-Finally, pass ``cmdclassd`` to the ``setup`` function::
-
-     setup(...,
-           cmdclass=cmdclassd)
-
-The commands we provide or customize are:
-
-**python setup.py test**
-
-This command will automatically build the package, install it to a temporary
-directory, and run the tests using `pytest <http://pytest.org/>`_ on this
-installed version. Note that the bulk of this command is actually defined
-in ``astropy.tests.command.AstropyTest``, because that allows the test
-machinery to operate outside a setuptools command. This, here we
-simply define the custom
-setuptools command.
-
-**python setup.py sdist**
-
-We redefine ``sdist`` to use the version from distutils rather than from
-setuptools, as the setuptools version requires duplication of information
-in ``MANIFEST.in``.
-
-**python setup.py build_docs**
-
-This command will automatically build the package, then run sphinx to build
-the documentation. This makes development much easier because it ensures
-sphinx extensions that use the package's  code to make documentation are
-actually using the in-development version of the code. Sphinx itself
-provides a custom setuptools command, which we
-expand with the following options:
-
-* ``-w``: set the return code to 1 if there are any warnings during the build
-  process.
-
-* ``-l``: completely clean previous builds, including files generated by
-  the sphinx-automodapi package (which creates API pages for different
-  functions/classes).
-
-* ``-n``: disable the intersphinx option.
-
-* ``-o``: open the documentation in a browser if a build finishes successfully.
-
-In addition, ``build_docs`` will automatically download and temporarily install
-sphinx-astropy (which is a meta-package that
-provides standardized configuration and documentation dependencies for astropy
-packages) if it isn't already installed. Temporary installation means that the
-package will be installed into an ``.eggs`` directory in the current working
-directory, and it will only be available for the duration of the call to
-``build_docs``.
-
-**python setup.py build_ext**
-
-This is also used when running ``build`` or ``install``. We add several 
features
-compared to the default ``build_ext`` command:
-
-* For packages with C/Cython extensions, we create a ``packagename._compiler``
-  submodule that contains information about the compilers used.
-
-* Packages that need to build C extensions using the Numpy C API, we allow
-  those packages to define the include path as ``'numpy'`` as opposed to having
-  to import Numpy and call ``get_include``. The goal is to solve the issue that
-  if one has to import Numpy to define extensions, then Numpy has to be
-  installed/available before the package is installed, which means that one
-  needs to install Numpy in a separate installation step.
-
-* We detect broken compilers and replace them with other compilers on-the-fly
-  unless the compiler is explicitly specified with the ``CC`` environment
-  variable.
-
-* If Cython is not installed, then we automatically check for generated C files
-  (which are normally present in the stable releases) and give a nice error
-  if these are not found.
-
-Version helpers
-^^^^^^^^^^^^^^^^
-
-Another piece of functionality we provide in astropy-helpers is the ability
-to generate a ``packagename.version`` file that includes functions that
-automatically set the version string for developer versions, to e.g.
-``3.2.dev22213`` so that each developer version has a unique number (although
-note that branches an equal number of commits away from the master branch will
-share the same version number). To use this, import::
-
-    from astropy_helpers.git_helpers import get_git_devstr
-
-in your ``setup.py`` file, and you will then be able to use::
-
-    VERSION += get_git_devstr()
-
-where ``VERSION`` is a version string without any developer version suffix.
-
-We then also provide a function that generates a ``version.py`` file inside 
your
-package (which can then be imported as ``packagename.version``) that contains
-variables such as ``major``, ``minor``, and ``bugfix``, as well as
-``version_info`` (a tuple of the previous three values), a ``release`` flag 
that
-indicates whether we are using a stable release, and several other 
complementary
-variables. To use this, import::
-
-    from astropy_helpers.version_helpers import generate_version_py
-
-in your ``setup.py`` file, and call::
-
-    generate_version_py(NAME, VERSION, RELEASE, uses_git=not RELEASE)
-
-where ``NAME`` is the name of your package, ``VERSION`` is the full version 
string
-(including any developer suffix), ``RELEASE`` indicates whether the version is 
a
-stable or developer version, and ``uses_git`` indicates whether we are in a git
-repository (using ``not RELEASE`` is sensible since git is not available in a
-stable release).
-
-Collecting package information
-^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-The ``setup`` function from setuptools can take a number of options that 
indicate
-for example what extensions to build, and what package data to include. 
However,
-for large packages this can become cumbersome. We therefore provide a mechanism
-for defining extensions and package data inside individual sub-packages. To do
-this, you can create ``setup_package.py`` files anywhere in your package, and
-these files can include one or more of the following functions:
-
-* ``get_package_data``:
-    This function, if defined, should return a dictionary mapping the name of
-    the subpackage(s) that need package data to a list of data file paths
-    (possibly including wildcards) relative to the path of the package's source
-    code.  e.g. if the source distribution has a needed data file
-    ``astropy/wcs/tests/data/3d_cd.hdr``, this function should return
-    ``{'astropy.wcs.tests':['data/3d_cd.hdr']}``. See the ``package_data``
-    option of the  :func:`distutils.core.setup` function.
-
-    It is recommended that all such data be in a directory named ``data`` 
inside
-    the package within which it is supposed to be used.  This package data
-    should be accessed via the ``astropy.utils.data.get_pkg_data_filename`` and
-    ``astropy.utils.data.get_pkg_data_fileobj`` functions.
-
-* ``get_extensions``:
-    This provides information for building C or Cython extensions. If defined,
-    it should return a list of ``distutils.core.Extension`` objects.
-
-* ``get_build_options``:
-    This function allows a package to add extra build options.  It
-    should return a list of tuples, where each element has:
-
-    - *name*: The name of the option as it would appear on the
-      commandline or in the ``setup.cfg`` file.
-
-    - *doc*: A short doc string for the option, displayed by
-      ``setup.py build --help``.
-
-    - *is_bool* (optional): When `True`, the option is a boolean
-      option and doesn't have an associated value.
-
-    Once an option has been added, its value can be looked up using
-    ``astropy_helpers.setup_helpers.get_distutils_build_option``.
-
-* ``get_external_libraries``:
-    This function declares that the package uses libraries that are
-    included in the astropy distribution that may also be distributed
-    elsewhere on the users system.  It should return a list of library
-    names.  For each library, a new build option is created,
-    ``'--use-system-X'`` which allows the user to request to use the
-    system's copy of the library.  The package would typically call
-    ``astropy_helpers.setup_helpers.use_system_library`` from its
-    ``get_extensions`` function to determine if the package should use
-    the system library or the included one.
-
-* ``get_entry_points()``:
-    This function can returns a dict formatted as required by
-    the ``entry_points`` argument to ``setup()``.
-
-With these files in place, you can then add the following to your ``setup.py``
-file::
-
-    from astropy_helpers.setup_helpers import get_package_info
-
-    ...
-
-    package_info = get_package_info()
-
-    ...
-
-    setup(..., **package_info)
-
-OpenMP helpers
-^^^^^^^^^^^^^^
-
-We provide a helper function ``add_openmp_flags_if_available`` that can be used
-to automatically add OpenMP flags for C/Cython extensions, based on whether
-OpenMP is available and produces executable code. To use this, edit the
-``setup_package.py`` file where you define a C extension, import the helper
-function::
-
-    from astropy_helpers.openmp_helpers import add_openmp_flags_if_available
-
-then once you have defined the extension and before returning it, use it as::
-
-    extension = Extension(...)
-
-    add_openmp_flags_if_available(extension)
-
-    return [extension]
-
-Using astropy-helpers
----------------------
-
-The easiest way to get set up with astropy-helpers in a new package is to use
-the `package-template <http://docs.astropy.org/projects/package-template>`_
-that we provide. This template is specifically designed for use with the 
helpers,
-so using it avoids some of the tedium of setting up the heleprs.
-
-However, we now go through the steps of adding astropy-helpers
-as a submodule to a package in case you wish to do so manually. First, add
-astropy-helpers as a submodule at the root of your repository::
-
-    git submodule add git://github.com/astropy/astropy-helpers astropy_helpers
-
-Then go inside the submodule and check out a stable version of astropy-helpers.
-You can see the available versions by running::
-
-    $ cd astropy_helpers
-    $ git tag
-    ...
-    v2.0.6
-    v2.0.7
-    ...
-    v3.0.1
-    v3.0.2
-
-If you want to support Python 2, pick the latest v2.0.x version (in the above
-case ``v2.0.7``) and if you don't need to support Python 2, just pick the 
latest
-stable version (in the above case ``v3.0.2``). Check out this version with 
e.g.::
-
-    $ git checkout v3.0.2
-
-Then go back up to the root of your repository and copy the ``ah_bootstrap.py``
-file from the submodule to the root of your repository::
-
-    $ cd ..
-    $ cp astropy_helpers/ah_bootstrap.py .
-
-Finally, add::
-
-    import ah_bootstrap
-
-at the top of your ``setup.py`` file. This will ensure that ``astropy_helpers``
-is now available to use in your ``setup.py`` file. Finally, add then commit 
your
-changes::
-
-    git add astropy_helpers ah_bootstrap.py setup.py
-    git commit -m "Added astropy-helpers"
-
-Updating astropy-helpers
-------------------------
-
-If you would like the Astropy team to automatically open pull requests to 
update
-astropy-helpers in your package, then see the instructions `here
-<https://github.com/astropy/astropy-procedures/blob/master/update-packages/README.md>`_.
-
-To instead update astropy-helpers manually, go inside the submodule and do::
-
-    cd astropy_helpers
-    git fetch origin
-
-Then checkout the version you want to use, e.g.::
-
-    git checkout v3.0.3
-
-Go back up to the root of the repository and update the ``ah_bootstap.py`` file
-too, then add your changes::
-
-    cp astropy_helpers/ah_bootstrap.py .
-    git add astropy_helpers ah_bootstrap.py
-    git commit ...
+For more information, see the documentation at 
http://astropy-helpers.readthedocs.io
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/astropy-helpers-3.1/ah_bootstrap.py 
new/astropy-helpers-3.1.1/ah_bootstrap.py
--- old/astropy-helpers-3.1/ah_bootstrap.py     2018-12-05 03:10:37.000000000 
+0100
+++ new/astropy-helpers-3.1.1/ah_bootstrap.py   2019-02-23 07:39:10.000000000 
+0100
@@ -45,18 +45,99 @@
 import subprocess as sp
 import sys
 
-__minimum_python_version__ = (3, 5)
-
-if sys.version_info < __minimum_python_version__:
-    print("ERROR: Python {} or later is required by astropy-helpers".format(
-        __minimum_python_version__))
-    sys.exit(1)
+from distutils import log
+from distutils.debug import DEBUG
 
 try:
     from ConfigParser import ConfigParser, RawConfigParser
 except ImportError:
     from configparser import ConfigParser, RawConfigParser
 
+import pkg_resources
+
+from setuptools import Distribution
+from setuptools.package_index import PackageIndex
+
+# This is the minimum Python version required for astropy-helpers
+__minimum_python_version__ = (3, 5)
+
+# TODO: Maybe enable checking for a specific version of astropy_helpers?
+DIST_NAME = 'astropy-helpers'
+PACKAGE_NAME = 'astropy_helpers'
+UPPER_VERSION_EXCLUSIVE = None
+
+# Defaults for other options
+DOWNLOAD_IF_NEEDED = True
+INDEX_URL = 'https://pypi.python.org/simple'
+USE_GIT = True
+OFFLINE = False
+AUTO_UPGRADE = True
+
+# A list of all the configuration options and their required types
+CFG_OPTIONS = [
+    ('auto_use', bool), ('path', str), ('download_if_needed', bool),
+    ('index_url', str), ('use_git', bool), ('offline', bool),
+    ('auto_upgrade', bool)
+]
+
+# Start off by parsing the setup.cfg file
+
+SETUP_CFG = ConfigParser()
+
+if os.path.exists('setup.cfg'):
+
+    try:
+        SETUP_CFG.read('setup.cfg')
+    except Exception as e:
+        if DEBUG:
+            raise
+
+        log.error(
+            "Error reading setup.cfg: {0!r}\n{1} will not be "
+            "automatically bootstrapped and package installation may fail."
+            "\n{2}".format(e, PACKAGE_NAME, _err_help_msg))
+
+# We used package_name in the package template for a while instead of name
+if SETUP_CFG.has_option('metadata', 'name'):
+    parent_package = SETUP_CFG.get('metadata', 'name')
+elif SETUP_CFG.has_option('metadata', 'package_name'):
+    parent_package = SETUP_CFG.get('metadata', 'package_name')
+else:
+    parent_package = None
+
+if SETUP_CFG.has_option('options', 'python_requires'):
+
+    python_requires = SETUP_CFG.get('options', 'python_requires')
+
+    # The python_requires key has a syntax that can be parsed by SpecifierSet
+    # in the packaging package. However, we don't want to have to depend on 
that
+    # package, so instead we can use setuptools (which bundles packaging). We
+    # have to add 'python' to parse it with Requirement.
+
+    from pkg_resources import Requirement
+    req = Requirement.parse('python' + python_requires)
+
+    # We want the Python version as a string, which we can get from the 
platform module
+    import platform
+    python_version = platform.python_version()
+
+    if not req.specifier.contains(python_version):
+        if parent_package is None:
+            print("ERROR: Python {} is required by this 
package".format(req.specifier))
+        else:
+            print("ERROR: Python {} is required by {}".format(req.specifier, 
parent_package))
+        sys.exit(1)
+
+if sys.version_info < __minimum_python_version__:
+
+    if parent_package is None:
+        print("ERROR: Python {} or later is required by 
astropy-helpers".format(
+            __minimum_python_version__))
+    else:
+        print("ERROR: Python {} or later is required by astropy-helpers for 
{}".format(
+            __minimum_python_version__, parent_package))
+
+    sys.exit(1)
 
 _str_types = (str, bytes)
 
@@ -116,36 +197,6 @@
 # End compatibility imports...
 
 
-# In case it didn't successfully import before the ez_setup checks
-import pkg_resources
-
-from setuptools import Distribution
-from setuptools.package_index import PackageIndex
-
-from distutils import log
-from distutils.debug import DEBUG
-
-
-# TODO: Maybe enable checking for a specific version of astropy_helpers?
-DIST_NAME = 'astropy-helpers'
-PACKAGE_NAME = 'astropy_helpers'
-UPPER_VERSION_EXCLUSIVE = None
-
-# Defaults for other options
-DOWNLOAD_IF_NEEDED = True
-INDEX_URL = 'https://pypi.python.org/simple'
-USE_GIT = True
-OFFLINE = False
-AUTO_UPGRADE = True
-
-# A list of all the configuration options and their required types
-CFG_OPTIONS = [
-    ('auto_use', bool), ('path', str), ('download_if_needed', bool),
-    ('index_url', str), ('use_git', bool), ('offline', bool),
-    ('auto_upgrade', bool)
-]
-
-
 class _Bootstrapper(object):
     """
     Bootstrapper implementation.  See ``use_astropy_helpers`` for parameter
@@ -215,36 +266,20 @@
 
     @classmethod
     def parse_config(cls):
-        if not os.path.exists('setup.cfg'):
-            return {}
-
-        cfg = ConfigParser()
-
-        try:
-            cfg.read('setup.cfg')
-        except Exception as e:
-            if DEBUG:
-                raise
-
-            log.error(
-                "Error reading setup.cfg: {0!r}\n{1} will not be "
-                "automatically bootstrapped and package installation may fail."
-                "\n{2}".format(e, PACKAGE_NAME, _err_help_msg))
-            return {}
 
-        if not cfg.has_section('ah_bootstrap'):
+        if not SETUP_CFG.has_section('ah_bootstrap'):
             return {}
 
         config = {}
 
         for option, type_ in CFG_OPTIONS:
-            if not cfg.has_option('ah_bootstrap', option):
+            if not SETUP_CFG.has_option('ah_bootstrap', option):
                 continue
 
             if type_ is bool:
-                value = cfg.getboolean('ah_bootstrap', option)
+                value = SETUP_CFG.getboolean('ah_bootstrap', option)
             else:
-                value = cfg.get('ah_bootstrap', option)
+                value = SETUP_CFG.get('ah_bootstrap', option)
 
             config[option] = value
 
@@ -633,8 +668,8 @@
         # only if the submodule is initialized.  We ignore this information for
         # now
         _git_submodule_status_re = re.compile(
-            '^(?P<status>[+-U ])(?P<commit>[0-9a-f]{40}) '
-            '(?P<submodule>\S+)( .*)?$')
+            r'^(?P<status>[+-U ])(?P<commit>[0-9a-f]{40}) '
+            r'(?P<submodule>\S+)( .*)?$')
 
         # The stdout should only contain one line--the status of the
         # requested submodule
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/astropy-helpers-3.1/astropy_helpers/git_helpers.py 
new/astropy-helpers-3.1.1/astropy_helpers/git_helpers.py
--- old/astropy-helpers-3.1/astropy_helpers/git_helpers.py      2018-05-17 
01:33:24.000000000 +0200
+++ new/astropy-helpers-3.1.1/astropy_helpers/git_helpers.py    2019-02-23 
07:39:10.000000000 +0100
@@ -15,6 +15,8 @@
 import subprocess
 import warnings
 
+__all__ = ['get_git_devstr']
+
 
 def _decode_stdio(stream):
     try:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/astropy-helpers-3.1/astropy_helpers/openmp_helpers.py 
new/astropy-helpers-3.1.1/astropy_helpers/openmp_helpers.py
--- old/astropy-helpers-3.1/astropy_helpers/openmp_helpers.py   2018-12-05 
03:10:37.000000000 +0100
+++ new/astropy-helpers-3.1.1/astropy_helpers/openmp_helpers.py 2019-02-23 
07:39:10.000000000 +0100
@@ -26,7 +26,7 @@
 from distutils.sysconfig import customize_compiler, get_config_var
 from distutils.errors import CompileError, LinkError
 
-from .setup_helpers import get_compiler_option
+from .distutils_helpers import get_compiler_option
 
 __all__ = ['add_openmp_flags_if_available']
 
@@ -176,6 +176,11 @@
     compile_flags = openmp_flags.get('compiler_flags')
     link_flags = openmp_flags.get('linker_flags')
 
+    # Pass -coverage flag to linker.
+    # https://github.com/astropy/astropy-helpers/pull/374
+    if '-coverage' in compile_flags and '-coverage' not in link_flags:
+        link_flags.append('-coverage')
+
     tmp_dir = tempfile.mkdtemp()
     start_dir = os.path.abspath('.')
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/astropy-helpers-3.1/astropy_helpers/setup_helpers.py 
new/astropy-helpers-3.1.1/astropy_helpers/setup_helpers.py
--- old/astropy-helpers-3.1/astropy_helpers/setup_helpers.py    2018-12-05 
03:10:37.000000000 +0100
+++ new/astropy-helpers-3.1.1/astropy_helpers/setup_helpers.py  2019-02-23 
07:39:10.000000000 +0100
@@ -37,6 +37,8 @@
 from .utils import get_numpy_include_path, write_if_different  # noqa
 from .commands.build_ext import should_build_with_cython, get_compiler_version 
 # noqa
 
+__all__ = ['register_commands', 'get_package_info']
+
 _module_state = {'registered_commands': None,
                  'have_sphinx': False,
                  'package_cache': None,
@@ -344,9 +346,6 @@
     - ``get_external_libraries()`` returns
       a list of libraries that can optionally be built using external
       dependencies.
-
-    - ``get_entry_points()`` returns a dict formatted as required by
-      the ``entry_points`` argument to ``setup()``.
     """
     ext_modules = []
     packages = []
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/astropy-helpers-3.1/astropy_helpers/version.py 
new/astropy-helpers-3.1.1/astropy_helpers/version.py
--- old/astropy-helpers-3.1/astropy_helpers/version.py  2018-12-05 
03:20:30.000000000 +0100
+++ new/astropy-helpers-3.1.1/astropy_helpers/version.py        2019-02-23 
07:39:22.000000000 +0100
@@ -1,19 +1,19 @@
-# Autogenerated by Astropy-affiliated package astropy_helpers's setup.py on 
2018-12-05 02:20:30 UTC
+# Autogenerated by Astropy-affiliated package astropy_helpers's setup.py on 
2019-02-23 06:39:22 UTC
 from __future__ import unicode_literals
 import datetime
 
-version = "3.1"
-githash = "9f82aac6c2141b425e2d639560f7260189d90b54"
+version = "3.1.1"
+githash = "79c3c01af3c436963f275e0f9e7dd3ac0625d70d"
 
 
 major = 3
 minor = 1
-bugfix = 0
+bugfix = 1
 
 version_info = (major, minor, bugfix)
 
 release = True
-timestamp = datetime.datetime(2018, 12, 5, 2, 20, 30)
+timestamp = datetime.datetime(2019, 2, 23, 6, 39, 22)
 debug = False
 
 astropy_helpers_version = ""
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' 
old/astropy-helpers-3.1/astropy_helpers/version_helpers.py 
new/astropy-helpers-3.1.1/astropy_helpers/version_helpers.py
--- old/astropy-helpers-3.1/astropy_helpers/version_helpers.py  2018-12-05 
03:10:37.000000000 +0100
+++ new/astropy-helpers-3.1.1/astropy_helpers/version_helpers.py        
2019-02-23 07:39:10.000000000 +0100
@@ -35,6 +35,8 @@
 from . import git_helpers
 from .distutils_helpers import is_distutils_display_option
 
+__all__ = ['generate_version_py']
+
 
 def _version_split(version):
     """
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/astropy-helpers-3.1/setup.py 
new/astropy-helpers-3.1.1/setup.py
--- old/astropy-helpers-3.1/setup.py    2018-12-05 03:18:32.000000000 +0100
+++ new/astropy-helpers-3.1.1/setup.py  2019-02-23 07:39:10.000000000 +0100
@@ -9,7 +9,7 @@
 from astropy_helpers.version_helpers import generate_version_py
 
 NAME = 'astropy_helpers'
-VERSION = '3.1'
+VERSION = '3.1.1'
 RELEASE = 'dev' not in VERSION
 
 generate_version_py(NAME, VERSION, RELEASE, False, uses_git=not RELEASE)
@@ -46,6 +46,7 @@
         'Topic :: Software Development :: Libraries :: Python Modules',
         'Topic :: System :: Archiving :: Packaging'
     ],
+    extras_require={'docs': ['sphinx-astropy']},
     cmdclass=cmdclass,
     python_requires='>=3.5',
     zip_safe=False,


Reply via email to