[master 1/1] Remove the cacheRequest kwarg for thin(pool) LVs (#1254567)

vpodzime installerbot-noreply at redhat.com
Tue Aug 18 12:09:32 UTC 2015


From: Vratislav Podzimek <vpodzime at redhat.com>

Otherwise a traceback appears because thin(pool) LVs don't support this kwarg.
---
 blivet/blivet.py | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/blivet/blivet.py b/blivet/blivet.py
index bde644b..8c8fa5a 100644
--- a/blivet/blivet.py
+++ b/blivet/blivet.py
@@ -959,6 +959,11 @@ def newLV(self, *args, **kwargs):
         if "%s-%s" % (vg.name, name) in self.names:
             raise ValueError("name already in use")
 
+        if thin_pool or thin_volume:
+            cache_req = kwargs.pop("cacheRequest", None)
+            if cache_req:
+                raise ValueError("Creating cached thin volumes and pools is not supported")
+
         if thin_pool:
             device_class = LVMThinPoolDevice
         elif thin_volume:


-- 
To view this commit on github, visit https://github.com/rhinstaller/blivet/commit/e4ba1bdf2cef72c67156bf1e63a4c3b01b1040df


More information about the anaconda-patches mailing list