)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"1991d968b6dd8c75996410993336c783dd73db03","unresolved":true,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Change-Id: I39afab6c844972a1c97c15055dbc1f07ed90a68b"},{"line_number":10,"context_line":""},{"line_number":11,"context_line":"Partial-Bug: #1898317"},{"line_number":12,"context_line":"Change-Id: I04265d6bdf84038670a3188a99cd2d639ad62cfe"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"844d320b_3dfb6cb9","line":11,"range":{"start_line":11,"start_character":0,"end_line":11,"end_character":7},"updated":"2021-02-17 22:26:52.000000000","message":"Closes","commit_id":"4e03a7700388679ad49b2ea72916d5396831e822"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"b43d80621fcc2aff0865a67d881bf76a43930e9d","unresolved":true,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Add \"--wait\" option for force-deleting a share/snapshot/share-instance"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Change-Id: I39afab6c844972a1c97c15055dbc1f07ed90a68b"},{"line_number":10,"context_line":""},{"line_number":11,"context_line":"Closes-Bug: #1898317"},{"line_number":12,"context_line":"Change-Id: I04265d6bdf84038670a3188a99cd2d639ad62cfe"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"dc0fbf61_cc967185","line":9,"range":{"start_line":9,"start_character":0,"end_line":9,"end_character":52},"updated":"2021-02-23 22:52:44.000000000","message":"Can you amend your commit message and remove this?\n\n\"Change-Id\" should be in the last paragraph of your commit message (like you have on line 12) and is critical to Gerrit - If you don\u0027t have it in your last paragraph, the gerrit commit hook will go ahead and assume this is a brand new change, and create a new change ID for it - and hence, your code will be submitted as an entirely new change, as you saw with https://review.opendev.org/c/openstack/python-manilaclient/+/772849","commit_id":"bb08fbd42623468c9fdb303881e5c56c972f909f"}],"manilaclient/tests/unit/v2/test_shell.py":[{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"b7dc8dbcfdb68581bd2dcf8306966ed3570cfbbf","unresolved":true,"context_lines":[{"line_number":959,"context_line":"    @ddt.data((\u0027share_xyz\u0027, ), (\u0027share_abc\u0027, \u0027share_xyz\u0027))"},{"line_number":960,"context_line":"    def test_force_delete_wait(self, shares_to_delete):"},{"line_number":961,"context_line":"        fake_shares \u003d ["},{"line_number":962,"context_line":"            shares.Share(\u0027fake\u0027, {\u0027id\u0027: \u00271234\u0027})"},{"line_number":963,"context_line":"            for share in shares_to_delete"},{"line_number":964,"context_line":"        ]"},{"line_number":965,"context_line":"        share_not_found_error \u003d (\"Delete for share %s failed: No share with \""}],"source_content_type":"text/x-python","patch_set":2,"id":"084901f8_48c5e5a2","line":962,"range":{"start_line":962,"start_character":25,"end_line":962,"end_character":31},"updated":"2021-02-17 22:26:18.000000000","message":"this can\u0027t be a string, it has to be a callable. \nThis is because this resolves to the Share resource\u0027s \"manager\" attribute/object [1], and the force_delete call is actually being resolved via this manager [2]\n\nso, you could create a fake like this:\n\n  fake_manager \u003d mock.Mock()\n  fake_shares \u003d [\n            shares.Share(fake_manager, {\u0027id\u0027: \u00271234\u0027})\n            for share in shares_to_delete\n  ]\n \n\n[1] https://github.com/openstack/python-manilaclient/blob/80ec2919ca6dafe458c2db2e455f937e2f67cfe2/manilaclient/common/apiclient/base.py#L435\n[2] https://github.com/openstack/python-manilaclient/blob/a68aaab1723b209de8d314abc7192d373074825a/manilaclient/v2/shares.py#L75-L77","commit_id":"8d565d4ff6296c1d071d23ede8073ce713afe4f7"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"b7dc8dbcfdb68581bd2dcf8306966ed3570cfbbf","unresolved":true,"context_lines":[{"line_number":977,"context_line":"        shell_v2._find_share.assert_has_calls(["},{"line_number":978,"context_line":"            mock.call(self.shell.cs, share) for share in shares_to_delete"},{"line_number":979,"context_line":"        ])"},{"line_number":980,"context_line":"        for share in fake_shares:"},{"line_number":981,"context_line":"            uri \u003d \u0027/shares/1234\u0027"},{"line_number":982,"context_line":"            self.assert_called_anytime("},{"line_number":983,"context_line":"                \u0027FORCE_DELETE\u0027, uri, clear_callstack\u003dFalse)"},{"line_number":984,"context_line":""},{"line_number":985,"context_line":"    def test_list_snapshots(self):"},{"line_number":986,"context_line":"        self.run_command(\u0027snapshot-list\u0027)"}],"source_content_type":"text/x-python","patch_set":2,"id":"c47d96b5_7de5f951","line":983,"range":{"start_line":980,"start_character":8,"end_line":983,"end_character":59},"updated":"2021-02-17 22:26:18.000000000","message":"Since we\u0027re mocking out the client manager, we can\u0027t assert the exact API call. You can check the mocked manager was invoked correctly however, \n\n  manager_mock.force_delete.assert_has_calls([\n            mock.call(share) for share in fake_shares])\n  self.assertEqual(len(shares_to_delete), \n                   manager_mock.force_delete.call_count)","commit_id":"8d565d4ff6296c1d071d23ede8073ce713afe4f7"}],"manilaclient/v2/shell.py":[{"author":{"_account_id":31213,"name":"Maari Tamm","email":"maari.tamm@citynetwork.eu","username":"maaritamm"},"change_message_id":"4cc81ccbb8bc43f927c33532de0389015db194d5","unresolved":true,"context_lines":[{"line_number":54,"context_line":"        \u0027snapshot\u0027: _find_share_snapshot,"},{"line_number":55,"context_line":"        \u0027share_replica\u0027: _find_share_replica,"},{"line_number":56,"context_line":"        \u0027share_group\u0027: _find_share_group,"},{"line_number":57,"context_line":"        \u0027share_group_snapshot\u0027: _find_share_group_snapshot,"},{"line_number":58,"context_line":"    }"},{"line_number":59,"context_line":""},{"line_number":60,"context_line":"    print_resource \u003d {"}],"source_content_type":"text/x-python","patch_set":1,"id":"8250961f_315c6f81","line":57,"updated":"2021-02-06 19:00:16.000000000","message":"Add share instance find option here:\n    \u0027share_instance\u0027: _find_share_instance","commit_id":"60bc89d9581c3d51ed37ddd39e9eb87895ff5dbf"},{"author":{"_account_id":31213,"name":"Maari Tamm","email":"maari.tamm@citynetwork.eu","username":"maaritamm"},"change_message_id":"4cc81ccbb8bc43f927c33532de0389015db194d5","unresolved":true,"context_lines":[{"line_number":62,"context_line":"        \u0027snapshot\u0027: _print_share_snapshot,"},{"line_number":63,"context_line":"        \u0027share_replica\u0027: _print_share_replica,"},{"line_number":64,"context_line":"        \u0027share_group\u0027: _print_share_group,"},{"line_number":65,"context_line":"        \u0027share_group_snapshot\u0027: _print_share_group_snapshot,"},{"line_number":66,"context_line":"    }"},{"line_number":67,"context_line":""},{"line_number":68,"context_line":"    expected_status \u003d expected_status or (\u0027available\u0027, )"}],"source_content_type":"text/x-python","patch_set":1,"id":"7b664dcc_9c4adc9f","line":65,"updated":"2021-02-06 19:00:16.000000000","message":"And share instance print option here:\n    \u0027share_instance\u0027: _print_share_instance","commit_id":"60bc89d9581c3d51ed37ddd39e9eb87895ff5dbf"},{"author":{"_account_id":31213,"name":"Maari Tamm","email":"maari.tamm@citynetwork.eu","username":"maaritamm"},"change_message_id":"4cc81ccbb8bc43f927c33532de0389015db194d5","unresolved":true,"context_lines":[{"line_number":80,"context_line":"        \u0027resource_type\u0027: resource_type.capitalize(),"},{"line_number":81,"context_line":"        \u0027resource\u0027: resource.id,"},{"line_number":82,"context_line":"    }"},{"line_number":83,"context_line":"    not_found_regex \u003d \"no %s .* exists\" % resource_type"},{"line_number":84,"context_line":"    while True:"},{"line_number":85,"context_line":"        if time_elapsed \u003e poll_timeout:"},{"line_number":86,"context_line":"            print_resource[resource_type](cs, resource)"}],"source_content_type":"text/x-python","patch_set":1,"id":"48be4791_28045805","line":83,"updated":"2021-02-06 19:00:16.000000000","message":"Looks like the not found error message for snapshots and share instances contains \u0027shareinstance\u0027 and \u0027sharesnapshot\u0027 instead of \u0027share_instance\u0027 or \u0027snapshot\u0027 so we end up getting an exception although the resource is deleted correctly here. To not get blocked here you could just change this line to:\nnot_found_regex \u003d \"no .* exists\"\nOr think of a better solution of course :)","commit_id":"60bc89d9581c3d51ed37ddd39e9eb87895ff5dbf"},{"author":{"_account_id":31213,"name":"Maari Tamm","email":"maari.tamm@citynetwork.eu","username":"maaritamm"},"change_message_id":"4cc81ccbb8bc43f927c33532de0389015db194d5","unresolved":true,"context_lines":[{"line_number":2397,"context_line":"        for instance in instances_to_delete:"},{"line_number":2398,"context_line":"            try:"},{"line_number":2399,"context_line":"                _wait_for_resource_status("},{"line_number":2400,"context_line":"                    cs, instance, expected_status\u003d\u0027deleted\u0027)"},{"line_number":2401,"context_line":"            except exceptions.CommandError as e:"},{"line_number":2402,"context_line":"                print(e, file\u003dsys.stderr)"},{"line_number":2403,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"bb862db5_f846cb45","line":2400,"updated":"2021-02-06 19:00:16.000000000","message":"pass here the resource type as well:\n        resource_type\u003d\u0027share_instance\u0027","commit_id":"60bc89d9581c3d51ed37ddd39e9eb87895ff5dbf"},{"author":{"_account_id":31213,"name":"Maari Tamm","email":"maari.tamm@citynetwork.eu","username":"maaritamm"},"change_message_id":"4cc81ccbb8bc43f927c33532de0389015db194d5","unresolved":true,"context_lines":[{"line_number":2873,"context_line":"    if args.wait:"},{"line_number":2874,"context_line":"        for snapshot in snapshots_to_delete:"},{"line_number":2875,"context_line":"            try:"},{"line_number":2876,"context_line":"                snapshot_ref \u003d _wait_for_share_status("},{"line_number":2877,"context_line":"                    cs, snapshot, expected_status\u003d\u0027deleted\u0027)"},{"line_number":2878,"context_line":"            except exceptions.CommandError as e:"},{"line_number":2879,"context_line":"                print(e, file\u003dsys.stderr)"}],"source_content_type":"text/x-python","patch_set":1,"id":"b86f6a54_a059eab3","line":2876,"range":{"start_line":2876,"start_character":41,"end_line":2876,"end_character":46},"updated":"2021-02-06 19:00:16.000000000","message":"resource","commit_id":"60bc89d9581c3d51ed37ddd39e9eb87895ff5dbf"},{"author":{"_account_id":31213,"name":"Maari Tamm","email":"maari.tamm@citynetwork.eu","username":"maaritamm"},"change_message_id":"4cc81ccbb8bc43f927c33532de0389015db194d5","unresolved":true,"context_lines":[{"line_number":2874,"context_line":"        for snapshot in snapshots_to_delete:"},{"line_number":2875,"context_line":"            try:"},{"line_number":2876,"context_line":"                snapshot_ref \u003d _wait_for_share_status("},{"line_number":2877,"context_line":"                    cs, snapshot, expected_status\u003d\u0027deleted\u0027)"},{"line_number":2878,"context_line":"            except exceptions.CommandError as e:"},{"line_number":2879,"context_line":"                print(e, file\u003dsys.stderr)"},{"line_number":2880,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"74d40975_e73869d1","line":2877,"updated":"2021-02-06 19:00:16.000000000","message":"pass the resource type here as well:\n    resource_type\u003d\u0027snapshot\u0027","commit_id":"60bc89d9581c3d51ed37ddd39e9eb87895ff5dbf"}],"releasenotes/notes/bug-1898317-add-wait-option-for-force-deleting-share-snapshot-share-instance-fb2531b6033f0ae5.yaml":[{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"7b01fb7ca51b8123ac52de111e23c15414bb7656","unresolved":true,"context_lines":[{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    The commands \"manila force-delete\", \"manila snapshot-force-delete\""},{"line_number":5,"context_line":"    and \"manila share-instance-force-delete\" now accept an optional"},{"line_number":6,"context_line":"    \"--wait\" that allows Admin to let the client poll for the"},{"line_number":7,"context_line":"    completion of the operation."},{"line_number":8,"context_line":""}],"source_content_type":"text/x-yaml","patch_set":4,"id":"df74f93a_3402126e","line":6,"range":{"start_line":6,"start_character":25,"end_line":6,"end_character":31},"updated":"2021-02-23 22:53:11.000000000","message":"nit: replace with \"administrator users\"","commit_id":"bb08fbd42623468c9fdb303881e5c56c972f909f"}]}
