Change in vdsm[ovirt-3.6]: Remove __init__.py file from lib64 vdsm python directory
ybronhei at redhat.com
ybronhei at redhat.com
Sun Jan 3 21:33:49 UTC 2016
Yaniv Bronhaim has uploaded a new change for review.
Change subject: Remove __init__.py file from lib64 vdsm python directory
......................................................................
Remove __init__.py file from lib64 vdsm python directory
During upgrade from vdsm-4.14 we restart supervdsmd service.
sys.path is configured to load py modules from /usr/lib64 before
/usr/lib. Therefore super loads the vdsm lib module from
old location (/usr/lib64/python2.7/site-packages) before it's removed.
(instead of the new location /usr/lib/python2.7/site-packages -
was introduced in https://gerrit.ovirt.org/#/c/33711)
This patch removes the old vdsm/__init__.py* files in post scriptlet
which prevents the wrong import.
Change-Id: I9dc611cfad83739af3d0706570420cb6dc9630c4
Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1279167
Signed-off-by: Yeela Kaplan <ykaplan at redhat.com>
Signed-off-by: Yaniv Bronhaim <ybronhei at redhat.com>
---
M vdsm.spec.in
1 file changed, 8 insertions(+), 0 deletions(-)
git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/72/51272/1
diff --git a/vdsm.spec.in b/vdsm.spec.in
index 2c0325d..46f1e7b 100644
--- a/vdsm.spec.in
+++ b/vdsm.spec.in
@@ -348,6 +348,14 @@
%description debug-plugin
Used by the trained monkeys at Red Hat to insert chaos and mayhem in to VDSM.
+%post python
+# Required For: upgrade from 4.14 to 4.17 - this shell be removed
+# HACK: Remove vdsm python lib __init__ file if installed on old location
+# https://bugzilla.redhat.com/show_bug.cgi?id=1279167
+if [ "$1" -ge 2 ]; then
+ rm -f %{python2_sitearch}/%{vdsm_name}/__init__.py*
+fi
+
%package tests
Summary: VDSM Test Suite
Requires: %{name} = %{version}-%{release}
--
To view, visit https://gerrit.ovirt.org/51272
To unsubscribe, visit https://gerrit.ovirt.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I9dc611cfad83739af3d0706570420cb6dc9630c4
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: ovirt-3.6
Gerrit-Owner: Yaniv Bronhaim <ybronhei at redhat.com>
More information about the vdsm-patches
mailing list