Commit Graph

24 Commits

Author SHA1 Message Date
Stephen Finucane 457a89ffda Add support for PEP-660
As with PEP-517 support, this is simply a shim over the setuptools
implementation added in setuptools v64.0.0 [1].

[1] https://github.com/pypa/setuptools/pull/3488

Change-Id: I32f974db37e364cf634b050b40bf0820dce0a3a3
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2023-11-01 12:53:18 -07:00
Clark Boylan ee04b62de2 Use _ instead of - in setup.cfg directives
Setuptools deprecated -'s at some point and they result in a bunch of
warnings in failed tests. This is distracting and eventually is likely
to create real errors. Go ahead and fix them now.

Change-Id: If3594269495ae1f3cefffd4c4f38d87af5c7fdfe
2023-05-31 13:25:23 -07:00
Clark Boylan 47c5afe79a Remove sphinx doc building integration
Setuptools and sphinx [0] have removed support for building docs through
setup.py. This has broken imports which break our own local doc builds.
Lets just remove it all (including the tests) so that we are compatible
with modern setuptools and sphinx.

An alternative approach would be to do conditional imports and continue
to support this for old setuptools and sphinx. But that feels like a
dead end that will be difficult to test. Probably better to rip this
bandaid off.

[0] https://www.sphinx-doc.org/en/master/changes.html#id7

Change-Id: I65038caceb192f495288414079ca0f07ce6318bb
2023-05-31 13:25:13 -07:00
Jeremy Stanley 571e259969 Drop wheel from pyproject.toml examples
Per https://github.com/pypa/setuptools/pull/3056 the addition of
wheel in build_system.requires is redundant since SetupTools already
drags it in anyway. Simplify our recommendations accordingly.

Change-Id: I0359ed11a6f0c54dc1af6a7f5f34e49476c58fb0
2022-02-28 14:35:37 +00:00
Clark Boylan d21c2caf1d Clarify the need for setup.py with PEP517
There was a misunderstanding that PBRs PEP517 build hooks meant we no
longer needed a setup.py. But it turns out the setuptools build_meta
hooks that we wrap call out to setup.py. This means PBR will continue to
need to be used in conjunction with a setup.py.

This is better for backward compatibiltiy anyway so not a huge loss.

Document this more properly and update the test to reflect it.

Change-Id: If4320da1e89a5c765e0bfe56b724364f9cba34f3
2021-11-08 08:56:18 -08:00
Monty Taylor 09ee153410 Add a PEP517 interface
pep517 defines a new module method of specifying build backends.
To allow pbr to exist in this world, we should define the interface
that's needed. For this to be used, one will put:

  [build-system]
  requires = ["pbr>=5.7.0", "setuptools>=36.6.0", "wheel"]
  build-backend = "pbr.build"

Into pyproject.toml - and the pep517 interface will be used.

This doesn't really change anything else - it just makes us support this.
So by itself this commit isn't SUPER helpful. But maybe let's take baby
steps with something this prone to strife, yeah?

After this we can start teasing some things apart and doing our
own things directly.

Co-Authored-By: Clark Boylan <clark.boylan@gmail.com>
Change-Id: I293f59b5074a38c78adffe580de2f1533bb01ce7
2021-11-03 10:05:32 -07:00
Antoine Musso 07b6ac85e6 Update some url to use opendev.org
The git web URL is now: https://opendev.org/openstack/pbr

Also stop linking README.rst to no more existing history/changelog
documentation page (removed by 96b84a9014).

Change-Id: I56b0e2b86a7fc66c5ae25e06175033a885f500f6
2020-08-06 15:09:50 +02:00
Ben Nemec fba29ab4f1 Typo fix: s/extract_mesages/extract_messages/
Change-Id: If4141dd8e8876fc3d9d3e7579177a44f7c7da563
2019-03-25 16:39:59 +00:00
melissaml f3811cb72b Change openstack-dev to openstack-discuss
Mailinglists have been updated. Openstack-discuss replaces openstack-dev.

Change-Id: Ifc72c767e76283df4608da8d7097ef86c367a5cf
2019-02-15 16:05:59 +00:00
Zuul bd300d07ee Merge "Add an option to skip generating RELEASENOTES.rst" 2018-10-16 16:08:13 +00:00
Tim Burke a34629a956 Add an option to skip generating RELEASENOTES.rst
This is comparable to the existing skip_authors and skip_changelog
options.

Change-Id: Icfefb20fb3c9b2e983e56f6e5440119d4dce2d3f
Co-Authored-By: Stephen Finucane <stephenfin@redhat.com>
2018-09-24 13:05:35 +01:00
Stephen Finucane 8ea9d9262d packaging: Remove support for pyN requirement files
Change-Id: I7f915ecdc819bc4d3c6811949f12bdadb108a1ab
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2018-07-23 11:04:39 +01:00
Stephen Finucane ecbda3076e Deprecate 'build_sphinx' integration
We now have a path away from this feature, so let's deprecate it while
we can.

Change-Id: Idfc34b9085c6da9b8cac24986be5f3bad142d927
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2018-07-18 15:23:44 +01:00
Stephen Finucane 75bac5d50b Add Sphinx extension
This duplicates what already exists in openstackdocstheme but provides a
migration path for users outside of the OpenStack ecosystem.

Change-Id: I73750b3fe984f9d2f339aac0f435a83ee68c89da
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2018-07-18 15:22:16 +01:00
Stephen Finucane 553b73a7a7 doc: Add documentation for missing '[pbr]' options
There are more that just autodoc options in here. Some formatting issues
are also corrected.

Change-Id: I075281d97c2fc7981a38ff1ddbb4ec76717ac726
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2018-07-18 15:13:41 +01:00
Ben Nemec 10fce39a7b Explicitly read setup.cfg as utf-8 on Python 3
Per the referenced bug, relying on the terminal encoding to read
setup.cfg is not safe.  Unfortunately, Python 2 doesn't accept an
encoding when reading config files so we need a fallback path for
that version.

Change-Id: If49344db2f9139c0557f6acd17671163e02468a5
Closes-Bug: 1745396
2018-03-27 10:54:57 +00:00
Zuul f4a1a7dec0 Merge "doc: Minor rework of usage doc" 2018-01-09 00:33:03 +00:00
Zuul 8a9a6d80bf Merge "Support PEP 345 Project-URL metadata" 2018-01-08 13:54:33 +00:00
Stephen Finucane faba96da13 doc: Minor rework of usage doc
Reorder some section to highlight those that are totally unique to pbr
rather than simply modified.

Change-Id: I8cea0ae7d85409573dc6cf1a5d2b7a8ebc5fe8b8
Signed-off-by: Stephen Finucane <sfinucan@redhat.com>
2018-01-08 11:39:12 +00:00
Jeremy Stanley 538d2c21a1 Support Description-Content-Type metadata
As of setuptools 36.4.0, support for Description-Content-Type
metadata was added via the long_description_content_type variable.
Add a metadata.description-content-type option for setup.cfg so it
can be provided through PBR. This makes it possible to instruct PyPI
and potentially other frontends to know an explicit RFC 1341 content
type, along with character set and variant, for the accompanying
long description.

Change-Id: I852f603d9ca4e4cd469eab4cae9933ef2581e3af
2017-12-04 19:46:41 +00:00
Jeremy Stanley 839ef3428d Support PEP 345 Project-URL metadata
By including one or more Project-URL entries in PKG-INFO metadata,
PyPI can display helpful hyperlinks in a generic manner. Add support
here to be able to pass it through setup.cfg with a project_urls
dict. See the corresponding section of the Core Metadata
Specifications from the Python Packaging User Guide for details:

https://packaging.python.org/specifications/core-metadata/#project-url-multiple-use

Setuptools implementation is underway here:

    https://github.com/pypa/setuptools/pull/1210

Change-Id: I14e580c654b619cab7eb24e31f736056d6cf9bd4
2017-11-22 23:55:17 +00:00
Stephen Finucane cc703f4926 Deprecate support for Sphinx < 1.6
We don't want to support older versions of Sphinx forever. While
OpenStack's global requirements have been bumped to Sphinx 1.6, there
are non-OpenStack users in the wild. Give them a chance to upgrade to
the newer version before we completely remove support.

This also gives us a chance to deprecate the '[sphinx_build] builders'
setuptools option, which is no longer necessary with Sphinx 1.6+. Do
this. The documentation is updated to reflect this (and some references
to a "custom" 'source_dir' option removed, as it's not at all specific
to pbr).

Change-Id: I18bbf693bca2f6e49d822ae2940d2170a2b90ce9
Related-Bug: #1702872
2017-09-25 16:22:48 +01:00
Doug Hellmann f323413992 turn on warning-as-error flag for doc build
Change-Id: I5566cfa09dac8dec7a1bc32d95b42d5b136d726f
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2017-06-22 16:08:39 -04:00
Doug Hellmann 2fa5003a05 rearrange existing documentation using the new standard layout
Change-Id: I885f1adf4fbfc1137c6c48039096bd7bdf89cbd3
Depends-On: Ia750cb049c0f53a234ea70ce1f2bbbb7a2aa9454
Signed-off-by: Doug Hellmann <doug@doughellmann.com>
2017-06-22 16:08:39 -04:00