qubes/vm/qubesvm: fix qid setter to accept str
Mainly for loading from XML.
This commit is contained in:
parent
d4147c52bd
commit
7886695c63
@ -57,6 +57,7 @@ except ImportError:
|
|||||||
|
|
||||||
def _setter_qid(self, prop, value):
|
def _setter_qid(self, prop, value):
|
||||||
# pylint: disable=unused-argument
|
# pylint: disable=unused-argument
|
||||||
|
value = int(value)
|
||||||
if not 0 <= value <= qubes.config.max_qid:
|
if not 0 <= value <= qubes.config.max_qid:
|
||||||
raise ValueError(
|
raise ValueError(
|
||||||
'{} value must be between 0 and qubes.config.max_qid'.format(
|
'{} value must be between 0 and qubes.config.max_qid'.format(
|
||||||
|
Loading…
Reference in New Issue
Block a user