)]}'
{"cinder/tests/unit/test_volume.py":[{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"050d0a3207864b36c2fe172a7643a32cf9a45feb","unresolved":false,"context_lines":[{"line_number":4152,"context_line":"                          self.context,"},{"line_number":4153,"context_line":"                          volume_dst.id,"},{"line_number":4154,"context_line":"                          volume\u003dvolume_dst)"},{"line_number":4155,"context_line":"        self.assertEqual(\u0027available\u0027, volume_src[\u0027status\u0027])"},{"line_number":4156,"context_line":"        self.volume.delete_volume(self.context, volume_dst.id,"},{"line_number":4157,"context_line":"                                  volume\u003dvolume_dst)"},{"line_number":4158,"context_line":"        self.volume.delete_volume(self.context, volume_src.id,"}],"source_content_type":"text/x-python","patch_set":1,"id":"dada55a8_f25b83f4","line":4155,"range":{"start_line":4155,"start_character":8,"end_line":4155,"end_character":59},"updated":"2016-07-19 14:00:08.000000000","message":"Is this right? There\u0027s no point in testing the src volume status here. I think you should check for the destination volume: self.assertEqual(\u0027error\u0027, volume_dst[\u0027status\u0027])","commit_id":"b1e2f65fd63939e61d399874d7a44f3bb7584a8a"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"ded3a704b5469387f49795db1ba996f53c4773c8","unresolved":false,"context_lines":[{"line_number":4152,"context_line":"                          self.context,"},{"line_number":4153,"context_line":"                          volume_dst.id,"},{"line_number":4154,"context_line":"                          volume\u003dvolume_dst)"},{"line_number":4155,"context_line":"        self.assertEqual(\u0027available\u0027, volume_src[\u0027status\u0027])"},{"line_number":4156,"context_line":"        self.volume.delete_volume(self.context, volume_dst.id,"},{"line_number":4157,"context_line":"                                  volume\u003dvolume_dst)"},{"line_number":4158,"context_line":"        self.volume.delete_volume(self.context, volume_src.id,"}],"source_content_type":"text/x-python","patch_set":1,"id":"dada55a8_3daff97e","line":4155,"range":{"start_line":4155,"start_character":8,"end_line":4155,"end_character":59},"in_reply_to":"dada55a8_5b1fd56b","updated":"2016-07-22 12:41:24.000000000","message":"Oh, I forgot to mention that I had fixed it in my local branch, will come in in the next patch.  ;-)","commit_id":"b1e2f65fd63939e61d399874d7a44f3bb7584a8a"},{"author":{"_account_id":10058,"name":"Erlon R. Cruz","email":"erlon.rodrigues.cruz@canonical.com","username":"sombrafam"},"change_message_id":"dc03b52da9c0ef364ef15993cc0009386d2bd13b","unresolved":false,"context_lines":[{"line_number":4152,"context_line":"                          self.context,"},{"line_number":4153,"context_line":"                          volume_dst.id,"},{"line_number":4154,"context_line":"                          volume\u003dvolume_dst)"},{"line_number":4155,"context_line":"        self.assertEqual(\u0027available\u0027, volume_src[\u0027status\u0027])"},{"line_number":4156,"context_line":"        self.volume.delete_volume(self.context, volume_dst.id,"},{"line_number":4157,"context_line":"                                  volume\u003dvolume_dst)"},{"line_number":4158,"context_line":"        self.volume.delete_volume(self.context, volume_src.id,"}],"source_content_type":"text/x-python","patch_set":1,"id":"dada55a8_5b1fd56b","line":4155,"range":{"start_line":4155,"start_character":8,"end_line":4155,"end_character":59},"in_reply_to":"dada55a8_88ae2f7f","updated":"2016-07-20 12:21:45.000000000","message":"I think its Ok to fix this in this patch. Otherwise, the test won\u0027t be testing the code you changed.","commit_id":"b1e2f65fd63939e61d399874d7a44f3bb7584a8a"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"a187ebecc096979e663ab0e255d7fce3a4078aa9","unresolved":false,"context_lines":[{"line_number":4152,"context_line":"                          self.context,"},{"line_number":4153,"context_line":"                          volume_dst.id,"},{"line_number":4154,"context_line":"                          volume\u003dvolume_dst)"},{"line_number":4155,"context_line":"        self.assertEqual(\u0027available\u0027, volume_src[\u0027status\u0027])"},{"line_number":4156,"context_line":"        self.volume.delete_volume(self.context, volume_dst.id,"},{"line_number":4157,"context_line":"                                  volume\u003dvolume_dst)"},{"line_number":4158,"context_line":"        self.volume.delete_volume(self.context, volume_src.id,"}],"source_content_type":"text/x-python","patch_set":1,"id":"dada55a8_88ae2f7f","line":4155,"range":{"start_line":4155,"start_character":8,"end_line":4155,"end_character":59},"in_reply_to":"dada55a8_f25b83f4","updated":"2016-07-20 07:59:05.000000000","message":"It\u0027s not wrong, it\u0027s just incomplete, and I though when I changed it that it was out of the scope of this patch to fix this test and just changed expected value that is due to the changes introduced by this patch.\n\nBut if this is a problem I\u0027ll just fix this test in this same patch.","commit_id":"b1e2f65fd63939e61d399874d7a44f3bb7584a8a"}],"cinder/volume/flows/manager/create_volume.py":[{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"b161ccf73e1a8be699fb14dea7d9108f66f2e9f7","unresolved":false,"context_lines":[{"line_number":190,"context_line":"        return False"},{"line_number":191,"context_line":""},{"line_number":192,"context_line":""},{"line_number":193,"context_line":"class ExtractVolumeRefTask(flow_utils.CinderTask):"},{"line_number":194,"context_line":"    \"\"\"Extracts volume reference for given volume id.\"\"\""},{"line_number":195,"context_line":""},{"line_number":196,"context_line":"    default_provides \u003d \u0027refreshed\u0027"},{"line_number":197,"context_line":""},{"line_number":198,"context_line":"    def __init__(self, db, host, set_error\u003dTrue):"},{"line_number":199,"context_line":"        super(ExtractVolumeRefTask, self).__init__(addons\u003d[ACTION])"},{"line_number":200,"context_line":"        self.db \u003d db"},{"line_number":201,"context_line":"        self.host \u003d host"},{"line_number":202,"context_line":"        self.set_error \u003d set_error"},{"line_number":203,"context_line":""},{"line_number":204,"context_line":"    def execute(self, context, volume):"},{"line_number":205,"context_line":"        # NOTE(harlowja): this will fetch the volume from the database, if"},{"line_number":206,"context_line":"        # the volume has been deleted before we got here then this should fail."},{"line_number":207,"context_line":"        #"},{"line_number":208,"context_line":"        # In the future we might want to have a lock on the volume_id so that"},{"line_number":209,"context_line":"        # the volume can not be deleted while its still being created?"},{"line_number":210,"context_line":"        volume.refresh()"},{"line_number":211,"context_line":"        return volume"},{"line_number":212,"context_line":""},{"line_number":213,"context_line":"    def revert(self, context, volume, result, **kwargs):"},{"line_number":214,"context_line":"        if isinstance(result, ft.Failure) or not self.set_error:"},{"line_number":215,"context_line":"            return"},{"line_number":216,"context_line":""},{"line_number":217,"context_line":"        reason \u003d _(\u0027Volume create failed while extracting volume ref.\u0027)"},{"line_number":218,"context_line":"        common.error_out_volume(context, self.db, volume.id, reason\u003dreason)"},{"line_number":219,"context_line":"        LOG.error(_LE(\"Volume %s: create failed\"), volume.id)"},{"line_number":220,"context_line":""},{"line_number":221,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"dada55a8_ba192f25","line":218,"range":{"start_line":193,"start_character":0,"end_line":218,"end_character":71},"updated":"2016-07-22 12:21:34.000000000","message":"Do we need this now? Maybe we can just move erroring out volume on revert to ExtractVolumeSpecTask?","commit_id":"d5aac50edb296d980044ad74c43c7a7c9b334be0"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"a0419b2bbf3e5ebc5b74708f1f7698486ee35e6b","unresolved":false,"context_lines":[{"line_number":190,"context_line":"        return False"},{"line_number":191,"context_line":""},{"line_number":192,"context_line":""},{"line_number":193,"context_line":"class ExtractVolumeRefTask(flow_utils.CinderTask):"},{"line_number":194,"context_line":"    \"\"\"Extracts volume reference for given volume id.\"\"\""},{"line_number":195,"context_line":""},{"line_number":196,"context_line":"    default_provides \u003d \u0027refreshed\u0027"},{"line_number":197,"context_line":""},{"line_number":198,"context_line":"    def __init__(self, db, host, set_error\u003dTrue):"},{"line_number":199,"context_line":"        super(ExtractVolumeRefTask, self).__init__(addons\u003d[ACTION])"},{"line_number":200,"context_line":"        self.db \u003d db"},{"line_number":201,"context_line":"        self.host \u003d host"},{"line_number":202,"context_line":"        self.set_error \u003d set_error"},{"line_number":203,"context_line":""},{"line_number":204,"context_line":"    def execute(self, context, volume):"},{"line_number":205,"context_line":"        # NOTE(harlowja): this will fetch the volume from the database, if"},{"line_number":206,"context_line":"        # the volume has been deleted before we got here then this should fail."},{"line_number":207,"context_line":"        #"},{"line_number":208,"context_line":"        # In the future we might want to have a lock on the volume_id so that"},{"line_number":209,"context_line":"        # the volume can not be deleted while its still being created?"},{"line_number":210,"context_line":"        volume.refresh()"},{"line_number":211,"context_line":"        return volume"},{"line_number":212,"context_line":""},{"line_number":213,"context_line":"    def revert(self, context, volume, result, **kwargs):"},{"line_number":214,"context_line":"        if isinstance(result, ft.Failure) or not self.set_error:"},{"line_number":215,"context_line":"            return"},{"line_number":216,"context_line":""},{"line_number":217,"context_line":"        reason \u003d _(\u0027Volume create failed while extracting volume ref.\u0027)"},{"line_number":218,"context_line":"        common.error_out_volume(context, self.db, volume.id, reason\u003dreason)"},{"line_number":219,"context_line":"        LOG.error(_LE(\"Volume %s: create failed\"), volume.id)"},{"line_number":220,"context_line":""},{"line_number":221,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"dada55a8_7d3e912a","line":218,"range":{"start_line":193,"start_character":0,"end_line":218,"end_character":71},"in_reply_to":"dada55a8_3a6c1f08","updated":"2016-07-22 12:43:28.000000000","message":"Hm… Okay, force-delete could possibly delete such volume, no harm to check.","commit_id":"d5aac50edb296d980044ad74c43c7a7c9b334be0"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"e9a492df33910ab9b0aa399312694ecc95d37311","unresolved":false,"context_lines":[{"line_number":190,"context_line":"        return False"},{"line_number":191,"context_line":""},{"line_number":192,"context_line":""},{"line_number":193,"context_line":"class ExtractVolumeRefTask(flow_utils.CinderTask):"},{"line_number":194,"context_line":"    \"\"\"Extracts volume reference for given volume id.\"\"\""},{"line_number":195,"context_line":""},{"line_number":196,"context_line":"    default_provides \u003d \u0027refreshed\u0027"},{"line_number":197,"context_line":""},{"line_number":198,"context_line":"    def __init__(self, db, host, set_error\u003dTrue):"},{"line_number":199,"context_line":"        super(ExtractVolumeRefTask, self).__init__(addons\u003d[ACTION])"},{"line_number":200,"context_line":"        self.db \u003d db"},{"line_number":201,"context_line":"        self.host \u003d host"},{"line_number":202,"context_line":"        self.set_error \u003d set_error"},{"line_number":203,"context_line":""},{"line_number":204,"context_line":"    def execute(self, context, volume):"},{"line_number":205,"context_line":"        # NOTE(harlowja): this will fetch the volume from the database, if"},{"line_number":206,"context_line":"        # the volume has been deleted before we got here then this should fail."},{"line_number":207,"context_line":"        #"},{"line_number":208,"context_line":"        # In the future we might want to have a lock on the volume_id so that"},{"line_number":209,"context_line":"        # the volume can not be deleted while its still being created?"},{"line_number":210,"context_line":"        volume.refresh()"},{"line_number":211,"context_line":"        return volume"},{"line_number":212,"context_line":""},{"line_number":213,"context_line":"    def revert(self, context, volume, result, **kwargs):"},{"line_number":214,"context_line":"        if isinstance(result, ft.Failure) or not self.set_error:"},{"line_number":215,"context_line":"            return"},{"line_number":216,"context_line":""},{"line_number":217,"context_line":"        reason \u003d _(\u0027Volume create failed while extracting volume ref.\u0027)"},{"line_number":218,"context_line":"        common.error_out_volume(context, self.db, volume.id, reason\u003dreason)"},{"line_number":219,"context_line":"        LOG.error(_LE(\"Volume %s: create failed\"), volume.id)"},{"line_number":220,"context_line":""},{"line_number":221,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"dada55a8_3a6c1f08","line":218,"range":{"start_line":193,"start_character":0,"end_line":218,"end_character":71},"in_reply_to":"dada55a8_ba192f25","updated":"2016-07-22 12:39:43.000000000","message":"As the comment says this is to check that it has not been deleted before getting here, so I think we should keep it.","commit_id":"d5aac50edb296d980044ad74c43c7a7c9b334be0"}],"cinder/volume/manager.py":[{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"b161ccf73e1a8be699fb14dea7d9108f66f2e9f7","unresolved":false,"context_lines":[{"line_number":571,"context_line":"                with coordination.Lock(locked_action):"},{"line_number":572,"context_line":"                    _run_flow()"},{"line_number":573,"context_line":"        finally:"},{"line_number":574,"context_line":"            try:"},{"line_number":575,"context_line":"                refreshed \u003d flow_engine.storage.fetch(\u0027refreshed\u0027)"},{"line_number":576,"context_line":"            except tfe.NotFound:"},{"line_number":577,"context_line":"                # If there\u0027s no vol_ref, then flow is reverted. Lets check out"},{"line_number":578,"context_line":"                # if rescheduling occurred."},{"line_number":579,"context_line":"                try:"},{"line_number":580,"context_line":"                    rescheduled \u003d flow_engine.storage.get_revert_result("},{"line_number":581,"context_line":"                        create_volume.OnFailureRescheduleTask.make_name("},{"line_number":582,"context_line":"                            [create_volume.ACTION]))"}],"source_content_type":"text/x-python","patch_set":2,"id":"dada55a8_7ac3378b","line":579,"range":{"start_line":574,"start_character":0,"end_line":579,"end_character":20},"updated":"2016-07-22 12:21:34.000000000","message":"I think we don\u0027t need that either now, I think we can just do the lookup from lines 580-582.","commit_id":"d5aac50edb296d980044ad74c43c7a7c9b334be0"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"e9a492df33910ab9b0aa399312694ecc95d37311","unresolved":false,"context_lines":[{"line_number":571,"context_line":"                with coordination.Lock(locked_action):"},{"line_number":572,"context_line":"                    _run_flow()"},{"line_number":573,"context_line":"        finally:"},{"line_number":574,"context_line":"            try:"},{"line_number":575,"context_line":"                refreshed \u003d flow_engine.storage.fetch(\u0027refreshed\u0027)"},{"line_number":576,"context_line":"            except tfe.NotFound:"},{"line_number":577,"context_line":"                # If there\u0027s no vol_ref, then flow is reverted. Lets check out"},{"line_number":578,"context_line":"                # if rescheduling occurred."},{"line_number":579,"context_line":"                try:"},{"line_number":580,"context_line":"                    rescheduled \u003d flow_engine.storage.get_revert_result("},{"line_number":581,"context_line":"                        create_volume.OnFailureRescheduleTask.make_name("},{"line_number":582,"context_line":"                            [create_volume.ACTION]))"}],"source_content_type":"text/x-python","patch_set":2,"id":"dada55a8_7d95f186","line":579,"range":{"start_line":574,"start_character":0,"end_line":579,"end_character":20},"in_reply_to":"dada55a8_7ac3378b","updated":"2016-07-22 12:39:43.000000000","message":"Well, this checks whether the refresh worked or not, so I think we want to keep it.","commit_id":"d5aac50edb296d980044ad74c43c7a7c9b334be0"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"b161ccf73e1a8be699fb14dea7d9108f66f2e9f7","unresolved":false,"context_lines":[{"line_number":584,"context_line":"                    pass"},{"line_number":585,"context_line":""},{"line_number":586,"context_line":"            if not rescheduled:"},{"line_number":587,"context_line":"                if not refreshed:"},{"line_number":588,"context_line":"                    # Flow was reverted and not rescheduled, fetching"},{"line_number":589,"context_line":"                    # volume_ref from the DB, because it will be needed."},{"line_number":590,"context_line":"                    volume.refresh()"},{"line_number":591,"context_line":"                # NOTE(dulek): Volume wasn\u0027t rescheduled so we need to update"},{"line_number":592,"context_line":"                # volume stats as these are decremented on delete."},{"line_number":593,"context_line":"                self._update_allocated_capacity(volume)"}],"source_content_type":"text/x-python","patch_set":2,"id":"dada55a8_da77c39d","line":590,"range":{"start_line":587,"start_character":0,"end_line":590,"end_character":36},"updated":"2016-07-22 12:21:34.000000000","message":"Well, we have it, so I don\u0027t think we need this fragment now.","commit_id":"d5aac50edb296d980044ad74c43c7a7c9b334be0"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"02a17d5a9d63e2aeb7626f7559b142ef18a9e449","unresolved":false,"context_lines":[{"line_number":584,"context_line":"                    pass"},{"line_number":585,"context_line":""},{"line_number":586,"context_line":"            if not rescheduled:"},{"line_number":587,"context_line":"                if not refreshed:"},{"line_number":588,"context_line":"                    # Flow was reverted and not rescheduled, fetching"},{"line_number":589,"context_line":"                    # volume_ref from the DB, because it will be needed."},{"line_number":590,"context_line":"                    volume.refresh()"},{"line_number":591,"context_line":"                # NOTE(dulek): Volume wasn\u0027t rescheduled so we need to update"},{"line_number":592,"context_line":"                # volume stats as these are decremented on delete."},{"line_number":593,"context_line":"                self._update_allocated_capacity(volume)"}],"source_content_type":"text/x-python","patch_set":2,"id":"dada55a8_e0bf765e","line":590,"range":{"start_line":587,"start_character":0,"end_line":590,"end_character":36},"in_reply_to":"dada55a8_bd1c896b","updated":"2016-07-22 13:05:31.000000000","message":"Well, this sucks, because it looks like we have a huge bug regarding error handling in the flow.   :-(\n\nI\u0027ll leave this as it is until I can confirm the bug in an environment and fix it.","commit_id":"d5aac50edb296d980044ad74c43c7a7c9b334be0"},{"author":{"_account_id":9535,"name":"Gorka Eguileor","email":"geguileo@redhat.com","username":"Gorka"},"change_message_id":"e9a492df33910ab9b0aa399312694ecc95d37311","unresolved":false,"context_lines":[{"line_number":584,"context_line":"                    pass"},{"line_number":585,"context_line":""},{"line_number":586,"context_line":"            if not rescheduled:"},{"line_number":587,"context_line":"                if not refreshed:"},{"line_number":588,"context_line":"                    # Flow was reverted and not rescheduled, fetching"},{"line_number":589,"context_line":"                    # volume_ref from the DB, because it will be needed."},{"line_number":590,"context_line":"                    volume.refresh()"},{"line_number":591,"context_line":"                # NOTE(dulek): Volume wasn\u0027t rescheduled so we need to update"},{"line_number":592,"context_line":"                # volume stats as these are decremented on delete."},{"line_number":593,"context_line":"                self._update_allocated_capacity(volume)"}],"source_content_type":"text/x-python","patch_set":2,"id":"dada55a8_bd1c896b","line":590,"range":{"start_line":587,"start_character":0,"end_line":590,"end_character":36},"in_reply_to":"dada55a8_da77c39d","updated":"2016-07-22 12:39:43.000000000","message":"I agree.","commit_id":"d5aac50edb296d980044ad74c43c7a7c9b334be0"},{"author":{"_account_id":11600,"name":"Michał Dulko","email":"michal.dulko@gmail.com","username":"dulek"},"change_message_id":"cb838cd7ab528f34b659030d70a88c9bf283bef5","unresolved":false,"context_lines":[{"line_number":600,"context_line":"            try:"},{"line_number":601,"context_line":"                flow_engine.storage.fetch(\u0027refreshed\u0027)"},{"line_number":602,"context_line":"            except tfe.NotFound:"},{"line_number":603,"context_line":"                # If there\u0027s no vol_ref, then flow is reverted. Lets check out"},{"line_number":604,"context_line":"                # if rescheduling occurred."},{"line_number":605,"context_line":"                try:"},{"line_number":606,"context_line":"                    rescheduled \u003d flow_engine.storage.get_revert_result("}],"source_content_type":"text/x-python","patch_set":8,"id":"1ac06dbe_f72d9afe","line":603,"range":{"start_line":603,"start_character":32,"end_line":603,"end_character":39},"updated":"2016-08-24 08:36:06.000000000","message":"This should read \"refreshed\" I think.","commit_id":"f5634ea3c12e037959d5561f4363c8ede7724de6"}]}
