)]}'
{"glance/api/v2/image_data.py":[{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"4f5af9a85d13c88051527c0c4bae58ec694f547d","unresolved":true,"context_lines":[{"line_number":149,"context_line":"        try:"},{"line_number":150,"context_line":"            image \u003d image_repo.get(image_id)"},{"line_number":151,"context_line":"            # NOTE(abhishekk): This is the right place to check whether user"},{"line_number":152,"context_line":"            # have permission to upload the image and remove the policy check"},{"line_number":153,"context_line":"            # later from the policy layer."},{"line_number":154,"context_line":"            api_pol \u003d api_policy.ImageAPIPolicy(req.context, image,"},{"line_number":155,"context_line":"                                                self.policy)"}],"source_content_type":"text/x-python","patch_set":2,"id":"936d7c70_1b53ccc7","line":152,"range":{"start_line":152,"start_character":14,"end_line":152,"end_character":18},"updated":"2021-08-16 17:28:17.000000000","message":"has","commit_id":"b51c071beb12d1cfe3da15332b643b44ec8c5adc"}],"glance/tests/unit/v2/test_image_data_resource.py":[{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"4f5af9a85d13c88051527c0c4bae58ec694f547d","unresolved":true,"context_lines":[{"line_number":131,"context_line":"        # some realistic data"},{"line_number":132,"context_line":"        patcher \u003d mock.patch(\u0027glance.api.v2.policy.check_is_image_mutable\u0027)"},{"line_number":133,"context_line":"        patcher.start()"},{"line_number":134,"context_line":"        self.addCleanup(patcher.stop)"},{"line_number":135,"context_line":""},{"line_number":136,"context_line":"    def test_download(self):"},{"line_number":137,"context_line":"        request \u003d unit_test_utils.get_fake_request()"}],"source_content_type":"text/x-python","patch_set":2,"id":"59622f16_4343c249","line":134,"updated":"2021-08-16 17:28:17.000000000","message":"fixtures.MockPatch does this better, IMHO:\n\nself.useFixture(fixtures.MockPatch(\u0027glance.api...\u0027))\n\n...ensuring we don\u0027t miss the cleanup step. But, not important.","commit_id":"b51c071beb12d1cfe3da15332b643b44ec8c5adc"}],"glance/tests/unit/v2/test_v2_policy.py":[{"author":{"_account_id":8122,"name":"Cyril Roelandt","email":"cyril@redhat.com","username":"cyril.roelandt.enovance"},"change_message_id":"366812bab820f9099e29501bd4294a21f6b412d3","unresolved":true,"context_lines":[{"line_number":249,"context_line":"        self.assertRaises(exception.Forbidden,"},{"line_number":250,"context_line":"                          self.policy.upload_image)"},{"line_number":251,"context_line":""},{"line_number":252,"context_line":"        # Make sure we are checking the legacy handler"},{"line_number":253,"context_line":"        with mock.patch(\u0027glance.api.v2.policy.check_is_image_mutable\u0027) as m:"},{"line_number":254,"context_line":"            self.policy.upload_image()"},{"line_number":255,"context_line":"            m.assert_called_once_with(self.context, self.image)"}],"source_content_type":"text/x-python","patch_set":2,"id":"0bd2f860_7343a72e","line":252,"range":{"start_line":252,"start_character":15,"end_line":252,"end_character":19},"updated":"2021-08-16 14:26:52.000000000","message":"If you need another PS, maybe include a \"TODO: remove this later\" since we are going to need to track all the legacy code \u0026 tests when we get rid of it.","commit_id":"b51c071beb12d1cfe3da15332b643b44ec8c5adc"},{"author":{"_account_id":9303,"name":"Abhishek Kekane","email":"akekane@redhat.com","username":"abhishekkekane"},"change_message_id":"597945aba5b7e3267b81acdb6c8790abb2e28598","unresolved":false,"context_lines":[{"line_number":249,"context_line":"        self.assertRaises(exception.Forbidden,"},{"line_number":250,"context_line":"                          self.policy.upload_image)"},{"line_number":251,"context_line":""},{"line_number":252,"context_line":"        # Make sure we are checking the legacy handler"},{"line_number":253,"context_line":"        with mock.patch(\u0027glance.api.v2.policy.check_is_image_mutable\u0027) as m:"},{"line_number":254,"context_line":"            self.policy.upload_image()"},{"line_number":255,"context_line":"            m.assert_called_once_with(self.context, self.image)"}],"source_content_type":"text/x-python","patch_set":2,"id":"b4a449b6_d08faaa2","line":252,"range":{"start_line":252,"start_character":15,"end_line":252,"end_character":19},"in_reply_to":"0bd2f860_7343a72e","updated":"2021-08-16 14:31:26.000000000","message":"Ack","commit_id":"b51c071beb12d1cfe3da15332b643b44ec8c5adc"},{"author":{"_account_id":4393,"name":"Dan Smith","email":"dms@danplanet.com","username":"danms"},"change_message_id":"4f5af9a85d13c88051527c0c4bae58ec694f547d","unresolved":false,"context_lines":[{"line_number":249,"context_line":"        self.assertRaises(exception.Forbidden,"},{"line_number":250,"context_line":"                          self.policy.upload_image)"},{"line_number":251,"context_line":""},{"line_number":252,"context_line":"        # Make sure we are checking the legacy handler"},{"line_number":253,"context_line":"        with mock.patch(\u0027glance.api.v2.policy.check_is_image_mutable\u0027) as m:"},{"line_number":254,"context_line":"            self.policy.upload_image()"},{"line_number":255,"context_line":"            m.assert_called_once_with(self.context, self.image)"}],"source_content_type":"text/x-python","patch_set":2,"id":"2396ef8b_727087ce","line":252,"range":{"start_line":252,"start_character":15,"end_line":252,"end_character":19},"in_reply_to":"b4a449b6_d08faaa2","updated":"2021-08-16 17:28:17.000000000","message":"I think the \"falls back to legacy\" name implies we remove it when we rip out the legacy stuff. Unless we\u0027re going to tag every single thing with something to find them, I think we rip out the legacy bit and remove/clean everything that fails.","commit_id":"b51c071beb12d1cfe3da15332b643b44ec8c5adc"}]}
