)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"443fdf0631cf8e11be8a4640da66346dde397cd3","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":8,"id":"02206eda_222bed50","updated":"2022-12-15 15:51:40.000000000","message":"Awesome, a few minor things, and you\u0027ll need to add RBAC policy testing, I\u0027ve linked to an example, and it should be fairly straight forward.","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"a3bf42d70367f3511236e94f8d2661a44f2d9c55","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":8,"id":"9493d5a4_1edc8dfd","updated":"2022-12-15 15:36:34.000000000","message":"Great start, just a few things inline","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"}],"api-ref/source/baremetal-api-v1-nodes-inventory.inc":[{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"a3bf42d70367f3511236e94f8d2661a44f2d9c55","unresolved":true,"context_lines":[{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Normal response code: 200"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"Error codes: 404"},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"Request"},{"line_number":22,"context_line":"-------"}],"source_content_type":"text/x-c++src","patch_set":8,"id":"06efdd4f_fa61ae61","line":19,"updated":"2022-12-15 15:36:34.000000000","message":"Worth explicitly mentioning that 404 is returned when 1) node was not found, 2) inventory for the node has never been recorded","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"},{"author":{"_account_id":35099,"name":"Jakub Jelinek","email":"jakub.jelinek@cern.ch","username":"kubajj"},"change_message_id":"e752f019bd8a3e6a05c9a1d8c60792f99bd55cc8","unresolved":true,"context_lines":[{"line_number":16,"context_line":""},{"line_number":17,"context_line":"Normal response code: 200"},{"line_number":18,"context_line":""},{"line_number":19,"context_line":"Error codes: 404"},{"line_number":20,"context_line":""},{"line_number":21,"context_line":"Request"},{"line_number":22,"context_line":"-------"}],"source_content_type":"text/x-c++src","patch_set":8,"id":"90b39230_48932e97","line":19,"in_reply_to":"06efdd4f_fa61ae61","updated":"2023-01-10 13:46:53.000000000","message":"Ack","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"a3bf42d70367f3511236e94f8d2661a44f2d9c55","unresolved":true,"context_lines":[{"line_number":30,"context_line":""},{"line_number":31,"context_line":".. rest_parameters:: parameters.yaml"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"   - inventory: n_inventory"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"**Example of inventory from a node:**"},{"line_number":36,"context_line":""}],"source_content_type":"text/x-c++src","patch_set":8,"id":"0d96bd90_60479a04","line":33,"updated":"2022-12-15 15:36:34.000000000","message":"and plugin_data?","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"},{"author":{"_account_id":35099,"name":"Jakub Jelinek","email":"jakub.jelinek@cern.ch","username":"kubajj"},"change_message_id":"e752f019bd8a3e6a05c9a1d8c60792f99bd55cc8","unresolved":true,"context_lines":[{"line_number":30,"context_line":""},{"line_number":31,"context_line":".. rest_parameters:: parameters.yaml"},{"line_number":32,"context_line":""},{"line_number":33,"context_line":"   - inventory: n_inventory"},{"line_number":34,"context_line":""},{"line_number":35,"context_line":"**Example of inventory from a node:**"},{"line_number":36,"context_line":""}],"source_content_type":"text/x-c++src","patch_set":8,"id":"e2d551d0_67d76f60","line":33,"in_reply_to":"0d96bd90_60479a04","updated":"2023-01-10 13:46:53.000000000","message":"Ack","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"}],"api-ref/source/parameters.yaml":[{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"a3bf42d70367f3511236e94f8d2661a44f2d9c55","unresolved":true,"context_lines":[{"line_number":1193,"context_line":"  type: array"},{"line_number":1194,"context_line":"n_inventory:"},{"line_number":1195,"context_line":"  description: |"},{"line_number":1196,"context_line":"    Link to the inventory of this node."},{"line_number":1197,"context_line":"  in: body"},{"line_number":1198,"context_line":"  required: false"},{"line_number":1199,"context_line":"  type: JSON"}],"source_content_type":"text/x-yaml","patch_set":8,"id":"4f01e933_6d7c335f","line":1196,"updated":"2022-12-15 15:36:34.000000000","message":"It does not seem to be a link though?","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"},{"author":{"_account_id":35099,"name":"Jakub Jelinek","email":"jakub.jelinek@cern.ch","username":"kubajj"},"change_message_id":"e752f019bd8a3e6a05c9a1d8c60792f99bd55cc8","unresolved":true,"context_lines":[{"line_number":1193,"context_line":"  type: array"},{"line_number":1194,"context_line":"n_inventory:"},{"line_number":1195,"context_line":"  description: |"},{"line_number":1196,"context_line":"    Link to the inventory of this node."},{"line_number":1197,"context_line":"  in: body"},{"line_number":1198,"context_line":"  required: false"},{"line_number":1199,"context_line":"  type: JSON"}],"source_content_type":"text/x-yaml","patch_set":8,"id":"7c76f7e8_cf1cb322","line":1196,"in_reply_to":"4f01e933_6d7c335f","updated":"2023-01-10 13:46:53.000000000","message":"Ack","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"}],"api-ref/source/samples/node-inventory-response.json":[{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"443fdf0631cf8e11be8a4640da66346dde397cd3","unresolved":true,"context_lines":[{"line_number":26,"context_line":"    \"local_gb\":10,"},{"line_number":27,"context_line":"    \"cpus\":1,"},{"line_number":28,"context_line":"    \"cpu_arch\":\"x86_64\","},{"line_number":29,"context_line":"    \"memory_mb\":2048 "},{"line_number":30,"context_line":"  }"},{"line_number":31,"context_line":"}"}],"source_content_type":"application/json","patch_set":8,"id":"b6f9fe9b_98e866ce","line":29,"updated":"2022-12-15 15:51:40.000000000","message":"nit: excess space","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"},{"author":{"_account_id":35099,"name":"Jakub Jelinek","email":"jakub.jelinek@cern.ch","username":"kubajj"},"change_message_id":"e752f019bd8a3e6a05c9a1d8c60792f99bd55cc8","unresolved":false,"context_lines":[{"line_number":26,"context_line":"    \"local_gb\":10,"},{"line_number":27,"context_line":"    \"cpus\":1,"},{"line_number":28,"context_line":"    \"cpu_arch\":\"x86_64\","},{"line_number":29,"context_line":"    \"memory_mb\":2048 "},{"line_number":30,"context_line":"  }"},{"line_number":31,"context_line":"}"}],"source_content_type":"application/json","patch_set":8,"id":"989e86a3_f0915792","line":29,"in_reply_to":"b6f9fe9b_98e866ce","updated":"2023-01-10 13:46:53.000000000","message":"Done","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"}],"doc/source/contributor/webapi-version-history.rst":[{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"443fdf0631cf8e11be8a4640da66346dde397cd3","unresolved":true,"context_lines":[{"line_number":2,"context_line":"REST API Version History"},{"line_number":3,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":4,"context_line":""},{"line_number":5,"context_line":"1.81 (Zed, ?)"},{"line_number":6,"context_line":"----------------------"},{"line_number":7,"context_line":""},{"line_number":8,"context_line":"Add endpoint to retrieve introspection data for nodes via the REST API."}],"source_content_type":"text/x-rst","patch_set":8,"id":"f957382c_02052475","line":5,"updated":"2022-12-15 15:51:40.000000000","message":"For what it is worth, typically we just say (Zed) or something like that and add the version number in post-release or just before release.","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"a3bf42d70367f3511236e94f8d2661a44f2d9c55","unresolved":true,"context_lines":[{"line_number":2,"context_line":"REST API Version History"},{"line_number":3,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":4,"context_line":""},{"line_number":5,"context_line":"1.81 (Zed, ?)"},{"line_number":6,"context_line":"----------------------"},{"line_number":7,"context_line":""},{"line_number":8,"context_line":"Add endpoint to retrieve introspection data for nodes via the REST API."}],"source_content_type":"text/x-rst","patch_set":8,"id":"a720dc3e_89c6c82c","line":5,"updated":"2022-12-15 15:36:34.000000000","message":"The current release is named Antelope, Zed was the previous one","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"},{"author":{"_account_id":35099,"name":"Jakub Jelinek","email":"jakub.jelinek@cern.ch","username":"kubajj"},"change_message_id":"e752f019bd8a3e6a05c9a1d8c60792f99bd55cc8","unresolved":false,"context_lines":[{"line_number":2,"context_line":"REST API Version History"},{"line_number":3,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":4,"context_line":""},{"line_number":5,"context_line":"1.81 (Zed, ?)"},{"line_number":6,"context_line":"----------------------"},{"line_number":7,"context_line":""},{"line_number":8,"context_line":"Add endpoint to retrieve introspection data for nodes via the REST API."}],"source_content_type":"text/x-rst","patch_set":8,"id":"6bd0b23a_e48fc24c","line":5,"in_reply_to":"a720dc3e_89c6c82c","updated":"2023-01-10 13:46:53.000000000","message":"Done","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"},{"author":{"_account_id":35099,"name":"Jakub Jelinek","email":"jakub.jelinek@cern.ch","username":"kubajj"},"change_message_id":"e752f019bd8a3e6a05c9a1d8c60792f99bd55cc8","unresolved":false,"context_lines":[{"line_number":2,"context_line":"REST API Version History"},{"line_number":3,"context_line":"\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d\u003d"},{"line_number":4,"context_line":""},{"line_number":5,"context_line":"1.81 (Zed, ?)"},{"line_number":6,"context_line":"----------------------"},{"line_number":7,"context_line":""},{"line_number":8,"context_line":"Add endpoint to retrieve introspection data for nodes via the REST API."}],"source_content_type":"text/x-rst","patch_set":8,"id":"444ff9e5_9ecdf6db","line":5,"in_reply_to":"f957382c_02052475","updated":"2023-01-10 13:46:53.000000000","message":"Done","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"}],"ironic/api/controllers/v1/node.py":[{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"5af50cf0dd55c36cc1c365dcb1167dbe9ecc57a0","unresolved":true,"context_lines":[{"line_number":1949,"context_line":"    def _node_inventory_convert(node_inventory):"},{"line_number":1950,"context_line":"        inventory_data \u003d node_inventory[\u0027inventory_data\u0027]"},{"line_number":1951,"context_line":"        plugin_data \u003d node_inventory[\u0027plugin_data\u0027]"},{"line_number":1952,"context_line":"        return (inventory_data, plugin_data)"},{"line_number":1953,"context_line":""},{"line_number":1954,"context_line":"    @METRICS.timer(\u0027NodeStatesController.get\u0027)"},{"line_number":1955,"context_line":"    @method.expose()"}],"source_content_type":"text/x-python","patch_set":1,"id":"114154f0_33e6e0b7","line":1952,"updated":"2022-12-13 11:30:12.000000000","message":"You cannot return a tuple of the API, you need a dict (probably with keys \"inventory\" and \"plugin_data\")","commit_id":"2bdc02433ed17a8a5b39b48cc90d8722cfaa176a"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"5af50cf0dd55c36cc1c365dcb1167dbe9ecc57a0","unresolved":true,"context_lines":[{"line_number":1959,"context_line":""},{"line_number":1960,"context_line":"        :param node_ident: the UUID of a node."},{"line_number":1961,"context_line":"        \"\"\""},{"line_number":1962,"context_line":"        node_inventory \u003d objects.NodeInventory.get_by_node_id("},{"line_number":1963,"context_line":"            api.request.context, node_ident)"},{"line_number":1964,"context_line":""},{"line_number":1965,"context_line":"        return self._node_inventory_convert(node_inventory)"}],"source_content_type":"text/x-python","patch_set":1,"id":"dbf5149b_804b6e3a","line":1962,"updated":"2022-12-13 11:30:12.000000000","message":"You need to limit access to this endpoint to callers with the minimum API version. Add a new API version and add checks that it\u0027s provided. See other examples in this file (grep for VERSION).\n\nOn top of that, endpoint are protected by policies. You need to add a new policy and check it. Again, any endpoint here can be used as an example. Check with Julia what the default policy should be, if in doubt.","commit_id":"2bdc02433ed17a8a5b39b48cc90d8722cfaa176a"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"5af50cf0dd55c36cc1c365dcb1167dbe9ecc57a0","unresolved":true,"context_lines":[{"line_number":1960,"context_line":"        :param node_ident: the UUID of a node."},{"line_number":1961,"context_line":"        \"\"\""},{"line_number":1962,"context_line":"        node_inventory \u003d objects.NodeInventory.get_by_node_id("},{"line_number":1963,"context_line":"            api.request.context, node_ident)"},{"line_number":1964,"context_line":""},{"line_number":1965,"context_line":"        return self._node_inventory_convert(node_inventory)"},{"line_number":1966,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"a42adbaf_5675b7b5","line":1963,"updated":"2022-12-13 11:30:12.000000000","message":"node_ident is a UUID or name","commit_id":"2bdc02433ed17a8a5b39b48cc90d8722cfaa176a"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"5af50cf0dd55c36cc1c365dcb1167dbe9ecc57a0","unresolved":true,"context_lines":[{"line_number":1986,"context_line":""},{"line_number":1987,"context_line":"    maintenance \u003d NodeMaintenanceController()"},{"line_number":1988,"context_line":"    \"\"\"Expose maintenance as a sub-element of nodes\"\"\""},{"line_number":1989,"context_line":""},{"line_number":1990,"context_line":"    from_chassis \u003d False"},{"line_number":1991,"context_line":"    \"\"\"A flag to indicate if the requests to this controller are coming"},{"line_number":1992,"context_line":"    from the top-level resource Chassis\"\"\""}],"source_content_type":"text/x-python","patch_set":1,"id":"610a29e8_d8e4823e","line":1989,"updated":"2022-12-13 11:30:12.000000000","message":"Add an instance of the sub-controller here, similar to the others.","commit_id":"2bdc02433ed17a8a5b39b48cc90d8722cfaa176a"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"018b47643505634c4192f765badb7352e99ab304","unresolved":true,"context_lines":[{"line_number":1986,"context_line":""},{"line_number":1987,"context_line":"    maintenance \u003d NodeMaintenanceController()"},{"line_number":1988,"context_line":"    \"\"\"Expose maintenance as a sub-element of nodes\"\"\""},{"line_number":1989,"context_line":""},{"line_number":1990,"context_line":"    from_chassis \u003d False"},{"line_number":1991,"context_line":"    \"\"\"A flag to indicate if the requests to this controller are coming"},{"line_number":1992,"context_line":"    from the top-level resource Chassis\"\"\""}],"source_content_type":"text/x-python","patch_set":1,"id":"dd9a6e47_f22fe2b8","line":1989,"in_reply_to":"610a29e8_d8e4823e","updated":"2022-12-13 14:55:08.000000000","message":"++","commit_id":"2bdc02433ed17a8a5b39b48cc90d8722cfaa176a"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"443fdf0631cf8e11be8a4640da66346dde397cd3","unresolved":false,"context_lines":[{"line_number":1986,"context_line":""},{"line_number":1987,"context_line":"    maintenance \u003d NodeMaintenanceController()"},{"line_number":1988,"context_line":"    \"\"\"Expose maintenance as a sub-element of nodes\"\"\""},{"line_number":1989,"context_line":""},{"line_number":1990,"context_line":"    from_chassis \u003d False"},{"line_number":1991,"context_line":"    \"\"\"A flag to indicate if the requests to this controller are coming"},{"line_number":1992,"context_line":"    from the top-level resource Chassis\"\"\""}],"source_content_type":"text/x-python","patch_set":1,"id":"4cadd908_98d15a7a","line":1989,"in_reply_to":"dd9a6e47_f22fe2b8","updated":"2022-12-15 15:51:40.000000000","message":"Done","commit_id":"2bdc02433ed17a8a5b39b48cc90d8722cfaa176a"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"018b47643505634c4192f765badb7352e99ab304","unresolved":true,"context_lines":[{"line_number":1854,"context_line":"                     \u0027event\u0027, \u0027conductor\u0027, \u0027user\u0027]"},{"line_number":1855,"context_line":""},{"line_number":1856,"context_line":"    standard_fields \u003d [\u0027uuid\u0027, \u0027created_at\u0027, \u0027severity\u0027, \u0027event\u0027]"},{"line_number":1857,"context_line":""},{"line_number":1858,"context_line":"    def __init__(self, node_ident):"},{"line_number":1859,"context_line":"        super(NodeHistoryController).__init__()"},{"line_number":1860,"context_line":"        self.node_ident \u003d node_ident"},{"line_number":1861,"context_line":""},{"line_number":1862,"context_line":"    def _history_event_convert_with_links(self, node_uuid, event,"},{"line_number":1863,"context_line":"                                          detail\u003dFalse):"}],"source_content_type":"text/x-python","patch_set":2,"id":"b0728525_a08add56","line":1860,"range":{"start_line":1857,"start_character":0,"end_line":1860,"end_character":36},"updated":"2022-12-13 14:55:08.000000000","message":"so I think this is what your missing basically.","commit_id":"30bd20f739ee5228393e11053a5955af98e9b423"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"018b47643505634c4192f765badb7352e99ab304","unresolved":true,"context_lines":[{"line_number":1960,"context_line":"        :param node_ident: the UUID of a node."},{"line_number":1961,"context_line":"        \"\"\""},{"line_number":1962,"context_line":"        node \u003d api_utils.check_node_policy_and_retrieve("},{"line_number":1963,"context_line":"            \u0027baremetal:node:inventory:get\u0027, self.node_ident)"},{"line_number":1964,"context_line":"        if api.request.version.minor \u003e\u003d versions.MINOR_81_NODE_INVENTORY:"},{"line_number":1965,"context_line":"            node_inventory \u003d objects.NodeInventory.get_by_node_id("},{"line_number":1966,"context_line":"                api.request.context, node.id)"}],"source_content_type":"text/x-python","patch_set":2,"id":"6892fe19_3bc44140","line":1963,"range":{"start_line":1963,"start_character":44,"end_line":1963,"end_character":59},"updated":"2022-12-13 14:55:08.000000000","message":"so node_ident, as a variable being passed in on get is not attached to self.\n\nSelf is when your in a sub-controloler, but I think you end up with a very specific pattern and a decorator. I\u0027ll look for an example.","commit_id":"30bd20f739ee5228393e11053a5955af98e9b423"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"cb2facb17829c08708349ca87db54d21858844b6","unresolved":false,"context_lines":[{"line_number":1960,"context_line":"        :param node_ident: the UUID of a node."},{"line_number":1961,"context_line":"        \"\"\""},{"line_number":1962,"context_line":"        node \u003d api_utils.check_node_policy_and_retrieve("},{"line_number":1963,"context_line":"            \u0027baremetal:node:inventory:get\u0027, self.node_ident)"},{"line_number":1964,"context_line":"        if api.request.version.minor \u003e\u003d versions.MINOR_81_NODE_INVENTORY:"},{"line_number":1965,"context_line":"            node_inventory \u003d objects.NodeInventory.get_by_node_id("},{"line_number":1966,"context_line":"                api.request.context, node.id)"}],"source_content_type":"text/x-python","patch_set":2,"id":"2426ea67_35fded7f","line":1963,"range":{"start_line":1963,"start_character":44,"end_line":1963,"end_character":59},"in_reply_to":"6892fe19_3bc44140","updated":"2023-01-13 20:47:26.000000000","message":"Done","commit_id":"30bd20f739ee5228393e11053a5955af98e9b423"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"a3bf42d70367f3511236e94f8d2661a44f2d9c55","unresolved":true,"context_lines":[{"line_number":1963,"context_line":"            \u0027baremetal:node:inventory:get\u0027, node_ident)"},{"line_number":1964,"context_line":"        if api.request.version.minor \u003e\u003d versions.MINOR_81_NODE_INVENTORY:"},{"line_number":1965,"context_line":"            node_inventory \u003d objects.NodeInventory.get_by_node_id("},{"line_number":1966,"context_line":"                api.request.context, node.id)"},{"line_number":1967,"context_line":"            return self._node_inventory_convert(node_inventory)"},{"line_number":1968,"context_line":"        else:"},{"line_number":1969,"context_line":"            raise exception.NotFound("}],"source_content_type":"text/x-python","patch_set":8,"id":"71c606f6_2157771d","line":1966,"updated":"2022-12-15 15:36:34.000000000","message":"This code only supports the database backend, we need swift support too","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"},{"author":{"_account_id":35099,"name":"Jakub Jelinek","email":"jakub.jelinek@cern.ch","username":"kubajj"},"change_message_id":"e752f019bd8a3e6a05c9a1d8c60792f99bd55cc8","unresolved":false,"context_lines":[{"line_number":1963,"context_line":"            \u0027baremetal:node:inventory:get\u0027, node_ident)"},{"line_number":1964,"context_line":"        if api.request.version.minor \u003e\u003d versions.MINOR_81_NODE_INVENTORY:"},{"line_number":1965,"context_line":"            node_inventory \u003d objects.NodeInventory.get_by_node_id("},{"line_number":1966,"context_line":"                api.request.context, node.id)"},{"line_number":1967,"context_line":"            return self._node_inventory_convert(node_inventory)"},{"line_number":1968,"context_line":"        else:"},{"line_number":1969,"context_line":"            raise exception.NotFound("}],"source_content_type":"text/x-python","patch_set":8,"id":"42c7fac2_5472549a","line":1966,"in_reply_to":"71c606f6_2157771d","updated":"2023-01-10 13:46:53.000000000","message":"Ack","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"443fdf0631cf8e11be8a4640da66346dde397cd3","unresolved":true,"context_lines":[{"line_number":1966,"context_line":"                api.request.context, node.id)"},{"line_number":1967,"context_line":"            return self._node_inventory_convert(node_inventory)"},{"line_number":1968,"context_line":"        else:"},{"line_number":1969,"context_line":"            raise exception.NotFound("},{"line_number":1970,"context_line":"                (_(\"This endpoint is supported starting with the API version \""},{"line_number":1971,"context_line":"                   \"1.%(min_version)s\") %"},{"line_number":1972,"context_line":"                 {\u0027min_version\u0027: versions.MINOR_81_NODE_INVENTORY}))"},{"line_number":1973,"context_line":""},{"line_number":1974,"context_line":""},{"line_number":1975,"context_line":"class NodesController(rest.RestController):"}],"source_content_type":"text/x-python","patch_set":8,"id":"bbd3364c_6b2b3088","line":1972,"range":{"start_line":1969,"start_character":4,"end_line":1972,"end_character":68},"updated":"2022-12-15 15:51:40.000000000","message":"So... to reach here, one has valid credentials, but invalid API client version.\n\nor has explicitly requested an old behavior.\n\nThis should actually raise NotAcceptable. We also typically house those checks/errors in utils.py.\n\nAn in-flight example: https://review.opendev.org/c/openstack/ironic/+/866235/10/ironic/api/controllers/v1/utils.py#1076","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"},{"author":{"_account_id":35099,"name":"Jakub Jelinek","email":"jakub.jelinek@cern.ch","username":"kubajj"},"change_message_id":"e752f019bd8a3e6a05c9a1d8c60792f99bd55cc8","unresolved":false,"context_lines":[{"line_number":1966,"context_line":"                api.request.context, node.id)"},{"line_number":1967,"context_line":"            return self._node_inventory_convert(node_inventory)"},{"line_number":1968,"context_line":"        else:"},{"line_number":1969,"context_line":"            raise exception.NotFound("},{"line_number":1970,"context_line":"                (_(\"This endpoint is supported starting with the API version \""},{"line_number":1971,"context_line":"                   \"1.%(min_version)s\") %"},{"line_number":1972,"context_line":"                 {\u0027min_version\u0027: versions.MINOR_81_NODE_INVENTORY}))"},{"line_number":1973,"context_line":""},{"line_number":1974,"context_line":""},{"line_number":1975,"context_line":"class NodesController(rest.RestController):"}],"source_content_type":"text/x-python","patch_set":8,"id":"9f199d69_aeb205df","line":1972,"range":{"start_line":1969,"start_character":4,"end_line":1972,"end_character":68},"in_reply_to":"bbd3364c_6b2b3088","updated":"2023-01-10 13:46:53.000000000","message":"Ack","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"d11557c74093def01c18c8babfcef853aae00c8d","unresolved":true,"context_lines":[{"line_number":48,"context_line":"from ironic.conductor import steps as conductor_steps"},{"line_number":49,"context_line":"import ironic.conf"},{"line_number":50,"context_line":"from ironic.drivers import base as driver_base"},{"line_number":51,"context_line":"from ironic.drivers.modules import inspector as inspector"},{"line_number":52,"context_line":"from ironic import objects"},{"line_number":53,"context_line":""},{"line_number":54,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"3aa6499a_1dfb32fe","line":51,"updated":"2023-01-12 13:54:58.000000000","message":"We should get rid of this import in favour of inspect_utils as part of the future refactoring that we discussed on IRC.","commit_id":"16e78a47f325a4c11705b25829a3efa6c4f78b39"},{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"cb2facb17829c08708349ca87db54d21858844b6","unresolved":true,"context_lines":[{"line_number":48,"context_line":"from ironic.conductor import steps as conductor_steps"},{"line_number":49,"context_line":"import ironic.conf"},{"line_number":50,"context_line":"from ironic.drivers import base as driver_base"},{"line_number":51,"context_line":"from ironic.drivers.modules import inspector as inspector"},{"line_number":52,"context_line":"from ironic import objects"},{"line_number":53,"context_line":""},{"line_number":54,"context_line":""}],"source_content_type":"text/x-python","patch_set":11,"id":"e4d06f4c_2a185e99","line":51,"in_reply_to":"3aa6499a_1dfb32fe","updated":"2023-01-13 20:47:26.000000000","message":"+1, from a consistency standpoint, I\u0027d also prefer this.","commit_id":"16e78a47f325a4c11705b25829a3efa6c4f78b39"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"d11557c74093def01c18c8babfcef853aae00c8d","unresolved":true,"context_lines":[{"line_number":1963,"context_line":"        node \u003d api_utils.check_node_policy_and_retrieve("},{"line_number":1964,"context_line":"            \u0027baremetal:node:inventory:get\u0027, node_ident)"},{"line_number":1965,"context_line":"        if api.request.version.minor \u003e\u003d versions.MINOR_81_NODE_INVENTORY:"},{"line_number":1966,"context_line":"            store_data \u003d CONF.inspector.inventory_data_backend"},{"line_number":1967,"context_line":"            if store_data \u003d\u003d \u0027none\u0027:"},{"line_number":1968,"context_line":"                raise exception.NotFound("},{"line_number":1969,"context_line":"                    (_(\"Cannot obtain node inventory because it was not \""}],"source_content_type":"text/x-python","patch_set":11,"id":"22dfe9a1_6f6c34b5","line":1966,"updated":"2023-01-12 13:54:58.000000000","message":"We should move this logic to inspect_utils as well.","commit_id":"16e78a47f325a4c11705b25829a3efa6c4f78b39"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"d11557c74093def01c18c8babfcef853aae00c8d","unresolved":true,"context_lines":[{"line_number":1975,"context_line":"            if store_data \u003d\u003d \u0027swift\u0027:"},{"line_number":1976,"context_line":"                return inspector.get_introspection_data(node.uuid)"},{"line_number":1977,"context_line":"        else:"},{"line_number":1978,"context_line":"            raise exception.NotAcceptable("},{"line_number":1979,"context_line":"                (_(\"This endpoint is supported starting with the API version \""},{"line_number":1980,"context_line":"                   \"1.%(min_version)s\") %"},{"line_number":1981,"context_line":"                 {\u0027min_version\u0027: versions.MINOR_81_NODE_INVENTORY}))"}],"source_content_type":"text/x-python","patch_set":11,"id":"25a48c34_71962438","line":1978,"updated":"2023-01-12 13:54:58.000000000","message":"Should have mentioned it, my bad. We normally do what you\u0027re doing here with one exception: for new controllers we return HTTP 404 on old versions. See my next comment below. This check won\u0027t be needed if you do what I suggest there.","commit_id":"16e78a47f325a4c11705b25829a3efa6c4f78b39"},{"author":{"_account_id":35099,"name":"Jakub Jelinek","email":"jakub.jelinek@cern.ch","username":"kubajj"},"change_message_id":"b4fcb444ddc12b5a318dbb1b1bafc392bfa65081","unresolved":false,"context_lines":[{"line_number":1975,"context_line":"            if store_data \u003d\u003d \u0027swift\u0027:"},{"line_number":1976,"context_line":"                return inspector.get_introspection_data(node.uuid)"},{"line_number":1977,"context_line":"        else:"},{"line_number":1978,"context_line":"            raise exception.NotAcceptable("},{"line_number":1979,"context_line":"                (_(\"This endpoint is supported starting with the API version \""},{"line_number":1980,"context_line":"                   \"1.%(min_version)s\") %"},{"line_number":1981,"context_line":"                 {\u0027min_version\u0027: versions.MINOR_81_NODE_INVENTORY}))"}],"source_content_type":"text/x-python","patch_set":11,"id":"4a772234_4aae784e","line":1978,"in_reply_to":"25a48c34_71962438","updated":"2023-01-13 13:39:15.000000000","message":"Done","commit_id":"16e78a47f325a4c11705b25829a3efa6c4f78b39"},{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"d11557c74093def01c18c8babfcef853aae00c8d","unresolved":true,"context_lines":[{"line_number":2053,"context_line":"            or (remainder[0] \u003d\u003d \u0027allocation\u0027"},{"line_number":2054,"context_line":"                and not api_utils.allow_allocations())"},{"line_number":2055,"context_line":"            or (remainder[0] \u003d\u003d \u0027history\u0027"},{"line_number":2056,"context_line":"                and not api_utils.allow_node_history())):"},{"line_number":2057,"context_line":"            pecan.abort(http_client.NOT_FOUND)"},{"line_number":2058,"context_line":"        if remainder[0] \u003d\u003d \u0027traits\u0027 and not api_utils.allow_traits():"},{"line_number":2059,"context_line":"            # NOTE(mgoddard): Returning here will ensure we exhibit the"}],"source_content_type":"text/x-python","patch_set":11,"id":"62849e90_1420fea2","line":2056,"updated":"2023-01-12 13:54:58.000000000","message":"Add inventory here with the appropriate check","commit_id":"16e78a47f325a4c11705b25829a3efa6c4f78b39"},{"author":{"_account_id":35099,"name":"Jakub Jelinek","email":"jakub.jelinek@cern.ch","username":"kubajj"},"change_message_id":"b4fcb444ddc12b5a318dbb1b1bafc392bfa65081","unresolved":false,"context_lines":[{"line_number":2053,"context_line":"            or (remainder[0] \u003d\u003d \u0027allocation\u0027"},{"line_number":2054,"context_line":"                and not api_utils.allow_allocations())"},{"line_number":2055,"context_line":"            or (remainder[0] \u003d\u003d \u0027history\u0027"},{"line_number":2056,"context_line":"                and not api_utils.allow_node_history())):"},{"line_number":2057,"context_line":"            pecan.abort(http_client.NOT_FOUND)"},{"line_number":2058,"context_line":"        if remainder[0] \u003d\u003d \u0027traits\u0027 and not api_utils.allow_traits():"},{"line_number":2059,"context_line":"            # NOTE(mgoddard): Returning here will ensure we exhibit the"}],"source_content_type":"text/x-python","patch_set":11,"id":"886f12c0_765ce759","line":2056,"in_reply_to":"62849e90_1420fea2","updated":"2023-01-13 13:39:15.000000000","message":"Done","commit_id":"16e78a47f325a4c11705b25829a3efa6c4f78b39"}],"ironic/api/controllers/v1/utils.py":[{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"5af50cf0dd55c36cc1c365dcb1167dbe9ecc57a0","unresolved":true,"context_lines":[{"line_number":1341,"context_line":"    return api.request.version.minor \u003e\u003d versions.MINOR_78_NODE_HISTORY"},{"line_number":1342,"context_line":""},{"line_number":1343,"context_line":""},{"line_number":1344,"context_line":"def allow_node_inventory():"},{"line_number":1345,"context_line":"    \"\"\"Check if node inventory is allowed.\"\"\""},{"line_number":1346,"context_line":"    return api.request.version.minor \u003e\u003d versions.MINOR_81_NODE_INVENTORY"},{"line_number":1347,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"845d682c_69c159e6","line":1344,"updated":"2022-12-13 11:30:12.000000000","message":"Aha, you even have the API version, now use this call in your new endpoint.","commit_id":"2bdc02433ed17a8a5b39b48cc90d8722cfaa176a"}],"ironic/common/policy.py":[{"author":{"_account_id":11655,"name":"Julia Kreger","email":"juliaashleykreger@gmail.com","username":"jkreger","status":"Flying to the moon with a Jetpack!"},"change_message_id":"443fdf0631cf8e11be8a4640da66346dde397cd3","unresolved":true,"context_lines":[{"line_number":954,"context_line":"        # operating context."},{"line_number":955,"context_line":"        deprecated_rule\u003ddeprecated_node_get"},{"line_number":956,"context_line":"    ),"},{"line_number":957,"context_line":"    policy.DocumentedRuleDefault("},{"line_number":958,"context_line":"        name\u003d\u0027baremetal:node:inventory:get\u0027,"},{"line_number":959,"context_line":"        check_str\u003dSYSTEM_OR_OWNER_READER,"},{"line_number":960,"context_line":"        scope_types\u003d[\u0027system\u0027, \u0027project\u0027],"}],"source_content_type":"text/x-python","patch_set":8,"id":"85d6154c_815964ad","line":957,"updated":"2022-12-15 15:51:40.000000000","message":"You will need to put testing in to validate this:\n\nhttps://review.opendev.org/c/openstack/ironic/+/866235/10/ironic/tests/unit/api/test_rbac_system_scoped.yaml is an in-flight example of scoped checks. There is also a test_rbac_project_scoped.yaml which will need similar tests for owneres, but also that validates lesses don\u0027t gain access.","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"},{"author":{"_account_id":35099,"name":"Jakub Jelinek","email":"jakub.jelinek@cern.ch","username":"kubajj"},"change_message_id":"e1428495e62c3fa3adc2138cc245b10e8b169d3a","unresolved":false,"context_lines":[{"line_number":954,"context_line":"        # operating context."},{"line_number":955,"context_line":"        deprecated_rule\u003ddeprecated_node_get"},{"line_number":956,"context_line":"    ),"},{"line_number":957,"context_line":"    policy.DocumentedRuleDefault("},{"line_number":958,"context_line":"        name\u003d\u0027baremetal:node:inventory:get\u0027,"},{"line_number":959,"context_line":"        check_str\u003dSYSTEM_OR_OWNER_READER,"},{"line_number":960,"context_line":"        scope_types\u003d[\u0027system\u0027, \u0027project\u0027],"}],"source_content_type":"text/x-python","patch_set":8,"id":"ce5a32b3_4a9388bb","line":957,"in_reply_to":"85d6154c_815964ad","updated":"2023-01-10 16:02:18.000000000","message":"Done","commit_id":"b2fd95bf5aa7303ce3ea29f2d2aafd33123b1cc3"}],"ironic/drivers/modules/inspector.py":[{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"d11557c74093def01c18c8babfcef853aae00c8d","unresolved":true,"context_lines":[{"line_number":427,"context_line":"    return swift_object_name"},{"line_number":428,"context_line":""},{"line_number":429,"context_line":""},{"line_number":430,"context_line":"def get_introspection_data(node_uuid):"},{"line_number":431,"context_line":"    \"\"\"Uploads introspection data to Swift."},{"line_number":432,"context_line":""},{"line_number":433,"context_line":"    :param data: data to store in Swift"}],"source_content_type":"text/x-python","patch_set":11,"id":"4110a6f7_c4b8b61c","line":430,"updated":"2023-01-12 13:54:58.000000000","message":"To be moved to inspect_utils in the next patch.","commit_id":"16e78a47f325a4c11705b25829a3efa6c4f78b39"}],"ironic/tests/unit/api/controllers/v1/test_node.py":[{"author":{"_account_id":10239,"name":"Dmitry Tantsur","email":"dtantsur@protonmail.com","username":"dtantsur"},"change_message_id":"41ad82b98c9e3b93e3b92ac669133bd1f14ab6ad","unresolved":true,"context_lines":[{"line_number":7960,"context_line":"        self.assertEqual({\u0027inventory\u0027: self.fake_inventory_data,"},{"line_number":7961,"context_line":"                          \u0027plugin_data\u0027: self.fake_plugin_data}, ret)"},{"line_number":7962,"context_line":""},{"line_number":7963,"context_line":"    def test_get_inventory_swift(self):"},{"line_number":7964,"context_line":"        self._add_inventory_swift()"},{"line_number":7965,"context_line":"        CONF.set_override(\u0027inventory_data_backend\u0027, \u0027swift\u0027,"},{"line_number":7966,"context_line":"                          group\u003d\u0027inspector\u0027)"}],"source_content_type":"text/x-python","patch_set":9,"id":"1e536713_9164008a","line":7963,"updated":"2023-01-10 13:48:15.000000000","message":"You can mock inspector.get_introspection_data for this call and check that the mocked value is returned.","commit_id":"253f17798eaf41ddc1ae367d48f9dc9f18983333"},{"author":{"_account_id":35099,"name":"Jakub Jelinek","email":"jakub.jelinek@cern.ch","username":"kubajj"},"change_message_id":"dc78145dd028e95881c515e20a4f5d225e401c3f","unresolved":false,"context_lines":[{"line_number":7960,"context_line":"        self.assertEqual({\u0027inventory\u0027: self.fake_inventory_data,"},{"line_number":7961,"context_line":"                          \u0027plugin_data\u0027: self.fake_plugin_data}, ret)"},{"line_number":7962,"context_line":""},{"line_number":7963,"context_line":"    def test_get_inventory_swift(self):"},{"line_number":7964,"context_line":"        self._add_inventory_swift()"},{"line_number":7965,"context_line":"        CONF.set_override(\u0027inventory_data_backend\u0027, \u0027swift\u0027,"},{"line_number":7966,"context_line":"                          group\u003d\u0027inspector\u0027)"}],"source_content_type":"text/x-python","patch_set":9,"id":"dcb53869_c75e1951","line":7963,"in_reply_to":"1e536713_9164008a","updated":"2023-01-10 14:02:34.000000000","message":"Done","commit_id":"253f17798eaf41ddc1ae367d48f9dc9f18983333"}]}
