From d9a707f1b7fb269b61a3695bc7cae569bc149a05 Mon Sep 17 00:00:00 2001 From: Tim Case Date: Sun, 19 Apr 2026 02:52:15 +0000 Subject: [PATCH 1/6] Preparation for packit --- .packit.yaml | 58 ++++++++++ Makefile | 18 +-- python-bitmath.spec | 271 ++++++++------------------------------------ 3 files changed, 113 insertions(+), 234 deletions(-) create mode 100644 .packit.yaml diff --git a/.packit.yaml b/.packit.yaml new file mode 100644 index 0000000..ec3d5ad --- /dev/null +++ b/.packit.yaml @@ -0,0 +1,58 @@ +upstream_package_name: bitmath +downstream_package_name: python-bitmath +specfile_path: python-bitmath.spec +upstream_tag_template: "v{version}" + +jobs: + # Copr build on every pull request + - job: copr_build + trigger: pull_request + owner: tbielawa + project: bitmath-ci + targets: + - fedora-rawhide-x86_64 + - fedora-42-x86_64 + - epel-9-x86_64 + - epel-10-x86_64 + + # Copr build on RC tags (v*-rc* pattern) + - job: copr_build + trigger: release + upstream_tag_include: "v.*-rc.*" + owner: tbielawa + project: bitmath-ci + targets: + - fedora-rawhide-x86_64 + - fedora-42-x86_64 + - epel-9-x86_64 + - epel-10-x86_64 + + # propose_downstream on production tags (clean vX.Y.Z, no RC suffix) + - job: propose_downstream + trigger: release + upstream_tag_exclude: ".*-rc.*" + dist_git_branches: + - rawhide + - f42 + - epel9 + - epel10 + + # Koji build triggers after dist-git PR is merged + - job: koji_build + trigger: commit + dist_git_branches: + - rawhide + - f42 + - epel9 + - epel10 + + # Bodhi update after successful Koji build (stable branches only, not rawhide) + - job: bodhi_update + trigger: commit + dist_git_branches: + - f42 + - epel9 + - epel10 + bodhi_extra_params: + update_type: enhancement + notes: "New upstream release. See https://github.com/timlnx/bitmath/releases for details." diff --git a/Makefile b/Makefile index b6647b4..f16a445 100644 --- a/Makefile +++ b/Makefile @@ -30,7 +30,7 @@ PKGNAME := python-$(NAME) # VERSION file provides one place to update the software version. VERSION := $(shell cat VERSION) -RPMRELEASE = $(shell awk '/global _short_release/{print $$NF; exit}' $(RPMSPEC).in) +RPMRELEASE := 1 RPMSPECDIR := . RPMSPEC := $(RPMSPECDIR)/$(PKGNAME).spec @@ -97,10 +97,6 @@ viewcover: ci-unittests conf.py: docsite/source/conf.py.in sed "s/%VERSION%/$(VERSION)/" $< > docsite/source/conf.py -# Build the spec file on the fly. Substitute version numbers from the -# canonical VERSION file. -python-bitmath.spec: python-bitmath.spec.in - sed "s/%VERSION%/$(VERSION)/" $< > $@ build: clean @echo "#############################################" @@ -140,18 +136,18 @@ install: mkdir -p /usr/share/man/man1/ gzip -9 -c bitmath.1 > /usr/share/man/man1/bitmath.1.gz -sdist: clean +sdist: clean virtualenv @echo "#############################################" @echo "# Creating SDIST" @echo "#############################################" - python -m build --sdist + . $(NAME)env3/bin/activate && pip install build && python -m build --sdist -rpmcommon: sdist python-bitmath.spec +rpmcommon: sdist @echo "#############################################" @echo "# Building (S)RPM Now" @echo "#############################################" @mkdir -p rpm-build - @cp dist/$(NAME)-$(VERSION).$(RPMRELEASE).tar.gz rpm-build/$(VERSION).$(RPMRELEASE).tar.gz + @cp dist/$(NAME)-$(VERSION).tar.gz rpm-build/$(VERSION).tar.gz srpm: rpmcommon rpmbuild --define "_topdir %(pwd)/rpm-build" \ @@ -160,6 +156,8 @@ srpm: rpmcommon --define "_srcrpmdir %{_topdir}" \ --define "_specdir $(RPMSPECDIR)" \ --define "_sourcedir %{_topdir}" \ + --define "_pkgversion $(VERSION)" \ + --define "_pkgrelease $(RPMRELEASE)" \ -bs $(RPMSPEC) @echo "#############################################" @echo "$(PKGNAME) SRPM is built:" @@ -173,6 +171,8 @@ rpm: rpmcommon --define "_srcrpmdir %{_topdir}" \ --define "_specdir $(RPMSPECDIR)" \ --define "_sourcedir %{_topdir}" \ + --define "_pkgversion $(VERSION)" \ + --define "_pkgrelease $(RPMRELEASE)" \ -ba $(RPMSPEC) @echo "#############################################" @echo "$(PKGNAME) RPMs are built:" diff --git a/python-bitmath.spec b/python-bitmath.spec index f8ece3b..46de4d4 100644 --- a/python-bitmath.spec +++ b/python-bitmath.spec @@ -1,46 +1,16 @@ -%if 0%{?rhel} && 0%{?rhel} <= 6 -%{!?__python2: %global __python2 /usr/bin/python2} -%{!?python2_sitelib: %global python2_sitelib %(%{__python2} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib())")} -%{!?python2_sitearch: %global python2_sitearch %(%{__python2} -c "from distutils.sysconfig import get_python_lib; print(get_python_lib(1))")} -%{!?py2_build: %global py2_build python setup.py build} -%{!?py2_install: %global py2_install python setup.py install -O1 --root=$RPM_BUILD_ROOT} -%endif - -%if 0%{?fedora} -%{!?python3_version: %global python3_version %(%{__python3} -c "import sys; sys.stdout.write(sys.version[:3])")} -%global with_python3 1 -%else -%global with_python3 0 -%endif - -%global _short_name bitmath -%global _short_release 1 - -Name: python-bitmath -Summary: Aids representing and manipulating file sizes in various prefix notations -Version: 1.3.3 -Release: %{_short_release}%{?dist} - -Group: Development/Libraries -License: BSD -Source0: https://github.com/tbielawa/bitmath/archive/%{version}.%{_short_release}.tar.gz -Url: https://github.com/tbielawa/bitmath - -BuildArch: noarch -BuildRequires: python2-mock -BuildRequires: python2-nose -BuildRequires: python2-progressbar -BuildRequires: python2-setuptools -BuildRequires: python2-devel -%if 0%{?with_python3} +Name: python-bitmath +Summary: Work with file sizes like numbers — convert, compare, sort, and format across any unit prefix +Version: 0 +Release: 1%{?dist} +License: MIT +Source0: https://github.com/timlnx/bitmath/archive/refs/tags/v%{version}.tar.gz +URL: https://github.com/timlnx/bitmath + +BuildArch: noarch BuildRequires: python3-devel -BuildRequires: python3-mock -BuildRequires: python3-nose -BuildRequires: python3-setuptools -%endif -%{?el6:Requires: python-argparse} -%{?el6:BuildRequires: python-argparse} -%{?el6:BuildRequires: python-unittest2} +BuildRequires: pyproject-rpm-macros +BuildRequires: python3-hatchling +BuildRequires: python3-pytest %description bitmath simplifies many facets of interacting with file sizes in @@ -48,7 +18,7 @@ various units. Examples include: converting between SI and NIST prefix units (GiB to kB), converting between units of the same type (SI to SI, or NIST to NIST), basic arithmetic operations (subtracting 42KiB from 50GiB), and rich comparison operations (1024 Bytes == 1KiB), -bitwise operations, sorting, automatic best human-readable prefix +bit-wise operations, sorting, automatic best human-readable prefix selection, and completely customizable formatting. In addition to the conversion and math operations, bitmath provides @@ -56,46 +26,14 @@ human readable representations of values which are suitable for use in interactive shells as well as larger scripts and applications. It can also read the capacity of system storage devices. bitmath can parse strings (like "1 KiB") into proper objects and has support for -integration with the argparse module as a custom argument type and the -progressbar module as a custom file transfer speed widget. +integration with the argparse module as a custom argument type. -bitmath is thoroughly unittested, with almost 200 individual tests (a -number which is always increasing). bitmath's test-coverage is almost -always at 100%. +bitmath ships almost 300 unit tests with near 100% code coverage. ###################################################################### # Sub-package setup -%package -n python2-bitmath -Summary: Aids representing and manipulating file sizes in various prefix notations -%{?python_provide:%python_provide python2-bitmath} - -%description -n python2-bitmath -bitmath simplifies many facets of interacting with file sizes in -various units. Examples include: converting between SI and NIST prefix -units (GiB to kB), converting between units of the same type (SI to -SI, or NIST to NIST), basic arithmetic operations (subtracting 42KiB -from 50GiB), and rich comparison operations (1024 Bytes == 1KiB), -bitwise operations, sorting, automatic best human-readable prefix -selection, and completely customizable formatting. - -In addition to the conversion and math operations, bitmath provides -human readable representations of values which are suitable for use in -interactive shells as well as larger scripts and applications. It can -also read the capacity of system storage devices. bitmath can parse -strings (like "1 KiB") into proper objects and has support for -integration with the argparse module as a custom argument type and the -progressbar module as a custom file transfer speed widget. - -bitmath is thoroughly unittested, with almost 200 individual tests (a -number which is always increasing). bitmath's test-coverage is almost -always at 100%. - -#--------------------------------------------------------------------- - -%if 0%{?with_python3} %package -n python3-bitmath -Summary: Aids representing and manipulating file sizes in various prefix notations -%{?python_provide:%python_provide python3-bitmath} +Summary: Aids representing and manipulating file sizes in various prefix notations %description -n python3-bitmath bitmath simplifies many facets of interacting with file sizes in @@ -103,7 +41,7 @@ various units. Examples include: converting between SI and NIST prefix units (GiB to kB), converting between units of the same type (SI to SI, or NIST to NIST), basic arithmetic operations (subtracting 42KiB from 50GiB), and rich comparison operations (1024 Bytes == 1KiB), -bitwise operations, sorting, automatic best human-readable prefix +bit-wise operations, sorting, automatic best human-readable prefix selection, and completely customizable formatting. In addition to the conversion and math operations, bitmath provides @@ -111,172 +49,55 @@ human readable representations of values which are suitable for use in interactive shells as well as larger scripts and applications. It can also read the capacity of system storage devices. bitmath can parse strings (like "1 KiB") into proper objects and has support for -integration with the argparse module as a custom argument type and the -progressbar module as a custom file transfer speed widget. +integration with the argparse module as a custom argument type. -bitmath is thoroughly unittested, with almost 200 individual tests (a -number which is always increasing). bitmath's test-coverage is almost -always at 100%. -%endif # with_python3 +bitmath ships almost 300 unit tests with near 100% code coverage. ###################################################################### -%check -nosetests -v - -%if 0%{?with_python3} -# We can't run the progressbar and argparse tests in python3 until -# progressbar has a python3 package available :( -# -# Skip those tests for now and run the rest -nosetests-%{python3_version} -e 'test_FileTransferSpeed' \ - -e 'test_BitmathType_' \ - -I '.*test_argparse_type.py' \ - -I '.*test_progressbar.py' -v -%endif # with_python3 +%generate_buildrequires +%pyproject_buildrequires ###################################################################### %prep -%setup -n bitmath-%{version}.%{_short_release} -q +%setup -n bitmath-%{version} -q ###################################################################### %build -%py2_build -%if 0%{?with_python3} -%py3_build -%endif +%pyproject_wheel ###################################################################### %install -%py2_install -mv $RPM_BUILD_ROOT/%{_bindir}/bitmath $RPM_BUILD_ROOT/%{_bindir}/bitmath-2.7 - -%if 0%{?with_python3} -%py3_install -pushd $RPM_BUILD_ROOT/%{_bindir}/ +%pyproject_install +%pyproject_save_files bitmath +pushd %{buildroot}%{_bindir} ln -s bitmath bitmath-%{python3_version} popd -%endif # with_python3 +mkdir -p %{buildroot}%{_mandir}/man1/ +cp -v *.1 %{buildroot}%{_mandir}/man1/ +ln -s bitmath.1 %{buildroot}%{_mandir}/man1/bitmath-%{python3_version}.1 +mkdir -p %{buildroot}%{_docdir}/%{name}/docs +cp -v -r docsite/source/* %{buildroot}%{_docdir}/%{name}/docs/ +find %{buildroot}%{_docdir}/%{name}/docs -name '.gitkeep' -delete -mkdir -p $RPM_BUILD_ROOT/%{_mandir}/man1/ -cp -v *.1 $RPM_BUILD_ROOT/%{_mandir}/man1/ -mkdir -p $RPM_BUILD_ROOT/%{_docdir}/%{name}/docs -cp -v -r docsite/source/* $RPM_BUILD_ROOT/%{_docdir}/%{name}/docs/ -rm -f $RPM_BUILD_ROOT/%{_docdir}/%{name}/docs/NEWS.rst +###################################################################### +%check +%pytest tests/ ###################################################################### -%files -n python2-bitmath -%{python2_sitelib}/* -%doc README.rst NEWS.rst LICENSE -%doc %{_mandir}/man1/bitmath.1* -%doc %{_docdir}/%{name}/docs/ -%{_bindir}/bitmath-2.7 +%files +%license LICENSE -%if 0%{?with_python3} -%files -n python3-bitmath -%{python3_sitelib}/* -%doc README.rst NEWS.rst LICENSE -%doc %{_mandir}/man1/bitmath.1* -%doc %{_docdir}/%{name}/docs/ +###################################################################### +%files -n python3-bitmath -f %{pyproject_files} +%license LICENSE +%doc README.rst NEWS.rst %{_bindir}/bitmath %{_bindir}/bitmath-%{python3_version} -%endif # with_python3 +%{_mandir}/man1/bitmath.1* +%{_mandir}/man1/bitmath-%{python3_version}.1* +%{_docdir}/%{name}/ ###################################################################### %changelog -* Thu Aug 23 2018 Tim Bielawa - 1.3.3-1 - - New release - -* Sat Mar 17 2018 Tim Bielawa - 1.3.2-1 -- New release - -* Sun Jul 17 2016 Tim Bielawa - 1.3.1-1 -- New release - -* Tue Jan 12 2016 Tim Bielawa - 1.3.0-2 -- Packaging update - -* Fri Jan 8 2016 Tim Bielawa - 1.3.0-1 -- Fix best_prefix for negative values GitHub: #55 - -* Tue Dec 29 2015 Tim Bielawa - 1.2.4-3 -- Fix tests to run on koji -- Minor packaging changes - -* Mon Nov 30 2015 Tim Bielawa - 1.2.4-1 -- New release. Now builds dual python2.x and 3.x packages. -- New function: query_device_capacity -- Minor bug fixes for everyone! - -* Sun Jan 4 2015 Tim Bielawa - 1.2.3-3 -- Add mock to build requires - -* Sun Jan 4 2015 Tim Bielawa - 1.2.3-2 -- Add python-progressbar build-dependency to satisfy 'check' tests - -* Sun Jan 4 2015 Tim Bielawa - 1.2.3-1 -- Add progressbar example to the README - -* Sun Jan 4 2015 Tim Bielawa - 1.2.2-1 -- Fix some problems with the automated build system - -* Sun Jan 4 2015 Tim Bielawa - 1.2.1-1 -- Add a new integration: the progressbar module FileTransferSpeed widget - -* Mon Dec 29 2014 Tim Bielawa - 1.2.0-1 -- Add argparse integration with a BitmathType argument type - -* Sat Dec 20 2014 Tim Bielawa - 1.1.0-1 -- New parse_string utility function from tonycpsu -- 'bitmath' tool added for converting on the command line - -* Fri Aug 15 2014 Tim Bielawa - 1.0.8-3 -- Actually fix this whole specfile and version mixup - -* Fri Aug 15 2014 Tim Bielawa - 1.0.8-2 -- Fix macro expansion in specfile changelog - -* Thu Aug 14 2014 Tim Bielawa - 1.0.8-1 -- First release with contributors: davidfischer-ch and hikusukih! Thank you! -- Real documentation (via readthedocs.org) -- Significant formatting functionality added: -- +formatting context manager, listdir, getsize -- Python3 compat via rtruediv contribution! -- So many more unit tests -- Coveralls code-coverage review -- Pluralization/singularity in string formatting (thanks for the contribution!) - -* Sat Jul 19 2014 Tim Bielawa - 1.0.7-1 -- Lots of documentation and unittest updates -- See GitHub Milestone 2: 1.0.7 for a list of closed issues - -* Mon Jul 14 2014 Tim Bielawa - 1.0.6-1 -- New instance properties -- Custom representation formatting method. #9 -- Best-prefix guessing: select the best human-readable prefix unit - automatically. #6 -- Bitwise operation support. #3 -- More unittests than your body has room for - -* Mon Apr 28 2014 Tim Bielawa - 1.0.5-1 -- Now with support for bitwise operations - -* Thu Mar 20 2014 Tim Bielawa - 1.0.4-1 -- Plenty of documentation updates -- Fix some issues with mix-type math operations. -- More unit tests! - -* Mon Mar 17 2014 Tim Bielawa - 1.0.3-1 -- Big issue converting NIST to SI -- Also, retroactively remove unexpanded macros from changelog - -* Thu Mar 13 2014 Tim Bielawa - 1.0.2-3 -- Bump release for new archive format - -* Thu Mar 13 2014 Tim Bielawa - 1.0.2-2 -- Bump spec for proper Source0 versioning - -* Thu Mar 13 2014 Tim Bielawa - 1.0.2-1 -- First real solid release with full functionality and documentation - -* Tue Mar 11 2014 Tim Bielawa - 1.0.0-1 -- First release +* Sat Apr 18 2026 Tim Case - 0-1 +- Packit-managed changelog. See https://github.com/timlnx/bitmath/releases From babaf8b71d1a02e86ece7aef82c39a3f7968a376 Mon Sep 17 00:00:00 2001 From: Tim Case Date: Sun, 19 Apr 2026 03:03:50 +0000 Subject: [PATCH 2/6] Makefile and bump packit again --- Makefile | 6 +++--- SECURITY.md | 1 - 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index f16a445..c051abf 100644 --- a/Makefile +++ b/Makefile @@ -102,19 +102,19 @@ build: clean @echo "#############################################" @echo "# Building sdist + wheel" @echo "#############################################" - python -m build + . $(NAME)env3/bin/activate && python -m build pypi: build @echo "#############################################" @echo "# Uploading to PyPI" @echo "#############################################" - twine upload dist/* + . $(NAME)env3/bin/activate && pip install twine && twine upload dist/* pypitest: build @echo "#############################################" @echo "# Uploading to TestPyPI" @echo "#############################################" - twine upload --repository testpypi dist/* + . $(NAME)env3/bin/activate && pip install twine && twine upload --repository testpypi dist/* # usage example: make tag TAG=1.1.0-1 tag: diff --git a/SECURITY.md b/SECURITY.md index 3502ed9..48edfec 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -42,4 +42,3 @@ As an emergency backup you can find me on bsky or instagram and direct message m * [insta - @tim.lnx](https://www.instagram.com/tim.lnx/) For less serious security issues with lower potential for exploitation or damage, please open a bug on the project and apply the `security` label to it. - From 6725ad6be52e3b312e2dea501cabf551246da6d5 Mon Sep 17 00:00:00 2001 From: Tim Case Date: Sun, 19 Apr 2026 11:37:10 +0000 Subject: [PATCH 3/6] spec: use Python 3.11 on RHEL 9 (EPEL 9 support) --- python-bitmath.spec | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/python-bitmath.spec b/python-bitmath.spec index 46de4d4..f7624d2 100644 --- a/python-bitmath.spec +++ b/python-bitmath.spec @@ -1,3 +1,8 @@ +# RHEL 9 ships Python 3.9 as default; use Python 3.11 from AppStream instead +%if 0%{?rhel} == 9 +%global python3_pkgversion 3.11 +%endif + Name: python-bitmath Summary: Work with file sizes like numbers — convert, compare, sort, and format across any unit prefix Version: 0 From 509fcce06d21159775dab2d34e51abec6cd64238 Mon Sep 17 00:00:00 2001 From: Tim Case Date: Sun, 19 Apr 2026 11:56:12 +0000 Subject: [PATCH 4/6] pyproject: lower requires-python to >=3.9 (EPEL 9 support) ci: add Python 3.9 to test matrix (EPEL 9 / RHEL 9 support) --- .github/workflows/python.yml | 2 +- pyproject.toml | 4 +++- python-bitmath.spec | 5 ----- 3 files changed, 4 insertions(+), 7 deletions(-) diff --git a/.github/workflows/python.yml b/.github/workflows/python.yml index 88bdca8..6b6ffd0 100644 --- a/.github/workflows/python.yml +++ b/.github/workflows/python.yml @@ -10,7 +10,7 @@ jobs: FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true strategy: matrix: - python-version: ["3.11", "3.12", "3.13"] + python-version: ["3.9", "3.11", "3.12", "3.13"] os: ["macos-latest", "ubuntu-latest"] runs-on: ${{ matrix.os }} steps: diff --git a/pyproject.toml b/pyproject.toml index 1125ef7..88c1afc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -7,7 +7,7 @@ name = "bitmath" version = "2.0.0" description = "Pythonic module for representing and manipulating file sizes with different prefix notations (file size unit conversion)" readme = "README.rst" -requires-python = ">=3.11" +requires-python = ">=3.9" authors = [ { name = "Tim Case", email = "bitmath@lnx.cx" }, ] @@ -23,6 +23,8 @@ classifiers = [ "Programming Language :: Python", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3 :: Only", + "Programming Language :: Python :: 3.9", + "Programming Language :: Python :: 3.10", "Programming Language :: Python :: 3.11", "Programming Language :: Python :: 3.12", "Programming Language :: Python :: 3.13", diff --git a/python-bitmath.spec b/python-bitmath.spec index f7624d2..46de4d4 100644 --- a/python-bitmath.spec +++ b/python-bitmath.spec @@ -1,8 +1,3 @@ -# RHEL 9 ships Python 3.9 as default; use Python 3.11 from AppStream instead -%if 0%{?rhel} == 9 -%global python3_pkgversion 3.11 -%endif - Name: python-bitmath Summary: Work with file sizes like numbers — convert, compare, sort, and format across any unit prefix Version: 0 From 4880a4e92caed6c230862500f5bd4f981ca0bd2b Mon Sep 17 00:00:00 2001 From: Tim Case Date: Sun, 19 Apr 2026 12:10:25 +0000 Subject: [PATCH 5/6] packit: remove .github version suffix from PR copr builds --- .packit.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.packit.yaml b/.packit.yaml index ec3d5ad..0a737a6 100644 --- a/.packit.yaml +++ b/.packit.yaml @@ -7,6 +7,7 @@ jobs: # Copr build on every pull request - job: copr_build trigger: pull_request + version_suffix: "" owner: tbielawa project: bitmath-ci targets: From e2e7420c3353e4ab8be8c2db9257071a13afcf02 Mon Sep 17 00:00:00 2001 From: Tim Case Date: Sun, 19 Apr 2026 20:54:23 +0000 Subject: [PATCH 6/6] Update contributing page and github testing workflows --- .github/workflows/python.yml | 2 +- docsite/source/contributing.rst | 22 ++++++++++++++++++++++ 2 files changed, 23 insertions(+), 1 deletion(-) diff --git a/.github/workflows/python.yml b/.github/workflows/python.yml index 6b6ffd0..154ea2f 100644 --- a/.github/workflows/python.yml +++ b/.github/workflows/python.yml @@ -10,7 +10,7 @@ jobs: FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true strategy: matrix: - python-version: ["3.9", "3.11", "3.12", "3.13"] + python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"] os: ["macos-latest", "ubuntu-latest"] runs-on: ${{ matrix.os }} steps: diff --git a/docsite/source/contributing.rst b/docsite/source/contributing.rst index 178033f..f1cfc88 100644 --- a/docsite/source/contributing.rst +++ b/docsite/source/contributing.rst @@ -91,6 +91,28 @@ fix a failing check yourself, leave a comment on the pull request explaining the situation and we'll help. +.. _contributing_python_versions: + +Supported Python Versions +************************* + +bitmath supports Python versions shipping with the current and previous +major RHEL release available via `EPEL `_. +This means the minimum supported version tracks the oldest Python still +included in a supported EPEL target: + +* **RHEL 10 / EPEL 10** — Python 3.12 +* **RHEL 9 / EPEL 9** — Python 3.9, 3.11 + +The CI matrix tests all versions in this range. When a RHEL major +release reaches end-of-life and is dropped from EPEL, the corresponding +Python versions may be dropped from the support matrix in the next +bitmath release. + +If anybody wants to take over Debian/Ubuntu patching, we can add notes +for which distributions are covered. + + .. _contributing_automated_tests: Automated Tests