)]}'
{"tempest/api/compute/base.py":[{"author":{"_account_id":22873,"name":"Martin Kopec","email":"mkopec@redhat.com","username":"mkopec"},"change_message_id":"9d40ad41e8447c5a169547f7f7e75865fc2e88c7","unresolved":false,"context_lines":[{"line_number":575,"context_line":"                                                volume[\u0027id\u0027], \u0027in-use\u0027)"},{"line_number":576,"context_line":"        return attachment"},{"line_number":577,"context_line":""},{"line_number":578,"context_line":"    def create_volume_snapshot(self, volume_id, name\u003dNone, description\u003dNone,"},{"line_number":579,"context_line":"                               metadata\u003dNone, force\u003dFalse):"},{"line_number":580,"context_line":"        name \u003d name or data_utils.rand_name("},{"line_number":581,"context_line":"            self.__class__.__name__ + \u0027-snapshot\u0027)"},{"line_number":582,"context_line":"        snapshot \u003d self.snapshots_client.create_snapshot("},{"line_number":583,"context_line":"            volume_id\u003dvolume_id,"},{"line_number":584,"context_line":"            force\u003dforce,"},{"line_number":585,"context_line":"            display_name\u003dname,"},{"line_number":586,"context_line":"            description\u003ddescription,"},{"line_number":587,"context_line":"            metadata\u003dmetadata)[\u0027snapshot\u0027]"},{"line_number":588,"context_line":"        self.addCleanup(self.snapshots_client.wait_for_resource_deletion,"},{"line_number":589,"context_line":"                        snapshot[\u0027id\u0027])"},{"line_number":590,"context_line":"        self.addCleanup(self.snapshots_client.delete_snapshot, snapshot[\u0027id\u0027])"},{"line_number":591,"context_line":"        waiters.wait_for_volume_resource_status(self.snapshots_client,"},{"line_number":592,"context_line":"                                                snapshot[\u0027id\u0027], \u0027available\u0027)"},{"line_number":593,"context_line":"        snapshot \u003d self.snapshots_client.show_snapshot("},{"line_number":594,"context_line":"            snapshot[\u0027id\u0027])[\u0027snapshot\u0027]"},{"line_number":595,"context_line":"        return snapshot"},{"line_number":596,"context_line":""},{"line_number":597,"context_line":"    def assert_flavor_equal(self, flavor_id, server_flavor):"},{"line_number":598,"context_line":"        \"\"\"Check whether server_flavor equals to flavor."}],"source_content_type":"text/x-python","patch_set":12,"id":"3f4c43b2_bb066a85","line":595,"range":{"start_line":578,"start_character":0,"end_line":595,"end_character":23},"updated":"2020-04-18 20:43:56.000000000","message":"this is a copy paste of the create_volume_snapshot method from tempest/scenario/manager.py\n\nthis is more a question for other cores, what is the best location (if any) for this method so that it would be accessible from tempest/api/compute/* tests and scenario ones as well?","commit_id":"ee546d43f90a923dc127ce3e652a46bbef8d5839"},{"author":{"_account_id":8556,"name":"Ghanshyam Maan","display_name":"Ghanshyam Maan","email":"gmaan.os14@gmail.com","username":"ghanshyam"},"change_message_id":"027f87f7820078866880624935e5c7546f3436aa","unresolved":false,"context_lines":[{"line_number":575,"context_line":"                                                volume[\u0027id\u0027], \u0027in-use\u0027)"},{"line_number":576,"context_line":"        return attachment"},{"line_number":577,"context_line":""},{"line_number":578,"context_line":"    def create_volume_snapshot(self, volume_id, name\u003dNone, description\u003dNone,"},{"line_number":579,"context_line":"                               metadata\u003dNone, force\u003dFalse):"},{"line_number":580,"context_line":"        name \u003d name or data_utils.rand_name("},{"line_number":581,"context_line":"            self.__class__.__name__ + \u0027-snapshot\u0027)"},{"line_number":582,"context_line":"        snapshot \u003d self.snapshots_client.create_snapshot("},{"line_number":583,"context_line":"            volume_id\u003dvolume_id,"},{"line_number":584,"context_line":"            force\u003dforce,"},{"line_number":585,"context_line":"            display_name\u003dname,"},{"line_number":586,"context_line":"            description\u003ddescription,"},{"line_number":587,"context_line":"            metadata\u003dmetadata)[\u0027snapshot\u0027]"},{"line_number":588,"context_line":"        self.addCleanup(self.snapshots_client.wait_for_resource_deletion,"},{"line_number":589,"context_line":"                        snapshot[\u0027id\u0027])"},{"line_number":590,"context_line":"        self.addCleanup(self.snapshots_client.delete_snapshot, snapshot[\u0027id\u0027])"},{"line_number":591,"context_line":"        waiters.wait_for_volume_resource_status(self.snapshots_client,"},{"line_number":592,"context_line":"                                                snapshot[\u0027id\u0027], \u0027available\u0027)"},{"line_number":593,"context_line":"        snapshot \u003d self.snapshots_client.show_snapshot("},{"line_number":594,"context_line":"            snapshot[\u0027id\u0027])[\u0027snapshot\u0027]"},{"line_number":595,"context_line":"        return snapshot"},{"line_number":596,"context_line":""},{"line_number":597,"context_line":"    def assert_flavor_equal(self, flavor_id, server_flavor):"},{"line_number":598,"context_line":"        \"\"\"Check whether server_flavor equals to flavor."}],"source_content_type":"text/x-python","patch_set":12,"id":"1f493fa4_241bd31b","line":595,"range":{"start_line":578,"start_character":0,"end_line":595,"end_character":23},"in_reply_to":"1f493fa4_644cbb76","updated":"2020-04-20 23:55:00.000000000","message":"I was thinking about common/compute.py but we cannot do addcleanup there. We can find few more duplicate code between API and scenario base class. We can do mixin class between both. for that we need to do that once we have clear pic of scenario manager stable version.\n\nI think we can add this as a step of scenario manager stable version on etherpad\n\nLet\u0027s merge this and optimize this as part of scenario manager work.","commit_id":"ee546d43f90a923dc127ce3e652a46bbef8d5839"},{"author":{"_account_id":5689,"name":"Masayuki Igawa","email":"masayuki@igawa.io","username":"igawa"},"change_message_id":"404462e33017a0de0ae81c2582fc2772bb4639b1","unresolved":false,"context_lines":[{"line_number":575,"context_line":"                                                volume[\u0027id\u0027], \u0027in-use\u0027)"},{"line_number":576,"context_line":"        return attachment"},{"line_number":577,"context_line":""},{"line_number":578,"context_line":"    def create_volume_snapshot(self, volume_id, name\u003dNone, description\u003dNone,"},{"line_number":579,"context_line":"                               metadata\u003dNone, force\u003dFalse):"},{"line_number":580,"context_line":"        name \u003d name or data_utils.rand_name("},{"line_number":581,"context_line":"            self.__class__.__name__ + \u0027-snapshot\u0027)"},{"line_number":582,"context_line":"        snapshot \u003d self.snapshots_client.create_snapshot("},{"line_number":583,"context_line":"            volume_id\u003dvolume_id,"},{"line_number":584,"context_line":"            force\u003dforce,"},{"line_number":585,"context_line":"            display_name\u003dname,"},{"line_number":586,"context_line":"            description\u003ddescription,"},{"line_number":587,"context_line":"            metadata\u003dmetadata)[\u0027snapshot\u0027]"},{"line_number":588,"context_line":"        self.addCleanup(self.snapshots_client.wait_for_resource_deletion,"},{"line_number":589,"context_line":"                        snapshot[\u0027id\u0027])"},{"line_number":590,"context_line":"        self.addCleanup(self.snapshots_client.delete_snapshot, snapshot[\u0027id\u0027])"},{"line_number":591,"context_line":"        waiters.wait_for_volume_resource_status(self.snapshots_client,"},{"line_number":592,"context_line":"                                                snapshot[\u0027id\u0027], \u0027available\u0027)"},{"line_number":593,"context_line":"        snapshot \u003d self.snapshots_client.show_snapshot("},{"line_number":594,"context_line":"            snapshot[\u0027id\u0027])[\u0027snapshot\u0027]"},{"line_number":595,"context_line":"        return snapshot"},{"line_number":596,"context_line":""},{"line_number":597,"context_line":"    def assert_flavor_equal(self, flavor_id, server_flavor):"},{"line_number":598,"context_line":"        \"\"\"Check whether server_flavor equals to flavor."}],"source_content_type":"text/x-python","patch_set":12,"id":"1f493fa4_644cbb76","line":595,"range":{"start_line":578,"start_character":0,"end_line":595,"end_character":23},"in_reply_to":"3f4c43b2_bb066a85","updated":"2020-04-20 23:28:40.000000000","message":"I think the best solution is migrating like these utility methods to a new common utility class.\n\nAnd, another possible location is tempest.test.BaseTestCase. It can be accessible from tempest/api/compute/* tests, scenario ones and any other tempest test cases.\nBut I also think it\u0027s not the best location because the class doesn\u0027t have like that utility method yet.","commit_id":"ee546d43f90a923dc127ce3e652a46bbef8d5839"}]}
