)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"97e2649f4c3cb3d3650c07fab5cc116bb951ee63","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"6432d548_7785f4b5","updated":"2023-08-25 08:58:03.000000000","message":"I\u0027m not sure but I think that the issue is in this setUp function [1]. I would probably try fixing the issue there. \n\nIn the setUp we call this create_application_credential() [2] function instead of this one [3] (notice there is no cleanUp). \n\n[1] https://opendev.org/openstack/tempest/src/commit/b2fefaf0b56ce96f6116f89faf79458ef4f9c7f3/tempest/api/identity/v3/test_access_rules.py#L51\n[2] https://opendev.org/openstack/tempest/src/commit/b2fefaf0b56ce96f6116f89faf79458ef4f9c7f3/tempest/lib/services/identity/v3/application_credentials_client.py#L31\n[3] https://opendev.org/openstack/tempest/src/commit/b2fefaf0b56ce96f6116f89faf79458ef4f9c7f3/tempest/api/identity/base.py#L326","commit_id":"2be2f14080f53ba4a895d7b2ee1fbed955a5b23f"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"d0033612e087b05873776063e948d543766dc626","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"3683da0c_78e37a15","updated":"2023-08-24 10:51:56.000000000","message":"check experimental","commit_id":"2be2f14080f53ba4a895d7b2ee1fbed955a5b23f"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"972435439b2c3822ea70bd1ae885cd0dc490d331","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":1,"id":"74c10905_71a6e33d","in_reply_to":"6432d548_7785f4b5","updated":"2023-08-25 09:18:07.000000000","message":"it appears so, propose another patch where you\u0027ll replace ac with self on line 51\nhttps://opendev.org/openstack/tempest/src/commit/b2fefaf0b56ce96f6116f89faf79458ef4f9c7f3/tempest/api/identity/v3/test_access_rules.py#L51\nAnd run it with your reproducer you mentioned.","commit_id":"2be2f14080f53ba4a895d7b2ee1fbed955a5b23f"},{"author":{"_account_id":30674,"name":"Lukas Piwowarski","email":"lpiwowar@redhat.com","username":"lukas-piwowarski"},"change_message_id":"a987d3ea937d8e5f3aae63aa7047fc42c4b5bb68","unresolved":true,"context_lines":[],"source_content_type":"","patch_set":1,"id":"044490d6_2774b2a4","in_reply_to":"74c10905_71a6e33d","updated":"2023-08-25 11:57:49.000000000","message":"I could not use the auxiliary function [1] in setUp because it was causing a failure for test_delete_access_rule test [2] as the application creds are deleted as a part of the testing. And when the clean-up function was called an error was raised.\n\n[1] https://opendev.org/openstack/tempest/src/commit/b2fefaf0b56ce96f6116f89faf79458ef4f9c7f3/tempest/api/identity/base.py#L326\n[2] https://opendev.org/openstack/tempest/src/commit/b2fefaf0b56ce96f6116f89faf79458ef4f9c7f3/tempest/api/identity/v3/test_access_rules.py#L77","commit_id":"2be2f14080f53ba4a895d7b2ee1fbed955a5b23f"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"7f7df7cc16377b75184290919209c57b785994c7","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"308caf26_3b00c724","updated":"2023-08-25 18:14:52.000000000","message":"Agree with that cleanup is happening but it seems we are creating the resource wrongly in setup. suggested one way inline","commit_id":"93cb9ffd3cfb866ab8ff307de76e1e1a69085a63"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"8a2d34590c0ad3706addd90b916a71f7a5184371","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"3d824175_8b747ecb","updated":"2023-09-06 08:17:37.000000000","message":"check experimental","commit_id":"347ef034590449426f0e9fd5fcc96a008e2cf95b"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"faa3b8d0232a9b69e84197879597edfa4ada750d","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"9f63d605_6527e75d","updated":"2023-09-05 20:33:44.000000000","message":"recheck ssh timeout","commit_id":"347ef034590449426f0e9fd5fcc96a008e2cf95b"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"cd04cdab9d4066b5b575d0c6a1eda955f84c60db","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"8c963677_6b9e3032","updated":"2023-09-06 06:46:54.000000000","message":"recheck timeout","commit_id":"347ef034590449426f0e9fd5fcc96a008e2cf95b"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"ad92b8f366bf1c0fb7f0472c793759d47bd347a7","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":3,"id":"3ec0e644_b77481ed","updated":"2023-09-05 16:15:19.000000000","message":"thanks. lgtm","commit_id":"347ef034590449426f0e9fd5fcc96a008e2cf95b"}],"tempest/api/identity/v3/test_access_rules.py":[{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"7f7df7cc16377b75184290919209c57b785994c7","unresolved":true,"context_lines":[{"line_number":40,"context_line":""},{"line_number":41,"context_line":"    def setUp(self):"},{"line_number":42,"context_line":"        super(AccessRulesV3Test, self).setUp()"},{"line_number":43,"context_line":"        ac \u003d self.non_admin_app_creds_client"},{"line_number":44,"context_line":"        access_rules \u003d ["},{"line_number":45,"context_line":"            {"},{"line_number":46,"context_line":"                \"path\": \"/v2.1/servers/*/ips\","},{"line_number":47,"context_line":"                \"method\": \"GET\","},{"line_number":48,"context_line":"                \"service\": \"compute\""},{"line_number":49,"context_line":"            }"},{"line_number":50,"context_line":"        ]"},{"line_number":51,"context_line":"        self.app_cred \u003d ac.create_application_credential("},{"line_number":52,"context_line":"            self.user_id,"},{"line_number":53,"context_line":"            name\u003ddata_utils.rand_name(\u0027application_credential\u0027),"},{"line_number":54,"context_line":"            access_rules\u003daccess_rules"},{"line_number":55,"context_line":"        )[\u0027application_credential\u0027]"},{"line_number":56,"context_line":""},{"line_number":57,"context_line":"    @decorators.idempotent_id(\u00272354c498-5119-4ba5-9f0d-44f16f78fb0e\u0027)"},{"line_number":58,"context_line":"    def test_list_access_rules(self):"}],"source_content_type":"text/x-python","patch_set":2,"id":"97b0c52f_78117c14","line":55,"range":{"start_line":43,"start_character":0,"end_line":55,"end_character":35},"updated":"2023-08-25 18:14:52.000000000","message":"I think creating the creds in setUp is the problem and it is not class level resource instead create a new one for every test. Main purpose of creating the resource at test class level is we do not need to create/delete that on every test execution instead that can be done once per test class.\n\nWe should create this in resource_setup() with cleanup and let list/show test use this among them.","commit_id":"93cb9ffd3cfb866ab8ff307de76e1e1a69085a63"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"ad92b8f366bf1c0fb7f0472c793759d47bd347a7","unresolved":false,"context_lines":[{"line_number":40,"context_line":""},{"line_number":41,"context_line":"    def setUp(self):"},{"line_number":42,"context_line":"        super(AccessRulesV3Test, self).setUp()"},{"line_number":43,"context_line":"        ac \u003d self.non_admin_app_creds_client"},{"line_number":44,"context_line":"        access_rules \u003d ["},{"line_number":45,"context_line":"            {"},{"line_number":46,"context_line":"                \"path\": \"/v2.1/servers/*/ips\","},{"line_number":47,"context_line":"                \"method\": \"GET\","},{"line_number":48,"context_line":"                \"service\": \"compute\""},{"line_number":49,"context_line":"            }"},{"line_number":50,"context_line":"        ]"},{"line_number":51,"context_line":"        self.app_cred \u003d ac.create_application_credential("},{"line_number":52,"context_line":"            self.user_id,"},{"line_number":53,"context_line":"            name\u003ddata_utils.rand_name(\u0027application_credential\u0027),"},{"line_number":54,"context_line":"            access_rules\u003daccess_rules"},{"line_number":55,"context_line":"        )[\u0027application_credential\u0027]"},{"line_number":56,"context_line":""},{"line_number":57,"context_line":"    @decorators.idempotent_id(\u00272354c498-5119-4ba5-9f0d-44f16f78fb0e\u0027)"},{"line_number":58,"context_line":"    def test_list_access_rules(self):"}],"source_content_type":"text/x-python","patch_set":2,"id":"4083daca_64cba68c","line":55,"range":{"start_line":43,"start_character":0,"end_line":55,"end_character":35},"in_reply_to":"43fa5c22_a004cbbc","updated":"2023-09-05 16:15:19.000000000","message":"Done","commit_id":"93cb9ffd3cfb866ab8ff307de76e1e1a69085a63"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"b36b14a6d727ce28983aedbe1d49628ae0efcc6c","unresolved":true,"context_lines":[{"line_number":40,"context_line":""},{"line_number":41,"context_line":"    def setUp(self):"},{"line_number":42,"context_line":"        super(AccessRulesV3Test, self).setUp()"},{"line_number":43,"context_line":"        ac \u003d self.non_admin_app_creds_client"},{"line_number":44,"context_line":"        access_rules \u003d ["},{"line_number":45,"context_line":"            {"},{"line_number":46,"context_line":"                \"path\": \"/v2.1/servers/*/ips\","},{"line_number":47,"context_line":"                \"method\": \"GET\","},{"line_number":48,"context_line":"                \"service\": \"compute\""},{"line_number":49,"context_line":"            }"},{"line_number":50,"context_line":"        ]"},{"line_number":51,"context_line":"        self.app_cred \u003d ac.create_application_credential("},{"line_number":52,"context_line":"            self.user_id,"},{"line_number":53,"context_line":"            name\u003ddata_utils.rand_name(\u0027application_credential\u0027),"},{"line_number":54,"context_line":"            access_rules\u003daccess_rules"},{"line_number":55,"context_line":"        )[\u0027application_credential\u0027]"},{"line_number":56,"context_line":""},{"line_number":57,"context_line":"    @decorators.idempotent_id(\u00272354c498-5119-4ba5-9f0d-44f16f78fb0e\u0027)"},{"line_number":58,"context_line":"    def test_list_access_rules(self):"}],"source_content_type":"text/x-python","patch_set":2,"id":"43fa5c22_a004cbbc","line":55,"range":{"start_line":43,"start_character":0,"end_line":55,"end_character":35},"in_reply_to":"97b0c52f_78117c14","updated":"2023-08-29 13:32:27.000000000","message":"that makes sense, based on the traceback there were 2 extra creds:\n testtools.matchers._impl.MismatchError: 2 !\u003d 4\nwe have 3 tests, creds were created for each, however, the last test deletes one \u003d\u003e 2","commit_id":"93cb9ffd3cfb866ab8ff307de76e1e1a69085a63"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"7f7df7cc16377b75184290919209c57b785994c7","unresolved":true,"context_lines":[{"line_number":75,"context_line":""},{"line_number":76,"context_line":"    @decorators.idempotent_id(\u0027278757e9-e193-4bf8-adf2-0b0a229a17d0\u0027)"},{"line_number":77,"context_line":"    def test_delete_access_rule(self):"},{"line_number":78,"context_line":"        access_rule_id \u003d self.app_cred[\u0027access_rules\u0027][0][\u0027id\u0027]"},{"line_number":79,"context_line":"        app_cred_id \u003d self.app_cred[\u0027id\u0027]"},{"line_number":80,"context_line":"        self.assertRaises("},{"line_number":81,"context_line":"            lib_exc.Forbidden,"}],"source_content_type":"text/x-python","patch_set":2,"id":"c0c1a55e_c4dc4da9","line":78,"range":{"start_line":78,"start_character":25,"end_line":78,"end_character":38},"updated":"2023-08-25 18:14:52.000000000","message":"instead of using the self.app_cred here, let\u0027s create the new one here with cleanup so that this test can delete it own created app/access and does not touch the class level one which is used by other list tests.","commit_id":"93cb9ffd3cfb866ab8ff307de76e1e1a69085a63"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"6f8739e0eb61a41d6e6609571fe6dbcee2ede40d","unresolved":false,"context_lines":[{"line_number":75,"context_line":""},{"line_number":76,"context_line":"    @decorators.idempotent_id(\u0027278757e9-e193-4bf8-adf2-0b0a229a17d0\u0027)"},{"line_number":77,"context_line":"    def test_delete_access_rule(self):"},{"line_number":78,"context_line":"        access_rule_id \u003d self.app_cred[\u0027access_rules\u0027][0][\u0027id\u0027]"},{"line_number":79,"context_line":"        app_cred_id \u003d self.app_cred[\u0027id\u0027]"},{"line_number":80,"context_line":"        self.assertRaises("},{"line_number":81,"context_line":"            lib_exc.Forbidden,"}],"source_content_type":"text/x-python","patch_set":2,"id":"19a296b8_67e8bb83","line":78,"range":{"start_line":78,"start_character":25,"end_line":78,"end_character":38},"in_reply_to":"27c2efcd_bbc40c6c","updated":"2023-08-29 19:50:41.000000000","message":"yep, we could do that","commit_id":"93cb9ffd3cfb866ab8ff307de76e1e1a69085a63"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"6d8bc6ab2fca8dfa9c6f084f53db3caad7b6dfe5","unresolved":true,"context_lines":[{"line_number":75,"context_line":""},{"line_number":76,"context_line":"    @decorators.idempotent_id(\u0027278757e9-e193-4bf8-adf2-0b0a229a17d0\u0027)"},{"line_number":77,"context_line":"    def test_delete_access_rule(self):"},{"line_number":78,"context_line":"        access_rule_id \u003d self.app_cred[\u0027access_rules\u0027][0][\u0027id\u0027]"},{"line_number":79,"context_line":"        app_cred_id \u003d self.app_cred[\u0027id\u0027]"},{"line_number":80,"context_line":"        self.assertRaises("},{"line_number":81,"context_line":"            lib_exc.Forbidden,"}],"source_content_type":"text/x-python","patch_set":2,"id":"ae18112b_ef72788c","line":78,"range":{"start_line":78,"start_character":25,"end_line":78,"end_character":38},"in_reply_to":"8d083f96_1396727f","updated":"2023-08-29 17:13:31.000000000","message":"maybe yes as it is under same project.","commit_id":"93cb9ffd3cfb866ab8ff307de76e1e1a69085a63"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"84933c66f40af99e605975d2b1148d9b9961799f","unresolved":true,"context_lines":[{"line_number":75,"context_line":""},{"line_number":76,"context_line":"    @decorators.idempotent_id(\u0027278757e9-e193-4bf8-adf2-0b0a229a17d0\u0027)"},{"line_number":77,"context_line":"    def test_delete_access_rule(self):"},{"line_number":78,"context_line":"        access_rule_id \u003d self.app_cred[\u0027access_rules\u0027][0][\u0027id\u0027]"},{"line_number":79,"context_line":"        app_cred_id \u003d self.app_cred[\u0027id\u0027]"},{"line_number":80,"context_line":"        self.assertRaises("},{"line_number":81,"context_line":"            lib_exc.Forbidden,"}],"source_content_type":"text/x-python","patch_set":2,"id":"27c2efcd_bbc40c6c","line":78,"range":{"start_line":78,"start_character":25,"end_line":78,"end_character":38},"in_reply_to":"ae18112b_ef72788c","updated":"2023-08-29 17:15:51.000000000","message":"otherway is to do same way we do in many delete tests. check the existence of the one this test create before and after delete. instead of counting all the access rules","commit_id":"93cb9ffd3cfb866ab8ff307de76e1e1a69085a63"},{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"b36b14a6d727ce28983aedbe1d49628ae0efcc6c","unresolved":true,"context_lines":[{"line_number":75,"context_line":""},{"line_number":76,"context_line":"    @decorators.idempotent_id(\u0027278757e9-e193-4bf8-adf2-0b0a229a17d0\u0027)"},{"line_number":77,"context_line":"    def test_delete_access_rule(self):"},{"line_number":78,"context_line":"        access_rule_id \u003d self.app_cred[\u0027access_rules\u0027][0][\u0027id\u0027]"},{"line_number":79,"context_line":"        app_cred_id \u003d self.app_cred[\u0027id\u0027]"},{"line_number":80,"context_line":"        self.assertRaises("},{"line_number":81,"context_line":"            lib_exc.Forbidden,"}],"source_content_type":"text/x-python","patch_set":2,"id":"8d083f96_1396727f","line":78,"range":{"start_line":78,"start_character":25,"end_line":78,"end_character":38},"in_reply_to":"c0c1a55e_c4dc4da9","updated":"2023-08-29 13:32:27.000000000","message":"sure, however, don\u0027t we have to edit the assertEqual logic on lines 88 and 92 as there might be exactly one app cred more (the one created in resources_setup)","commit_id":"93cb9ffd3cfb866ab8ff307de76e1e1a69085a63"}]}
