Commit 4b163794 authored by Michael Hanselmann's avatar Michael Hanselmann
Browse files

RAPI: Remove “__version__” for instance creation

If left in data, FillOpCode will complain. This fixes the QA breakage
after commit 526a662a

.
Signed-off-by: default avatarMichael Hanselmann <hansmi@google.com>
Reviewed-by: default avatarIustin Pop <iustin@google.com>
parent 527fbde8
...@@ -825,8 +825,10 @@ class R_2_instances(baserlib.R_Generic): ...@@ -825,8 +825,10 @@ class R_2_instances(baserlib.R_Generic):
if data_version == 0: if data_version == 0:
op = self._ParseVersion0CreateRequest() op = self._ParseVersion0CreateRequest()
elif data_version == 1: elif data_version == 1:
op = _ParseInstanceCreateRequestVersion1(self.request_body, data = self.request_body.copy()
self.dryRun()) # Remove "__version__"
data.pop(_REQ_DATA_VERSION, None)
op = _ParseInstanceCreateRequestVersion1(data, self.dryRun())
else: else:
raise http.HttpBadRequest("Unsupported request data version %s" % raise http.HttpBadRequest("Unsupported request data version %s" %
data_version) data_version)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment