)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"b0e248bab6f57135a9a4da50e7c941b73079d2fd","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":16,"id":"cb74e00b_b5c1ddf7","updated":"2023-12-04 09:42:59.000000000","message":"Katka, it looks like it is almost done!:) There are just 3 small comments. We can go through them later.","commit_id":"c112cf1b1201c48f2582305be64fb2094bc20e57"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"ab023249cc3a956a795a40b60d583f36734d5711","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":16,"id":"0cf28919_ed7b5a97","updated":"2023-12-04 14:14:17.000000000","message":"it looks great, 2 small details and we can proceed :)","commit_id":"c112cf1b1201c48f2582305be64fb2094bc20e57"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"e574297c957488dab357de41845e2260e8ed2ef8","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":18,"id":"2ed31304_90b00bef","updated":"2023-12-11 08:29:35.000000000","message":"recheck\n\"Timed out\" error. It doesn\u0027t seem to be related to the patch.","commit_id":"6a117ff828fbd252f9e874e04bcf523ad5783077"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"db4b9bada7408d8dd65368246795e4c1ae7dd947","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":18,"id":"4e8c6ec9_34d1a515","updated":"2023-12-08 15:25:56.000000000","message":"recheck\nThe failure in job tempest-full-yoga was not caused by the patch","commit_id":"6a117ff828fbd252f9e874e04bcf523ad5783077"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"8bb8ca87754d41e27125c3c5666f1fb6cf856beb","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":19,"id":"ad030ef3_055b17f9","updated":"2023-12-14 10:35:52.000000000","message":"I\u0027ve tested the change and it seems to be working! \\o/ I\u0027ve only raised two questions.","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"a976a1a80dd972e3b6fcd1ed162a086169b0ba3a","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":19,"id":"ddafbf1f_6f8df908","updated":"2023-12-14 10:57:27.000000000","message":"Plus we should probably add a release note:)\n\nhttps://review.opendev.org/c/openstack/tempest/+/897231/10/releasenotes/notes/Add-resource_name_prefix-config-option-26e0b7cfeffc48f9.yaml","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"05ff833bf5a3ac930d8ec776a31340a334d120e1","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":19,"id":"1a1498a9_61a0770d","updated":"2023-12-13 14:26:20.000000000","message":"lgtm, I tested the feature and it works great! Couple of suggestions below. When pushing a new patch-set, please, rebase on top of the parent change (I had to do some changes there) - it will avoid merge conflict later.","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"bf96d86c17dbb0f8a520e61755ad809eea12d9ca","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":19,"id":"9ae3075e_2ecd77c0","in_reply_to":"5989f973_aec57bd4","updated":"2023-12-15 11:03:56.000000000","message":"Done.","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"ee77b893693163dc1b57f343d57aeb18d1290d89","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":19,"id":"5989f973_aec57bd4","in_reply_to":"ddafbf1f_6f8df908","updated":"2023-12-14 14:00:52.000000000","message":"+1, a new config opt \u003d a new release note so that it appears in the change log: \nhttps://docs.openstack.org/releasenotes/tempest/","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"c60e56804e22786cd2298a892674a4d49a25cc0f","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":21,"id":"72ebbf90_d16c8eae","updated":"2023-12-21 09:10:25.000000000","message":"Looks good to me!","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"d9a509be2a7ac90bb8ca8acf7ef504717d60183a","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":21,"id":"4a7444d6_d46883b6","updated":"2024-01-03 19:29:16.000000000","message":"a few comment inline, I am ok with the idea as overall but we need to handle all cases if doing any change in rest_client. most importantly unit tests are missing to verify the code.\n\nApart from unit test, can we add a job or run this way in at least one of the existing job to make sure it run successfully.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"cafc1472ec74b720cbc493bc4f7d37216ac90a24","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":21,"id":"6000ba0c_b9972592","updated":"2023-12-20 16:49:42.000000000","message":"lgtm","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"a8562aa5a747c7aaa43c7b3e803a73a035895644","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":21,"id":"26027311_3bfe1a71","updated":"2024-01-04 21:23:46.000000000","message":"please rebase on top of https://review.opendev.org/c/openstack/tempest/+/879923\n\nso that we will be able to see how cleanup CLI looks like.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"6e5f877ff0da5f799f94b4ebac97dc43d2fdb962","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":21,"id":"8ac2359a_7b7de18a","in_reply_to":"4a7444d6_d46883b6","updated":"2024-01-25 15:24:24.000000000","message":"Thank you for the review. I am currently working on adding all needed changes. I am leaving unit tests as the last addition, but beside them I would like to ask you to look into changes I made so far. Thank you!","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"c5b5daa113526e61d869e5ef45b22352c1f7e931","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":25,"id":"8a392567_43139a71","updated":"2024-03-13 11:16:55.000000000","message":"couple of suggestions, other than that, it looks ok","commit_id":"438c5fde26bae00b04cf5d611f00247a7683f771"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"f8183055403e88778a0fae1e6b4dfdee8066eecd","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":26,"id":"8dfaa650_869cdd1b","updated":"2024-03-26 10:34:37.000000000","message":"Looks good to me!","commit_id":"e4b1d0b8c51a6316230cdc80a6884a940af3cdf6"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"dc4b8c6f7ee21ae976a910b7da3a364879e4bb50","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":27,"id":"cc2c09d6_bab35dc2","updated":"2024-04-03 11:30:47.000000000","message":"Looks good to me!","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"07850c662ee83f6bd2246bbec926c89c3c94c893","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":27,"id":"16a24886_f53457a2","updated":"2024-04-17 23:02:47.000000000","message":"This need more updates. Also, I would like to see it enabling in some job so that we can verify that logic is working fine or not. NOTE, the new interface/code is not running anywhere so it is difficult to capture all issue until we see it is passing in some job.","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"d333ff6d7e97eb5e07f577ee66f74f941acb7c1d","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":27,"id":"211e74eb_e9873e90","updated":"2024-04-03 11:19:17.000000000","message":"lgtm, thanks","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"ebf04512598d143f8c6e59feb512ff1045235f13","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":29,"id":"6e7fe093_9060a36a","updated":"2024-05-07 19:49:33.000000000","message":"all my previous comments are fixed,thanks. \n\nOther than Martin comment, I would like this to be enabled in one of the job and see how it run.\n\ncan you enable it in tempest-all job?","commit_id":"a90a6bd19cb940b748e6c2d93f95200edc3e8abb"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"23229ec375698ba9f19b746f55293f7aff66de9c","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":29,"id":"6f1cbb69_b7424226","updated":"2024-05-04 16:56:55.000000000","message":"lgtm, i\u0027ve noticed only one small detail","commit_id":"a90a6bd19cb940b748e6c2d93f95200edc3e8abb"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"59ce0751a53c4392e7d85959fd3e0d1bf0bf16ff","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":30,"id":"d59c62fe_b62c6b40","updated":"2024-05-10 18:04:23.000000000","message":"A note here.\n\nI was not able to see what all resources are recording to cleanup, log says below which means 0 resources were recorded? commented in the  follow up change which test this code about logging he recorded file. Without that it is difficult to know if resources are recorded and cleaned up or not\n\nvenv-tempest run-test: commands[0] | tempest cleanup --debug --resource-list\nBegin cleanup\nList count, 0 Projects after reconcile\nProcessing 0 projects\nProcessing global services\nList count, 0 Flavors after reconcile\nList count, 0 Images after reconcile\nList count, 0 Users after reconcile\nList count, 0 Projects after reconcile\nList count, 0 Domains after reconcile\nList count, 0 Roles after reconcile\nProcessing services\nList count, 0 Servers\nList count, 0 Keypairs\nList count, 0 Server Groups\nList count, 0 Network Floating IPs\nList count, 0 Routers\nList count, 0 Ports\nList count, 0 Subnets\nList count, 0 Networks\nList count, 0 security_groups\nList count, 0 Subnet Pools\nList count, 0 Snapshots\nList count, 0 Volumes","commit_id":"9847d29342932bd36cbf8aa7c2e662515417073e"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"b94496c6fb2c25b065675ce2a80b634776c32f19","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":30,"id":"9a0b9ee7_8bab7ac2","updated":"2024-05-10 07:21:54.000000000","message":"Looks good to me!","commit_id":"9847d29342932bd36cbf8aa7c2e662515417073e"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"d6977cecc8bdf496bc0d7601d72ebf5f5f602eef","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":30,"id":"a7c2de53_2452baa3","updated":"2024-05-09 14:29:58.000000000","message":"thanks","commit_id":"9847d29342932bd36cbf8aa7c2e662515417073e"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"c8bf48e89d94aeb544f688d33658d75cd2e82178","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":30,"id":"fb8e38ba_971fc5a9","in_reply_to":"d59c62fe_b62c6b40","updated":"2024-05-11 08:43:06.000000000","message":"this is the cleanup output, it only means that 0 resources were deleted as part of the cleanup which usually means that no resources were left behind after tempest testing","commit_id":"9847d29342932bd36cbf8aa7c2e662515417073e"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"9e5f0539071b6135ba4d9c9be2dc8c2765a6cfbe","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":30,"id":"a6e74927_983e2fda","in_reply_to":"fb8e38ba_971fc5a9","updated":"2024-05-13 07:57:56.000000000","message":"Yes, I think better way how to see which resources were recorded is to check the resource list itself (resource_list.json).","commit_id":"9847d29342932bd36cbf8aa7c2e662515417073e"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"4101e583e7d9c529fbab1a716eb39a91aee17098","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":31,"id":"17f91a79_f73b8994","updated":"2024-05-16 07:52:51.000000000","message":"I have fixed the issue with running tempest cleanup --dry-run. There should be no more clashes between cleanup options.","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"9be11068a5bcebbced9ddb2596a6170542dae520","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":31,"id":"6d1dd581_c823b41a","updated":"2024-05-20 08:42:06.000000000","message":"The server groups seem to be broken even for saved_state.json. If you run tempest cleanup --init-saved-state then saved_state.json does not contain server groups even though there are multiple server groups on the system. I think that the issue is that we are not calling /os-server-groups with all_projects\u003dTrue when listing the server groups [1]. \n\nThe reason why it worked locally for kstrenko is probably the fact that she was creating the server groups with the same user that was used for deletion. I\u0027ve tested the change locally with all_projects\u003dTrue and it worked well even for server_groups [2].\n\nThe solution is to allow to pass all_projects\u003dTrue in the list_server_groups() API call [3].\n\n[1] https://docs.openstack.org/api-ref/compute/#list-server-groups\n[2] https://paste.opendev.org/show/bcX17KwamvrC8g0ytaaz/\n[3] https://opendev.org/openstack/tempest/src/commit/aec7f39cbe29fef41f64001cb2abbbdef35b3500/tempest/lib/services/compute/server_groups_client.py#L60","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"64306afa3627594abeedc84d903ed6285cab809d","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":31,"id":"f41ad9c1_b1a4b4a5","updated":"2024-05-17 01:35:32.000000000","message":"This is not cleaning the leaked resource.","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"6ba6325391ce0a525cb325c7970f66d482558376","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":31,"id":"1a1b6a28_f9f19447","updated":"2024-05-16 14:23:46.000000000","message":"lgtm","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"5c390d067b36c6e4a855071a9cc595584b058585","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":31,"id":"8c525dcd_5c2d043a","updated":"2024-05-16 10:42:05.000000000","message":"recheck\nThe failure was not caused by the patch","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"8e147909795a740a78b8f17aa05ad2d74d776991","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":31,"id":"4eda91a0_5f1e0334","updated":"2024-05-16 10:58:10.000000000","message":"recheck tempest-full-enforce-scope-new-defaults test_snapshot_backup test timed out","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"48c8f1aedaa884d3817772608d6eb1c054a01e67","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":31,"id":"717f1fb0_46ae4ce9","updated":"2024-05-17 01:36:16.000000000","message":"same case in https://review.opendev.org/c/openstack/tempest/+/919617 testing:\n\nI created many keypairs not deleted by tests and cleanup script did not clean those:\n\nhttps://zuul.opendev.org/t/openstack/build/118123fc64d6436e931c83b72c3984e7/console","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"72cc9475fd34b204aca0d2d49ab03a81dc2dcd36","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":31,"id":"e12558ec_523e490b","in_reply_to":"17f91a79_f73b8994","updated":"2024-05-16 23:03:51.000000000","message":"thanks, that is why I am concerned on its testing and before +2 I would like to to actually know if it is working or not.\n\nOne important question and to know why this dry-run issue not captured by the job tempest-extra-tests where we enable its dry-run in. or what extra you are doing in your local testing?\n\n https://review.opendev.org/c/openstack/tempest/+/918725/\n\nafter that we should be able to enable/test it in upstream also.","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"64306afa3627594abeedc84d903ed6285cab809d","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":31,"id":"a57ca8a1_02508c47","in_reply_to":"2adce661_8dbe9376","updated":"2024-05-17 01:35:32.000000000","message":"Test result for https://review.opendev.org/c/openstack/tempest/+/919783:\n\nI left server groups not to be deleted by test and cleanup script shoould do but it seems it did not cleanup that:\n\nservers group in resource-list:\n\n  \"server_groups\": {\n    \"2e03c33e-95fd-4525-9fa0-d7075d9bdfb9\": \"server-group\",\n    \"f78a39a7-421c-4258-8856-e7da319a44a4\": \"tempest-ServerGroupTestJSON-Server-Group-1830054073\",\n    \"ca93d38c-2e82-4955-8546-787a22d502da\": \"tempest-server-group-833715885\",\n    \"31f25455-2d9c-4caa-a253-cce2cea9fddf\": \"tempest-server-group-833715885\",\n    \"6e4f47db-b1a0-4f77-bc7f-ea9dfd1a805d\": \"tempest-server-group-288955005\",\n    \"561dd30a-2a0e-4943-ac27-24b3b970ddf8\": \"tempest-server-group-1441038193\"\n  },\n\nI see only POST and GET request for SG and not the delete it means this resource is leaked\n\n- https://zuul.opendev.org/t/openstack/build/f066e6c4f3c144868cb26d5d4f9a3d81/log/controller/logs/tempest_log.txt#76550\n\n- https://zuul.opendev.org/t/openstack/build/f066e6c4f3c144868cb26d5d4f9a3d81/log/controller/logs/tempest_log.txt#76577\n\nBut no Sg is cleaned up in cleanup:\n\nBegin cleanup\nList count, 0 Projects after reconcile\nProcessing 0 projects\nProcessing global services\nList count, 0 Flavors after reconcile\nList count, 0 Images after reconcile\nList count, 0 Users after reconcile\nList count, 0 Projects after reconcile\nList count, 0 Domains after reconcile\nList count, 0 Roles after reconcile\nProcessing services\nList count, 0 Servers\nList count, 0 Keypairs\nList count, 0 Server Groups\nList count, 0 Network Floating IPs\nList count, 0 Routers\nList count, 0 Ports\nList count, 0 Subnets\nList count, 0 Networks\nList count, 0 security_groups\nList count, 0 Subnet Pools\nList count, 0 Snapshots\nList count, 0 Volumes\nClearing \u0027resource_list.json\u0027 file.","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"d69a88da722409e76f30c2a687903a76001832ce","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":31,"id":"3ecb8d3d_d353a537","in_reply_to":"41e847ed_95b7d6ff","updated":"2024-05-20 18:20:21.000000000","message":"I see. Thanks for the testing and updates.","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"0ddfd8285eb0a86474d47da6a665a6224ba559ec","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":31,"id":"76947d16_54901413","in_reply_to":"5e3dda78_aed60bd4","updated":"2024-05-21 04:08:35.000000000","message":"Cool, now this is working, cleanup is able to cleanup the SG.\n\nList count, 3 Server Groups\nDeleting Server Group with id 8c5353cb-2960-4a63-af52-b495d55fb6f0\nDeleting Server Group with id 3ed51e3d-e833-4b61-a8a7-5ac3150fcd8a\nDeleting Server Group with id 7c3d0426-7b40-42d0-9752-52112f67e711\n\nhttps://zuul.opendev.org/t/openstack/build/af6e2283fcd64698b426289f52fff5df/log/job-output.txt#27878-27880\n\n@Lukas, I think we might have the same issue of listing for other resources also. for example, keypair also not getting deleted - \n\nList count, 0 Keypairs\n- https://zuul.opendev.org/t/openstack/build/c446c4e9438e4697a091e3f3a13bf5ba/console\n\nAnyways this is not related to this change only so i reported the bug and ok to merge it. https://bugs.launchpad.net/tempest/+bug/2066214","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"e4857a29acd99ded54ab1f1563343bcef9774fe5","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":31,"id":"dc578a17_3dbd6350","in_reply_to":"6d1dd581_c823b41a","updated":"2024-05-20 09:34:51.000000000","message":"Thank you for this discovery, it was very helpful! Following up on your comment I have added some repairs for server groups so it would work with all cleanups. With this I think we can agree that tempest cleanup --resource-list is working fine and hopefully we can agree on merge.","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"6e05bddc4c806d231afda49230533d5e876050b6","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":31,"id":"cb7aa2d9_15abd7aa","in_reply_to":"717f1fb0_46ae4ce9","updated":"2024-05-20 09:31:56.000000000","message":"Keypairs do not work for saved_state.json as well. I think that the issue is similar as with the server groups. For the server_groups there is solution to add all_projects\u003dTrue to the API call but I do not know at the moment how to force the API endpoint for keypairs to list all keys easily [1]. \n\n[1] https://docs.openstack.org/api-ref/compute/#list-keypairs","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"9ed368abc2a06d1bc01751c5152ca76d33b9396e","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":31,"id":"acbaf3bd_c4ae7682","in_reply_to":"a3e36282_f4243151","updated":"2024-05-17 18:34:33.000000000","message":"in your step mentioned in https://paste.opendev.org/show/b3ts9WPfCOE7GsNZryF2/\n\ncan you check the list again after cleanup and see if Server groups is empty?\n\n\n\u003e I have also noticed one misunderstanding. The resource-list method\n\u003e does not collect data from GET requests, only from POST requests.\n\u003e Maybe this miscommunication caused the failed scripts?\n\nI did not get but failure is not related to this. GET call are just to show resource status. What i was expecting there to see delete call on created server group which is not there and resource list cleanup should delete it but it did not.","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"57a8efbea46388c1e9972eb36551230548a7ab18","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":31,"id":"4d137b74_9ae03d17","in_reply_to":"a57ca8a1_02508c47","updated":"2024-05-17 10:12:17.000000000","message":"The problem was with missing saved_state.json even though we don\u0027t need this file for the new options (prefix and resource-list). So locally I just made sure to not have saved_state.json generated to reproduce the error.","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"b3942f56e42cf92a57be4b50bd79fe84bdb91336","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":31,"id":"41e847ed_95b7d6ff","in_reply_to":"acbaf3bd_c4ae7682","updated":"2024-05-20 07:19:47.000000000","message":"I have checked that the list is empty again, sorry for not including it in the link. And I now understand what you meant regarding GET method. But then I don\u0027t know where the problem is, the changes are working fine locally, so can there be problem with the calling of the jobs? I am quite unsure where to look as I have tried everything I can think of on my end, so if you have suggestions don\u0027t hesitate to share them with me.","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"d69a88da722409e76f30c2a687903a76001832ce","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":31,"id":"5e3dda78_aed60bd4","in_reply_to":"dc578a17_3dbd6350","updated":"2024-05-20 18:20:21.000000000","message":"I see. thanks lukas for investigating it. This is good point on how we list the SG in cleanup. I am testing it with the new changes.","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"01f0918f0240caf5a43adcee5d5fda53672c528a","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":31,"id":"2adce661_8dbe9376","in_reply_to":"e12558ec_523e490b","updated":"2024-05-16 23:12:35.000000000","message":"FYI, I am trying to reproduce the resource leak in the below testing changes and test both dry-run a well actual cleanup happening successfully. \n\nBelow is summary of testing till now:\n1. It records the resources: **tested ok in https://review.opendev.org/c/openstack/tempest/+/918725**\n2. It pass if no resource to cleanup: **tested ok in https://review.opendev.org/c/openstack/tempest/+/918725**\n3. cleanup resource for resource leak case - **Testing in progress in below changes**\n\nhttps://review.opendev.org/c/openstack/tempest/+/919617/\nhttps://review.opendev.org/c/openstack/tempest/+/919783/","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"57a8efbea46388c1e9972eb36551230548a7ab18","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":31,"id":"a3e36282_f4243151","in_reply_to":"f41ad9c1_b1a4b4a5","updated":"2024-05-17 10:12:17.000000000","message":"I have tested deleting server groups and keypairs locally and it seems to be working fine. I used method -\u003e putting generated resource into resource_list.json and it had no problem cleaning this resource. You can check my steps here: https://paste.opendev.org/show/b3ts9WPfCOE7GsNZryF2/.\n\nSo I have tried to look for the problem that caused these concerns. I have found out that even using regular tempest cleanup without added option, the return value doesn\u0027t show how many resource it deleted, like so:\n\n 2024-05-17 04:24:36.164615 | controller | venv-tempest run-test-pre: PYTHONHASHSEED\u003d\u002735145331\u0027\n 2024-05-17 04:24:36.164792 | controller | venv-tempest run-test: commands[0] |  \n tempest cleanup --debug\n 2024-05-17 04:24:37.340149 | controller | Begin cleanup\n2024-05-17 04:24:37.420755 | controller | List count, 0 Projects after reconcile\n2024-05-17 04:24:37.420937 | controller | Processing 0 projects\n2024-05-17 04:24:37.421133 | controller | Processing global services\n2024-05-17 04:24:37.499410 | controller | List count, 0 Flavors after reconcile\n2024-05-17 04:24:37.553918 | controller | List count, 0 Images after reconcile\n2024-05-17 04:24:37.592609 | controller | List count, 0 Users after reconcile\n2024-05-17 04:24:37.625321 | controller | List count, 0 Projects after reconcile\n2024-05-17 04:24:37.658923 | controller | List count, 0 Domains after reconcile\n2024-05-17 04:24:37.690859 | controller | List count, 0 Roles after reconcile\n2024-05-17 04:24:37.717973 | controller | List count, 0 Regions\n2024-05-17 04:24:37.718181 | controller | Processing services\n2024-05-17 04:24:37.768232 | controller | List count, 0 Servers\n2024-05-17 04:24:37.791793 | controller | List count, 0 Keypairs\n2024-05-17 04:24:37.816680 | controller | List count, 0 Server Groups\n2024-05-17 04:24:37.890560 | controller | List count, 0 Network Floating IPs\n2024-05-17 04:24:38.814177 | controller | List count, 0 Routers\n2024-05-17 04:24:38.925449 | controller | List count, 0 Ports\n2024-05-17 04:24:39.001709 | controller | List count, 0 Subnets\n2024-05-17 04:24:39.080083 | controller | List count, 0 Networks\n2024-05-17 04:24:39.221337 | controller | List count, 0 security_groups\n2024-05-17 04:24:39.256218 | controller | List count, 0 Subnet Pools\n2024-05-17 04:24:39.287201 | controller | List count, 0 Snapshots\n2024-05-17 04:24:39.322818 | controller | List count, 0 Volumes\n2024-05-17 04:24:39.420997 | controller | ___________________________________ summary ____________________________________\n2024-05-17 04:24:39.421086 | controller |   venv-tempest: commands succeeded\n2024-05-17 04:24:39.442888 | controller |   congratulations :)\n2024-05-17 04:24:39.708813 | controller | ok: Runtime: 0:00:11.480179\n\nI took this output from here: https://storage.bhs.cloud.ovh.net/v1/AUTH_dcaab5e32b234d56b626f72581e3644c/zuul_opendev_logs_050/periodic/opendev.org/openstack/tempest/master/tempest-full-parallel/0504f32/job-output.txt\n\nThere could be no resources that need deletion, but there can also be some bug in the output? I haven\u0027t found any other leads as to why the resource are not (or appear not) deleted. So if you could look into the patch one more time, that would be much appreciated.\n\nI have also noticed one misunderstanding. The resource-list method does not collect data from GET requests, only from POST requests. Maybe this miscommunication caused the failed scripts?","commit_id":"7244a9e50cb80ac888d3f9c1f2a614adb3b6b37c"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"0ddfd8285eb0a86474d47da6a665a6224ba559ec","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":33,"id":"738b1c4a_5b643a18","updated":"2024-05-21 04:08:35.000000000","message":"I am satisfied with my testing which found the big issue in cleanup command where listing resource is wrong. Thanks a lot Lukas for debugging it. To continue fixing that bug I have reported LP https://bugs.launchpad.net/tempest/+bug/2066214.\n\nI am find with this change now. As martin was already +2 on this, I am approving it.\n\nThanks a lot Katarina for your hard work and for your patience on this. Great work.","commit_id":"f999b15bd4152ec3169046b05fa625a54f430150"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"9e3cc8008f53190766696718087cab0bc4675ee3","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":33,"id":"e67e5044_af6664d1","updated":"2024-05-20 15:37:02.000000000","message":"recheck test_volume_backup_incremental failed on tempest-full-py3 with:\n(VolumesBackupsTest:_run_cleanups) Failed to delete backup 5b2a66b9-d43b-4d79-b56e-0f7760c42cab within the required time (196 s)","commit_id":"f999b15bd4152ec3169046b05fa625a54f430150"}],"releasenotes/notes/resource-list-cbf9779e8b434654.yaml":[{"author":{"_account_id":13252,"name":"Dr. Jens Harbott","display_name":"Jens Harbott (frickler)","email":"frickler@offenerstapel.de","username":"jrosenboom"},"change_message_id":"12b385baa465a6529076a49cd67652984f546acd","unresolved":true,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"features:"},{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    A new config option in the default section, record_resources, is"},{"line_number":5,"context_line":"    added to allow the recording of all resources created by Tempest."},{"line_number":6,"context_line":"    List of these resources will be saved in resource_list.json file,"},{"line_number":7,"context_line":"    which will be appended in case of multiple Tempest runs. This file"}],"source_content_type":"text/x-yaml","patch_set":20,"id":"3a7abdae_2c43b02b","line":4,"range":{"start_line":4,"start_character":48,"end_line":4,"end_character":64},"updated":"2023-12-15 11:25:42.000000000","message":"Enclose option names and file names in double backticks for nicer formatting:\n\n``record_resources``","commit_id":"4e05b65ccbc00c9968de5f6c24c194db3a5599a1"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"d25d49f387bfbf20b8d6d7a336ccbb69d7fbe96e","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"features:"},{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    A new config option in the default section, record_resources, is"},{"line_number":5,"context_line":"    added to allow the recording of all resources created by Tempest."},{"line_number":6,"context_line":"    List of these resources will be saved in resource_list.json file,"},{"line_number":7,"context_line":"    which will be appended in case of multiple Tempest runs. This file"}],"source_content_type":"text/x-yaml","patch_set":20,"id":"33ad96c4_f1968a95","line":4,"range":{"start_line":4,"start_character":48,"end_line":4,"end_character":64},"in_reply_to":"3a7abdae_2c43b02b","updated":"2023-12-15 12:52:16.000000000","message":"Done. Thanks for the suggestion.","commit_id":"4e05b65ccbc00c9968de5f6c24c194db3a5599a1"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"07850c662ee83f6bd2246bbec926c89c3c94c893","unresolved":true,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"features:"},{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    A new config option in the default section, ``record_resources``, is"},{"line_number":5,"context_line":"    added to allow the recording of all resources created by Tempest."},{"line_number":6,"context_line":"    List of these resources will be saved in ``resource_list.json`` file,"},{"line_number":7,"context_line":"    which will be appended in case of multiple Tempest runs. This file"},{"line_number":8,"context_line":"    is intended to be used with ``tempest cleanup`` command by using newly"},{"line_number":9,"context_line":"    added option ``--resource-list``, which creates a new method to"},{"line_number":10,"context_line":"    remove only resources created by Tempest."}],"source_content_type":"text/x-yaml","patch_set":27,"id":"185b920a_595d0c27","line":10,"range":{"start_line":4,"start_character":4,"end_line":10,"end_character":45},"updated":"2024-04-17 23:02:47.000000000","message":"let\u0027s highlight the new way to do tempest cleanup. mentioning about new config option at first hide the new interface of tempest cleanup.\n\n    A new interface ``--resource-list`` has been introduced in the\n    ``tempest cleanup`` command to remove the resources created by\n    Tempest. A new config option in the default section, ``record_resources``,\n    is added to allow the recording of all resources created by Tempest.\n    A list of these resources will be saved in ``resource_list.json`` file,\n    which will be appended in case of multiple Tempest runs. This file\n    is intended to be used with the ``tempest cleanup`` command if it is\n    used with the newly added option ``--resource-list``.","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"ad8c4827f916a0df104d034fbb75c4b3bd7f8351","unresolved":false,"context_lines":[{"line_number":1,"context_line":"---"},{"line_number":2,"context_line":"features:"},{"line_number":3,"context_line":"  - |"},{"line_number":4,"context_line":"    A new config option in the default section, ``record_resources``, is"},{"line_number":5,"context_line":"    added to allow the recording of all resources created by Tempest."},{"line_number":6,"context_line":"    List of these resources will be saved in ``resource_list.json`` file,"},{"line_number":7,"context_line":"    which will be appended in case of multiple Tempest runs. This file"},{"line_number":8,"context_line":"    is intended to be used with ``tempest cleanup`` command by using newly"},{"line_number":9,"context_line":"    added option ``--resource-list``, which creates a new method to"},{"line_number":10,"context_line":"    remove only resources created by Tempest."}],"source_content_type":"text/x-yaml","patch_set":27,"id":"e1e43026_37c6fe87","line":10,"range":{"start_line":4,"start_character":4,"end_line":10,"end_character":45},"in_reply_to":"185b920a_595d0c27","updated":"2024-04-22 13:15:15.000000000","message":"Done","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"}],"tempest/cmd/cleanup.py":[{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"05ff833bf5a3ac930d8ec776a31340a334d120e1","unresolved":true,"context_lines":[{"line_number":68,"context_line":"  init state - all resources present at that moment."},{"line_number":69,"context_line":""},{"line_number":70,"context_line":"* ``--help``: Print the help text for the command and parameters."},{"line_number":71,"context_line":""},{"line_number":72,"context_line":".. [1] The ``_projects_to_clean`` dictionary in ``dry_run.json`` lists the"},{"line_number":73,"context_line":"    projects that ``tempest cleanup`` will loop through to delete child"},{"line_number":74,"context_line":"    objects, but the command will, by default, not delete the projects"}],"source_content_type":"text/x-python","patch_set":19,"id":"04da20cc_b4c6c299","line":71,"updated":"2023-12-13 14:26:20.000000000","message":"let\u0027s document the new --resource-list cleanup arg here.","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"8bb8ca87754d41e27125c3c5666f1fb6cf856beb","unresolved":true,"context_lines":[{"line_number":68,"context_line":"  init state - all resources present at that moment."},{"line_number":69,"context_line":""},{"line_number":70,"context_line":"* ``--help``: Print the help text for the command and parameters."},{"line_number":71,"context_line":""},{"line_number":72,"context_line":".. [1] The ``_projects_to_clean`` dictionary in ``dry_run.json`` lists the"},{"line_number":73,"context_line":"    projects that ``tempest cleanup`` will loop through to delete child"},{"line_number":74,"context_line":"    objects, but the command will, by default, not delete the projects"}],"source_content_type":"text/x-python","patch_set":19,"id":"56c09175_79b9b55f","line":71,"in_reply_to":"04da20cc_b4c6c299","updated":"2023-12-14 10:35:52.000000000","message":"+1","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"bf96d86c17dbb0f8a520e61755ad809eea12d9ca","unresolved":false,"context_lines":[{"line_number":68,"context_line":"  init state - all resources present at that moment."},{"line_number":69,"context_line":""},{"line_number":70,"context_line":"* ``--help``: Print the help text for the command and parameters."},{"line_number":71,"context_line":""},{"line_number":72,"context_line":".. [1] The ``_projects_to_clean`` dictionary in ``dry_run.json`` lists the"},{"line_number":73,"context_line":"    projects that ``tempest cleanup`` will loop through to delete child"},{"line_number":74,"context_line":"    objects, but the command will, by default, not delete the projects"}],"source_content_type":"text/x-python","patch_set":19,"id":"0b776065_2e8703a0","line":71,"in_reply_to":"56c09175_79b9b55f","updated":"2023-12-15 11:03:56.000000000","message":"Done.","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"05ff833bf5a3ac930d8ec776a31340a334d120e1","unresolved":true,"context_lines":[{"line_number":279,"context_line":"                            \"double-check erasing only resources created \""},{"line_number":280,"context_line":"                            \"by Tempest. \""},{"line_number":281,"context_line":"                            \"NOTE: To create \" + RESOURCE_LIST_JSON + \" \""},{"line_number":282,"context_line":"                            \"set config option record_resources to True.\")"},{"line_number":283,"context_line":"        return parser"},{"line_number":284,"context_line":""},{"line_number":285,"context_line":"    def get_description(self):"}],"source_content_type":"text/x-python","patch_set":19,"id":"c6347abc_87bdd9c1","line":282,"range":{"start_line":282,"start_character":71,"end_line":282,"end_character":72},"updated":"2023-12-13 14:26:20.000000000","message":"under default section in the tempest.conf file","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"ee77b893693163dc1b57f343d57aeb18d1290d89","unresolved":true,"context_lines":[{"line_number":279,"context_line":"                            \"double-check erasing only resources created \""},{"line_number":280,"context_line":"                            \"by Tempest. \""},{"line_number":281,"context_line":"                            \"NOTE: To create \" + RESOURCE_LIST_JSON + \" \""},{"line_number":282,"context_line":"                            \"set config option record_resources to True.\")"},{"line_number":283,"context_line":"        return parser"},{"line_number":284,"context_line":""},{"line_number":285,"context_line":"    def get_description(self):"}],"source_content_type":"text/x-python","patch_set":19,"id":"a5c942e1_849243fa","line":282,"range":{"start_line":282,"start_character":71,"end_line":282,"end_character":72},"in_reply_to":"991a9cd3_7ef98da1","updated":"2023-12-14 14:00:52.000000000","message":"we could, but in that case the logic behind creating the resource file would need to be improved so that each tempest run generates a new file. Either option is fine by me.","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"bf96d86c17dbb0f8a520e61755ad809eea12d9ca","unresolved":true,"context_lines":[{"line_number":279,"context_line":"                            \"double-check erasing only resources created \""},{"line_number":280,"context_line":"                            \"by Tempest. \""},{"line_number":281,"context_line":"                            \"NOTE: To create \" + RESOURCE_LIST_JSON + \" \""},{"line_number":282,"context_line":"                            \"set config option record_resources to True.\")"},{"line_number":283,"context_line":"        return parser"},{"line_number":284,"context_line":""},{"line_number":285,"context_line":"    def get_description(self):"}],"source_content_type":"text/x-python","patch_set":19,"id":"af9b6c6c_64befd4c","line":282,"range":{"start_line":282,"start_character":71,"end_line":282,"end_character":72},"in_reply_to":"a5c942e1_849243fa","updated":"2023-12-15 11:03:56.000000000","message":"Added the suggested line. And to add to the passing any location to resource_list.json file discussion, I think that it sounds good, if we had multiple files from different runs. But if we want to have only one file, that contains all the runs, in my opinion the user doesn\u0027t need this option as it creates more complications with not that much of merit.","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"c60e56804e22786cd2298a892674a4d49a25cc0f","unresolved":false,"context_lines":[{"line_number":279,"context_line":"                            \"double-check erasing only resources created \""},{"line_number":280,"context_line":"                            \"by Tempest. \""},{"line_number":281,"context_line":"                            \"NOTE: To create \" + RESOURCE_LIST_JSON + \" \""},{"line_number":282,"context_line":"                            \"set config option record_resources to True.\")"},{"line_number":283,"context_line":"        return parser"},{"line_number":284,"context_line":""},{"line_number":285,"context_line":"    def get_description(self):"}],"source_content_type":"text/x-python","patch_set":19,"id":"74ba1770_d768b3d2","line":282,"range":{"start_line":282,"start_character":71,"end_line":282,"end_character":72},"in_reply_to":"a5c942e1_849243fa","updated":"2023-12-21 09:10:25.000000000","message":"Ok, that\u0027s true. Let\u0027s keep it simple.","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"8bb8ca87754d41e27125c3c5666f1fb6cf856beb","unresolved":true,"context_lines":[{"line_number":279,"context_line":"                            \"double-check erasing only resources created \""},{"line_number":280,"context_line":"                            \"by Tempest. \""},{"line_number":281,"context_line":"                            \"NOTE: To create \" + RESOURCE_LIST_JSON + \" \""},{"line_number":282,"context_line":"                            \"set config option record_resources to True.\")"},{"line_number":283,"context_line":"        return parser"},{"line_number":284,"context_line":""},{"line_number":285,"context_line":"    def get_description(self):"}],"source_content_type":"text/x-python","patch_set":19,"id":"991a9cd3_7ef98da1","line":282,"range":{"start_line":282,"start_character":71,"end_line":282,"end_character":72},"in_reply_to":"c6347abc_87bdd9c1","updated":"2023-12-14 10:35:52.000000000","message":"I\u0027m wondering whether we do not want to parametrize this. So that the user can pass any location for the resouce_list.json.\n\n```\ntempest cleanup --resource-list /path/to/file/file.json\n```","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"d9a509be2a7ac90bb8ca8acf7ef504717d60183a","unresolved":true,"context_lines":[{"line_number":60,"context_line":"  parameters), running it again with ``--dry-run`` should yield an empty"},{"line_number":61,"context_line":"  report."},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"* ``--resource-list``: Allows the use of file ``./resource_list.json``, which"},{"line_number":64,"context_line":"  should contain all resources created by Tempest during all Tempest runs, to"},{"line_number":65,"context_line":"  create a double-check feature for removing only resources created by Tempest."},{"line_number":66,"context_line":"  List of these resources is created when config option ``record_resources``"},{"line_number":67,"context_line":"  in default section is set to true."},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"* ``--help``: Print the help text for the command and parameters."},{"line_number":70,"context_line":""}],"source_content_type":"text/x-python","patch_set":21,"id":"b30c32e0_2251e30b","line":67,"range":{"start_line":63,"start_character":0,"end_line":67,"end_character":36},"updated":"2024-01-03 19:29:16.000000000","message":"one question, as this is tempest created file and once anyone run the tempest cleanup then it should be cleaned up too. so where we delete the resources from this file once that is deleted?\n\nIf we do not delete the deleted resources from this file then any running tempest multiple times then this file end up having all the previous deleted resources also.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"6e5f877ff0da5f799f94b4ebac97dc43d2fdb962","unresolved":false,"context_lines":[{"line_number":60,"context_line":"  parameters), running it again with ``--dry-run`` should yield an empty"},{"line_number":61,"context_line":"  report."},{"line_number":62,"context_line":""},{"line_number":63,"context_line":"* ``--resource-list``: Allows the use of file ``./resource_list.json``, which"},{"line_number":64,"context_line":"  should contain all resources created by Tempest during all Tempest runs, to"},{"line_number":65,"context_line":"  create a double-check feature for removing only resources created by Tempest."},{"line_number":66,"context_line":"  List of these resources is created when config option ``record_resources``"},{"line_number":67,"context_line":"  in default section is set to true."},{"line_number":68,"context_line":""},{"line_number":69,"context_line":"* ``--help``: Print the help text for the command and parameters."},{"line_number":70,"context_line":""}],"source_content_type":"text/x-python","patch_set":21,"id":"1610e120_002cdefd","line":67,"range":{"start_line":63,"start_character":0,"end_line":67,"end_character":36},"in_reply_to":"b30c32e0_2251e30b","updated":"2024-01-25 15:24:24.000000000","message":"I have added clearing the resource_list.json file after a successful run. If you meant another more sophisticated method, don\u0027t hesitate to correct me.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"f8183055403e88778a0fae1e6b4dfdee8066eecd","unresolved":true,"context_lines":[{"line_number":365,"context_line":"            try:"},{"line_number":366,"context_line":"                with open(resource_list_json, \u0027rb\u0027) as json_file:"},{"line_number":367,"context_line":"                    self.resource_data \u003d json.load(json_file)"},{"line_number":368,"context_line":"                    self.check_resource_files()"},{"line_number":369,"context_line":"            except IOError as ex:"},{"line_number":370,"context_line":"                LOG.exception("},{"line_number":371,"context_line":"                    \"Failed loading \u0027resource_list.json\u0027, please \""}],"source_content_type":"text/x-python","patch_set":26,"id":"6a57d594_97fe2d9f","line":368,"updated":"2024-03-26 10:34:37.000000000","message":"Do we want to keep this check here?","commit_id":"e4b1d0b8c51a6316230cdc80a6884a940af3cdf6"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"9d12ce721efbe75955cf313d7977eb634f744aab","unresolved":false,"context_lines":[{"line_number":365,"context_line":"            try:"},{"line_number":366,"context_line":"                with open(resource_list_json, \u0027rb\u0027) as json_file:"},{"line_number":367,"context_line":"                    self.resource_data \u003d json.load(json_file)"},{"line_number":368,"context_line":"                    self.check_resource_files()"},{"line_number":369,"context_line":"            except IOError as ex:"},{"line_number":370,"context_line":"                LOG.exception("},{"line_number":371,"context_line":"                    \"Failed loading \u0027resource_list.json\u0027, please \""}],"source_content_type":"text/x-python","patch_set":26,"id":"57e057ff_d5972475","line":368,"in_reply_to":"206f84d1_fdd42ba5","updated":"2024-04-03 08:21:20.000000000","message":"I have erased the function all together.","commit_id":"e4b1d0b8c51a6316230cdc80a6884a940af3cdf6"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"615d86e256c5cdef3ae76798a6a9adcb30804926","unresolved":true,"context_lines":[{"line_number":365,"context_line":"            try:"},{"line_number":366,"context_line":"                with open(resource_list_json, \u0027rb\u0027) as json_file:"},{"line_number":367,"context_line":"                    self.resource_data \u003d json.load(json_file)"},{"line_number":368,"context_line":"                    self.check_resource_files()"},{"line_number":369,"context_line":"            except IOError as ex:"},{"line_number":370,"context_line":"                LOG.exception("},{"line_number":371,"context_line":"                    \"Failed loading \u0027resource_list.json\u0027, please \""}],"source_content_type":"text/x-python","patch_set":26,"id":"206f84d1_fdd42ba5","line":368,"in_reply_to":"6a57d594_97fe2d9f","updated":"2024-03-27 09:20:29.000000000","message":"Good question. I have created this function to find duplicates in resource_list and saved_state_json files, which would uncover a hidden problem as this should not happen. But when we started discussing all the cleaning options to be separate, I don\u0027t think it\u0027s that needed anymore. I can remove this function or move it into a more suited place, wdyt?","commit_id":"e4b1d0b8c51a6316230cdc80a6884a940af3cdf6"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"07850c662ee83f6bd2246bbec926c89c3c94c893","unresolved":true,"context_lines":[{"line_number":92,"context_line":"  create another method for removing only resources created by Tempest."},{"line_number":93,"context_line":"  List of these resources is created when config option ``record_resources``"},{"line_number":94,"context_line":"  in default section is set to true. After using this option for cleanup,"},{"line_number":95,"context_line":"  the existing ``./resource_list.json`` is cleared from deleted resources."},{"line_number":96,"context_line":""},{"line_number":97,"context_line":"* ``--help``: Print the help text for the command and parameters."},{"line_number":98,"context_line":""}],"source_content_type":"text/x-python","patch_set":27,"id":"d06ac5ea_6fe4153b","line":95,"range":{"start_line":95,"start_character":0,"end_line":95,"end_character":74},"updated":"2024-04-17 23:02:47.000000000","message":"do not we need to ignore this option when ``--init-saved-state`` is used? Like we di in --prefix option?","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"bf6bb783c1f0c6c5f395d0c907abf017015a74cd","unresolved":false,"context_lines":[{"line_number":92,"context_line":"  create another method for removing only resources created by Tempest."},{"line_number":93,"context_line":"  List of these resources is created when config option ``record_resources``"},{"line_number":94,"context_line":"  in default section is set to true. After using this option for cleanup,"},{"line_number":95,"context_line":"  the existing ``./resource_list.json`` is cleared from deleted resources."},{"line_number":96,"context_line":""},{"line_number":97,"context_line":"* ``--help``: Print the help text for the command and parameters."},{"line_number":98,"context_line":""}],"source_content_type":"text/x-python","patch_set":27,"id":"67f92cea_a0b24796","line":95,"range":{"start_line":95,"start_character":0,"end_line":95,"end_character":74},"in_reply_to":"d06ac5ea_6fe4153b","updated":"2024-05-03 13:14:47.000000000","message":"Acknowledged","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"07850c662ee83f6bd2246bbec926c89c3c94c893","unresolved":true,"context_lines":[{"line_number":93,"context_line":"  List of these resources is created when config option ``record_resources``"},{"line_number":94,"context_line":"  in default section is set to true. After using this option for cleanup,"},{"line_number":95,"context_line":"  the existing ``./resource_list.json`` is cleared from deleted resources."},{"line_number":96,"context_line":""},{"line_number":97,"context_line":"* ``--help``: Print the help text for the command and parameters."},{"line_number":98,"context_line":""},{"line_number":99,"context_line":".. [1] The ``_projects_to_clean`` dictionary in ``dry_run.json`` lists the"}],"source_content_type":"text/x-python","patch_set":27,"id":"687c87e8_d0ec7142","line":96,"updated":"2024-04-17 23:02:47.000000000","message":"Also, we need to add an explanation about the order of options will be prioritize by the Tempest, basically explaining what we do in the code\n- https://review.opendev.org/c/openstack/tempest/+/897847/27/tempest/cmd/cleanup_service.py#173\n\nSomething like:\n\nIf there is any ``saved_state.json``\n  file present (e.g. if you ran the tempest cleanup with ``--init-saved-state``\n  before) and you run the tempest cleanup with ``--resource-list``, the\n  ``saved_state.json`` file will be ignored and cleanup will be done based on\n  the ``--resource-list`` only. If you run the tempest cleanup with both ``--prefix`` and ``--resource-list``, the\n  ``--resource-list`` will be ignored and cleanup will be done based on\n  the ``--prefix`` only.","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"ad8c4827f916a0df104d034fbb75c4b3bd7f8351","unresolved":false,"context_lines":[{"line_number":93,"context_line":"  List of these resources is created when config option ``record_resources``"},{"line_number":94,"context_line":"  in default section is set to true. After using this option for cleanup,"},{"line_number":95,"context_line":"  the existing ``./resource_list.json`` is cleared from deleted resources."},{"line_number":96,"context_line":""},{"line_number":97,"context_line":"* ``--help``: Print the help text for the command and parameters."},{"line_number":98,"context_line":""},{"line_number":99,"context_line":".. [1] The ``_projects_to_clean`` dictionary in ``dry_run.json`` lists the"}],"source_content_type":"text/x-python","patch_set":27,"id":"68b002db_72103445","line":96,"in_reply_to":"687c87e8_d0ec7142","updated":"2024-04-22 13:15:15.000000000","message":"Done","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"07850c662ee83f6bd2246bbec926c89c3c94c893","unresolved":true,"context_lines":[{"line_number":296,"context_line":"        parser.add_argument(\u0027--prefix\u0027, dest\u003d\u0027prefix\u0027, default\u003dNone,"},{"line_number":297,"context_line":"                            help\u003d\"Only resources that match the prefix will \""},{"line_number":298,"context_line":"                            \"be deleted (resources in saved_state.json are \""},{"line_number":299,"context_line":"                            \"not taken into account). Note that some \""},{"line_number":300,"context_line":"                            \"resources are not named thus they will not be \""},{"line_number":301,"context_line":"                            \"deleted when filtering based on the prefix. This \""},{"line_number":302,"context_line":"                            \"opt will be ignored when --init-saved-state is \""},{"line_number":303,"context_line":"                            \"used so that it can capture the true init state \""},{"line_number":304,"context_line":"                            \"- all resources present at that moment.\")"},{"line_number":305,"context_line":"        parser.add_argument(\u0027--resource-list\u0027, action\u003d\"store_true\","},{"line_number":306,"context_line":"                            dest\u003d\u0027resource_list\u0027, default\u003dFalse,"},{"line_number":307,"context_line":"                            help\u003d\"Runs tempest cleanup with generated \""}],"source_content_type":"text/x-python","patch_set":27,"id":"3d3e73c0_ddd2eaa6","line":304,"range":{"start_line":299,"start_character":0,"end_line":304,"end_character":70},"updated":"2024-04-17 23:02:47.000000000","message":"I think let\u0027s leave the --prefix help modification in this change. If anyting needs to be modified we should do it in a separate change.","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"bf6bb783c1f0c6c5f395d0c907abf017015a74cd","unresolved":false,"context_lines":[{"line_number":296,"context_line":"        parser.add_argument(\u0027--prefix\u0027, dest\u003d\u0027prefix\u0027, default\u003dNone,"},{"line_number":297,"context_line":"                            help\u003d\"Only resources that match the prefix will \""},{"line_number":298,"context_line":"                            \"be deleted (resources in saved_state.json are \""},{"line_number":299,"context_line":"                            \"not taken into account). Note that some \""},{"line_number":300,"context_line":"                            \"resources are not named thus they will not be \""},{"line_number":301,"context_line":"                            \"deleted when filtering based on the prefix. This \""},{"line_number":302,"context_line":"                            \"opt will be ignored when --init-saved-state is \""},{"line_number":303,"context_line":"                            \"used so that it can capture the true init state \""},{"line_number":304,"context_line":"                            \"- all resources present at that moment.\")"},{"line_number":305,"context_line":"        parser.add_argument(\u0027--resource-list\u0027, action\u003d\"store_true\","},{"line_number":306,"context_line":"                            dest\u003d\u0027resource_list\u0027, default\u003dFalse,"},{"line_number":307,"context_line":"                            help\u003d\"Runs tempest cleanup with generated \""}],"source_content_type":"text/x-python","patch_set":27,"id":"e794eff4_bfadd710","line":304,"range":{"start_line":299,"start_character":0,"end_line":304,"end_character":70},"in_reply_to":"3d3e73c0_ddd2eaa6","updated":"2024-05-03 13:14:47.000000000","message":"Done.","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"07850c662ee83f6bd2246bbec926c89c3c94c893","unresolved":true,"context_lines":[{"line_number":309,"context_line":"                            \"erase resources created during Tempest run. \""},{"line_number":310,"context_line":"                            \"NOTE: To create \" + RESOURCE_LIST_JSON + \" \""},{"line_number":311,"context_line":"                            \"set config option record_resources under default \""},{"line_number":312,"context_line":"                            \"section in tempest.conf file to true.\")"},{"line_number":313,"context_line":"        return parser"},{"line_number":314,"context_line":""},{"line_number":315,"context_line":"    def get_description(self):"}],"source_content_type":"text/x-python","patch_set":27,"id":"c3c0ab9c_52b6a8ba","line":312,"range":{"start_line":312,"start_character":67,"end_line":312,"end_character":68},"updated":"2024-04-17 23:02:47.000000000","message":"also, we need to add the below message also:\n\nThis opt will be \"\n                            \"ignored when --init-saved-state is used so that \"\n                            \"it can capture the true init state - all \"\n                            \"resources present at that moment.\n                            \n                            This option will be ignored if passed with \u0027--prefix\u0027.","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"ad8c4827f916a0df104d034fbb75c4b3bd7f8351","unresolved":false,"context_lines":[{"line_number":309,"context_line":"                            \"erase resources created during Tempest run. \""},{"line_number":310,"context_line":"                            \"NOTE: To create \" + RESOURCE_LIST_JSON + \" \""},{"line_number":311,"context_line":"                            \"set config option record_resources under default \""},{"line_number":312,"context_line":"                            \"section in tempest.conf file to true.\")"},{"line_number":313,"context_line":"        return parser"},{"line_number":314,"context_line":""},{"line_number":315,"context_line":"    def get_description(self):"}],"source_content_type":"text/x-python","patch_set":27,"id":"f351e610_7e69204a","line":312,"range":{"start_line":312,"start_character":67,"end_line":312,"end_character":68},"in_reply_to":"c3c0ab9c_52b6a8ba","updated":"2024-04-22 13:15:15.000000000","message":"Done","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"07850c662ee83f6bd2246bbec926c89c3c94c893","unresolved":true,"context_lines":[{"line_number":351,"context_line":""},{"line_number":352,"context_line":"    def _load_json(self, saved_state_json\u003dSAVED_STATE_JSON,"},{"line_number":353,"context_line":"                   resource_list_json\u003dRESOURCE_LIST_JSON):"},{"line_number":354,"context_line":"        if self.options.resource_list:"},{"line_number":355,"context_line":"            try:"},{"line_number":356,"context_line":"                with open(resource_list_json, \u0027rb\u0027) as json_file:"},{"line_number":357,"context_line":"                    self.resource_data \u003d json.load(json_file)"}],"source_content_type":"text/x-python","patch_set":27,"id":"469cace8_6872999a","line":354,"range":{"start_line":354,"start_character":7,"end_line":354,"end_character":38},"updated":"2024-04-17 23:02:47.000000000","message":"with this condition it seems if --resource-list is mentioned then we are ignoring the ``--init-saved-state``. I think we wanted to ignore this (like we do --prefix) option if ``--init-saved-state`` is used.","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"ad8c4827f916a0df104d034fbb75c4b3bd7f8351","unresolved":false,"context_lines":[{"line_number":351,"context_line":""},{"line_number":352,"context_line":"    def _load_json(self, saved_state_json\u003dSAVED_STATE_JSON,"},{"line_number":353,"context_line":"                   resource_list_json\u003dRESOURCE_LIST_JSON):"},{"line_number":354,"context_line":"        if self.options.resource_list:"},{"line_number":355,"context_line":"            try:"},{"line_number":356,"context_line":"                with open(resource_list_json, \u0027rb\u0027) as json_file:"},{"line_number":357,"context_line":"                    self.resource_data \u003d json.load(json_file)"}],"source_content_type":"text/x-python","patch_set":27,"id":"5e381ae2_97e7d078","line":354,"range":{"start_line":354,"start_character":7,"end_line":354,"end_character":38},"in_reply_to":"469cace8_6872999a","updated":"2024-04-22 13:15:15.000000000","message":"Done","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"}],"tempest/cmd/cleanup_service.py":[{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"d9a509be2a7ac90bb8ca8acf7ef504717d60183a","unresolved":true,"context_lines":[{"line_number":158,"context_line":"        snaps \u003d client.list_snapshots()[\u0027snapshots\u0027]"},{"line_number":159,"context_line":"        if not self.is_save_state:"},{"line_number":160,"context_line":"            # recreate list removing saved snapshots"},{"line_number":161,"context_line":"            snaps \u003d [snap for snap in snaps if snap[\u0027id\u0027]"},{"line_number":162,"context_line":"                     not in self.saved_state_json[\u0027snapshots\u0027].keys()]"},{"line_number":163,"context_line":"            if self.is_resource_list:"},{"line_number":164,"context_line":"                snaps \u003d [snap for snap in snaps if snap[\u0027id\u0027]"},{"line_number":165,"context_line":"                         in self.resource_list_json[\u0027snapshots\u0027].keys()]"},{"line_number":166,"context_line":"        LOG.debug(\"List count, %s Snapshots\", len(snaps))"},{"line_number":167,"context_line":"        return snaps"},{"line_number":168,"context_line":""}],"source_content_type":"text/x-python","patch_set":21,"id":"f3b73c0c_0babcc52","line":165,"range":{"start_line":161,"start_character":0,"end_line":165,"end_character":72},"updated":"2024-01-03 19:29:16.000000000","message":"also, we should check if any resource is present in both file which is conflicting and may delete the wrong resource. any resource should not be present in both file but if there is any bug then it can happen so we should double check it before actually deleting the resource.\n\nMaybe we can check it in some common function that there is no resource present in both file if so then abort the cleanup. Maybe we can check that in cleanup.py-\u003e_load_json() and abort the cleanup if there is any such resource.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"6e5f877ff0da5f799f94b4ebac97dc43d2fdb962","unresolved":false,"context_lines":[{"line_number":158,"context_line":"        snaps \u003d client.list_snapshots()[\u0027snapshots\u0027]"},{"line_number":159,"context_line":"        if not self.is_save_state:"},{"line_number":160,"context_line":"            # recreate list removing saved snapshots"},{"line_number":161,"context_line":"            snaps \u003d [snap for snap in snaps if snap[\u0027id\u0027]"},{"line_number":162,"context_line":"                     not in self.saved_state_json[\u0027snapshots\u0027].keys()]"},{"line_number":163,"context_line":"            if self.is_resource_list:"},{"line_number":164,"context_line":"                snaps \u003d [snap for snap in snaps if snap[\u0027id\u0027]"},{"line_number":165,"context_line":"                         in self.resource_list_json[\u0027snapshots\u0027].keys()]"},{"line_number":166,"context_line":"        LOG.debug(\"List count, %s Snapshots\", len(snaps))"},{"line_number":167,"context_line":"        return snaps"},{"line_number":168,"context_line":""}],"source_content_type":"text/x-python","patch_set":21,"id":"cb972dad_3f8726ab","line":165,"range":{"start_line":161,"start_character":0,"end_line":165,"end_character":72},"in_reply_to":"cf134524_18ea6a34","updated":"2024-01-25 15:24:24.000000000","message":"I have added a function into _load_json() function like you suggested. If the function finds matching IDs, the cleanup is aborted.\n\nResource-list method is not explicit in this patch yet, but I will look into it.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"a8562aa5a747c7aaa43c7b3e803a73a035895644","unresolved":true,"context_lines":[{"line_number":158,"context_line":"        snaps \u003d client.list_snapshots()[\u0027snapshots\u0027]"},{"line_number":159,"context_line":"        if not self.is_save_state:"},{"line_number":160,"context_line":"            # recreate list removing saved snapshots"},{"line_number":161,"context_line":"            snaps \u003d [snap for snap in snaps if snap[\u0027id\u0027]"},{"line_number":162,"context_line":"                     not in self.saved_state_json[\u0027snapshots\u0027].keys()]"},{"line_number":163,"context_line":"            if self.is_resource_list:"},{"line_number":164,"context_line":"                snaps \u003d [snap for snap in snaps if snap[\u0027id\u0027]"},{"line_number":165,"context_line":"                         in self.resource_list_json[\u0027snapshots\u0027].keys()]"},{"line_number":166,"context_line":"        LOG.debug(\"List count, %s Snapshots\", len(snaps))"},{"line_number":167,"context_line":"        return snaps"},{"line_number":168,"context_line":""}],"source_content_type":"text/x-python","patch_set":21,"id":"cf134524_18ea6a34","line":165,"range":{"start_line":161,"start_character":0,"end_line":165,"end_character":72},"in_reply_to":"f3b73c0c_0babcc52","updated":"2024-01-04 21:23:46.000000000","message":"also, we should make the resource-list mehtod very expliclt. i am commenting the overall pic of cleanup in another change, please check that https://review.opendev.org/c/openstack/tempest/+/879923/20/tempest/cmd/cleanup_service.py#164\n\nAlso, please rebase it on top of below change so that we have clear code change in cleanup - https://review.opendev.org/c/openstack/tempest/+/879923","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"c5b5daa113526e61d869e5ef45b22352c1f7e931","unresolved":true,"context_lines":[{"line_number":977,"context_line":"        else:"},{"line_number":978,"context_line":"            if not self.is_save_state:"},{"line_number":979,"context_line":"                users \u003d self._filter_out_ids_from_saved(users, \u0027users\u0027)"},{"line_number":980,"context_line":""},{"line_number":981,"context_line":"            if self.is_preserve:"},{"line_number":982,"context_line":"                users \u003d [user for user in users if user[\u0027name\u0027]"},{"line_number":983,"context_line":"                         not in CONF_USERS]"}],"source_content_type":"text/x-python","patch_set":25,"id":"f3b7bdac_a00d85f6","side":"PARENT","line":980,"updated":"2024-03-13 11:16:55.000000000","message":"visually, it was better before as the if above is a different if from the below one \u003d better to have an empty line between them","commit_id":"cc56539c23a082fa093e5bf10aa8e03aac97b18b"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"c3bc33672e742e44af375a19115733c8d500565e","unresolved":false,"context_lines":[{"line_number":977,"context_line":"        else:"},{"line_number":978,"context_line":"            if not self.is_save_state:"},{"line_number":979,"context_line":"                users \u003d self._filter_out_ids_from_saved(users, \u0027users\u0027)"},{"line_number":980,"context_line":""},{"line_number":981,"context_line":"            if self.is_preserve:"},{"line_number":982,"context_line":"                users \u003d [user for user in users if user[\u0027name\u0027]"},{"line_number":983,"context_line":"                         not in CONF_USERS]"}],"source_content_type":"text/x-python","patch_set":25,"id":"e89eac13_d5ad6881","side":"PARENT","line":980,"in_reply_to":"f3b7bdac_a00d85f6","updated":"2024-03-25 12:13:34.000000000","message":"Acknowledged","commit_id":"cc56539c23a082fa093e5bf10aa8e03aac97b18b"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"c5b5daa113526e61d869e5ef45b22352c1f7e931","unresolved":true,"context_lines":[{"line_number":536,"context_line":"        flips \u003d client.list_floatingips(**self.tenant_filter)"},{"line_number":537,"context_line":"        flips \u003d flips[\u0027floatingips\u0027]"},{"line_number":538,"context_line":""},{"line_number":539,"context_line":"        if self.is_resource_list:"},{"line_number":540,"context_line":"            flips \u003d self._filter_by_resource_list(flips, \u0027floatingips\u0027)"},{"line_number":541,"context_line":"        elif not self.is_save_state:"},{"line_number":542,"context_line":"            # recreate list removing saved flips"}],"source_content_type":"text/x-python","patch_set":25,"id":"8b269c6a_3e358b58","line":539,"range":{"start_line":539,"start_character":8,"end_line":539,"end_character":10},"updated":"2024-03-13 11:16:55.000000000","message":"same as below","commit_id":"438c5fde26bae00b04cf5d611f00247a7683f771"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"d333ff6d7e97eb5e07f577ee66f74f941acb7c1d","unresolved":false,"context_lines":[{"line_number":536,"context_line":"        flips \u003d client.list_floatingips(**self.tenant_filter)"},{"line_number":537,"context_line":"        flips \u003d flips[\u0027floatingips\u0027]"},{"line_number":538,"context_line":""},{"line_number":539,"context_line":"        if self.is_resource_list:"},{"line_number":540,"context_line":"            flips \u003d self._filter_by_resource_list(flips, \u0027floatingips\u0027)"},{"line_number":541,"context_line":"        elif not self.is_save_state:"},{"line_number":542,"context_line":"            # recreate list removing saved flips"}],"source_content_type":"text/x-python","patch_set":25,"id":"467733a6_3fd961d7","line":539,"range":{"start_line":539,"start_character":8,"end_line":539,"end_character":10},"in_reply_to":"8b269c6a_3e358b58","updated":"2024-04-03 11:19:17.000000000","message":"Done","commit_id":"438c5fde26bae00b04cf5d611f00247a7683f771"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"c5b5daa113526e61d869e5ef45b22352c1f7e931","unresolved":true,"context_lines":[{"line_number":634,"context_line":"        rules \u003d rules[\u0027metering_label_rules\u0027]"},{"line_number":635,"context_line":"        rules \u003d self._filter_by_tenant_id(rules)"},{"line_number":636,"context_line":""},{"line_number":637,"context_line":"        if self.is_resource_list:"},{"line_number":638,"context_line":"            rules \u003d self._filter_by_resource_list("},{"line_number":639,"context_line":"                rules, \u0027metering_label_rules\u0027)"},{"line_number":640,"context_line":"        elif not self.is_save_state:"}],"source_content_type":"text/x-python","patch_set":25,"id":"85f9beeb_941823c3","line":637,"range":{"start_line":637,"start_character":8,"end_line":637,"end_character":10},"updated":"2024-03-13 11:16:55.000000000","message":"the same as the comment on line 901","commit_id":"438c5fde26bae00b04cf5d611f00247a7683f771"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"d333ff6d7e97eb5e07f577ee66f74f941acb7c1d","unresolved":false,"context_lines":[{"line_number":634,"context_line":"        rules \u003d rules[\u0027metering_label_rules\u0027]"},{"line_number":635,"context_line":"        rules \u003d self._filter_by_tenant_id(rules)"},{"line_number":636,"context_line":""},{"line_number":637,"context_line":"        if self.is_resource_list:"},{"line_number":638,"context_line":"            rules \u003d self._filter_by_resource_list("},{"line_number":639,"context_line":"                rules, \u0027metering_label_rules\u0027)"},{"line_number":640,"context_line":"        elif not self.is_save_state:"}],"source_content_type":"text/x-python","patch_set":25,"id":"8b4c8883_31ed5d00","line":637,"range":{"start_line":637,"start_character":8,"end_line":637,"end_character":10},"in_reply_to":"85f9beeb_941823c3","updated":"2024-04-03 11:19:17.000000000","message":"Done","commit_id":"438c5fde26bae00b04cf5d611f00247a7683f771"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"c5b5daa113526e61d869e5ef45b22352c1f7e931","unresolved":true,"context_lines":[{"line_number":898,"context_line":"        client \u003d self.client"},{"line_number":899,"context_line":"        regions \u003d client.list_regions()"},{"line_number":900,"context_line":""},{"line_number":901,"context_line":"        if self.is_resource_list:"},{"line_number":902,"context_line":"            regions \u003d self._filter_by_resource_list("},{"line_number":903,"context_line":"                regions[\u0027regions\u0027], \u0027regions\u0027)"},{"line_number":904,"context_line":"        elif not self.is_save_state:"}],"source_content_type":"text/x-python","patch_set":25,"id":"2fb0ffe2_4428a2e4","line":901,"range":{"start_line":901,"start_character":8,"end_line":901,"end_character":10},"updated":"2024-03-13 11:16:55.000000000","message":"it seems we could use \u0027elif\u0027 here and move the lines 898,899 under \u0027elif not self.is_save_state\u0027 .. wdyt?","commit_id":"438c5fde26bae00b04cf5d611f00247a7683f771"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"c3bc33672e742e44af375a19115733c8d500565e","unresolved":true,"context_lines":[{"line_number":898,"context_line":"        client \u003d self.client"},{"line_number":899,"context_line":"        regions \u003d client.list_regions()"},{"line_number":900,"context_line":""},{"line_number":901,"context_line":"        if self.is_resource_list:"},{"line_number":902,"context_line":"            regions \u003d self._filter_by_resource_list("},{"line_number":903,"context_line":"                regions[\u0027regions\u0027], \u0027regions\u0027)"},{"line_number":904,"context_line":"        elif not self.is_save_state:"}],"source_content_type":"text/x-python","patch_set":25,"id":"fc1c7f29_3c7bff22","line":901,"range":{"start_line":901,"start_character":8,"end_line":901,"end_character":10},"in_reply_to":"2fb0ffe2_4428a2e4","updated":"2024-03-25 12:13:34.000000000","message":"It is needed in the else branch. But I have moved the \u0027if prefix\u0027 branch to make the branching consistent with other resources. If you do not like this solution I can always change it back.","commit_id":"438c5fde26bae00b04cf5d611f00247a7683f771"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"d333ff6d7e97eb5e07f577ee66f74f941acb7c1d","unresolved":false,"context_lines":[{"line_number":898,"context_line":"        client \u003d self.client"},{"line_number":899,"context_line":"        regions \u003d client.list_regions()"},{"line_number":900,"context_line":""},{"line_number":901,"context_line":"        if self.is_resource_list:"},{"line_number":902,"context_line":"            regions \u003d self._filter_by_resource_list("},{"line_number":903,"context_line":"                regions[\u0027regions\u0027], \u0027regions\u0027)"},{"line_number":904,"context_line":"        elif not self.is_save_state:"}],"source_content_type":"text/x-python","patch_set":25,"id":"cbfe7bc6_55cc97b2","line":901,"range":{"start_line":901,"start_character":8,"end_line":901,"end_character":10},"in_reply_to":"fc1c7f29_3c7bff22","updated":"2024-04-03 11:19:17.000000000","message":"Done","commit_id":"438c5fde26bae00b04cf5d611f00247a7683f771"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"23229ec375698ba9f19b746f55293f7aff66de9c","unresolved":true,"context_lines":[{"line_number":496,"context_line":"                # recreate list removing saved networks"},{"line_number":497,"context_line":"                networks \u003d self._filter_out_ids_from_saved("},{"line_number":498,"context_line":"                    networks, \u0027networks\u0027)"},{"line_number":499,"context_line":"            # filter out networks declared in tempest.conf"},{"line_number":500,"context_line":"            if self.is_preserve:"},{"line_number":501,"context_line":"                networks \u003d [network for network in networks"},{"line_number":502,"context_line":"                            if network[\u0027id\u0027] not in CONF_NETWORKS]"},{"line_number":503,"context_line":"        LOG.debug(\"List count, %s Networks\", len(networks))"},{"line_number":504,"context_line":"        return networks"},{"line_number":505,"context_line":""}],"source_content_type":"text/x-python","patch_set":29,"id":"776d8fc7_65b65311","line":502,"range":{"start_line":499,"start_character":7,"end_line":502,"end_character":39},"updated":"2024-05-04 16:56:55.000000000","message":"this is mistakenly indented","commit_id":"a90a6bd19cb940b748e6c2d93f95200edc3e8abb"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"31faaead05ce2f9bd36993dac3596337de7fe24f","unresolved":false,"context_lines":[{"line_number":496,"context_line":"                # recreate list removing saved networks"},{"line_number":497,"context_line":"                networks \u003d self._filter_out_ids_from_saved("},{"line_number":498,"context_line":"                    networks, \u0027networks\u0027)"},{"line_number":499,"context_line":"            # filter out networks declared in tempest.conf"},{"line_number":500,"context_line":"            if self.is_preserve:"},{"line_number":501,"context_line":"                networks \u003d [network for network in networks"},{"line_number":502,"context_line":"                            if network[\u0027id\u0027] not in CONF_NETWORKS]"},{"line_number":503,"context_line":"        LOG.debug(\"List count, %s Networks\", len(networks))"},{"line_number":504,"context_line":"        return networks"},{"line_number":505,"context_line":""}],"source_content_type":"text/x-python","patch_set":29,"id":"6c4d11af_b0890a3c","line":502,"range":{"start_line":499,"start_character":7,"end_line":502,"end_character":39},"in_reply_to":"48e85451_fe8d0662","updated":"2024-05-09 11:28:36.000000000","message":"You\u0027re right, thank you for the correction.","commit_id":"a90a6bd19cb940b748e6c2d93f95200edc3e8abb"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"ebf04512598d143f8c6e59feb512ff1045235f13","unresolved":true,"context_lines":[{"line_number":496,"context_line":"                # recreate list removing saved networks"},{"line_number":497,"context_line":"                networks \u003d self._filter_out_ids_from_saved("},{"line_number":498,"context_line":"                    networks, \u0027networks\u0027)"},{"line_number":499,"context_line":"            # filter out networks declared in tempest.conf"},{"line_number":500,"context_line":"            if self.is_preserve:"},{"line_number":501,"context_line":"                networks \u003d [network for network in networks"},{"line_number":502,"context_line":"                            if network[\u0027id\u0027] not in CONF_NETWORKS]"},{"line_number":503,"context_line":"        LOG.debug(\"List count, %s Networks\", len(networks))"},{"line_number":504,"context_line":"        return networks"},{"line_number":505,"context_line":""}],"source_content_type":"text/x-python","patch_set":29,"id":"48e85451_fe8d0662","line":502,"range":{"start_line":499,"start_character":7,"end_line":502,"end_character":39},"in_reply_to":"776d8fc7_65b65311","updated":"2024-05-07 19:49:33.000000000","message":"yeah, we should not delete the networks here.","commit_id":"a90a6bd19cb940b748e6c2d93f95200edc3e8abb"}],"tempest/config.py":[{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"b0e248bab6f57135a9a4da50e7c941b73079d2fd","unresolved":true,"context_lines":[{"line_number":1345,"context_line":"or"},{"line_number":1346,"context_line":" $ python -m testtools.run TEST_ID\"\"\"),"},{"line_number":1347,"context_line":"    cfg.BoolOpt(\u0027record_resources\u0027,"},{"line_number":1348,"context_line":"                default\u003dTrue,"},{"line_number":1349,"context_line":"                help\u003d\"Allow to record all resources created by Tempest. \""},{"line_number":1350,"context_line":"                     \"All the created resource will be stored in file \""},{"line_number":1351,"context_line":"                     \"resource_list.json.\"),"}],"source_content_type":"text/x-python","patch_set":16,"id":"008563e7_88fd825e","line":1348,"range":{"start_line":1348,"start_character":24,"end_line":1348,"end_character":28},"updated":"2023-12-04 09:42:59.000000000","message":"We need to switch this back to False:).","commit_id":"c112cf1b1201c48f2582305be64fb2094bc20e57"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"ab023249cc3a956a795a40b60d583f36734d5711","unresolved":true,"context_lines":[{"line_number":1345,"context_line":"or"},{"line_number":1346,"context_line":" $ python -m testtools.run TEST_ID\"\"\"),"},{"line_number":1347,"context_line":"    cfg.BoolOpt(\u0027record_resources\u0027,"},{"line_number":1348,"context_line":"                default\u003dTrue,"},{"line_number":1349,"context_line":"                help\u003d\"Allow to record all resources created by Tempest. \""},{"line_number":1350,"context_line":"                     \"All the created resource will be stored in file \""},{"line_number":1351,"context_line":"                     \"resource_list.json.\"),"}],"source_content_type":"text/x-python","patch_set":16,"id":"be37121c_f9275b6f","line":1348,"range":{"start_line":1348,"start_character":24,"end_line":1348,"end_character":28},"in_reply_to":"008563e7_88fd825e","updated":"2023-12-04 14:14:17.000000000","message":"+1","commit_id":"c112cf1b1201c48f2582305be64fb2094bc20e57"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"345bd47af454d3856fb4e8cf9a20bb6c6b009f29","unresolved":false,"context_lines":[{"line_number":1345,"context_line":"or"},{"line_number":1346,"context_line":" $ python -m testtools.run TEST_ID\"\"\"),"},{"line_number":1347,"context_line":"    cfg.BoolOpt(\u0027record_resources\u0027,"},{"line_number":1348,"context_line":"                default\u003dTrue,"},{"line_number":1349,"context_line":"                help\u003d\"Allow to record all resources created by Tempest. \""},{"line_number":1350,"context_line":"                     \"All the created resource will be stored in file \""},{"line_number":1351,"context_line":"                     \"resource_list.json.\"),"}],"source_content_type":"text/x-python","patch_set":16,"id":"aeb0c06c_1e0b43d7","line":1348,"range":{"start_line":1348,"start_character":24,"end_line":1348,"end_character":28},"in_reply_to":"2d3c692d_b5c1bffc","updated":"2023-12-08 10:58:46.000000000","message":"Done","commit_id":"c112cf1b1201c48f2582305be64fb2094bc20e57"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"3dbd7a213bdd4ba3d34d32e41a67ba27bc51ff6a","unresolved":true,"context_lines":[{"line_number":1345,"context_line":"or"},{"line_number":1346,"context_line":" $ python -m testtools.run TEST_ID\"\"\"),"},{"line_number":1347,"context_line":"    cfg.BoolOpt(\u0027record_resources\u0027,"},{"line_number":1348,"context_line":"                default\u003dTrue,"},{"line_number":1349,"context_line":"                help\u003d\"Allow to record all resources created by Tempest. \""},{"line_number":1350,"context_line":"                     \"All the created resource will be stored in file \""},{"line_number":1351,"context_line":"                     \"resource_list.json.\"),"}],"source_content_type":"text/x-python","patch_set":16,"id":"2d3c692d_b5c1bffc","line":1348,"range":{"start_line":1348,"start_character":24,"end_line":1348,"end_character":28},"in_reply_to":"be37121c_f9275b6f","updated":"2023-12-05 13:25:34.000000000","message":"Acknowledged. I will change it to False, when I get a +1 from Zuul, which will mean the function is okay.","commit_id":"c112cf1b1201c48f2582305be64fb2094bc20e57"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"05ff833bf5a3ac930d8ec776a31340a334d120e1","unresolved":true,"context_lines":[{"line_number":1362,"context_line":"                help\u003d\"Allows to record all resources created by Tempest. \""},{"line_number":1363,"context_line":"                     \"These resources are stored in file resource_list.json, \""},{"line_number":1364,"context_line":"                     \"which can be later used to double-check resource \""},{"line_number":1365,"context_line":"                     \"deletion for command tempest cleanup.\"),"},{"line_number":1366,"context_line":"]"},{"line_number":1367,"context_line":""},{"line_number":1368,"context_line":"_opts \u003d ["}],"source_content_type":"text/x-python","patch_set":19,"id":"af366ebb_6663281c","line":1365,"range":{"start_line":1365,"start_character":58,"end_line":1365,"end_character":59},"updated":"2023-12-13 14:26:20.000000000","message":"Let\u0027s also add a note like this:\n\nThe resource_list.json file will be appended in case of multiple tempest runs. The file will contain a list of resources created during all tempest runs.","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"ee77b893693163dc1b57f343d57aeb18d1290d89","unresolved":true,"context_lines":[{"line_number":1362,"context_line":"                help\u003d\"Allows to record all resources created by Tempest. \""},{"line_number":1363,"context_line":"                     \"These resources are stored in file resource_list.json, \""},{"line_number":1364,"context_line":"                     \"which can be later used to double-check resource \""},{"line_number":1365,"context_line":"                     \"deletion for command tempest cleanup.\"),"},{"line_number":1366,"context_line":"]"},{"line_number":1367,"context_line":""},{"line_number":1368,"context_line":"_opts \u003d ["}],"source_content_type":"text/x-python","patch_set":19,"id":"7352f72e_b23d5f30","line":1365,"range":{"start_line":1365,"start_character":58,"end_line":1365,"end_character":59},"in_reply_to":"018d41f0_e246198f","updated":"2023-12-14 14:00:52.000000000","message":"i feel like we would be putting too much responsibility on a user :D this could make sense if the logic behind creating the resource file would need to be improved so that each tempest run generates a new file.","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"bf96d86c17dbb0f8a520e61755ad809eea12d9ca","unresolved":true,"context_lines":[{"line_number":1362,"context_line":"                help\u003d\"Allows to record all resources created by Tempest. \""},{"line_number":1363,"context_line":"                     \"These resources are stored in file resource_list.json, \""},{"line_number":1364,"context_line":"                     \"which can be later used to double-check resource \""},{"line_number":1365,"context_line":"                     \"deletion for command tempest cleanup.\"),"},{"line_number":1366,"context_line":"]"},{"line_number":1367,"context_line":""},{"line_number":1368,"context_line":"_opts \u003d ["}],"source_content_type":"text/x-python","patch_set":19,"id":"073de82e_93b3fffd","line":1365,"range":{"start_line":1365,"start_character":58,"end_line":1365,"end_character":59},"in_reply_to":"7352f72e_b23d5f30","updated":"2023-12-15 11:03:56.000000000","message":"Added suggested line. Although, path option sounds more flexible, I agree with Martin on this topic.","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"c60e56804e22786cd2298a892674a4d49a25cc0f","unresolved":false,"context_lines":[{"line_number":1362,"context_line":"                help\u003d\"Allows to record all resources created by Tempest. \""},{"line_number":1363,"context_line":"                     \"These resources are stored in file resource_list.json, \""},{"line_number":1364,"context_line":"                     \"which can be later used to double-check resource \""},{"line_number":1365,"context_line":"                     \"deletion for command tempest cleanup.\"),"},{"line_number":1366,"context_line":"]"},{"line_number":1367,"context_line":""},{"line_number":1368,"context_line":"_opts \u003d ["}],"source_content_type":"text/x-python","patch_set":19,"id":"212662be_cf3f9e21","line":1365,"range":{"start_line":1365,"start_character":58,"end_line":1365,"end_character":59},"in_reply_to":"7352f72e_b23d5f30","updated":"2023-12-21 09:10:25.000000000","message":"Ok, that\u0027s true. Let\u0027s keep it simple.","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"8bb8ca87754d41e27125c3c5666f1fb6cf856beb","unresolved":true,"context_lines":[{"line_number":1362,"context_line":"                help\u003d\"Allows to record all resources created by Tempest. \""},{"line_number":1363,"context_line":"                     \"These resources are stored in file resource_list.json, \""},{"line_number":1364,"context_line":"                     \"which can be later used to double-check resource \""},{"line_number":1365,"context_line":"                     \"deletion for command tempest cleanup.\"),"},{"line_number":1366,"context_line":"]"},{"line_number":1367,"context_line":""},{"line_number":1368,"context_line":"_opts \u003d ["}],"source_content_type":"text/x-python","patch_set":19,"id":"018d41f0_e246198f","line":1365,"range":{"start_line":1365,"start_character":58,"end_line":1365,"end_character":59},"in_reply_to":"af366ebb_6663281c","updated":"2023-12-14 10:35:52.000000000","message":"Do we want to maybe parametrize this so that the user can specify a path to a location where the record_resources.json file is created?\n\n```\n[DEFAULT]\nrecord_recources \u003d path/to/file/file.json\n```","commit_id":"061d3fa04f0526cf53dbd3a8c95c2f30f2ba93e9"}],"tempest/lib/common/rest_client.py":[{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"b0e248bab6f57135a9a4da50e7c941b73079d2fd","unresolved":true,"context_lines":[{"line_number":1020,"context_line":"    def resource_record(self, resp_dict):"},{"line_number":1021,"context_line":"        \"\"\"Records resources into resource_list.json file.\"\"\""},{"line_number":1022,"context_line":""},{"line_number":1023,"context_line":"        global rec_rw_lock"},{"line_number":1024,"context_line":""},{"line_number":1025,"context_line":"        if rec_rw_lock is None:"},{"line_number":1026,"context_line":"            path \u003d self.lock_dir"}],"source_content_type":"text/x-python","patch_set":16,"id":"b2481b52_4168ec07","line":1023,"range":{"start_line":1023,"start_character":0,"end_line":1023,"end_character":2},"updated":"2023-12-04 09:42:59.000000000","message":"Can we make it not a global variable?","commit_id":"c112cf1b1201c48f2582305be64fb2094bc20e57"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"ab023249cc3a956a795a40b60d583f36734d5711","unresolved":true,"context_lines":[{"line_number":1020,"context_line":"    def resource_record(self, resp_dict):"},{"line_number":1021,"context_line":"        \"\"\"Records resources into resource_list.json file.\"\"\""},{"line_number":1022,"context_line":""},{"line_number":1023,"context_line":"        global rec_rw_lock"},{"line_number":1024,"context_line":""},{"line_number":1025,"context_line":"        if rec_rw_lock is None:"},{"line_number":1026,"context_line":"            path \u003d self.lock_dir"}],"source_content_type":"text/x-python","patch_set":16,"id":"d0a9ebf3_8c219e32","line":1023,"range":{"start_line":1023,"start_character":0,"end_line":1023,"end_character":2},"in_reply_to":"b2481b52_4168ec07","updated":"2023-12-04 14:14:17.000000000","message":"+1","commit_id":"c112cf1b1201c48f2582305be64fb2094bc20e57"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"3dbd7a213bdd4ba3d34d32e41a67ba27bc51ff6a","unresolved":false,"context_lines":[{"line_number":1020,"context_line":"    def resource_record(self, resp_dict):"},{"line_number":1021,"context_line":"        \"\"\"Records resources into resource_list.json file.\"\"\""},{"line_number":1022,"context_line":""},{"line_number":1023,"context_line":"        global rec_rw_lock"},{"line_number":1024,"context_line":""},{"line_number":1025,"context_line":"        if rec_rw_lock is None:"},{"line_number":1026,"context_line":"            path \u003d self.lock_dir"}],"source_content_type":"text/x-python","patch_set":16,"id":"5d88841c_875388a1","line":1023,"range":{"start_line":1023,"start_character":0,"end_line":1023,"end_character":2},"in_reply_to":"d0a9ebf3_8c219e32","updated":"2023-12-05 13:25:34.000000000","message":"Done. I have made it a class variable. I hope it works the same.","commit_id":"c112cf1b1201c48f2582305be64fb2094bc20e57"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"b0e248bab6f57135a9a4da50e7c941b73079d2fd","unresolved":true,"context_lines":[{"line_number":1043,"context_line":""},{"line_number":1044,"context_line":"        resource_type \u003d list(resp_dict.keys())[0]"},{"line_number":1045,"context_line":""},{"line_number":1046,"context_line":"        if resource_type[-1] !\u003d \u0027s\u0027:"},{"line_number":1047,"context_line":"            resource_type_s \u003d resource_type + \u0027s\u0027"},{"line_number":1048,"context_line":"        else:"},{"line_number":1049,"context_line":"            resource_type_s \u003d resource_type"},{"line_number":1050,"context_line":""},{"line_number":1051,"context_line":"        if resource_type_s not in data:"},{"line_number":1052,"context_line":"            data[resource_type_s] \u003d {}"}],"source_content_type":"text/x-python","patch_set":16,"id":"c248c598_a26bf2f2","line":1049,"range":{"start_line":1046,"start_character":8,"end_line":1049,"end_character":43},"updated":"2023-12-04 09:42:59.000000000","message":"This is just a nit. If we want to keep this it can be simplified:\n\n```\nif not resource_type.endswith(\u0027s\u0027):\n  resource_type +\u003d \u0027s\u0027\n```","commit_id":"c112cf1b1201c48f2582305be64fb2094bc20e57"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"055a07b8877fecfb74ebaafde86bf6b5d857e2a7","unresolved":false,"context_lines":[{"line_number":1043,"context_line":""},{"line_number":1044,"context_line":"        resource_type \u003d list(resp_dict.keys())[0]"},{"line_number":1045,"context_line":""},{"line_number":1046,"context_line":"        if resource_type[-1] !\u003d \u0027s\u0027:"},{"line_number":1047,"context_line":"            resource_type_s \u003d resource_type + \u0027s\u0027"},{"line_number":1048,"context_line":"        else:"},{"line_number":1049,"context_line":"            resource_type_s \u003d resource_type"},{"line_number":1050,"context_line":""},{"line_number":1051,"context_line":"        if resource_type_s not in data:"},{"line_number":1052,"context_line":"            data[resource_type_s] \u003d {}"}],"source_content_type":"text/x-python","patch_set":16,"id":"b8d06bb9_1c3627e0","line":1049,"range":{"start_line":1046,"start_character":8,"end_line":1049,"end_character":43},"in_reply_to":"c248c598_a26bf2f2","updated":"2023-12-05 13:20:14.000000000","message":"Done","commit_id":"c112cf1b1201c48f2582305be64fb2094bc20e57"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"3dbd7a213bdd4ba3d34d32e41a67ba27bc51ff6a","unresolved":false,"context_lines":[{"line_number":1043,"context_line":""},{"line_number":1044,"context_line":"        resource_type \u003d list(resp_dict.keys())[0]"},{"line_number":1045,"context_line":""},{"line_number":1046,"context_line":"        if resource_type[-1] !\u003d \u0027s\u0027:"},{"line_number":1047,"context_line":"            resource_type_s \u003d resource_type + \u0027s\u0027"},{"line_number":1048,"context_line":"        else:"},{"line_number":1049,"context_line":"            resource_type_s \u003d resource_type"},{"line_number":1050,"context_line":""},{"line_number":1051,"context_line":"        if resource_type_s not in data:"},{"line_number":1052,"context_line":"            data[resource_type_s] \u003d {}"}],"source_content_type":"text/x-python","patch_set":16,"id":"264fcc26_a087acff","line":1049,"range":{"start_line":1046,"start_character":8,"end_line":1049,"end_character":43},"in_reply_to":"c248c598_a26bf2f2","updated":"2023-12-05 13:25:34.000000000","message":"Done. Good suggestion, I did not like this block of code as well.","commit_id":"c112cf1b1201c48f2582305be64fb2094bc20e57"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"d9a509be2a7ac90bb8ca8acf7ef504717d60183a","unresolved":true,"context_lines":[{"line_number":1024,"context_line":"        \"\"\"Returns the primary type of resource this client works with.\"\"\""},{"line_number":1025,"context_line":"        return \u0027resource\u0027"},{"line_number":1026,"context_line":""},{"line_number":1027,"context_line":"    def resource_record(self, resp_dict):"},{"line_number":1028,"context_line":"        \"\"\"Records resources into resource_list.json file.\"\"\""},{"line_number":1029,"context_line":""},{"line_number":1030,"context_line":"        if self.rec_rw_lock is None:"}],"source_content_type":"text/x-python","patch_set":21,"id":"448318c6_8630c024","line":1027,"range":{"start_line":1027,"start_character":8,"end_line":1027,"end_character":23},"updated":"2024-01-03 19:29:16.000000000","message":"I think this code need a good amount of unit test so that we verify that all type of resource body (list, dict, with/without top key, with/without uuid etc) are handled properly.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"bf6bb783c1f0c6c5f395d0c907abf017015a74cd","unresolved":false,"context_lines":[{"line_number":1024,"context_line":"        \"\"\"Returns the primary type of resource this client works with.\"\"\""},{"line_number":1025,"context_line":"        return \u0027resource\u0027"},{"line_number":1026,"context_line":""},{"line_number":1027,"context_line":"    def resource_record(self, resp_dict):"},{"line_number":1028,"context_line":"        \"\"\"Records resources into resource_list.json file.\"\"\""},{"line_number":1029,"context_line":""},{"line_number":1030,"context_line":"        if self.rec_rw_lock is None:"}],"source_content_type":"text/x-python","patch_set":21,"id":"9723a105_fe8b789f","line":1027,"range":{"start_line":1027,"start_character":8,"end_line":1027,"end_character":23},"in_reply_to":"448318c6_8630c024","updated":"2024-05-03 13:14:47.000000000","message":"Done.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"d9a509be2a7ac90bb8ca8acf7ef504717d60183a","unresolved":true,"context_lines":[{"line_number":1046,"context_line":"        except (AttributeError, TypeError, ValueError):"},{"line_number":1047,"context_line":"            return"},{"line_number":1048,"context_line":""},{"line_number":1049,"context_line":"        resource_type \u003d list(resp_dict.keys())[0]"},{"line_number":1050,"context_line":""},{"line_number":1051,"context_line":"        resource_dict \u003d resp_dict[resource_type]"},{"line_number":1052,"context_line":""}],"source_content_type":"text/x-python","patch_set":21,"id":"a9c7a2c1_a8ba92c1","line":1049,"range":{"start_line":1049,"start_character":1,"end_line":1049,"end_character":49},"updated":"2024-01-03 19:29:16.000000000","message":"I am not sure this is very safe to do. OpenStack REST APIs are not so perfect and many projects have a different way to return the resource body, a few or majority of them might be returning the created resource body as list wrapped in a resource key but there is no guarantee that all do the same.\n\nWe should check if the top key exist or not and then extract the resource body.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"6e5f877ff0da5f799f94b4ebac97dc43d2fdb962","unresolved":false,"context_lines":[{"line_number":1046,"context_line":"        except (AttributeError, TypeError, ValueError):"},{"line_number":1047,"context_line":"            return"},{"line_number":1048,"context_line":""},{"line_number":1049,"context_line":"        resource_type \u003d list(resp_dict.keys())[0]"},{"line_number":1050,"context_line":""},{"line_number":1051,"context_line":"        resource_dict \u003d resp_dict[resource_type]"},{"line_number":1052,"context_line":""}],"source_content_type":"text/x-python","patch_set":21,"id":"05b6fee1_f0246870","line":1049,"range":{"start_line":1049,"start_character":1,"end_line":1049,"end_character":49},"in_reply_to":"a9c7a2c1_a8ba92c1","updated":"2024-01-25 15:24:24.000000000","message":"I have added checking if top key exists. If not, the function returns without adding a new resource. I am not sure if a valid resource can be extracted when it is not a dictionary, so I guess when making unit test I can look into this more. For now I skip this option.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"d9a509be2a7ac90bb8ca8acf7ef504717d60183a","unresolved":true,"context_lines":[{"line_number":1050,"context_line":""},{"line_number":1051,"context_line":"        resource_dict \u003d resp_dict[resource_type]"},{"line_number":1052,"context_line":""},{"line_number":1053,"context_line":"        if not isinstance(resource_dict, dict):"},{"line_number":1054,"context_line":"            return"},{"line_number":1055,"context_line":""},{"line_number":1056,"context_line":"        if not resource_type.endswith(\u0027s\u0027):"},{"line_number":1057,"context_line":"            resource_type +\u003d \u0027s\u0027"}],"source_content_type":"text/x-python","patch_set":21,"id":"5707f03c_47f8fc52","line":1054,"range":{"start_line":1053,"start_character":0,"end_line":1054,"end_character":18},"updated":"2024-01-03 19:29:16.000000000","message":"can we handle dict and list both? because in some cases it can be list when there is multiple resource creation happen in single request.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"6e5f877ff0da5f799f94b4ebac97dc43d2fdb962","unresolved":false,"context_lines":[{"line_number":1050,"context_line":""},{"line_number":1051,"context_line":"        resource_dict \u003d resp_dict[resource_type]"},{"line_number":1052,"context_line":""},{"line_number":1053,"context_line":"        if not isinstance(resource_dict, dict):"},{"line_number":1054,"context_line":"            return"},{"line_number":1055,"context_line":""},{"line_number":1056,"context_line":"        if not resource_type.endswith(\u0027s\u0027):"},{"line_number":1057,"context_line":"            resource_type +\u003d \u0027s\u0027"}],"source_content_type":"text/x-python","patch_set":21,"id":"d568a43f_0f87a1b5","line":1054,"range":{"start_line":1053,"start_character":0,"end_line":1054,"end_character":18},"in_reply_to":"5707f03c_47f8fc52","updated":"2024-01-25 15:24:24.000000000","message":"I have added handling of a list. You were right, there can be a list of resources. It should work now.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"d9a509be2a7ac90bb8ca8acf7ef504717d60183a","unresolved":true,"context_lines":[{"line_number":1059,"context_line":"        if resource_type not in data:"},{"line_number":1060,"context_line":"            data[resource_type] \u003d {}"},{"line_number":1061,"context_line":""},{"line_number":1062,"context_line":"        if \u0027name\u0027 and \u0027id\u0027 in resource_dict:"},{"line_number":1063,"context_line":"            data[resource_type].update("},{"line_number":1064,"context_line":"                {resource_dict.get(\u0027id\u0027): resource_dict.get(\u0027name\u0027)})"},{"line_number":1065,"context_line":"        elif \u0027name\u0027 in resource_dict:"}],"source_content_type":"text/x-python","patch_set":21,"id":"3cec1edf_7e01f85c","line":1062,"range":{"start_line":1062,"start_character":11,"end_line":1062,"end_character":17},"updated":"2024-01-03 19:29:16.000000000","message":"resource name is not always unique and there might be multiple resouece having same name in DB. uuid are the unique identifier of resource so we should record that to make the delete request of that resource so that we are 100% sure that what we request for delete is deleted.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"6e5f877ff0da5f799f94b4ebac97dc43d2fdb962","unresolved":true,"context_lines":[{"line_number":1059,"context_line":"        if resource_type not in data:"},{"line_number":1060,"context_line":"            data[resource_type] \u003d {}"},{"line_number":1061,"context_line":""},{"line_number":1062,"context_line":"        if \u0027name\u0027 and \u0027id\u0027 in resource_dict:"},{"line_number":1063,"context_line":"            data[resource_type].update("},{"line_number":1064,"context_line":"                {resource_dict.get(\u0027id\u0027): resource_dict.get(\u0027name\u0027)})"},{"line_number":1065,"context_line":"        elif \u0027name\u0027 in resource_dict:"}],"source_content_type":"text/x-python","patch_set":21,"id":"84d5e9d2_6ffbaec7","line":1062,"range":{"start_line":1062,"start_character":11,"end_line":1062,"end_character":17},"in_reply_to":"3cec1edf_7e01f85c","updated":"2024-01-25 15:24:24.000000000","message":"I am aware that names do not have to be unique and that is why the deletion is based on using IDs. The name is something like an addition to a better looking json file, to navigate better in. But there is a possibility that resource has only ID, which would mean I skip this resource. So I will look more into this as well.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"bf6bb783c1f0c6c5f395d0c907abf017015a74cd","unresolved":false,"context_lines":[{"line_number":1059,"context_line":"        if resource_type not in data:"},{"line_number":1060,"context_line":"            data[resource_type] \u003d {}"},{"line_number":1061,"context_line":""},{"line_number":1062,"context_line":"        if \u0027name\u0027 and \u0027id\u0027 in resource_dict:"},{"line_number":1063,"context_line":"            data[resource_type].update("},{"line_number":1064,"context_line":"                {resource_dict.get(\u0027id\u0027): resource_dict.get(\u0027name\u0027)})"},{"line_number":1065,"context_line":"        elif \u0027name\u0027 in resource_dict:"}],"source_content_type":"text/x-python","patch_set":21,"id":"c0dd35f0_2d482f79","line":1062,"range":{"start_line":1062,"start_character":11,"end_line":1062,"end_character":17},"in_reply_to":"84d5e9d2_6ffbaec7","updated":"2024-05-03 13:14:47.000000000","message":"Resolved.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"d9a509be2a7ac90bb8ca8acf7ef504717d60183a","unresolved":true,"context_lines":[{"line_number":1062,"context_line":"        if \u0027name\u0027 and \u0027id\u0027 in resource_dict:"},{"line_number":1063,"context_line":"            data[resource_type].update("},{"line_number":1064,"context_line":"                {resource_dict.get(\u0027id\u0027): resource_dict.get(\u0027name\u0027)})"},{"line_number":1065,"context_line":"        elif \u0027name\u0027 in resource_dict:"},{"line_number":1066,"context_line":"            data[resource_type].update({resource_dict.get(\u0027name\u0027): \"\"})"},{"line_number":1067,"context_line":""},{"line_number":1068,"context_line":"        self.rec_rw_lock.acquire_write_lock()"},{"line_number":1069,"context_line":"        with open(\"resource_list.json\", \u0027w+\u0027) as f:"}],"source_content_type":"text/x-python","patch_set":21,"id":"efac4bc8_ce2c6075","line":1066,"range":{"start_line":1065,"start_character":0,"end_line":1066,"end_character":71},"updated":"2024-01-03 19:29:16.000000000","message":"I will say let\u0027s not same resource with name and only save with resource uuid or id only","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"07850c662ee83f6bd2246bbec926c89c3c94c893","unresolved":false,"context_lines":[{"line_number":1062,"context_line":"        if \u0027name\u0027 and \u0027id\u0027 in resource_dict:"},{"line_number":1063,"context_line":"            data[resource_type].update("},{"line_number":1064,"context_line":"                {resource_dict.get(\u0027id\u0027): resource_dict.get(\u0027name\u0027)})"},{"line_number":1065,"context_line":"        elif \u0027name\u0027 in resource_dict:"},{"line_number":1066,"context_line":"            data[resource_type].update({resource_dict.get(\u0027name\u0027): \"\"})"},{"line_number":1067,"context_line":""},{"line_number":1068,"context_line":"        self.rec_rw_lock.acquire_write_lock()"},{"line_number":1069,"context_line":"        with open(\"resource_list.json\", \u0027w+\u0027) as f:"}],"source_content_type":"text/x-python","patch_set":21,"id":"7d2b1b37_0a2409f5","line":1066,"range":{"start_line":1065,"start_character":0,"end_line":1066,"end_character":71},"in_reply_to":"d3543f32_3b804a06","updated":"2024-04-17 23:02:47.000000000","message":"you are right, as discussed I think it make sense to use name for such resources","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"6e5f877ff0da5f799f94b4ebac97dc43d2fdb962","unresolved":true,"context_lines":[{"line_number":1062,"context_line":"        if \u0027name\u0027 and \u0027id\u0027 in resource_dict:"},{"line_number":1063,"context_line":"            data[resource_type].update("},{"line_number":1064,"context_line":"                {resource_dict.get(\u0027id\u0027): resource_dict.get(\u0027name\u0027)})"},{"line_number":1065,"context_line":"        elif \u0027name\u0027 in resource_dict:"},{"line_number":1066,"context_line":"            data[resource_type].update({resource_dict.get(\u0027name\u0027): \"\"})"},{"line_number":1067,"context_line":""},{"line_number":1068,"context_line":"        self.rec_rw_lock.acquire_write_lock()"},{"line_number":1069,"context_line":"        with open(\"resource_list.json\", \u0027w+\u0027) as f:"}],"source_content_type":"text/x-python","patch_set":21,"id":"d3543f32_3b804a06","line":1066,"range":{"start_line":1065,"start_character":0,"end_line":1066,"end_character":71},"in_reply_to":"efac4bc8_ce2c6075","updated":"2024-01-25 15:24:24.000000000","message":"This part of code is for keypairs specifically (I don\u0027t know if more resources work like this). If I remember correctly, keypairs don\u0027t have IDs, so for their deletion I used this method.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"07850c662ee83f6bd2246bbec926c89c3c94c893","unresolved":true,"context_lines":[{"line_number":1035,"context_line":"        if res_type not in data:"},{"line_number":1036,"context_line":"            data[res_type] \u003d {}"},{"line_number":1037,"context_line":""},{"line_number":1038,"context_line":"        if \u0027id\u0027 in res_dict:"},{"line_number":1039,"context_line":"            data[res_type].update("},{"line_number":1040,"context_line":"                {res_dict.get(\u0027id\u0027): res_dict.get(\u0027name\u0027)})"},{"line_number":1041,"context_line":"        elif \u0027name\u0027 in res_dict:"},{"line_number":1042,"context_line":"            data[res_type].update({res_dict.get(\u0027name\u0027): \"\"})"},{"line_number":1043,"context_line":""},{"line_number":1044,"context_line":"        self.rec_rw_lock.acquire_write_lock()"},{"line_number":1045,"context_line":"        with open(\"resource_list.json\", \u0027w+\u0027) as f:"},{"line_number":1046,"context_line":"            f.write(json.dumps(data, indent\u003d2, separators\u003d(\u0027,\u0027, \u0027: \u0027)))"}],"source_content_type":"text/x-python","patch_set":25,"id":"ebcb2d11_d80d6714","line":1043,"range":{"start_line":1038,"start_character":8,"end_line":1043,"end_character":0},"updated":"2024-04-17 23:02:47.000000000","message":"I think we can check for uuid first\n\n if \u0027uuid\u0027 in res_dict:\n     data[res_type].update(\n         {res_dict.get(\u0027uuid\u0027): res_dict.get(\u0027name\u0027)})\n elif \u0027id\u0027 in res_dict:\n         data[res_type].update(\n             {res_dict.get(\u0027id\u0027): res_dict.get(\u0027name\u0027)})\n elif \u0027name\u0027 in res_dict:\n         data[res_type].update({res_dict.get(\u0027name\u0027): \"\"})","commit_id":"438c5fde26bae00b04cf5d611f00247a7683f771"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"ad8c4827f916a0df104d034fbb75c4b3bd7f8351","unresolved":false,"context_lines":[{"line_number":1035,"context_line":"        if res_type not in data:"},{"line_number":1036,"context_line":"            data[res_type] \u003d {}"},{"line_number":1037,"context_line":""},{"line_number":1038,"context_line":"        if \u0027id\u0027 in res_dict:"},{"line_number":1039,"context_line":"            data[res_type].update("},{"line_number":1040,"context_line":"                {res_dict.get(\u0027id\u0027): res_dict.get(\u0027name\u0027)})"},{"line_number":1041,"context_line":"        elif \u0027name\u0027 in res_dict:"},{"line_number":1042,"context_line":"            data[res_type].update({res_dict.get(\u0027name\u0027): \"\"})"},{"line_number":1043,"context_line":""},{"line_number":1044,"context_line":"        self.rec_rw_lock.acquire_write_lock()"},{"line_number":1045,"context_line":"        with open(\"resource_list.json\", \u0027w+\u0027) as f:"},{"line_number":1046,"context_line":"            f.write(json.dumps(data, indent\u003d2, separators\u003d(\u0027,\u0027, \u0027: \u0027)))"}],"source_content_type":"text/x-python","patch_set":25,"id":"006c849c_a153eefc","line":1043,"range":{"start_line":1038,"start_character":8,"end_line":1043,"end_character":0},"in_reply_to":"ebcb2d11_d80d6714","updated":"2024-04-22 13:15:15.000000000","message":"I have not found resources with uuid, but I can add this option just to be sure.","commit_id":"438c5fde26bae00b04cf5d611f00247a7683f771"}],"tempest/tests/cmd/test_cleanup.py":[{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"d9a509be2a7ac90bb8ca8acf7ef504717d60183a","unresolved":true,"context_lines":[{"line_number":26,"context_line":"        test_saved_json \u003d \u0027tempest/tests/cmd/test_saved_state_json.json\u0027"},{"line_number":27,"context_line":"        # test if the file is loaded without any issues/exceptions"},{"line_number":28,"context_line":"        c.options \u003d mock.Mock()"},{"line_number":29,"context_line":"        c.options.resource_list \u003d False"},{"line_number":30,"context_line":"        c._load_json(test_saved_json)"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"    @mock.patch(\u0027tempest.cmd.cleanup.TempestCleanup.init\u0027)"}],"source_content_type":"text/x-python","patch_set":21,"id":"29a30367_9caf6629","line":29,"range":{"start_line":29,"start_character":0,"end_line":29,"end_character":39},"updated":"2024-01-03 19:29:16.000000000","message":"as per my previous comment about checking the resource presence in both saved state file and resource-json file, here we should add a test that cleanup.py check about it and abandon the load_json if there is any such resource.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"bf6bb783c1f0c6c5f395d0c907abf017015a74cd","unresolved":false,"context_lines":[{"line_number":26,"context_line":"        test_saved_json \u003d \u0027tempest/tests/cmd/test_saved_state_json.json\u0027"},{"line_number":27,"context_line":"        # test if the file is loaded without any issues/exceptions"},{"line_number":28,"context_line":"        c.options \u003d mock.Mock()"},{"line_number":29,"context_line":"        c.options.resource_list \u003d False"},{"line_number":30,"context_line":"        c._load_json(test_saved_json)"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"    @mock.patch(\u0027tempest.cmd.cleanup.TempestCleanup.init\u0027)"}],"source_content_type":"text/x-python","patch_set":21,"id":"37a4fc86_a58aec36","line":29,"range":{"start_line":29,"start_character":0,"end_line":29,"end_character":39},"in_reply_to":"29a30367_9caf6629","updated":"2024-05-03 13:14:47.000000000","message":"Acknowledged","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"07850c662ee83f6bd2246bbec926c89c3c94c893","unresolved":true,"context_lines":[{"line_number":27,"context_line":"        test_resource_list \u003d \u0027tempest/tests/cmd/test_resource_list.json\u0027"},{"line_number":28,"context_line":"        # test if the file is loaded without any issues/exceptions"},{"line_number":29,"context_line":"        c.options \u003d mock.Mock()"},{"line_number":30,"context_line":"        c._load_json(test_saved_json, test_resource_list)"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"    @mock.patch(\u0027tempest.cmd.cleanup.TempestCleanup.init\u0027)"},{"line_number":33,"context_line":"    @mock.patch(\u0027tempest.cmd.cleanup.TempestCleanup._cleanup\u0027)"}],"source_content_type":"text/x-python","patch_set":27,"id":"74101137_04fa1d7a","line":30,"range":{"start_line":30,"start_character":0,"end_line":30,"end_character":57},"updated":"2024-04-17 23:02:47.000000000","message":"we need to extend this test to verify which file will be loaded when both option is passed. That is how we will be able to verify what we do in cleanup.py is working fine or not","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"ad8c4827f916a0df104d034fbb75c4b3bd7f8351","unresolved":false,"context_lines":[{"line_number":27,"context_line":"        test_resource_list \u003d \u0027tempest/tests/cmd/test_resource_list.json\u0027"},{"line_number":28,"context_line":"        # test if the file is loaded without any issues/exceptions"},{"line_number":29,"context_line":"        c.options \u003d mock.Mock()"},{"line_number":30,"context_line":"        c._load_json(test_saved_json, test_resource_list)"},{"line_number":31,"context_line":""},{"line_number":32,"context_line":"    @mock.patch(\u0027tempest.cmd.cleanup.TempestCleanup.init\u0027)"},{"line_number":33,"context_line":"    @mock.patch(\u0027tempest.cmd.cleanup.TempestCleanup._cleanup\u0027)"}],"source_content_type":"text/x-python","patch_set":27,"id":"ef72a75f_6e8f0f85","line":30,"range":{"start_line":30,"start_character":0,"end_line":30,"end_character":57},"in_reply_to":"74101137_04fa1d7a","updated":"2024-04-22 13:15:15.000000000","message":"Done","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"}],"tempest/tests/cmd/test_cleanup_services.py":[{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"d9a509be2a7ac90bb8ca8acf7ef504717d60183a","unresolved":true,"context_lines":[{"line_number":61,"context_line":"    def test_not_implemented_ex(self):"},{"line_number":62,"context_line":"        kwargs \u003d {\u0027data\u0027: {\u0027data\u0027: \u0027test\u0027},"},{"line_number":63,"context_line":"                  \u0027is_dry_run\u0027: False,"},{"line_number":64,"context_line":"                  \u0027resource_list_json\u0027: {\u0027saved\u0027: \u0027data\u0027},"},{"line_number":65,"context_line":"                  \u0027saved_state_json\u0027: {\u0027saved\u0027: \u0027data\u0027},"},{"line_number":66,"context_line":"                  \u0027is_preserve\u0027: False,"},{"line_number":67,"context_line":"                  \u0027is_resource_list\u0027: False,"}],"source_content_type":"text/x-python","patch_set":21,"id":"024a0336_c469cd75","line":64,"range":{"start_line":64,"start_character":57,"end_line":64,"end_character":58},"updated":"2024-01-03 19:29:16.000000000","message":"also we should add a few of the resource test here that if resource is in resource_list_json then that gets deleted or not","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"bf6bb783c1f0c6c5f395d0c907abf017015a74cd","unresolved":false,"context_lines":[{"line_number":61,"context_line":"    def test_not_implemented_ex(self):"},{"line_number":62,"context_line":"        kwargs \u003d {\u0027data\u0027: {\u0027data\u0027: \u0027test\u0027},"},{"line_number":63,"context_line":"                  \u0027is_dry_run\u0027: False,"},{"line_number":64,"context_line":"                  \u0027resource_list_json\u0027: {\u0027saved\u0027: \u0027data\u0027},"},{"line_number":65,"context_line":"                  \u0027saved_state_json\u0027: {\u0027saved\u0027: \u0027data\u0027},"},{"line_number":66,"context_line":"                  \u0027is_preserve\u0027: False,"},{"line_number":67,"context_line":"                  \u0027is_resource_list\u0027: False,"}],"source_content_type":"text/x-python","patch_set":21,"id":"7da11b1b_2ad84515","line":64,"range":{"start_line":64,"start_character":57,"end_line":64,"end_character":58},"in_reply_to":"024a0336_c469cd75","updated":"2024-05-03 13:14:47.000000000","message":"Tests to check deletion are already written elsewhere.","commit_id":"92e394d715183bada956a6af1e68eafd491a5d3f"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"07850c662ee83f6bd2246bbec926c89c3c94c893","unresolved":true,"context_lines":[{"line_number":211,"context_line":"            data\u003d{},"},{"line_number":212,"context_line":"            saved_state_json\u003dself.saved_state"},{"line_number":213,"context_line":"            )"},{"line_number":214,"context_line":""},{"line_number":215,"context_line":"    def _test_delete(self, mocked_fixture_tuple_list, fail\u003dFalse):"},{"line_number":216,"context_line":"        serv \u003d self._create_cmd_service(self.service_class)"},{"line_number":217,"context_line":"        resp, fixtures \u003d self.run_function_with_mocks("}],"source_content_type":"text/x-python","patch_set":27,"id":"fcd7cb2b_213dc7f1","line":214,"updated":"2024-04-17 23:02:47.000000000","message":"Also, we need to write a few new test which can verify:\n\n1. if ``--resource-list`` and ``--prefix`` is send together then cleanup service ignore te ``--resource-list``.\n2. if ``--resource-list`` is passed and is_save_state is there then ``--resource-list`` is used and saved init file is ignored.","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"bf6bb783c1f0c6c5f395d0c907abf017015a74cd","unresolved":false,"context_lines":[{"line_number":211,"context_line":"            data\u003d{},"},{"line_number":212,"context_line":"            saved_state_json\u003dself.saved_state"},{"line_number":213,"context_line":"            )"},{"line_number":214,"context_line":""},{"line_number":215,"context_line":"    def _test_delete(self, mocked_fixture_tuple_list, fail\u003dFalse):"},{"line_number":216,"context_line":"        serv \u003d self._create_cmd_service(self.service_class)"},{"line_number":217,"context_line":"        resp, fixtures \u003d self.run_function_with_mocks("}],"source_content_type":"text/x-python","patch_set":27,"id":"d5866aa8_07467cd8","line":214,"in_reply_to":"e743678f_929d5ae3","updated":"2024-05-03 13:14:47.000000000","message":"Done","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"ad8c4827f916a0df104d034fbb75c4b3bd7f8351","unresolved":true,"context_lines":[{"line_number":211,"context_line":"            data\u003d{},"},{"line_number":212,"context_line":"            saved_state_json\u003dself.saved_state"},{"line_number":213,"context_line":"            )"},{"line_number":214,"context_line":""},{"line_number":215,"context_line":"    def _test_delete(self, mocked_fixture_tuple_list, fail\u003dFalse):"},{"line_number":216,"context_line":"        serv \u003d self._create_cmd_service(self.service_class)"},{"line_number":217,"context_line":"        resp, fixtures \u003d self.run_function_with_mocks("}],"source_content_type":"text/x-python","patch_set":27,"id":"e743678f_929d5ae3","line":214,"in_reply_to":"fcd7cb2b_213dc7f1","updated":"2024-04-22 13:15:15.000000000","message":"I am not sure how to do these tests. I will update it in new patch.","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"}],"tempest/tests/lib/common/test_rest_client.py":[{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"07850c662ee83f6bd2246bbec926c89c3c94c893","unresolved":true,"context_lines":[{"line_number":768,"context_line":""},{"line_number":769,"context_line":"    def test_resource_record_dict(self):"},{"line_number":770,"context_line":"        test_dict_body \u003d b\u0027{\"project\": {\"id\": \"test-id\", \"name\": \"\"}}\\n\u0027"},{"line_number":771,"context_line":"        self.rest_client.resource_record(test_dict_body)"},{"line_number":772,"context_line":""},{"line_number":773,"context_line":"    def test_resource_record_list(self):"},{"line_number":774,"context_line":"        test_list_body \u003d \u0027\u0027\u0027{"}],"source_content_type":"text/x-python","patch_set":27,"id":"f1b8d710_bb5a62d6","line":771,"range":{"start_line":771,"start_character":54,"end_line":771,"end_character":56},"updated":"2024-04-17 23:02:47.000000000","message":"after recording the resource we need to check how data is recorded in resource_list.json it should be:\n\n{\n\"project\": { \"test-id\": \"\"\n}\n\nWithout that check we are just checking that resource_record() method is not failing anywhere but not checking whether it record data correctly or not.","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"ad8c4827f916a0df104d034fbb75c4b3bd7f8351","unresolved":false,"context_lines":[{"line_number":768,"context_line":""},{"line_number":769,"context_line":"    def test_resource_record_dict(self):"},{"line_number":770,"context_line":"        test_dict_body \u003d b\u0027{\"project\": {\"id\": \"test-id\", \"name\": \"\"}}\\n\u0027"},{"line_number":771,"context_line":"        self.rest_client.resource_record(test_dict_body)"},{"line_number":772,"context_line":""},{"line_number":773,"context_line":"    def test_resource_record_list(self):"},{"line_number":774,"context_line":"        test_list_body \u003d \u0027\u0027\u0027{"}],"source_content_type":"text/x-python","patch_set":27,"id":"262340e2_3770465e","line":771,"range":{"start_line":771,"start_character":54,"end_line":771,"end_character":56},"in_reply_to":"f1b8d710_bb5a62d6","updated":"2024-04-22 13:15:15.000000000","message":"Done","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"07850c662ee83f6bd2246bbec926c89c3c94c893","unresolved":true,"context_lines":[{"line_number":784,"context_line":"            ]"},{"line_number":785,"context_line":"        }\u0027\u0027\u0027"},{"line_number":786,"context_line":"        test_list_body \u003d test_list_body.encode(\u0027utf-8\u0027)"},{"line_number":787,"context_line":"        self.rest_client.resource_record(test_list_body)"},{"line_number":788,"context_line":""},{"line_number":789,"context_line":"    def test_resource_update_id(self):"},{"line_number":790,"context_line":"        data \u003d {}"}],"source_content_type":"text/x-python","patch_set":27,"id":"e35b8677_416572b7","line":787,"range":{"start_line":787,"start_character":55,"end_line":787,"end_character":56},"updated":"2024-04-17 23:02:47.000000000","message":"ditto. after recording the resource we need to check how data is recorded in resource_list.json it should be:\n\n{\n\"user\": { \"test-uuid\": \"test-name\",\n          \"test-uuid2\": \"test-name2\"}\n}","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"ad8c4827f916a0df104d034fbb75c4b3bd7f8351","unresolved":false,"context_lines":[{"line_number":784,"context_line":"            ]"},{"line_number":785,"context_line":"        }\u0027\u0027\u0027"},{"line_number":786,"context_line":"        test_list_body \u003d test_list_body.encode(\u0027utf-8\u0027)"},{"line_number":787,"context_line":"        self.rest_client.resource_record(test_list_body)"},{"line_number":788,"context_line":""},{"line_number":789,"context_line":"    def test_resource_update_id(self):"},{"line_number":790,"context_line":"        data \u003d {}"}],"source_content_type":"text/x-python","patch_set":27,"id":"cdc06ba2_055aa511","line":787,"range":{"start_line":787,"start_character":55,"end_line":787,"end_character":56},"in_reply_to":"e35b8677_416572b7","updated":"2024-04-22 13:15:15.000000000","message":"Done","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"07850c662ee83f6bd2246bbec926c89c3c94c893","unresolved":true,"context_lines":[{"line_number":792,"context_line":""},{"line_number":793,"context_line":"        self.rest_client.rec_rw_lock \u003d mock.MagicMock()"},{"line_number":794,"context_line":"        self.rest_client.resource_update(data, \u0027user\u0027, res_dict)"},{"line_number":795,"context_line":"        result \u003d {\u0027users\u0027: {\u0027test-uuid\u0027: \u0027test-name\u0027}}"},{"line_number":796,"context_line":"        self.assertEqual(data, result)"},{"line_number":797,"context_line":""},{"line_number":798,"context_line":"    def test_resource_update_name(self):"},{"line_number":799,"context_line":"        data \u003d {\u0027keypairs\u0027: {}}"}],"source_content_type":"text/x-python","patch_set":27,"id":"ba21fdaf_25a3df83","line":796,"range":{"start_line":795,"start_character":0,"end_line":796,"end_character":38},"updated":"2024-04-17 23:02:47.000000000","message":"++, this is the complete test.","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"},{"author":{"_account_id":36227,"name":"Katarina Strenkova","email":"kstrenko@redhat.com","username":"kstrenko"},"change_message_id":"bf6bb783c1f0c6c5f395d0c907abf017015a74cd","unresolved":false,"context_lines":[{"line_number":792,"context_line":""},{"line_number":793,"context_line":"        self.rest_client.rec_rw_lock \u003d mock.MagicMock()"},{"line_number":794,"context_line":"        self.rest_client.resource_update(data, \u0027user\u0027, res_dict)"},{"line_number":795,"context_line":"        result \u003d {\u0027users\u0027: {\u0027test-uuid\u0027: \u0027test-name\u0027}}"},{"line_number":796,"context_line":"        self.assertEqual(data, result)"},{"line_number":797,"context_line":""},{"line_number":798,"context_line":"    def test_resource_update_name(self):"},{"line_number":799,"context_line":"        data \u003d {\u0027keypairs\u0027: {}}"}],"source_content_type":"text/x-python","patch_set":27,"id":"233f968e_7b87079c","line":796,"range":{"start_line":795,"start_character":0,"end_line":796,"end_character":38},"in_reply_to":"ba21fdaf_25a3df83","updated":"2024-05-03 13:14:47.000000000","message":"Acknowledged","commit_id":"486d7e828ab96ce57d47f588d3f2442cbcfb53d1"}]}
