_get_changed_synthetic_fields() does not guarantee returned fields to be updatable

Bug #1750353 reported by Lujin Luo
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
neutron
Fix Released
Undecided
Lujin Luo

Bug Description

While revising [1], I discovered an issue of _get_changed_synthetic_fields(): it does not guarantee returned fields to be updatable.

How to reproduce:
 Set a breakpoint in [2] and then run neutron.tests.unit.objects.test_ports.DistributedPortBindingIfaceObjTestCase.test_update_updates_from_db_object, the returned fields are
-> return fields
(Pdb) fields
{'host': u'c2753a12ec', 'port_id': 'ae5700cd-f872-4694-bf36-92b919b0d3bf'}
where 'host' and 'port_id' are not updatable.

[1] https://review.openstack.org/#/c/544206/
[2] https://github.com/openstack/neutron/blob/master/neutron/objects/base.py#L696

Lujin Luo (luo-lujin)
Changed in neutron:
assignee: nobody → Lujin Luo (luo-lujin)
description: updated
Lujin Luo (luo-lujin)
description: updated
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (master)

Fix proposed to branch: master
Review: https://review.openstack.org/545799

Changed in neutron:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (master)

Reviewed: https://review.openstack.org/545799
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=d5f27524819bc95530d0d5856782546fd02d65f8
Submitter: Zuul
Branch: master

commit d5f27524819bc95530d0d5856782546fd02d65f8
Author: Lujin <email address hidden>
Date: Mon Feb 19 20:06:07 2018 +0900

    Ensure _get_changed_synthetic_fields() return updatable fields

    Currently _get_changed_synthetic_fields() does not guarantee
    returned fields to be updatable. This patch adds this guarantee.

    Change-Id: I123ae390bec489a931180a2e33f4bf7b1d51edb2
    Closes-Bug: #1750353

Changed in neutron:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron 13.0.0.0b1

This issue was fixed in the openstack/neutron 13.0.0.0b1 development milestone.

tags: added: neutron-proactive-backport-potential
tags: added: neutron-easy-proactive-backport-potential
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (stable/queens)

Fix proposed to branch: stable/queens
Review: https://review.openstack.org/573617

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (stable/pike)

Fix proposed to branch: stable/pike
Review: https://review.openstack.org/573618

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to neutron (stable/ocata)

Fix proposed to branch: stable/ocata
Review: https://review.openstack.org/573620

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (stable/ocata)

Reviewed: https://review.openstack.org/573620
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=ce13674afdc1888616b488562cca9f6fba2dc0d2
Submitter: Zuul
Branch: stable/ocata

commit ce13674afdc1888616b488562cca9f6fba2dc0d2
Author: Lujin <email address hidden>
Date: Mon Feb 19 20:06:07 2018 +0900

    Ensure _get_changed_synthetic_fields() return updatable fields

    Currently _get_changed_synthetic_fields() does not guarantee
    returned fields to be updatable. This patch adds this guarantee.

    Change-Id: I123ae390bec489a931180a2e33f4bf7b1d51edb2
    Closes-Bug: #1750353
    (cherry picked from commit d5f27524819bc95530d0d5856782546fd02d65f8)

tags: added: in-stable-ocata
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to neutron (stable/queens)

Reviewed: https://review.openstack.org/573617
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=75d08e2b0c44859c55152fbadeb5e23204aeee4b
Submitter: Zuul
Branch: stable/queens

commit 75d08e2b0c44859c55152fbadeb5e23204aeee4b
Author: Lujin <email address hidden>
Date: Mon Feb 19 20:06:07 2018 +0900

    Ensure _get_changed_synthetic_fields() return updatable fields

    Currently _get_changed_synthetic_fields() does not guarantee
    returned fields to be updatable. This patch adds this guarantee.

    Change-Id: I123ae390bec489a931180a2e33f4bf7b1d51edb2
    Closes-Bug: #1750353
    (cherry picked from commit d5f27524819bc95530d0d5856782546fd02d65f8)

tags: added: in-stable-queens
Boden R (boden)
Changed in neutron:
status: Fix Released → In Progress
Revision history for this message
Slawek Kaplonski (slaweq) wrote :

We can't backport it to stable branches as it cause issues with some stadium projects

tags: removed: in-stable-ocata in-stable-queens neutron-easy-proactive-backport-potential neutron-proactive-backport-potential
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on neutron (stable/pike)

Change abandoned by Slawek Kaplonski (<email address hidden>) on branch: stable/pike
Review: https://review.openstack.org/573618
Reason: as we had to revert it from Queens we will not backport it also here

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron 12.0.4

This issue was fixed in the openstack/neutron 12.0.4 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/neutron ocata-eol

This issue was fixed in the openstack/neutron ocata-eol release.

Changed in neutron:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.