)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":29632,"name":"Carlos Eduardo","email":"ces.eduardo98@gmail.com","username":"silvacarlos"},"change_message_id":"064f56bc6fef34c97ab09eb404cdd04a85d78800","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"50b650c8_9ce31169","updated":"2024-03-07 13:18:15.000000000","message":"Hey, Christian! Thank you for working on this change... It needs some more work though, let me expand:\n\nThe bug mentions: Force delete does not work if share service is down\n\nSo in other words: if you attempt to force delete a share which the share service is down, the share deletion will be stuck.\n\nAs the expected behavior, what we need is: when a service is down, we can use a new manila-manage command to delete a share.\n\nIn you fix, you\u0027re dropping all of the share instances that have their shares in a disabled state, so it will end up dropping things we should not drop.\n\nI believe you could add an argument to the comment where the administrator would be able to specify which share they want to delete and then do the deletion of the share. Releasing quotas here can be challenging though, so we can have more people chiming in on that discussion :)","commit_id":"e7e4583b9b99a73b6a7d3b9766395b576c98381d"},{"author":{"_account_id":36860,"name":"Mike Lutaaya","display_name":"mike-lu","email":"hafswabilan@gmail.com","username":"mike-lu"},"change_message_id":"56da1c60277dd2f1d5bf25f43a995ba565f779d8","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"5e95ad83_2374cf6a","updated":"2024-03-07 12:53:30.000000000","message":"could you try to add unit test for this","commit_id":"e7e4583b9b99a73b6a7d3b9766395b576c98381d"},{"author":{"_account_id":29632,"name":"Carlos Eduardo","email":"ces.eduardo98@gmail.com","username":"silvacarlos"},"change_message_id":"064f56bc6fef34c97ab09eb404cdd04a85d78800","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"81c188c6_0afa928c","in_reply_to":"5e95ad83_2374cf6a","updated":"2024-03-07 13:18:15.000000000","message":"+1","commit_id":"e7e4583b9b99a73b6a7d3b9766395b576c98381d"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"ec493d3295f399b4dcc5cb248b76d34c00ffe4e8","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":4,"id":"b0aaea24_f3adb6f9","updated":"2024-03-09 00:23:51.000000000","message":"Thanks for working on this Christian; please see comments inline","commit_id":"e44a0208555fb81e7cff46b5bb526fd8864c27c1"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"4115034a1b70d02c3f581e7110fe2bd4c500ea9c","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"3bb1dee7_9781ae2c","updated":"2024-03-13 18:15:38.000000000","message":"Thanks for the update; further comments inline","commit_id":"48e2f32a46bd770f87717b103857fc98d3e496e2"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0a6cb5aa7aa3c7d72997165c00fb68f529d67d1d","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":10,"id":"f435f1ce_c89b8190","updated":"2024-03-19 16:25:31.000000000","message":"Thank you for the update Christian; please see further comments inline","commit_id":"fceb19204b01dce7c030699dca2c1074e599db0d"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"c7347875dcb6adff67127aa760404fcccc153cfc","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":14,"id":"1a704d00_0a75d459","updated":"2024-03-25 22:52:41.000000000","message":"Thanks for the update Christian. Please see comments inline","commit_id":"1bda25df3311c44e3ba7c57ac98a858e55a0cf84"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"122a89bf8dcd31d916e9c188558b0be1bb764f68","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":14,"id":"43fb6b3d_49b01aeb","updated":"2024-03-27 06:24:24.000000000","message":"resolved","commit_id":"1bda25df3311c44e3ba7c57ac98a858e55a0cf84"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"e0856163b69a0e2f85838008c7c01b6ece93bf14","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":16,"id":"3e1b49c3_f4ba3d20","updated":"2024-04-02 23:19:21.000000000","message":"Christian, please see comment inline, could you please also add a release note? \n\nhttps://docs.openstack.org/manila/latest/contributor/adding_release_notes.html","commit_id":"64fe7c3d0901e7a3281af0ed493dcc0ca8f8e98a"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"317ba07781a01711c4bf1f5780dd5c96c8751f95","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":17,"id":"bf64f5c5_6a98d9f6","updated":"2024-04-04 11:04:53.000000000","message":"resolved","commit_id":"6cf77ccc65607c6bff3573fb6c7c9ad62224473a"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"29821bbb46f12b222965ff714e824c90b23e9ead","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":18,"id":"f7fdaab5_ba71e71e","updated":"2024-04-04 22:02:07.000000000","message":"Resolved","commit_id":"6ec0331fc24debd0e6df2d9af7c4e2607ace3a4a"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"e8b7d610090cddddc8c560cc44c00f1c2a70cd4a","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":20,"id":"2c334e99_f6b8e04d","updated":"2024-04-05 05:37:49.000000000","message":"Resolved","commit_id":"a98d55714b5c64938d01b85af8def78fc08c784d"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"33b3029731729bd620056cfda8c4430920bc7639","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":21,"id":"25e03327_0d6f1dd9","updated":"2024-04-05 15:10:17.000000000","message":"Resolved","commit_id":"b97ae959cb6a5a6935fd1dc91ed40c2a5af80410"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"e8ebcbddbf1f65f055ef5dc10ff69a262c054a6b","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":21,"id":"cd6fb8c3_617b4ce8","updated":"2024-04-05 14:54:39.000000000","message":"Resolved","commit_id":"b97ae959cb6a5a6935fd1dc91ed40c2a5af80410"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"8c0b7a544cd4985908e3d0ed5104c47803b1095f","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":23,"id":"7294a1b2_50a0d7ea","updated":"2024-04-05 15:12:35.000000000","message":"Christian: good job and thanks; LGTM","commit_id":"23de7b4b0cfb7c3ac4663f395298d19fa7a8776f"},{"author":{"_account_id":29632,"name":"Carlos Eduardo","email":"ces.eduardo98@gmail.com","username":"silvacarlos"},"change_message_id":"446baa7cbc0f2e97335189d91cc63568a3dd5d4b","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":23,"id":"d78ae4f5_05f6cb4d","updated":"2024-04-09 16:18:43.000000000","message":"LGTM, thank you!","commit_id":"23de7b4b0cfb7c3ac4663f395298d19fa7a8776f"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"4b607ce66168d731de0960cbf50fd6e4c0576feb","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":23,"id":"b85509e4_834d2cc8","updated":"2024-04-05 15:11:56.000000000","message":"Resolved","commit_id":"23de7b4b0cfb7c3ac4663f395298d19fa7a8776f"}],"manila/cmd/manage.py":[{"author":{"_account_id":29632,"name":"Carlos Eduardo","email":"ces.eduardo98@gmail.com","username":"silvacarlos"},"change_message_id":"064f56bc6fef34c97ab09eb404cdd04a85d78800","unresolved":true,"context_lines":[{"line_number":402,"context_line":"        }"},{"line_number":403,"context_line":"        print(msg % msg_args)"},{"line_number":404,"context_line":""},{"line_number":405,"context_line":"    def delete(self):"},{"line_number":406,"context_line":"        \"\"\"Delete manila share instances reporting as down\"\"\""},{"line_number":407,"context_line":"        ctxt \u003d context.get_admin_context()"},{"line_number":408,"context_line":"        share_instances \u003d db.share_instance_get_all()"},{"line_number":409,"context_line":""},{"line_number":410,"context_line":"        for share_instance in share_instances:"},{"line_number":411,"context_line":"            if utils.service_is_up(share_instance):"},{"line_number":412,"context_line":"                continue"},{"line_number":413,"context_line":"            db.share_instance_delete(ctxt, share_instance[\u0027id\u0027])"},{"line_number":414,"context_line":"            print(\"Deleted share instance %s\" % share_instance[\u0027id\u0027])"},{"line_number":415,"context_line":""},{"line_number":416,"context_line":""},{"line_number":417,"context_line":"class ShareServerCommands(object):"}],"source_content_type":"text/x-python","patch_set":3,"id":"c147c5f5_d709f772","line":414,"range":{"start_line":405,"start_character":4,"end_line":414,"end_character":69},"updated":"2024-03-07 13:18:15.000000000","message":"You should specify the share you want to delete through this function, otherwise you will end up deleting all shares in a service, and you\u0027d drop likely hundreds or thousands of shares that you didn\u0027t mean to","commit_id":"e7e4583b9b99a73b6a7d3b9766395b576c98381d"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"bccdb9c0c5778a7e55e9d52d9a1982a58570c6f4","unresolved":false,"context_lines":[{"line_number":402,"context_line":"        }"},{"line_number":403,"context_line":"        print(msg % msg_args)"},{"line_number":404,"context_line":""},{"line_number":405,"context_line":"    def delete(self):"},{"line_number":406,"context_line":"        \"\"\"Delete manila share instances reporting as down\"\"\""},{"line_number":407,"context_line":"        ctxt \u003d context.get_admin_context()"},{"line_number":408,"context_line":"        share_instances \u003d db.share_instance_get_all()"},{"line_number":409,"context_line":""},{"line_number":410,"context_line":"        for share_instance in share_instances:"},{"line_number":411,"context_line":"            if utils.service_is_up(share_instance):"},{"line_number":412,"context_line":"                continue"},{"line_number":413,"context_line":"            db.share_instance_delete(ctxt, share_instance[\u0027id\u0027])"},{"line_number":414,"context_line":"            print(\"Deleted share instance %s\" % share_instance[\u0027id\u0027])"},{"line_number":415,"context_line":""},{"line_number":416,"context_line":""},{"line_number":417,"context_line":"class ShareServerCommands(object):"}],"source_content_type":"text/x-python","patch_set":3,"id":"f7bbed9b_82631204","line":414,"range":{"start_line":405,"start_character":4,"end_line":414,"end_character":69},"in_reply_to":"c147c5f5_d709f772","updated":"2024-03-13 11:47:37.000000000","message":"Resolved","commit_id":"e7e4583b9b99a73b6a7d3b9766395b576c98381d"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"ec493d3295f399b4dcc5cb248b76d34c00ffe4e8","unresolved":true,"context_lines":[{"line_number":401,"context_line":"            \u0027nhost\u0027: new_host,"},{"line_number":402,"context_line":"        }"},{"line_number":403,"context_line":"        print(msg % msg_args)"},{"line_number":404,"context_line":""},{"line_number":405,"context_line":"    def delete(self, share_instance_id):"},{"line_number":406,"context_line":"        \"\"\"Delete manila share instances reporting as down\"\"\""},{"line_number":407,"context_line":"        ctxt \u003d context.get_admin_context()"}],"source_content_type":"text/x-python","patch_set":4,"id":"bf04dfc2_ead00cdf","line":404,"updated":"2024-03-09 00:23:51.000000000","message":"If you accept any arguments, you need to allow a way to provide them.. \ni.e., you need to add the argument to the parser via @args(...) see the method above.. \n\nhere, you need to accept a \"share_id\" (and not a share_instance_id, see further comments)","commit_id":"e44a0208555fb81e7cff46b5bb526fd8864c27c1"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"bccdb9c0c5778a7e55e9d52d9a1982a58570c6f4","unresolved":false,"context_lines":[{"line_number":401,"context_line":"            \u0027nhost\u0027: new_host,"},{"line_number":402,"context_line":"        }"},{"line_number":403,"context_line":"        print(msg % msg_args)"},{"line_number":404,"context_line":""},{"line_number":405,"context_line":"    def delete(self, share_instance_id):"},{"line_number":406,"context_line":"        \"\"\"Delete manila share instances reporting as down\"\"\""},{"line_number":407,"context_line":"        ctxt \u003d context.get_admin_context()"}],"source_content_type":"text/x-python","patch_set":4,"id":"390da306_85fddd34","line":404,"in_reply_to":"bf04dfc2_ead00cdf","updated":"2024-03-13 11:47:37.000000000","message":"Resolved","commit_id":"e44a0208555fb81e7cff46b5bb526fd8864c27c1"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"ec493d3295f399b4dcc5cb248b76d34c00ffe4e8","unresolved":true,"context_lines":[{"line_number":402,"context_line":"        }"},{"line_number":403,"context_line":"        print(msg % msg_args)"},{"line_number":404,"context_line":""},{"line_number":405,"context_line":"    def delete(self, share_instance_id):"},{"line_number":406,"context_line":"        \"\"\"Delete manila share instances reporting as down\"\"\""},{"line_number":407,"context_line":"        ctxt \u003d context.get_admin_context()"},{"line_number":408,"context_line":"        share_instance \u003d db.share_instance_get(ctxt, share_instance_id)"}],"source_content_type":"text/x-python","patch_set":4,"id":"3cc32c0e_25c0c9b4","line":405,"range":{"start_line":405,"start_character":21,"end_line":405,"end_character":38},"updated":"2024-03-09 00:23:51.000000000","message":"\"share_id\"\n\nnot share_instance_id\n\nyou\u0027re implementing a way to delete shares, not individual share instances","commit_id":"e44a0208555fb81e7cff46b5bb526fd8864c27c1"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"bccdb9c0c5778a7e55e9d52d9a1982a58570c6f4","unresolved":false,"context_lines":[{"line_number":402,"context_line":"        }"},{"line_number":403,"context_line":"        print(msg % msg_args)"},{"line_number":404,"context_line":""},{"line_number":405,"context_line":"    def delete(self, share_instance_id):"},{"line_number":406,"context_line":"        \"\"\"Delete manila share instances reporting as down\"\"\""},{"line_number":407,"context_line":"        ctxt \u003d context.get_admin_context()"},{"line_number":408,"context_line":"        share_instance \u003d db.share_instance_get(ctxt, share_instance_id)"}],"source_content_type":"text/x-python","patch_set":4,"id":"36a859af_7c5cf16d","line":405,"range":{"start_line":405,"start_character":21,"end_line":405,"end_character":38},"in_reply_to":"3cc32c0e_25c0c9b4","updated":"2024-03-13 11:47:37.000000000","message":"Resolved","commit_id":"e44a0208555fb81e7cff46b5bb526fd8864c27c1"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"ec493d3295f399b4dcc5cb248b76d34c00ffe4e8","unresolved":true,"context_lines":[{"line_number":405,"context_line":"    def delete(self, share_instance_id):"},{"line_number":406,"context_line":"        \"\"\"Delete manila share instances reporting as down\"\"\""},{"line_number":407,"context_line":"        ctxt \u003d context.get_admin_context()"},{"line_number":408,"context_line":"        share_instance \u003d db.share_instance_get(ctxt, share_instance_id)"},{"line_number":409,"context_line":""},{"line_number":410,"context_line":"        if not share_instance and utils.service_is_up(share_instance_id):"},{"line_number":411,"context_line":"            print(\"Share instance not found or service is still up %s\""}],"source_content_type":"text/x-python","patch_set":4,"id":"ce89acf9_d829b779","line":408,"range":{"start_line":408,"start_character":28,"end_line":408,"end_character":46},"updated":"2024-03-09 00:23:51.000000000","message":"share_get","commit_id":"e44a0208555fb81e7cff46b5bb526fd8864c27c1"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"bccdb9c0c5778a7e55e9d52d9a1982a58570c6f4","unresolved":false,"context_lines":[{"line_number":405,"context_line":"    def delete(self, share_instance_id):"},{"line_number":406,"context_line":"        \"\"\"Delete manila share instances reporting as down\"\"\""},{"line_number":407,"context_line":"        ctxt \u003d context.get_admin_context()"},{"line_number":408,"context_line":"        share_instance \u003d db.share_instance_get(ctxt, share_instance_id)"},{"line_number":409,"context_line":""},{"line_number":410,"context_line":"        if not share_instance and utils.service_is_up(share_instance_id):"},{"line_number":411,"context_line":"            print(\"Share instance not found or service is still up %s\""}],"source_content_type":"text/x-python","patch_set":4,"id":"626338f0_947d6ea5","line":408,"range":{"start_line":408,"start_character":28,"end_line":408,"end_character":46},"in_reply_to":"ce89acf9_d829b779","updated":"2024-03-13 11:47:37.000000000","message":"Resolved","commit_id":"e44a0208555fb81e7cff46b5bb526fd8864c27c1"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"ec493d3295f399b4dcc5cb248b76d34c00ffe4e8","unresolved":true,"context_lines":[{"line_number":407,"context_line":"        ctxt \u003d context.get_admin_context()"},{"line_number":408,"context_line":"        share_instance \u003d db.share_instance_get(ctxt, share_instance_id)"},{"line_number":409,"context_line":""},{"line_number":410,"context_line":"        if not share_instance and utils.service_is_up(share_instance_id):"},{"line_number":411,"context_line":"            print(\"Share instance not found or service is still up %s\""},{"line_number":412,"context_line":"                  % share_instance_id)"},{"line_number":413,"context_line":"            sys.exit(1)"}],"source_content_type":"text/x-python","patch_set":4,"id":"82d86d6d_c05e0d56","line":410,"range":{"start_line":410,"start_character":40,"end_line":410,"end_character":53},"updated":"2024-03-09 00:23:51.000000000","message":"\"service_is_up\" has to be done with a service, it can\u0027t be done with a share instance\n\n\nAlso, this condition seems incorrect:\n\nyou\u0027re using \"and\"; so effectively you\u0027re testing if:\n\n1) You don\u0027t have a share instance _and_\n2) The service is operational\n\n\nif you don\u0027t have a share instance, line 408 will blow up with a ShareNotFound error, and won\u0027t reach this condition. \n\nFurther, I don\u0027t understand the service is up check - is your intention to disallow this style of deletion if the service is up? \n\n\nPlease re-write this with \"share\".. (and not share_instance) and then we can have a discussion around what to do further","commit_id":"e44a0208555fb81e7cff46b5bb526fd8864c27c1"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"bccdb9c0c5778a7e55e9d52d9a1982a58570c6f4","unresolved":true,"context_lines":[{"line_number":407,"context_line":"        ctxt \u003d context.get_admin_context()"},{"line_number":408,"context_line":"        share_instance \u003d db.share_instance_get(ctxt, share_instance_id)"},{"line_number":409,"context_line":""},{"line_number":410,"context_line":"        if not share_instance and utils.service_is_up(share_instance_id):"},{"line_number":411,"context_line":"            print(\"Share instance not found or service is still up %s\""},{"line_number":412,"context_line":"                  % share_instance_id)"},{"line_number":413,"context_line":"            sys.exit(1)"}],"source_content_type":"text/x-python","patch_set":4,"id":"983c3800_8051b2b3","line":410,"range":{"start_line":410,"start_character":40,"end_line":410,"end_character":53},"in_reply_to":"82d86d6d_c05e0d56","updated":"2024-03-13 11:47:37.000000000","message":"Thanks for the review.\nI have updated the implementation. However, like you mentioned, we need to decide what to do further if we found the share that the admin is attempting to delete.\nDo we use force delete or soft delete?","commit_id":"e44a0208555fb81e7cff46b5bb526fd8864c27c1"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"2d8c7aceb9f4afe9653824eccad285f52c82c4b6","unresolved":false,"context_lines":[{"line_number":407,"context_line":"        ctxt \u003d context.get_admin_context()"},{"line_number":408,"context_line":"        share_instance \u003d db.share_instance_get(ctxt, share_instance_id)"},{"line_number":409,"context_line":""},{"line_number":410,"context_line":"        if not share_instance and utils.service_is_up(share_instance_id):"},{"line_number":411,"context_line":"            print(\"Share instance not found or service is still up %s\""},{"line_number":412,"context_line":"                  % share_instance_id)"},{"line_number":413,"context_line":"            sys.exit(1)"}],"source_content_type":"text/x-python","patch_set":4,"id":"130a2539_4cb99738","line":410,"range":{"start_line":410,"start_character":40,"end_line":410,"end_character":53},"in_reply_to":"983c3800_8051b2b3","updated":"2024-03-16 09:23:07.000000000","message":"Resolved","commit_id":"e44a0208555fb81e7cff46b5bb526fd8864c27c1"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"4115034a1b70d02c3f581e7110fe2bd4c500ea9c","unresolved":true,"context_lines":[{"line_number":405,"context_line":""},{"line_number":406,"context_line":"    @args(\u0027--share_id\u0027, required\u003dTrue, help\u003dSHARE_DELETE_HELP)"},{"line_number":407,"context_line":"    def delete(self, share_id):"},{"line_number":408,"context_line":"        \"\"\"Delete manila share reporting as down\"\"\""},{"line_number":409,"context_line":"        ctxt \u003d context.get_admin_context()"},{"line_number":410,"context_line":"        share \u003d db.share_get(ctxt, share_id)"},{"line_number":411,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"228202a9_d19f564a","line":408,"range":{"start_line":408,"start_character":31,"end_line":408,"end_character":48},"updated":"2024-03-13 18:15:38.000000000","message":"Convert this into a multiline comment with some more detail:\n\n```\n\n\"\"\"\nDelete manila share from the database. \n\nThis command is useful after a share\u0027s manager service\nhas been decommissioned.\n\"\"\"\n```","commit_id":"48e2f32a46bd770f87717b103857fc98d3e496e2"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"b9d9296330b15d6977ad748b5a35b8740ad5f5f4","unresolved":false,"context_lines":[{"line_number":405,"context_line":""},{"line_number":406,"context_line":"    @args(\u0027--share_id\u0027, required\u003dTrue, help\u003dSHARE_DELETE_HELP)"},{"line_number":407,"context_line":"    def delete(self, share_id):"},{"line_number":408,"context_line":"        \"\"\"Delete manila share reporting as down\"\"\""},{"line_number":409,"context_line":"        ctxt \u003d context.get_admin_context()"},{"line_number":410,"context_line":"        share \u003d db.share_get(ctxt, share_id)"},{"line_number":411,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"35a72a75_a1911300","line":408,"range":{"start_line":408,"start_character":31,"end_line":408,"end_character":48},"in_reply_to":"228202a9_d19f564a","updated":"2024-03-16 09:22:43.000000000","message":"Resolved","commit_id":"48e2f32a46bd770f87717b103857fc98d3e496e2"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"4115034a1b70d02c3f581e7110fe2bd4c500ea9c","unresolved":true,"context_lines":[{"line_number":409,"context_line":"        ctxt \u003d context.get_admin_context()"},{"line_number":410,"context_line":"        share \u003d db.share_get(ctxt, share_id)"},{"line_number":411,"context_line":""},{"line_number":412,"context_line":"        if share:"},{"line_number":413,"context_line":"            db.share_delete(ctxt, share_id)"},{"line_number":414,"context_line":"            print(\"Deleted share %s\" % share_id)"},{"line_number":415,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"f3a64c5b_c90ba2d6","line":412,"range":{"start_line":412,"start_character":8,"end_line":412,"end_character":16},"updated":"2024-03-13 18:15:38.000000000","message":"no need for this; if there\u0027s no share, share_get raises a NotFound exception: https://github.com/openstack/manila/blob/1bfbfac266808077b7ab35c8ff2f5f52a5923ae1/manila/db/sqlalchemy/api.py#L2371-L2381","commit_id":"48e2f32a46bd770f87717b103857fc98d3e496e2"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"b9d9296330b15d6977ad748b5a35b8740ad5f5f4","unresolved":false,"context_lines":[{"line_number":409,"context_line":"        ctxt \u003d context.get_admin_context()"},{"line_number":410,"context_line":"        share \u003d db.share_get(ctxt, share_id)"},{"line_number":411,"context_line":""},{"line_number":412,"context_line":"        if share:"},{"line_number":413,"context_line":"            db.share_delete(ctxt, share_id)"},{"line_number":414,"context_line":"            print(\"Deleted share %s\" % share_id)"},{"line_number":415,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"6d6de255_649ec9b4","line":412,"range":{"start_line":412,"start_character":8,"end_line":412,"end_character":16},"in_reply_to":"f3a64c5b_c90ba2d6","updated":"2024-03-16 09:22:43.000000000","message":"Resolved","commit_id":"48e2f32a46bd770f87717b103857fc98d3e496e2"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"4115034a1b70d02c3f581e7110fe2bd4c500ea9c","unresolved":true,"context_lines":[{"line_number":410,"context_line":"        share \u003d db.share_get(ctxt, share_id)"},{"line_number":411,"context_line":""},{"line_number":412,"context_line":"        if share:"},{"line_number":413,"context_line":"            db.share_delete(ctxt, share_id)"},{"line_number":414,"context_line":"            print(\"Deleted share %s\" % share_id)"},{"line_number":415,"context_line":""},{"line_number":416,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"c0224302_0bd82d5c","line":413,"range":{"start_line":413,"start_character":15,"end_line":413,"end_character":27},"updated":"2024-03-13 18:15:38.000000000","message":"this won\u0027t work... \n\ntake a look at https://github.com/openstack/manila/blob/master/manila/db/sqlalchemy/api.py#L2602-L2605\n\nWe prevent deleting shares with any share instances left. \nAny valid share will have at least one share instance.\n\nSo, after you retrieve the share, you\u0027d need to delete the share\u0027s instances first before deleting the share itself.. \n\nSo iterate through share[\u0027instances\u0027] and delete each of them with db.share_instance_delete. \n\nThis may not be a concern at this stage, but for correctness, i want to suggest doing another thing:\n\nlets do this deletion in a specific order: \n\nShare instances have a field called \"replica_state\"; ensure that you separate the \"active\" replica (instance[\"replica_state\"]\u003d\u003d\"active\") from all the other replicas.. so something like:\n\n\n```\n   active_replicas \u003d []\n   # We delete \"active\" replicas at the end\n   for instance in share[\u0027instances\u0027]\n       if instance[\u0027replica_state\u0027] \u003d\u003d \"active\":\n           active_replicas.append(instance)\n        else:\n          db.share_instance_delete(ctxt, share_instance[\u0027id\u0027])\n    for instance in active_replicas:\n        db.share_instance_delete(ctxt, share_instance[\u0027id\u0027]) \n        \n   # finally, clean up the share\n   db.share_delete(ctxt, share_id)  \n    \n```\n\n\nWhen you do this; please also add a unit test in https://github.com/openstack/manila/blob/master/manila/tests/cmd/test_manage.py","commit_id":"48e2f32a46bd770f87717b103857fc98d3e496e2"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"b9d9296330b15d6977ad748b5a35b8740ad5f5f4","unresolved":false,"context_lines":[{"line_number":410,"context_line":"        share \u003d db.share_get(ctxt, share_id)"},{"line_number":411,"context_line":""},{"line_number":412,"context_line":"        if share:"},{"line_number":413,"context_line":"            db.share_delete(ctxt, share_id)"},{"line_number":414,"context_line":"            print(\"Deleted share %s\" % share_id)"},{"line_number":415,"context_line":""},{"line_number":416,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"7fc94767_1045a5ff","line":413,"range":{"start_line":413,"start_character":15,"end_line":413,"end_character":27},"in_reply_to":"c0224302_0bd82d5c","updated":"2024-03-16 09:22:43.000000000","message":"Resolved","commit_id":"48e2f32a46bd770f87717b103857fc98d3e496e2"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0a6cb5aa7aa3c7d72997165c00fb68f529d67d1d","unresolved":true,"context_lines":[{"line_number":424,"context_line":"            db.share_instance_delete(ctxt, share_instance[\u0027id\u0027])"},{"line_number":425,"context_line":""},{"line_number":426,"context_line":"        # finally, clean up the share"},{"line_number":427,"context_line":"        db.share_delete(ctxt, share_id)"},{"line_number":428,"context_line":""},{"line_number":429,"context_line":""},{"line_number":430,"context_line":"class ShareServerCommands(object):"}],"source_content_type":"text/x-python","patch_set":10,"id":"7af5627a_a9f83fef","line":427,"updated":"2024-03-19 16:25:31.000000000","message":"please restore the print statement.. its useful to know the share was successfully deleted.","commit_id":"fceb19204b01dce7c030699dca2c1074e599db0d"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"9a4fbc4e0ee562526727c0e81b8dbabbc21cc604","unresolved":false,"context_lines":[{"line_number":424,"context_line":"            db.share_instance_delete(ctxt, share_instance[\u0027id\u0027])"},{"line_number":425,"context_line":""},{"line_number":426,"context_line":"        # finally, clean up the share"},{"line_number":427,"context_line":"        db.share_delete(ctxt, share_id)"},{"line_number":428,"context_line":""},{"line_number":429,"context_line":""},{"line_number":430,"context_line":"class ShareServerCommands(object):"}],"source_content_type":"text/x-python","patch_set":10,"id":"e9d8a83f_3594e21a","line":427,"in_reply_to":"7af5627a_a9f83fef","updated":"2024-03-20 12:42:05.000000000","message":"Resolved","commit_id":"fceb19204b01dce7c030699dca2c1074e599db0d"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"a671be1688e39b2add0624e08dbc784dc092d297","unresolved":true,"context_lines":[{"line_number":425,"context_line":"            print(\"Deleted share instance %s\" % share_instance[\u0027id\u0027])"},{"line_number":426,"context_line":""},{"line_number":427,"context_line":"        # finally, clean up the share"},{"line_number":428,"context_line":"        db.share_delete(ctxt, share_id)"},{"line_number":429,"context_line":""},{"line_number":430,"context_line":""},{"line_number":431,"context_line":"class ShareServerCommands(object):"}],"source_content_type":"text/x-python","patch_set":12,"id":"d1f57de0_cfb96e75","line":428,"updated":"2024-03-20 21:39:21.000000000","message":"add a print statement here as well:\n\nprint(\"Deleted share %s\" % share_id)","commit_id":"fe1f6fdd3269d7c9ebb1422a841d9e89001c28de"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"2ebf6905a4f415d1bd93b372d35e7e11cb3ee1fb","unresolved":false,"context_lines":[{"line_number":425,"context_line":"            print(\"Deleted share instance %s\" % share_instance[\u0027id\u0027])"},{"line_number":426,"context_line":""},{"line_number":427,"context_line":"        # finally, clean up the share"},{"line_number":428,"context_line":"        db.share_delete(ctxt, share_id)"},{"line_number":429,"context_line":""},{"line_number":430,"context_line":""},{"line_number":431,"context_line":"class ShareServerCommands(object):"}],"source_content_type":"text/x-python","patch_set":12,"id":"f773b159_b1cdddd8","line":428,"in_reply_to":"d1f57de0_cfb96e75","updated":"2024-03-22 14:16:37.000000000","message":"Resolved","commit_id":"fe1f6fdd3269d7c9ebb1422a841d9e89001c28de"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"c7347875dcb6adff67127aa760404fcccc153cfc","unresolved":true,"context_lines":[{"line_number":403,"context_line":"        }"},{"line_number":404,"context_line":"        print(msg % msg_args)"},{"line_number":405,"context_line":""},{"line_number":406,"context_line":"    @args(\u0027--share_id\u0027, required\u003dTrue, help\u003dSHARE_DELETE_HELP)"},{"line_number":407,"context_line":"    def delete(self, share_id):"},{"line_number":408,"context_line":"        \"\"\"Delete manila share from the database."},{"line_number":409,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"2fbeda27_881ade8f","line":406,"range":{"start_line":406,"start_character":13,"end_line":406,"end_character":21},"updated":"2024-03-25 22:52:41.000000000","message":"please use a hyphen, not underscore in option names","commit_id":"1bda25df3311c44e3ba7c57ac98a858e55a0cf84"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"ef920711380acd289b5577eee1d68934f29ac98d","unresolved":false,"context_lines":[{"line_number":403,"context_line":"        }"},{"line_number":404,"context_line":"        print(msg % msg_args)"},{"line_number":405,"context_line":""},{"line_number":406,"context_line":"    @args(\u0027--share_id\u0027, required\u003dTrue, help\u003dSHARE_DELETE_HELP)"},{"line_number":407,"context_line":"    def delete(self, share_id):"},{"line_number":408,"context_line":"        \"\"\"Delete manila share from the database."},{"line_number":409,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"da53e577_f3a941ad","line":406,"range":{"start_line":406,"start_character":13,"end_line":406,"end_character":21},"in_reply_to":"2fbeda27_881ade8f","updated":"2024-03-27 06:28:15.000000000","message":"resolved","commit_id":"1bda25df3311c44e3ba7c57ac98a858e55a0cf84"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"c7347875dcb6adff67127aa760404fcccc153cfc","unresolved":true,"context_lines":[{"line_number":425,"context_line":"            print(\"Deleted share instance %s\" % share_instance[\u0027id\u0027])"},{"line_number":426,"context_line":""},{"line_number":427,"context_line":"        # finally, clean up the share"},{"line_number":428,"context_line":"        db.share_delete(ctxt, share_id)"},{"line_number":429,"context_line":"        print(\"Deleted share %s\" % share_id)"},{"line_number":430,"context_line":""},{"line_number":431,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"591c86e4_e13505a9","line":428,"range":{"start_line":428,"start_character":0,"end_line":428,"end_character":39},"updated":"2024-03-25 22:52:41.000000000","message":"So mocking stuff in unit tests incorrectly will trick the tests. I tried running this on devstack and I ran into an error at this step... (the command fails with \"ShareNotFound\" error, always) \n\nYou don\u0027t need this; because: https://github.com/openstack/manila/blob/36549c8b97dad72a55bdc7a7ef58a4c5d06944be/manila/db/sqlalchemy/api.py#L1921-L1933\n\nWhen deleting the last share instance, the \"share_instance_delete\" sqlalchemy method is deleting the share object as well.","commit_id":"1bda25df3311c44e3ba7c57ac98a858e55a0cf84"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"ef920711380acd289b5577eee1d68934f29ac98d","unresolved":false,"context_lines":[{"line_number":425,"context_line":"            print(\"Deleted share instance %s\" % share_instance[\u0027id\u0027])"},{"line_number":426,"context_line":""},{"line_number":427,"context_line":"        # finally, clean up the share"},{"line_number":428,"context_line":"        db.share_delete(ctxt, share_id)"},{"line_number":429,"context_line":"        print(\"Deleted share %s\" % share_id)"},{"line_number":430,"context_line":""},{"line_number":431,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"2c79805e_75b0acda","line":428,"range":{"start_line":428,"start_character":0,"end_line":428,"end_character":39},"in_reply_to":"591c86e4_e13505a9","updated":"2024-03-27 06:28:15.000000000","message":"resolved","commit_id":"1bda25df3311c44e3ba7c57ac98a858e55a0cf84"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"e0856163b69a0e2f85838008c7c01b6ece93bf14","unresolved":true,"context_lines":[{"line_number":403,"context_line":"        }"},{"line_number":404,"context_line":"        print(msg % msg_args)"},{"line_number":405,"context_line":""},{"line_number":406,"context_line":"    @args(\u0027--share-id\u0027, required\u003dTrue, help\u003dSHARE_DELETE_HELP)"},{"line_number":407,"context_line":"    def delete(self, share_id):"},{"line_number":408,"context_line":"        \"\"\"Delete manila share from the database."},{"line_number":409,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"f0055ea0_6845d992","line":406,"range":{"start_line":406,"start_character":11,"end_line":406,"end_character":21},"updated":"2024-04-02 23:19:21.000000000","message":"okay this won\u0027t work.. \n\ni\u0027m gettng this error:\n\n\n````\n(venv) stack@zorilla-srbac:~/manila$ manila-manage share delete --share c44a2115-95d7-4e0e-b744-514bf397c8fe\nCRITICAL manila [-] Unhandled error: oslo_config.cfg.NoSuchOptError: no such option share-id in group [DEFAULT]\nERROR manila Traceback (most recent call last):\nERROR manila   File \"/opt/stack/data/venv/lib/python3.10/site-packages/oslo_config/cfg.py\", line 3210, in __getattr__\nERROR manila     return getattr(self._conf._namespace, name)\nERROR manila AttributeError: \u0027_Namespace\u0027 object has no attribute \u0027share-id\u0027\nERROR manila\nERROR manila During handling of the above exception, another exception occurred:\nERROR manila\nERROR manila Traceback (most recent call last):\nERROR manila   File \"/opt/stack/data/venv/bin/manila-manage\", line 10, in \u003cmodule\u003e\nERROR manila     sys.exit(main())\nERROR manila   File \"/opt/stack/manila/manila/cmd/manage.py\", line 568, in main\nERROR manila     fn_args \u003d fetch_func_args(fn)\nERROR manila   File \"/opt/stack/manila/manila/cmd/manage.py\", line 538, in fetch_func_args\nERROR manila     fn_args.append(getattr(CONF.category, arg))\nERROR manila   File \"/opt/stack/data/venv/lib/python3.10/site-packages/oslo_config/cfg.py\", line 3212, in __getattr__\nERROR manila     raise NoSuchOptError(name)\nERROR manila oslo_config.cfg.NoSuchOptError: no such option share-id in group [DEFAULT]\nERROR manila\n````\n\nThis is because we\u0027re using oslo config\u0027s CLI Opts interface that disallows hyphens in variable (option) names. Please revert this to \"share_id\".","commit_id":"64fe7c3d0901e7a3281af0ed493dcc0ca8f8e98a"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"317ba07781a01711c4bf1f5780dd5c96c8751f95","unresolved":false,"context_lines":[{"line_number":403,"context_line":"        }"},{"line_number":404,"context_line":"        print(msg % msg_args)"},{"line_number":405,"context_line":""},{"line_number":406,"context_line":"    @args(\u0027--share-id\u0027, required\u003dTrue, help\u003dSHARE_DELETE_HELP)"},{"line_number":407,"context_line":"    def delete(self, share_id):"},{"line_number":408,"context_line":"        \"\"\"Delete manila share from the database."},{"line_number":409,"context_line":""}],"source_content_type":"text/x-python","patch_set":16,"id":"e55d3866_eb81ec7b","line":406,"range":{"start_line":406,"start_character":11,"end_line":406,"end_character":21},"in_reply_to":"f0055ea0_6845d992","updated":"2024-04-04 11:04:53.000000000","message":"resolved","commit_id":"64fe7c3d0901e7a3281af0ed493dcc0ca8f8e98a"}],"manila/share/api.py":[{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"ec493d3295f399b4dcc5cb248b76d34c00ffe4e8","unresolved":true,"context_lines":[{"line_number":1441,"context_line":"        # Status will be changed in manila.share.manager after verification"},{"line_number":1442,"context_line":"        # for race condition between share creation on server"},{"line_number":1443,"context_line":"        # and server deletion."},{"line_number":1444,"context_line":""},{"line_number":1445,"context_line":"        self.share_rpcapi.delete_share_server(context, server)"},{"line_number":1446,"context_line":""},{"line_number":1447,"context_line":"    def manage_share_server("}],"source_content_type":"text/x-python","patch_set":4,"id":"a61205ed_b68823d1","line":1444,"updated":"2024-03-09 00:23:51.000000000","message":"please undo this unrelated whitespace change","commit_id":"e44a0208555fb81e7cff46b5bb526fd8864c27c1"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"fc6b6c90c1ce68a2a9b0262efec50d2d743b96d1","unresolved":false,"context_lines":[{"line_number":1441,"context_line":"        # Status will be changed in manila.share.manager after verification"},{"line_number":1442,"context_line":"        # for race condition between share creation on server"},{"line_number":1443,"context_line":"        # and server deletion."},{"line_number":1444,"context_line":""},{"line_number":1445,"context_line":"        self.share_rpcapi.delete_share_server(context, server)"},{"line_number":1446,"context_line":""},{"line_number":1447,"context_line":"    def manage_share_server("}],"source_content_type":"text/x-python","patch_set":4,"id":"66711f7b_e736b84b","line":1444,"in_reply_to":"a61205ed_b68823d1","updated":"2024-03-13 11:57:51.000000000","message":"Resolved","commit_id":"e44a0208555fb81e7cff46b5bb526fd8864c27c1"}],"manila/tests/cmd/test_manage.py":[{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0a6cb5aa7aa3c7d72997165c00fb68f529d67d1d","unresolved":true,"context_lines":[{"line_number":442,"context_line":"    @ddt.data("},{"line_number":443,"context_line":"            {\u0027id\u0027: \u0027fake_share_id\u0027}"},{"line_number":444,"context_line":"            )"},{"line_number":445,"context_line":"    @ddt.unpack"},{"line_number":446,"context_line":"    def test_share_delete(self, share):"},{"line_number":447,"context_line":"        share_id \u003d share[\u0027id\u0027]"},{"line_number":448,"context_line":"        share_instances \u003d {"}],"source_content_type":"text/x-python","patch_set":10,"id":"f53f3966_776e5b27","line":445,"range":{"start_line":445,"start_character":3,"end_line":445,"end_character":15},"updated":"2024-03-19 16:25:31.000000000","message":"\"unpack\" allows you to pass objects and have them unpacked into multiple variables... in this case, you just have one item... why even use ddt at all? \n\njust set the \"id\" to \"fake_share_id\" on line 449","commit_id":"fceb19204b01dce7c030699dca2c1074e599db0d"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"9a4fbc4e0ee562526727c0e81b8dbabbc21cc604","unresolved":false,"context_lines":[{"line_number":442,"context_line":"    @ddt.data("},{"line_number":443,"context_line":"            {\u0027id\u0027: \u0027fake_share_id\u0027}"},{"line_number":444,"context_line":"            )"},{"line_number":445,"context_line":"    @ddt.unpack"},{"line_number":446,"context_line":"    def test_share_delete(self, share):"},{"line_number":447,"context_line":"        share_id \u003d share[\u0027id\u0027]"},{"line_number":448,"context_line":"        share_instances \u003d {"}],"source_content_type":"text/x-python","patch_set":10,"id":"9c606539_c8df8f99","line":445,"range":{"start_line":445,"start_character":3,"end_line":445,"end_character":15},"in_reply_to":"f53f3966_776e5b27","updated":"2024-03-20 12:42:05.000000000","message":"Resolved","commit_id":"fceb19204b01dce7c030699dca2c1074e599db0d"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0a6cb5aa7aa3c7d72997165c00fb68f529d67d1d","unresolved":true,"context_lines":[{"line_number":445,"context_line":"    @ddt.unpack"},{"line_number":446,"context_line":"    def test_share_delete(self, share):"},{"line_number":447,"context_line":"        share_id \u003d share[\u0027id\u0027]"},{"line_number":448,"context_line":"        share_instances \u003d {"},{"line_number":449,"context_line":"            \u0027id\u0027: share_id,"},{"line_number":450,"context_line":"            \u0027instances\u0027: ["},{"line_number":451,"context_line":"                {\u0027id\u0027: \u0027instance_id1\u0027, \u0027replica_state\u0027: \u0027active\u0027},"}],"source_content_type":"text/x-python","patch_set":10,"id":"cc849e18_f8e2682c","line":448,"range":{"start_line":448,"start_character":8,"end_line":448,"end_character":23},"updated":"2024-03-19 16:25:31.000000000","message":"this is a share, not just a list of share instances..","commit_id":"fceb19204b01dce7c030699dca2c1074e599db0d"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"9a4fbc4e0ee562526727c0e81b8dbabbc21cc604","unresolved":false,"context_lines":[{"line_number":445,"context_line":"    @ddt.unpack"},{"line_number":446,"context_line":"    def test_share_delete(self, share):"},{"line_number":447,"context_line":"        share_id \u003d share[\u0027id\u0027]"},{"line_number":448,"context_line":"        share_instances \u003d {"},{"line_number":449,"context_line":"            \u0027id\u0027: share_id,"},{"line_number":450,"context_line":"            \u0027instances\u0027: ["},{"line_number":451,"context_line":"                {\u0027id\u0027: \u0027instance_id1\u0027, \u0027replica_state\u0027: \u0027active\u0027},"}],"source_content_type":"text/x-python","patch_set":10,"id":"ee84909e_8cf3fc3c","line":448,"range":{"start_line":448,"start_character":8,"end_line":448,"end_character":23},"in_reply_to":"cc849e18_f8e2682c","updated":"2024-03-20 12:42:05.000000000","message":"Resolved","commit_id":"fceb19204b01dce7c030699dca2c1074e599db0d"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"0a6cb5aa7aa3c7d72997165c00fb68f529d67d1d","unresolved":true,"context_lines":[{"line_number":462,"context_line":""},{"line_number":463,"context_line":"        self.share_cmds.delete(share_id)"},{"line_number":464,"context_line":""},{"line_number":465,"context_line":"        mock.db.share_instance_delete.assert_any_call(\u0027admin_ctxt\u0027,"},{"line_number":466,"context_line":"                                                      \u0027instance_id1\u0027)"},{"line_number":467,"context_line":"        mock.db.share_instance_delete.assert_any_call(\u0027admin_ctxt\u0027,"},{"line_number":468,"context_line":"                                                      \u0027instance_id2\u0027)"},{"line_number":469,"context_line":"        mock.db.share_instance_delete.assert_any_call(\u0027admin_ctxt\u0027,"},{"line_number":470,"context_line":"                                                      \u0027instance_id3\u0027)"},{"line_number":471,"context_line":"        mock.db.share_delete.assert_called_once_with(\u0027admin_ctxt\u0027,"},{"line_number":472,"context_line":"                                                     share_id)"},{"line_number":473,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"08d6e27b_769c3089","line":470,"range":{"start_line":465,"start_character":8,"end_line":470,"end_character":69},"updated":"2024-03-19 16:25:31.000000000","message":"replace this with:\n\n\n```\n   mock.db.share_instance_delete.assert_has_calls([\n       mock.call(\u0027admin_ctxt\u0027, \u0027instance_id2\u0027),\n       mock.call(\u0027admin_ctxt\u0027, \u0027instance_id1\u0027),\n       mock.call(\u0027admin_ctxt\u0027, \u0027instance_id3\u0027),\n   ])\n```\nand then:\n\n```\nself.assertEqual(3, mock.db.share_instance_delete.call_count)\n```   \n\nThis will tighten the asserts and ensure two things:\n1) The call order... we want the \"active\" replicas to be deleted at the end\n2) The call count - you want to make sure the method is called exactly the same number of times as we expect.","commit_id":"fceb19204b01dce7c030699dca2c1074e599db0d"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"9a4fbc4e0ee562526727c0e81b8dbabbc21cc604","unresolved":false,"context_lines":[{"line_number":462,"context_line":""},{"line_number":463,"context_line":"        self.share_cmds.delete(share_id)"},{"line_number":464,"context_line":""},{"line_number":465,"context_line":"        mock.db.share_instance_delete.assert_any_call(\u0027admin_ctxt\u0027,"},{"line_number":466,"context_line":"                                                      \u0027instance_id1\u0027)"},{"line_number":467,"context_line":"        mock.db.share_instance_delete.assert_any_call(\u0027admin_ctxt\u0027,"},{"line_number":468,"context_line":"                                                      \u0027instance_id2\u0027)"},{"line_number":469,"context_line":"        mock.db.share_instance_delete.assert_any_call(\u0027admin_ctxt\u0027,"},{"line_number":470,"context_line":"                                                      \u0027instance_id3\u0027)"},{"line_number":471,"context_line":"        mock.db.share_delete.assert_called_once_with(\u0027admin_ctxt\u0027,"},{"line_number":472,"context_line":"                                                     share_id)"},{"line_number":473,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"5b976ed5_b517f159","line":470,"range":{"start_line":465,"start_character":8,"end_line":470,"end_character":69},"in_reply_to":"08d6e27b_769c3089","updated":"2024-03-20 12:42:05.000000000","message":"Resolved","commit_id":"fceb19204b01dce7c030699dca2c1074e599db0d"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"a671be1688e39b2add0624e08dbc784dc092d297","unresolved":true,"context_lines":[{"line_number":465,"context_line":"        ])"},{"line_number":466,"context_line":""},{"line_number":467,"context_line":"        self.assertEqual(3, mock.db.share_instance_delete.call_count)"},{"line_number":468,"context_line":"        mock.db.share_delete.assert_called_once_with(\u0027admin_ctxt\u0027,"},{"line_number":469,"context_line":"                                                     share_id)"},{"line_number":470,"context_line":""},{"line_number":471,"context_line":"    def test_share_server_update_capability(self):"}],"source_content_type":"text/x-python","patch_set":12,"id":"e86168cc_ee7cea57","line":468,"range":{"start_line":468,"start_character":8,"end_line":468,"end_character":29},"updated":"2024-03-20 21:39:21.000000000","message":"You\u0027re not creating this mock.. do this after line 458..","commit_id":"fe1f6fdd3269d7c9ebb1422a841d9e89001c28de"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"2ebf6905a4f415d1bd93b372d35e7e11cb3ee1fb","unresolved":false,"context_lines":[{"line_number":465,"context_line":"        ])"},{"line_number":466,"context_line":""},{"line_number":467,"context_line":"        self.assertEqual(3, mock.db.share_instance_delete.call_count)"},{"line_number":468,"context_line":"        mock.db.share_delete.assert_called_once_with(\u0027admin_ctxt\u0027,"},{"line_number":469,"context_line":"                                                     share_id)"},{"line_number":470,"context_line":""},{"line_number":471,"context_line":"    def test_share_server_update_capability(self):"}],"source_content_type":"text/x-python","patch_set":12,"id":"c36eae53_9292a98c","line":468,"range":{"start_line":468,"start_character":8,"end_line":468,"end_character":29},"in_reply_to":"e86168cc_ee7cea57","updated":"2024-03-22 14:16:37.000000000","message":"Resolved","commit_id":"fe1f6fdd3269d7c9ebb1422a841d9e89001c28de"}],"releasenotes/notes/bug-1867030-delete-share-55663c74a93e77fd.yaml":[{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"bc38a6f2d55c8072c4cc845fa600cee1f67d79c4","unresolved":true,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"fixes:"},{"line_number":3,"context_line":"  Launchpad bug 2058427 \u003chttps://bugs.launchpad.net/manila/+bug/1867030\u003e_"},{"line_number":4,"context_line":"  has been fixed for delete share."}],"source_content_type":"text/x-yaml","patch_set":18,"id":"89725960_f6d3882f","line":3,"range":{"start_line":3,"start_character":1,"end_line":3,"end_character":73},"updated":"2024-04-04 20:38:51.000000000","message":"A named link in reStructured text is formatted like this:\n\n```\n `Launchpad bug 1867030 \u003chttps://bugs.launchpad.net/manila/+bug/1867030\u003e`_\n``` \n\nYou can see how the o/p is rendered locally using:\n\n```\ntox -e reno\n```\n\nand pulling up the build on a browser; or look at the result of this CI job:\n\nhttps://86a143c8d6d86ca01f4a-89fe38ecf51174f0ec189bba1ecebda6.ssl.cf1.rackcdn.com/911694/18/check/build-openstack-releasenotes/2335e85/docs/unreleased.html","commit_id":"6ec0331fc24debd0e6df2d9af7c4e2607ace3a4a"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"bc38a6f2d55c8072c4cc845fa600cee1f67d79c4","unresolved":true,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"fixes:"},{"line_number":3,"context_line":"  Launchpad bug 2058427 \u003chttps://bugs.launchpad.net/manila/+bug/1867030\u003e_"},{"line_number":4,"context_line":"  has been fixed for delete share."}],"source_content_type":"text/x-yaml","patch_set":18,"id":"515b80bd_7136e947","line":3,"range":{"start_line":3,"start_character":16,"end_line":3,"end_character":23},"updated":"2024-04-04 20:38:51.000000000","message":"incorrect bug number","commit_id":"6ec0331fc24debd0e6df2d9af7c4e2607ace3a4a"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"e8b7d610090cddddc8c560cc44c00f1c2a70cd4a","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"fixes:"},{"line_number":3,"context_line":"  Launchpad bug 2058427 \u003chttps://bugs.launchpad.net/manila/+bug/1867030\u003e_"},{"line_number":4,"context_line":"  has been fixed for delete share."}],"source_content_type":"text/x-yaml","patch_set":18,"id":"90f0a67a_706dd38b","line":3,"range":{"start_line":3,"start_character":16,"end_line":3,"end_character":23},"in_reply_to":"1f5c814e_672cfa11","updated":"2024-04-05 05:37:49.000000000","message":"Resolved","commit_id":"6ec0331fc24debd0e6df2d9af7c4e2607ace3a4a"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"e23a4eb2876bdc64add93ac802626a5a00d895be","unresolved":true,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"fixes:"},{"line_number":3,"context_line":"  Launchpad bug 2058427 \u003chttps://bugs.launchpad.net/manila/+bug/1867030\u003e_"},{"line_number":4,"context_line":"  has been fixed for delete share."}],"source_content_type":"text/x-yaml","patch_set":18,"id":"1f5c814e_672cfa11","line":3,"range":{"start_line":3,"start_character":16,"end_line":3,"end_character":23},"in_reply_to":"32d9e481_f6e2d08a","updated":"2024-04-04 22:28:10.000000000","message":"Did you forget to push up a change?","commit_id":"6ec0331fc24debd0e6df2d9af7c4e2607ace3a4a"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"29821bbb46f12b222965ff714e824c90b23e9ead","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"fixes:"},{"line_number":3,"context_line":"  Launchpad bug 2058427 \u003chttps://bugs.launchpad.net/manila/+bug/1867030\u003e_"},{"line_number":4,"context_line":"  has been fixed for delete share."}],"source_content_type":"text/x-yaml","patch_set":18,"id":"32d9e481_f6e2d08a","line":3,"range":{"start_line":3,"start_character":16,"end_line":3,"end_character":23},"in_reply_to":"515b80bd_7136e947","updated":"2024-04-04 22:02:07.000000000","message":"Resolved","commit_id":"6ec0331fc24debd0e6df2d9af7c4e2607ace3a4a"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"29821bbb46f12b222965ff714e824c90b23e9ead","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"fixes:"},{"line_number":3,"context_line":"  Launchpad bug 2058427 \u003chttps://bugs.launchpad.net/manila/+bug/1867030\u003e_"},{"line_number":4,"context_line":"  has been fixed for delete share."}],"source_content_type":"text/x-yaml","patch_set":18,"id":"db45d3ab_0b17dd7b","line":3,"range":{"start_line":3,"start_character":1,"end_line":3,"end_character":73},"in_reply_to":"89725960_f6d3882f","updated":"2024-04-04 22:02:07.000000000","message":"Resolved","commit_id":"6ec0331fc24debd0e6df2d9af7c4e2607ace3a4a"},{"author":{"_account_id":16643,"name":"Goutham Pacha Ravi","email":"gouthampravi@gmail.com","username":"gouthamr"},"change_message_id":"85c6f58bc71e3cb43913ead18e967d7df52df09b","unresolved":true,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"fixes:"},{"line_number":3,"context_line":"  -"},{"line_number":4,"context_line":"    Launchpad `bug 2058427 \u003chttps://bugs.launchpad.net/manila/+bug/2058427\u003e`_"},{"line_number":5,"context_line":"    has been fixed for delete share."}],"source_content_type":"text/x-yaml","patch_set":20,"id":"cfb2d95b_1f543cb1","line":4,"range":{"start_line":4,"start_character":28,"end_line":4,"end_character":74},"updated":"2024-04-05 14:45:16.000000000","message":"this isn\u0027t the bug you\u0027re resolving","commit_id":"a98d55714b5c64938d01b85af8def78fc08c784d"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"4b607ce66168d731de0960cbf50fd6e4c0576feb","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"fixes:"},{"line_number":3,"context_line":"  -"},{"line_number":4,"context_line":"    Launchpad `bug 2058427 \u003chttps://bugs.launchpad.net/manila/+bug/2058427\u003e`_"},{"line_number":5,"context_line":"    has been fixed for delete share."}],"source_content_type":"text/x-yaml","patch_set":20,"id":"78a91514_70280d6e","line":4,"range":{"start_line":4,"start_character":28,"end_line":4,"end_character":74},"in_reply_to":"864da026_c744b550","updated":"2024-04-05 15:11:56.000000000","message":"Resolved","commit_id":"a98d55714b5c64938d01b85af8def78fc08c784d"},{"author":{"_account_id":36853,"name":"christian okeke","email":"eceokekechima@gmail.com","username":"ccokeke"},"change_message_id":"33b3029731729bd620056cfda8c4430920bc7639","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"fixes:"},{"line_number":3,"context_line":"  -"},{"line_number":4,"context_line":"    Launchpad `bug 2058427 \u003chttps://bugs.launchpad.net/manila/+bug/2058427\u003e`_"},{"line_number":5,"context_line":"    has been fixed for delete share."}],"source_content_type":"text/x-yaml","patch_set":20,"id":"864da026_c744b550","line":4,"range":{"start_line":4,"start_character":28,"end_line":4,"end_character":74},"in_reply_to":"cfb2d95b_1f543cb1","updated":"2024-04-05 15:10:17.000000000","message":"Resolved","commit_id":"a98d55714b5c64938d01b85af8def78fc08c784d"}]}
