public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Patrick McLean" <chutzpah@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: app-admin/salt/, app-admin/salt/files/
Date: Mon, 18 Apr 2022 17:34:02 +0000 (UTC)	[thread overview]
Message-ID: <1650303233.f46615977e1e24ca348fffdc81d1011dfdf0b4d0.chutzpah@gentoo> (raw)

commit:     f46615977e1e24ca348fffdc81d1011dfdf0b4d0
Author:     Patrick McLean <chutzpah <AT> gentoo <DOT> org>
AuthorDate: Mon Apr 18 17:33:24 2022 +0000
Commit:     Patrick McLean <chutzpah <AT> gentoo <DOT> org>
CommitDate: Mon Apr 18 17:33:53 2022 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f4661597

app-admin/salt: Revbump, fix probly with py319 (bug #839276)

Closes: https://bugs.gentoo.org/839276
Signed-off-by: Patrick McLean <chutzpah <AT> gentoo.org>

 app-admin/salt/files/salt-3004.1-py310.patch       | 53 ++++++++++++++++++++++
 ...salt-3004.1-r2.ebuild => salt-3004.1-r3.ebuild} |  1 +
 2 files changed, 54 insertions(+)

diff --git a/app-admin/salt/files/salt-3004.1-py310.patch b/app-admin/salt/files/salt-3004.1-py310.patch
new file mode 100644
index 000000000000..7e30d7687a66
--- /dev/null
+++ b/app-admin/salt/files/salt-3004.1-py310.patch
@@ -0,0 +1,53 @@
+From a58bbbe058df8f45872c43a95992f6a7a7914ab9 Mon Sep 17 00:00:00 2001
+From: piterpunk <piterpunk@slackware.com>
+Date: Fri, 15 Oct 2021 11:03:20 -0300
+Subject: [PATCH] Fix _compat.py importlib logic for Python 3.10
+
+Use the same logic in _compat.py and entrypoints.py to load
+the same importlib.metadata. Python's built in implementation for
+Python >= 3.10 and the Salt one for others.
+---
+ salt/_compat.py | 30 +++++++++++++++++-------------
+ 1 file changed, 17 insertions(+), 13 deletions(-)
+
+diff --git a/salt/_compat.py b/salt/_compat.py
+index 8149657bea61..a402f17a3c71 100644
+--- a/salt/_compat.py
++++ b/salt/_compat.py
+@@ -11,19 +11,23 @@
+ else:
+     import salt.ext.ipaddress as ipaddress
+ 
++if sys.version_info >= (3, 10):
++    # Python 3.10 will include a fix in importlib.metadata which allows us to
++    # get the distribution of a loaded entry-point
++    import importlib.metadata  # pylint: disable=no-member,no-name-in-module
++else:
++    # importlib_metadata before version 3.3.0 does not include the functionality we need.
++    try:
++        import importlib_metadata
+ 
+-# importlib_metadata before version 3.3.0 does not include the functionality we need.
+-try:
+-    import importlib_metadata
+-
+-    importlib_metadata_version = [
+-        int(part)
+-        for part in importlib_metadata.version("importlib_metadata").split(".")
+-        if part.isdigit()
+-    ]
+-    if tuple(importlib_metadata_version) < (3, 3, 0):
++        importlib_metadata_version = [
++            int(part)
++            for part in importlib_metadata.version("importlib_metadata").split(".")
++            if part.isdigit()
++        ]
++        if tuple(importlib_metadata_version) < (3, 3, 0):
++            # Use the vendored importlib_metadata
++            import salt.ext.importlib_metadata as importlib_metadata
++    except ImportError:
+         # Use the vendored importlib_metadata
+         import salt.ext.importlib_metadata as importlib_metadata
+-except ImportError:
+-    # Use the vendored importlib_metadata
+-    import salt.ext.importlib_metadata as importlib_metadata

diff --git a/app-admin/salt/salt-3004.1-r2.ebuild b/app-admin/salt/salt-3004.1-r3.ebuild
similarity index 99%
rename from app-admin/salt/salt-3004.1-r2.ebuild
rename to app-admin/salt/salt-3004.1-r3.ebuild
index 38244a2fee60..d7ded011cd0a 100644
--- a/app-admin/salt/salt-3004.1-r2.ebuild
+++ b/app-admin/salt/salt-3004.1-r3.ebuild
@@ -110,6 +110,7 @@ PATCHES=(
 	"${FILESDIR}/salt-3004.1-jinja-3.patch"
 	"${FILESDIR}/salt-3004.1-tests.patch"
 	"${FILESDIR}/salt-3004.1-relax-pyzmq-dep.patch"
+	"${FILESDIR}/salt-3004.1-py310.patch"
 )
 
 python_prepare_all() {


             reply	other threads:[~2022-04-18 17:34 UTC|newest]

Thread overview: 36+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-18 17:34 Patrick McLean [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-12-24  9:23 [gentoo-commits] repo/gentoo:master commit in: app-admin/salt/, app-admin/salt/files/ Sebastian Pipping
2023-09-08 22:56 Patrick McLean
2023-08-15 19:47 Patrick McLean
2023-04-20 19:19 Patrick McLean
2023-01-30  4:55 Sebastian Pipping
2023-01-10 14:15 Michał Górny
2022-08-31 17:21 Patrick McLean
2022-06-22 11:50 Michał Górny
2022-04-18 18:49 Patrick McLean
2022-03-31 16:18 Patrick McLean
2022-03-31 16:07 Patrick McLean
2022-03-27  1:00 Sam James
2021-09-08  1:01 Patrick McLean
2021-06-09 22:27 Patrick McLean
2021-02-27  2:32 Patrick McLean
2021-02-27  2:32 Patrick McLean
2021-02-18  1:18 Patrick McLean
2021-02-09 17:00 Patrick McLean
2020-09-04  1:45 Patrick McLean
2020-04-30 17:58 Patrick McLean
2020-04-30  1:17 Patrick McLean
2019-02-27 21:40 Patrick McLean
2018-10-24 23:02 Patrick McLean
2017-12-05 21:44 Patrick McLean
2017-08-15 17:17 Manuel Rüger
2017-08-01  1:28 Patrick McLean
2016-12-01  1:16 Patrick McLean
2016-12-01  1:16 Patrick McLean
2016-06-16 23:43 Patrick McLean
2016-06-16 18:48 Patrick McLean
2016-02-01 22:57 Patrick McLean
2015-11-24  0:21 Patrick McLean
2015-11-20  2:16 Patrick McLean
2015-11-06  7:58 Justin Lecher
2015-08-25 17:31 Patrick McLean

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1650303233.f46615977e1e24ca348fffdc81d1011dfdf0b4d0.chutzpah@gentoo \
    --to=chutzpah@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox