public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [rpms/ansible-lint] rawhide: Fix for Python-3.15 (#2481417)
@ 2026-06-20 12:49 Parag Nemade
0 siblings, 0 replies; only message in thread
From: Parag Nemade @ 2026-06-20 12:49 UTC (permalink / raw)
To: git-commits
A new commit has been pushed.
Repo : rpms/ansible-lint
Branch : rawhide
Commit : 8848ca8b0ce6941276fcfb9907cff2fa75d4d966
Author : Parag Nemade <pnemade AT redhat DOT com>
Date : 2026-06-20T18:13:17+05:30
Stats : +41/-2 in 2 file(s)
URL : https://src.fedoraproject.org/rpms/ansible-lint/c/8848ca8b0ce6941276fcfb9907cff2fa75d4d966?branch=rawhide
Log:
Fix for Python-3.15 (#2481417)
---
diff --git a/Fix-py-3.15-dataclasses-import-issue.patch b/Fix-py-3.15-dataclasses-import-issue.patch
new file mode 100644
index 0000000..23a5916
--- /dev/null
+++ b/Fix-py-3.15-dataclasses-import-issue.patch
@@ -0,0 +1,34 @@
+diff -urN ansible-lint-26.4.0.orig/src/ansiblelint/utils.py ansible-lint-26.4.0/src/ansiblelint/utils.py
+--- ansible-lint-26.4.0.orig/src/ansiblelint/utils.py 2026-04-01 20:07:03.000000000 +0530
++++ ansible-lint-26.4.0/src/ansiblelint/utils.py 2026-06-20 17:37:22.549215606 +0530
+@@ -39,7 +39,7 @@
+ MutableMapping,
+ Sequence,
+ )
+-from dataclasses import _MISSING_TYPE, dataclass, field
++from dataclasses import MISSING, dataclass, field
+ from functools import cache, lru_cache
+ from pathlib import Path
+ from typing import TYPE_CHECKING, Any
+@@ -907,8 +911,10 @@
+
+ raw_task: MutableMapping[str, Any]
+ filename: str = ""
+- _normalized_task: MutableMapping[str, Any] | _MISSING_TYPE = field(
+- init=False, repr=False
++ _normalized_task: MutableMapping[str, Any] | Any = field(
++ init=False,
++ repr=False,
++ default=MISSING,
+ )
+ error: MatchError | None = None
+ position: str = ""
+@@ -969,7 +975,7 @@
+ # When we cannot normalize it, we just use the raw task instead
+ # to avoid adding extra complexity to the rules.
+ self._normalized_task = self.raw_task
+- if isinstance(self._normalized_task, _MISSING_TYPE):
++ if self._normalized_task is MISSING:
+ msg = "Task was not normalized"
+ raise TypeError(msg)
+ return self._normalized_task
diff --git a/ansible-lint.spec b/ansible-lint.spec
index d69ee62..b7f4860 100644
--- a/ansible-lint.spec
+++ b/ansible-lint.spec
@@ -4,13 +4,15 @@
Name: %{archive_name}
Epoch: 1
Version: 26.4.0
-Release: 4%{?dist}
+Release: 5%{?dist}
Summary: Best practices checker for Ansible
# README file says its just GPLv3
License: GPL-3.0-only
URL: https://github.com/ansible/ansible-lint
Source0: %{url}/archive/refs/tags/v%{version}.tar.gz#/%{archive_name}-%{version}.tar.gz
+# Patch from upstream commits https://github.com/ansible/ansible-lint/pull/5062/commits
+Patch0: Fix-py-3.15-dataclasses-import-issue.patch
BuildArch: noarch
BuildRequires: pyproject-rpm-macros
@@ -32,7 +34,7 @@ Requires: /usr/bin/ansible
Python3 module for ansible-lint.
%prep
-%autosetup -n %{archive_name}-%{version}
+%autosetup -n %{archive_name}-%{version} -p1
# https://github.com/ansible/ansible-lint/commit/16ec984dfcc8ced362aad5c0dafd6ccd3b9f00c8
# Update pathspec dependency version
@@ -62,6 +64,9 @@ ln -sr %{buildroot}%{_bindir}/%{name}{,-3}
%{_bindir}/%{name}-3
%changelog
+* Sat Jun 20 2026 Parag Nemade <pnemade AT redhat DOT com> - 1:26.4.0-5
+- Fix for Python-3.15 (#2481417)
+
* Thu Jun 04 2026 Python Maint <python-maint@redhat.com> - 1:26.4.0-4
- Rebuilt for Python 3.15
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2026-06-20 12:49 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-06-20 12:49 [rpms/ansible-lint] rawhide: Fix for Python-3.15 (#2481417) Parag Nemade
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox