)]}'
{"openstackclient/image/v2/image.py":[{"author":{"_account_id":21514,"name":"Huanxuan Ao","email":"aohuanxuan@163.com","username":"aohuanxuan"},"change_message_id":"d709c42951f8fa07745170243f80c2144fb65b08","unresolved":false,"context_lines":[{"line_number":389,"context_line":"                                   % {\u0027image\u0027: image, \u0027e\u0027: e})"},{"line_number":390,"context_line":""},{"line_number":391,"context_line":"        total \u003d len(parsed_args.images)"},{"line_number":392,"context_line":"        if (delresult \u003e 0):"},{"line_number":393,"context_line":"            msg \u003d (_(\"Failed to delete %(dresult)s of %(total)s images.\")"},{"line_number":394,"context_line":"                   % {\u0027dresult\u0027: delresult, \u0027total\u0027: total})"},{"line_number":395,"context_line":"            raise exceptions.CommandError(msg)"}],"source_content_type":"text/x-python","patch_set":1,"id":"9abb7d3a_39859c06","line":392,"range":{"start_line":392,"start_character":11,"end_line":392,"end_character":26},"updated":"2016-06-01 06:26:07.000000000","message":"Needn\u0027t \"()\"","commit_id":"5dd2204db74e4a4c7734d65e9bc19aa3f4a30d75"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"392c30813c2e0dc275117e65ec0bcbef5741414c","unresolved":false,"context_lines":[{"line_number":373,"context_line":""},{"line_number":374,"context_line":"    def take_action(self, parsed_args):"},{"line_number":375,"context_line":""},{"line_number":376,"context_line":"        delresult \u003d 0"},{"line_number":377,"context_line":"        image_client \u003d self.app.client_manager.image"},{"line_number":378,"context_line":"        for image in parsed_args.images:"},{"line_number":379,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_fb4338ad","line":376,"range":{"start_line":376,"start_character":8,"end_line":376,"end_character":17},"updated":"2016-06-13 05:48:33.000000000","message":"del_result*","commit_id":"e7727b1dc71304a92456db7a5e8be7c43d052e14"},{"author":{"_account_id":6482,"name":"Steve Martinelli","email":"s.martinelli@gmail.com","username":"stevemar"},"change_message_id":"392c30813c2e0dc275117e65ec0bcbef5741414c","unresolved":false,"context_lines":[{"line_number":384,"context_line":"                image_client.images.delete(image_obj.id)"},{"line_number":385,"context_line":"            except Exception as e:"},{"line_number":386,"context_line":"                delresult +\u003d 1"},{"line_number":387,"context_line":"                self.app.log.error(_(\"Failed to delete Image with \""},{"line_number":388,"context_line":"                                   \"name or ID \u0027%(image)s\u0027: %(e)s\")"},{"line_number":389,"context_line":"                                   % {\u0027image\u0027: image, \u0027e\u0027: e})"},{"line_number":390,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"7aa08908_5b136cb8","line":387,"range":{"start_line":387,"start_character":55,"end_line":387,"end_character":60},"updated":"2016-06-13 05:48:33.000000000","message":"image*","commit_id":"e7727b1dc71304a92456db7a5e8be7c43d052e14"}],"openstackclient/tests/image/v2/test_image.py":[{"author":{"_account_id":14937,"name":"Tang Chen","email":"imtangchen@163.com","username":"tangchen"},"change_message_id":"bc94a9e26ea4ccaddc03db8360913e99a4178b40","unresolved":false,"context_lines":[{"line_number":486,"context_line":"        ]"},{"line_number":487,"context_line":""},{"line_number":488,"context_line":"        parsed_args \u003d self.check_parser(self.cmd, arglist, verifylist)"},{"line_number":489,"context_line":"        ret_delete \u003d ["},{"line_number":490,"context_line":"            None,"},{"line_number":491,"context_line":"            None,"},{"line_number":492,"context_line":"            exceptions.NotFound(\u0027404\u0027)"},{"line_number":493,"context_line":"        ]"},{"line_number":494,"context_line":""},{"line_number":495,"context_line":"        self.images_mock.delete \u003d mock.Mock(side_effect\u003dret_delete)"},{"line_number":496,"context_line":"        self.assertRaises(exceptions.CommandError, self.cmd.take_action,"},{"line_number":497,"context_line":"                          parsed_args)"},{"line_number":498,"context_line":"        calls \u003d [mock.call(i.id) for i in images]"}],"source_content_type":"text/x-python","patch_set":3,"id":"7aa08908_d38efcce","line":495,"range":{"start_line":489,"start_character":0,"end_line":495,"end_character":67},"updated":"2016-06-08 08:28:29.000000000","message":"The test is incorrect.\n\nYou created only 2 images, so you should expect the 3rd call of find_resource() fails, not the delete().","commit_id":"7307952ba46b094865a0d430631dffe8d98b7d48"},{"author":{"_account_id":14937,"name":"Tang Chen","email":"imtangchen@163.com","username":"tangchen"},"change_message_id":"f467e5cf56696efdfd571cbcb892067e305cc9f1","unresolved":false,"context_lines":[{"line_number":496,"context_line":"            None,"},{"line_number":497,"context_line":"            exceptions.CommandError,"},{"line_number":498,"context_line":"        ]"},{"line_number":499,"context_line":"        self.images_mock.get \u003d mock.Mock(side_effect\u003dret_get)"},{"line_number":500,"context_line":"        self.images_mock.delete \u003d mock.Mock(side_effect\u003dret_delete)"},{"line_number":501,"context_line":"        self.assertRaises(exceptions.CommandError, self.cmd.take_action,"},{"line_number":502,"context_line":"                          parsed_args)"}],"source_content_type":"text/x-python","patch_set":4,"id":"7aa08908_573f9186","line":499,"range":{"start_line":499,"start_character":25,"end_line":499,"end_character":28},"updated":"2016-06-08 09:42:00.000000000","message":"Please don\u0027t fake get() here. Please refer to the code in test_network.py.\n\n        # Fake exception in utils.find_resource()\n        # In compute v2, we use utils.find_resource() to find a network.\n        # It calls get() several times, but find() only one time. So we\n        # choose to fake get() always raise exception, then pass through.\n        # And fake find() to find the real network or not.\n        self.compute.networks.get.side_effect \u003d Exception()\n        ret_find \u003d [\n            self._networks[0],\n            Exception(),\n            self._networks[1],\n        ]\n        self.compute.networks.find.side_effect \u003d ret_find\n\nIn find_resource(), get() will be called several times. So fake it always to return exception, and fake find() return the correct result instead.","commit_id":"c8fdb0a6455713480afec750799d73e8cbd10793"}]}
