We return plain strings everywhere so we should encode the unicode object with utf-8 and store it as a plain string.
Signed-off-by: Vratislav Podzimek vpodzime@redhat.com --- blivet/devices.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/blivet/devices.py b/blivet/devices.py index 4877a39..6aa6c26 100644 --- a/blivet/devices.py +++ b/blivet/devices.py @@ -1374,8 +1374,8 @@ class PartitionDevice(StorageDevice): if self.partedPartition is None: self._name = self.req_name else: - self._name = \ - devicePathToName(self.partedPartition.getDeviceNodeName()) + dev_node_name = self.partedPartition.getDeviceNodeName() + self._name = devicePathToName(dev_node_name.encode("utf-8"))
def dependsOn(self, dep): """ Return True if this device depends on dep. """