)]}'
{"nova/tests/virt/xenapi/test_volumeops.py":[{"author":{"_account_id":100,"name":"Johannes Erdfelt","email":"johannes@erdfelt.com","username":"johannes.erdfelt"},"change_message_id":"09eb0931a78ecc8d768783aed015e3c2d6fab5f3","unresolved":false,"context_lines":[{"line_number":177,"context_line":"        mock_detach.assert_called_once_with(\"vm_ref\", [\"1\"])"},{"line_number":178,"context_line":""},{"line_number":179,"context_line":"    def test_get_all_volume_vbd_refs_no_vbds(self):"},{"line_number":180,"context_line":"        with mock.patch.object(self.session.VM, \"get_VBDs\") as mock_get:"},{"line_number":181,"context_line":"            with mock.patch.object(self.session.VBD,"},{"line_number":182,"context_line":"                                   \"get_other_config\") as mock_conf:"},{"line_number":183,"context_line":"                mock_get.return_value \u003d []"}],"source_content_type":"text/x-python","patch_set":3,"id":"7adec928_0a7cb5b4","line":180,"updated":"2014-05-22 21:40:37.000000000","message":"It makes me sad we can\u0027t use the decorator version because of the use of self.session :(","commit_id":"c7e1670ea4264b33cf3826d9a861c4e7903f38b2"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"367fce7f7242d565294d63e639a193c4d07b1236","unresolved":false,"context_lines":[{"line_number":177,"context_line":"        mock_detach.assert_called_once_with(\"vm_ref\", [\"1\"])"},{"line_number":178,"context_line":""},{"line_number":179,"context_line":"    def test_get_all_volume_vbd_refs_no_vbds(self):"},{"line_number":180,"context_line":"        with mock.patch.object(self.session.VM, \"get_VBDs\") as mock_get:"},{"line_number":181,"context_line":"            with mock.patch.object(self.session.VBD,"},{"line_number":182,"context_line":"                                   \"get_other_config\") as mock_conf:"},{"line_number":183,"context_line":"                mock_get.return_value \u003d []"}],"source_content_type":"text/x-python","patch_set":3,"id":"3ae8d1ca_15417139","line":180,"in_reply_to":"7adec928_0a7cb5b4","updated":"2014-05-27 15:31:27.000000000","message":"Yeah, its because of how we replace the session with a mock, since we can\u0027t use the real one as it required the XenAPI.py thats not a nova requirement. :(","commit_id":"c7e1670ea4264b33cf3826d9a861c4e7903f38b2"},{"author":{"_account_id":100,"name":"Johannes Erdfelt","email":"johannes@erdfelt.com","username":"johannes.erdfelt"},"change_message_id":"09eb0931a78ecc8d768783aed015e3c2d6fab5f3","unresolved":false,"context_lines":[{"line_number":214,"context_line":"                mock_get.assert_called_once_with(\"vm_ref\")"},{"line_number":215,"context_line":""},{"line_number":216,"context_line":""},{"line_number":217,"context_line":"class AttachVolumeTestCase(VolumeOpsTestBase):"},{"line_number":218,"context_line":"    @mock.patch.object(volumeops.VolumeOps, \"_attach_volume\")"},{"line_number":219,"context_line":"    @mock.patch.object(vm_utils, \"vm_ref_or_raise\")"},{"line_number":220,"context_line":"    def test_attach_volume_default_hotplug(self, mock_get_vm, mock_attach):"}],"source_content_type":"text/x-python","patch_set":3,"id":"7adec928_2a95f1e3","line":217,"updated":"2014-05-22 21:40:37.000000000","message":"Minor nit, the previous class is VolumeDetachTestCase, but this on is AttachVolumeTestCase :) (I know, that\u0027s how it was before...)","commit_id":"c7e1670ea4264b33cf3826d9a861c4e7903f38b2"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"367fce7f7242d565294d63e639a193c4d07b1236","unresolved":false,"context_lines":[{"line_number":214,"context_line":"                mock_get.assert_called_once_with(\"vm_ref\")"},{"line_number":215,"context_line":""},{"line_number":216,"context_line":""},{"line_number":217,"context_line":"class AttachVolumeTestCase(VolumeOpsTestBase):"},{"line_number":218,"context_line":"    @mock.patch.object(volumeops.VolumeOps, \"_attach_volume\")"},{"line_number":219,"context_line":"    @mock.patch.object(vm_utils, \"vm_ref_or_raise\")"},{"line_number":220,"context_line":"    def test_attach_volume_default_hotplug(self, mock_get_vm, mock_attach):"}],"source_content_type":"text/x-python","patch_set":3,"id":"3ae8d1ca_755f150f","line":217,"in_reply_to":"7adec928_2a95f1e3","updated":"2014-05-27 15:31:27.000000000","message":"oh yeah... we should fix that, maybe another change.","commit_id":"c7e1670ea4264b33cf3826d9a861c4e7903f38b2"}],"nova/virt/xenapi/volumeops.py":[{"author":{"_account_id":100,"name":"Johannes Erdfelt","email":"johannes@erdfelt.com","username":"johannes.erdfelt"},"change_message_id":"09eb0931a78ecc8d768783aed015e3c2d6fab5f3","unresolved":false,"context_lines":[{"line_number":162,"context_line":"            sr_ref \u003d volume_utils.find_sr_from_vbd(self._session, vbd_ref)"},{"line_number":163,"context_line":""},{"line_number":164,"context_line":"            if not is_vm_shutdown:"},{"line_number":165,"context_line":"                vm_utils.unplug_vbd(self._session, vbd_ref, vm_ref)"},{"line_number":166,"context_line":""},{"line_number":167,"context_line":"            vm_utils.destroy_vbd(self._session, vbd_ref)"},{"line_number":168,"context_line":"            # Forget (i.e. disconnect) SR only if not in use"}],"source_content_type":"text/x-python","patch_set":3,"id":"7adec928_8a3e05d9","line":165,"updated":"2014-05-22 21:40:37.000000000","message":"Not for this patch, but is there a way we could always use unplug_vbd but ignore any errors because it\u0027s already shutdown?","commit_id":"c7e1670ea4264b33cf3826d9a861c4e7903f38b2"},{"author":{"_account_id":782,"name":"John Garbutt","email":"john@johngarbutt.com","username":"johngarbutt"},"change_message_id":"367fce7f7242d565294d63e639a193c4d07b1236","unresolved":false,"context_lines":[{"line_number":162,"context_line":"            sr_ref \u003d volume_utils.find_sr_from_vbd(self._session, vbd_ref)"},{"line_number":163,"context_line":""},{"line_number":164,"context_line":"            if not is_vm_shutdown:"},{"line_number":165,"context_line":"                vm_utils.unplug_vbd(self._session, vbd_ref, vm_ref)"},{"line_number":166,"context_line":""},{"line_number":167,"context_line":"            vm_utils.destroy_vbd(self._session, vbd_ref)"},{"line_number":168,"context_line":"            # Forget (i.e. disconnect) SR only if not in use"}],"source_content_type":"text/x-python","patch_set":3,"id":"3ae8d1ca_55be9900","line":165,"in_reply_to":"7adec928_8a3e05d9","updated":"2014-05-27 15:31:27.000000000","message":"Good points, its more pythonic, but it would involve us trusting XenServer\u0027s error handling, which I would rather avoid, since its easy to avoid in this case.\n\nReally, XenServer should just have a better API for all this.","commit_id":"c7e1670ea4264b33cf3826d9a861c4e7903f38b2"}]}
