Accepting request 1156351 from systemsmanagement:saltstack
OBS-URL: https://build.opensuse.org/request/show/1156351 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/salt?expand=0&rev=145
This commit is contained in:
commit
dc587cd012
@ -1 +1 @@
|
||||
32a086961fa3b3b60287a78169b2ad66a000073a
|
||||
49e3fd4997f92fccba76eb5e4586f6eaaf7a5b8e
|
63
make-importing-seco.range-thread-safe-bsc-1211649.patch
Normal file
63
make-importing-seco.range-thread-safe-bsc-1211649.patch
Normal file
@ -0,0 +1,63 @@
|
||||
From 0913a58a36ef69d957dd9cc5c95fafe6d56448d5 Mon Sep 17 00:00:00 2001
|
||||
From: Marek Czernek <marek.czernek@suse.com>
|
||||
Date: Mon, 4 Mar 2024 11:27:35 +0100
|
||||
Subject: [PATCH] Make importing seco.range thread safe (bsc#1211649)
|
||||
|
||||
---
|
||||
salt/roster/range.py | 5 +++++
|
||||
salt/utils/roster_matcher.py | 5 +++++
|
||||
2 files changed, 10 insertions(+)
|
||||
|
||||
diff --git a/salt/roster/range.py b/salt/roster/range.py
|
||||
index 3f039dcef42..1525f70c32b 100644
|
||||
--- a/salt/roster/range.py
|
||||
+++ b/salt/roster/range.py
|
||||
@@ -15,16 +15,21 @@ import copy
|
||||
import fnmatch
|
||||
import logging
|
||||
|
||||
+import salt.loader
|
||||
+
|
||||
log = logging.getLogger(__name__)
|
||||
|
||||
# Try to import range from https://github.com/ytoolshed/range
|
||||
HAS_RANGE = False
|
||||
try:
|
||||
+ salt.loader.LOAD_LOCK.acquire()
|
||||
import seco.range
|
||||
|
||||
HAS_RANGE = True
|
||||
except ImportError:
|
||||
log.error("Unable to load range library")
|
||||
+finally:
|
||||
+ salt.loader.LOAD_LOCK.release()
|
||||
# pylint: enable=import-error
|
||||
|
||||
|
||||
diff --git a/salt/utils/roster_matcher.py b/salt/utils/roster_matcher.py
|
||||
index db5dfda3e03..5165dc122b7 100644
|
||||
--- a/salt/utils/roster_matcher.py
|
||||
+++ b/salt/utils/roster_matcher.py
|
||||
@@ -8,14 +8,19 @@ import functools
|
||||
import logging
|
||||
import re
|
||||
|
||||
+import salt.loader
|
||||
+
|
||||
# Try to import range from https://github.com/ytoolshed/range
|
||||
HAS_RANGE = False
|
||||
try:
|
||||
+ salt.loader.LOAD_LOCK.acquire()
|
||||
import seco.range
|
||||
|
||||
HAS_RANGE = True
|
||||
except ImportError:
|
||||
pass
|
||||
+finally:
|
||||
+ salt.loader.LOAD_LOCK.release()
|
||||
# pylint: enable=import-error
|
||||
|
||||
|
||||
--
|
||||
2.44.0
|
||||
|
@ -1,3 +1,11 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Mar 6 13:38:29 UTC 2024 - Marek Czernek <marek.czernek@suse.com>
|
||||
|
||||
- Make importing seco.range thread safe (bsc#1211649)
|
||||
|
||||
- Added:
|
||||
* make-importing-seco.range-thread-safe-bsc-1211649.patch
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Mon Feb 26 10:43:37 UTC 2024 - Pablo Suárez Hernández <pablo.suarezhernandez@suse.com>
|
||||
|
||||
|
@ -353,7 +353,8 @@ Patch99: allow-kwargs-for-fileserver-roots-update-bsc-1218482.patch
|
||||
Patch100: discover-both-.yml-and-.yaml-playbooks-bsc-1211888.patch
|
||||
# PATCH-FIX_UPSTREAM https://github.com/saltstack/salt/pull/66130
|
||||
Patch101: fix-problematic-tests-and-allow-smooth-tests-executi.patch
|
||||
|
||||
# PATCH-FIX_OPENSUSE: https://github.com/openSUSE/salt/pull/628
|
||||
Patch102: make-importing-seco.range-thread-safe-bsc-1211649.patch
|
||||
|
||||
### IMPORTANT: The line below is used as a snippet marker. Do not touch it.
|
||||
### SALT PATCHES LIST END
|
||||
|
Loading…
Reference in New Issue
Block a user