)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":9708,"name":"Balazs Gibizer","display_name":"gibi","email":"gibizer@gmail.com","username":"gibi"},"change_message_id":"13804dea7287a545cdfc85272f1e8b743168964d","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"c5eea122_a806091b","updated":"2025-09-08 13:38:53.000000000","message":"I should add some test coverage...","commit_id":"7e524a0cf8481ed6ca3421a08984e6a582d9ea6b"}],"rally_openstack/task/scenarios/nova/utils.py":[{"author":{"_account_id":9545,"name":"Andriy Kurilin","email":"andr.kurilin@gmail.com","username":"akurilin"},"change_message_id":"fcc4377a339530c3decc1bdfeb978860a33145a6","unresolved":true,"context_lines":[{"line_number":159,"context_line":"                    nic[\"net-id\"] \u003d self._get_network_id(nic[\"net-name\"])"},{"line_number":160,"context_line":""},{"line_number":161,"context_line":"        with atomic.ActionTimer(self, \"nova.boot_server\"):"},{"line_number":162,"context_line":"            server \u003d self.clients(\"nova\", \"2.37\").servers.create("},{"line_number":163,"context_line":"                server_name, image, flavor, **kwargs)"},{"line_number":164,"context_line":""},{"line_number":165,"context_line":"            self.sleep_between(CONF.openstack.nova_server_boot_prepoll_delay)"}],"source_content_type":"text/x-python","patch_set":3,"id":"ab69e37c_edf8fcb7","line":162,"updated":"2025-09-09 14:24:33.000000000","message":"This is not correct way to specify the version 😊\n\nInitializing the client with exact version should be done only if the scenario specifically targets this version which is not true here.\n\nThe api microversion for nova should be set either via context [0][1] or via \"api_info\" of environment spec (have the same format as context) if you want to change the default api_version for all tasks.\n\n[0] https://rally.readthedocs.io/en/latest/plugins/plugin_reference.html#api-versions-context\n[1] https://github.com/openstack/rally-openstack/blob/3.0.0/rally-jobs/nova.yaml#L801-L803\n\nAlso, it would be nice to add a validation that \"none\" is passed only when the proper api_version is used. \nThis can be done by\n\n1) creating add new validator for scenario arguments.\n\nsomething like this one:\n- validator: https://github.com/openstack/rally-openstack/blob/3.0.0/rally_openstack/common/validators.py#L557-L594\n- usage: https://github.com/openstack/rally-openstack/blob/3.0.0/rally_openstack/task/scenarios/cinder/volumes.py#L471\n\n`volume_type_exists` validator accepts a scenario argument name to check. the new validator should do the same. and if the `nics` is equal to `\"nics\"`, it should check whether api_version is ge of 2.37.\nProbably, the simplest way to get selected version for Nova would be checking `context[\"users\"][0][\"credential\"].clients().nova.api_version` which should rever to https://github.com/openstack/python-novaclient/blob/18.11.0/novaclient/v2/client.py#L215\n\n2) by adding this validation to all nova\u0027s scenarios","commit_id":"182af40bf2534b09412cb82c1c79476f1b84508b"}]}
