From d37d562a416e91e140322045283d1c5398c28ad6 Mon Sep 17 00:00:00 2001 From: Ondrej Nosek Date: Sep 06 2022 18:30:55 +0000 Subject: 1.43 Release Signed-off-by: Ondrej Nosek --- diff --git a/README.rst b/README.rst index 51ad961..33df8ca 100644 --- a/README.rst +++ b/README.rst @@ -3,7 +3,7 @@ Introduction This is the fedpkg project, which mostly is a subclass of the rpkg project. -rpkg works with Python 2.7, 3.6, 3.9 and 3.10. +rpkg works with Python 2.7, 3.6, 3.9, 3.10 and 3.11. License ======= diff --git a/doc/source/conf.py b/doc/source/conf.py index c2a7a8c..ff935d6 100644 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -20,13 +20,13 @@ # -- Project information ----------------------------------------------------- project = 'fedpkg' -copyright = '2021, fedpkg Team' +copyright = '2022, fedpkg Team' author = 'fedpkg Team' # The short X.Y version -version = '1.42' +version = '1.43' # The full version, including alpha/beta/rc tags -release = '1.42' +release = '1.43' # -- General configuration --------------------------------------------------- diff --git a/doc/source/releases.rst b/doc/source/releases.rst index 087a148..bad106e 100644 --- a/doc/source/releases.rst +++ b/doc/source/releases.rst @@ -6,6 +6,7 @@ Releases .. toctree:: :maxdepth: 1 + releases/1.43 releases/1.42 releases/1.41 releases/1.40 diff --git a/doc/source/releases/1.43.rst b/doc/source/releases/1.43.rst new file mode 100644 index 0000000..6b57583 --- /dev/null +++ b/doc/source/releases/1.43.rst @@ -0,0 +1,79 @@ +.. _release_1.43: + +fedpkg 1.43 Release Notes +========================= + +Released on *September 6, 2022* + +This release requires ``rpkg >= 1.65-1``. + +Python compatibility +-------------------- + +fedpkg works with Python 2.7, 3.6, 3.9, 3.10 and 3.11 + +What's new in fedpkg 1.43 +------------------------- + +Enable Python argcomplete +~~~~~~~~~~~~~~~~~~~~~~~~~ +You might miss it in the previous release. If it is not yet running for you after installation - in the previous `release notes`_ there is a description and a guide on how to enable it. + +.. _`release notes`: https://docs.pagure.org/fedpkg/releases/1.42.html + +Fix high and medium level bandit findings +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +Fix the high & medium level bandit security findings. This allows enabling a more strict policy - when a new medium/high level warning appears, unit tests will fail. + +'rpmdefines' changes depending on rpkg +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +'rpmdefines' structure needs a different format after it was changed in rpkg (`#620`_) + +.. _`#620`: https://pagure.io/rpkg/pull-request/620 + +``request-branch``: detect existing branch +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +Prevent opening an issue for 'fedora-scm-requests' team to create a new branch when the branch already exists. + +Add compatibility for Bodhi >= 6.0.0 +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +Compatibility with Bodhi 5.X is retained. + +Fix tests with bodhi-client 6+ +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +bodhi-client was ported to use OIDC Client for authentication. We need to mock out its OIDC provider metadata discovery because it does an unavoidable network request, and we also need to make sure `HOME` is defined in `os.environ` because the new OIDC code expects to read it (in `BodhiClient._build_oidc_client()`). + +``update --suggest-logout`` option added +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +Option `--suggest-logout` was not implemented although it is supported by Bodhi. This commit adds this option. + +Remove python3-mock dependency from fedpkg +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +This commit introduces the use of unittest.mock on Python3. It is also necessary for EPEL 9 release because it doesn't contain `python3-mock`. + +Refactoring of '_request_branch' method +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ +Nesting if-statements usually leads to worse maintainability and understandability of a code. This commit refactors code in such a way that nested if-statements are removed. + +Other small fixes +~~~~~~~~~~~~~~~~~ +* Improve change management process documentation - updated `CONTRIBUTING.md` +* Fix new type flake8 issues. + +Change Logs +----------- +- Improve change management process documentation (onosek) +- Fix medium level bandit findings (onosek) +- rpmdefines changes depending on rpkg - `#620`_ (onosek) +- `request-branch`: detect existing branch - `#481`_ (onosek) +- Refactoring of _request_branch method (drumian) +- Fix tests with bodhi-client 6+ (awilliam) +- Add compatibility for Bodhi >= 6.0.0 (aurelien) +- fedpkg update --suggest-logout option added - `#472`_ (drumian) +- WIP: Remove python3-mock dependency from fedpkg - `rhbz#2061765`_ (drumian) + +.. _`#620`: https://pagure.io/rpkg/pull-request/620 +.. _`#481`: https://pagure.io/fedpkg/issue/481 +.. _`#472`: https://pagure.io/fedpkg/issue/472 +.. _`rhbz#2061765`: https://bugzilla.redhat.com/show_bug.cgi?id=2061765 + diff --git a/jenkins_test.dockerfile b/jenkins_test.dockerfile index 7005cbc..629e199 100644 --- a/jenkins_test.dockerfile +++ b/jenkins_test.dockerfile @@ -14,11 +14,12 @@ RUN dnf -y update && dnf -y install \ krb5-devel \ openssl-devel \ make \ - git + git \ + bandit RUN dnf clean all WORKDIR /src ENV PYTHONPATH "${PYTHONPATH}:./rpkg" -CMD ["tox", "-e", "py36,py39,flake8"] +CMD ["tox", "-e", "py36,py39,flake8,bandit"] diff --git a/setup.py b/setup.py index c7bef6d..963ed56 100755 --- a/setup.py +++ b/setup.py @@ -32,7 +32,7 @@ with open(tests_requirements, 'r') as f: setup( name="fedpkg", - version="1.42", + version="1.43", author="Dennis Gilmore", author_email="dgilmore@fedoraproject.org", description=("Fedora plugin to rpkg to manage " @@ -69,5 +69,6 @@ setup( 'Programming Language :: Python :: 3.6', 'Programming Language :: Python :: 3.9', 'Programming Language :: Python :: 3.10', + 'Programming Language :: Python :: 3.11', ], ) diff --git a/tox.ini b/tox.ini index 009f3ae..2d53a26 100644 --- a/tox.ini +++ b/tox.ini @@ -1,5 +1,5 @@ [tox] -envlist = py27,py36,py39,py310,flake8 +envlist = py27,py36,py39,py310,py311,flake8,doc,bandit [testenv] sitepackages=false @@ -8,8 +8,12 @@ basepython= py36: {env:TOXPYTHON:python3.6} py39: {env:TOXPYTHON:python3.9} py310: {env:TOXPYTHON:python3.10} + py310: {env:TOXPYTHON:python3.11} flake8: {env:TOXPYTHON:python3.6} flake8python2: {env:TOXPYTHON:python2.7} + doc: {env:TOXPYTHON:python3} + bandit: {env:TOXPYTHON:python3} + deps = -r{toxinidir}/requirements.txt -r{toxinidir}/tests-requirements.txt @@ -31,3 +35,18 @@ commands = python -m flake8 fedpkg/ test/ [testenv:flake8python2] deps = flake8 commands = python -m flake8 fedpkg/ test/ + +[testenv:doc] +skip_install = True +deps = + {[testenv]deps} + Sphinx + sphinx-rtd-theme +changedir = {toxinidir}/doc +commands = make html + +[testenv:bandit] +skip_install = true +deps = bandit +commands = bandit -r -ll fedpkg/ test/ +ignore_outcome = False