Comment 0 for bug 1371559

Revision history for this message
Kamil Rykowski (kamil-rykowski) wrote :

Step1: Create an empty image using api v1 or v2.
Step2: Use glanceclient with v2 API to update image property called "architecture":

glance --os-image-version 2 image-update --property architecture='x86'

This will show following error message:

<html>
  <head>
    <title>409 Conflict</title>
  </head>
  <body>
    <h1>409 Conflict</h1>
    There was a conflict when trying to complete your request.<br /><br />
    Property architecture does not exist.

  </body>
</html> (HTTP 409)

The error shows up, because the client sends to glance API following data:

[{"patch: "/architecture", "value": "x86", "op": "replace"}]

instead of

[{"patch: "/architecture", "value": "x86", "op": "add"}]

The issue is somehow related to overridden patch method in SchemaBasedModel class, which propagates non existing properties from schema properties.