)]}'
{"cinder/tests/unit/test_rbd.py":[{"author":{"_account_id":7173,"name":"Scott DAngelo","email":"scott.dangelo@gmail.com","username":"scottda"},"change_message_id":"220decb17c9513b8bbc5db2e0ae720e554629abe","unresolved":false,"context_lines":[{"line_number":419,"context_line":"        self.driver.delete_snapshot(self.snapshot)"},{"line_number":420,"context_line":""},{"line_number":421,"context_line":"        proxy.unprotect_snap.assert_called_with(self.snapshot.name)"},{"line_number":422,"context_line":""},{"line_number":423,"context_line":"    @common_mocks"},{"line_number":424,"context_line":"    @mock.patch(\u0027cinder.objects.Volume.get_by_id\u0027)"},{"line_number":425,"context_line":"    def test_delete_unprotected_snapshot(self, volume_get_by_id):"}],"source_content_type":"text/x-python","patch_set":8,"id":"9a061dce_e18f71ca","line":422,"updated":"2016-04-08 22:13:20.000000000","message":"What happened to your delete_notfound_on_remove_snapshot test from ps#5?","commit_id":"06355974bba4fa592d8f5840b424757bab67e04f"}],"cinder/volume/drivers/rbd.py":[{"author":{"_account_id":12924,"name":"Patrick East","email":"east.patrick@gmail.com","username":"patrick.east"},"change_message_id":"adfc85fe4eb6ed48d62a290e4ffc2be2de16228f","unresolved":false,"context_lines":[{"line_number":782,"context_line":"            try:"},{"line_number":783,"context_line":"                volume.remove_snap(snap_name)"},{"line_number":784,"context_line":"            except self.rbd.ImageNotFound:"},{"line_number":785,"context_line":"                LOG.info(_LI(\"Snapshot %s does not exist in backend.\"),"},{"line_number":786,"context_line":"                         snap_name)"},{"line_number":787,"context_line":""},{"line_number":788,"context_line":"    def retype(self, context, volume, new_type, diff, host):"}],"source_content_type":"text/x-python","patch_set":1,"id":"ba0121b8_2fb34499","line":785,"updated":"2016-04-01 18:18:19.000000000","message":"It might be nice to add a little bit more context to this message, a comment that it failed to delete the snapshot because it doesn\u0027t exist would (I think) be much more helpful for someone reading the logs.","commit_id":"03881d15d3e7c69601bd5b42c8aa101c633b591c"},{"author":{"_account_id":14305,"name":"Yuriy Nesenenko","email":"ynesenenko@mirantis.com","username":"yuriy_n"},"change_message_id":"de14d18b1ec6c487eb7580115b1dfc66df41e9d5","unresolved":false,"context_lines":[{"line_number":781,"context_line":"                raise exception.SnapshotIsBusy(snapshot_name\u003dsnap_name)"},{"line_number":782,"context_line":"            try:"},{"line_number":783,"context_line":"                volume.remove_snap(snap_name)"},{"line_number":784,"context_line":"            except self.rbd.ImageNotFound:"},{"line_number":785,"context_line":"                LOG.info(_LI(\"Snapshot %s no longer exists in backend. Nothing to delete. Moving forward.\"),"},{"line_number":786,"context_line":"                         snap_name)"},{"line_number":787,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"9a061dce_8a46e478","line":784,"range":{"start_line":784,"start_character":28,"end_line":784,"end_character":41},"updated":"2016-04-07 14:58:53.000000000","message":"No need to duplicate L767-769 if the image wasn\u0027t found.","commit_id":"2cf0aeebab918d0aebbed3e1434c0206ce989125"},{"author":{"_account_id":6908,"name":"Simon Leinen","email":"simon.leinen@gmail.com","username":"simon-leinen"},"change_message_id":"03909deb626839e9af11d6652d098c81ea55f7bc","unresolved":false,"context_lines":[{"line_number":765,"context_line":"                volume.remove_snap(snap_name)"},{"line_number":766,"context_line":"            except self.rbd.InvalidArgument:"},{"line_number":767,"context_line":"                LOG.info(_LI(\"Unable to unprotect snapshot %s.\"), snap_name)"},{"line_number":768,"context_line":"                # Snapshot is already un protected, proceeding to delete"},{"line_number":769,"context_line":"                volume.remove_snap(snap_name)"},{"line_number":770,"context_line":"            except self.rbd.ImageNotFound:"},{"line_number":771,"context_line":"                LOG.info(_LI(\"Snapshot %s does not exist in backend.\"),"}],"source_content_type":"text/x-python","patch_set":8,"id":"9a061dce_b47130e3","line":768,"updated":"2016-04-09 06:01:44.000000000","message":"Typo: un protected -\u003e unprotected","commit_id":"06355974bba4fa592d8f5840b424757bab67e04f"},{"author":{"_account_id":6908,"name":"Simon Leinen","email":"simon.leinen@gmail.com","username":"simon-leinen"},"change_message_id":"03909deb626839e9af11d6652d098c81ea55f7bc","unresolved":false,"context_lines":[{"line_number":766,"context_line":"            except self.rbd.InvalidArgument:"},{"line_number":767,"context_line":"                LOG.info(_LI(\"Unable to unprotect snapshot %s.\"), snap_name)"},{"line_number":768,"context_line":"                # Snapshot is already un protected, proceeding to delete"},{"line_number":769,"context_line":"                volume.remove_snap(snap_name)"},{"line_number":770,"context_line":"            except self.rbd.ImageNotFound:"},{"line_number":771,"context_line":"                LOG.info(_LI(\"Snapshot %s does not exist in backend.\"),"},{"line_number":772,"context_line":"                         snap_name)"}],"source_content_type":"text/x-python","patch_set":8,"id":"9a061dce_94498c91","line":769,"updated":"2016-04-09 06:01:44.000000000","message":"LOGIC ERROR: If this remove_snap() fails with ImageNotFound, there will be no handler for it—\"except\" clauses only handle errors within the \"try\" section, not in other clauses!\nThis is bad because when a volume is already unprotected, and it has already been deleted in the backend, this code will always fail to properly delete it.","commit_id":"06355974bba4fa592d8f5840b424757bab67e04f"},{"author":{"_account_id":6908,"name":"Simon Leinen","email":"simon.leinen@gmail.com","username":"simon-leinen"},"change_message_id":"5a7077c105c3ad3adcf6a32c0bbb83f1c256fa49","unresolved":false,"context_lines":[{"line_number":781,"context_line":"                raise exception.SnapshotIsBusy(snapshot_name\u003dsnap_name)"},{"line_number":782,"context_line":"            try:"},{"line_number":783,"context_line":"                volume.remove_snap(snap_name)"},{"line_number":784,"context_line":"            except self.rbd.ImageNotFound:"},{"line_number":785,"context_line":"                LOG.info(_LI(\"Snapshot %s no longer exists in backend.\"),"},{"line_number":786,"context_line":"                         snap_name)"},{"line_number":787,"context_line":""}],"source_content_type":"text/x-python","patch_set":9,"id":"9a061dce_fffee136","line":784,"updated":"2016-04-09 08:27:53.000000000","message":"Looks like this will do the right thing, except it will log two info notices when the RBD image is missing from the backend, one from unprotect_snap() and one from remove_snap():\n\nSnapshot %s does not exist in backend.\nSnapshot %s no longer exists in backend.\n\nI think it\u0027s OK, if a little ugly, that this message is logged twice - anyway this is a situation that \"shouldn\u0027t happen\" (though it exists in the field due to previous bugs). But it is confusing that the wording is different.","commit_id":"fc5ca79f4f00625f60058d9b9ad10c2b4b499b8f"}]}
