)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":37843,"name":"Olamide Ojo","display_name":"olamidepeterojo","email":"peterojoolamide@gmail.com","username":"olamidepeterojo"},"change_message_id":"8ae2777a3b8020800c9f5a2fc4401ab0846fb029","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":5,"id":"16bb7918_d0a326e5","updated":"2026-11-05 16:50:53.000000000","message":"The changes I intend to make go beyond preserving the existing metadata key rules.I still have to account for metadata values as well so I\u0027m currently working on another patch and would take this up as the next patch needing enhancing","commit_id":"b661948d1fa39ca2882820e5339c16d8cb0395ff"}],"manila/api/schemas/shares.py":[{"author":{"_account_id":37860,"name":"Adeola Adesina","email":"adeolaadesina46@gmail.com","username":"AdeolaAdesina"},"change_message_id":"93cb960ddb7fdb19022fc32ce5c0b719025f1d43","unresolved":true,"context_lines":[{"line_number":266,"context_line":"update_metadata_item_request_body \u003d {"},{"line_number":267,"context_line":"    \u0027type\u0027: \u0027object\u0027,"},{"line_number":268,"context_line":"    \u0027properties\u0027: {"},{"line_number":269,"context_line":"        \u0027metadata\u0027: parameter_types.metadata,"},{"line_number":270,"context_line":"    },"},{"line_number":271,"context_line":"    \u0027required\u0027: [\u0027metadata\u0027],"},{"line_number":272,"context_line":"    \u0027additionalProperties\u0027: False,"}],"source_content_type":"text/x-python","patch_set":2,"id":"6ec8324f_0ec5d256","line":269,"range":{"start_line":269,"start_character":20,"end_line":269,"end_character":35},"updated":"2026-10-19 11:31:09.000000000","message":"The parameter_types.metadata allows null metadata, that is metadata\u003dnull. But metadata\u003dnull is not supported in the legacy validation function, is_valid_body","commit_id":"17a9dc3b14d67c2e4332e9a95b885e0b5eee6e15"},{"author":{"_account_id":37843,"name":"Olamide Ojo","display_name":"olamidepeterojo","email":"peterojoolamide@gmail.com","username":"olamidepeterojo"},"change_message_id":"33463db215a9c2301c28aab51a870e661de421b0","unresolved":false,"context_lines":[{"line_number":266,"context_line":"update_metadata_item_request_body \u003d {"},{"line_number":267,"context_line":"    \u0027type\u0027: \u0027object\u0027,"},{"line_number":268,"context_line":"    \u0027properties\u0027: {"},{"line_number":269,"context_line":"        \u0027metadata\u0027: parameter_types.metadata,"},{"line_number":270,"context_line":"    },"},{"line_number":271,"context_line":"    \u0027required\u0027: [\u0027metadata\u0027],"},{"line_number":272,"context_line":"    \u0027additionalProperties\u0027: False,"}],"source_content_type":"text/x-python","patch_set":2,"id":"86fa572b_6561e8d9","line":269,"range":{"start_line":269,"start_character":20,"end_line":269,"end_character":35},"in_reply_to":"6ec8324f_0ec5d256","updated":"2026-10-20 17:38:02.000000000","message":"Acknowledged","commit_id":"17a9dc3b14d67c2e4332e9a95b885e0b5eee6e15"},{"author":{"_account_id":39572,"name":"Gracious Obeagu","display_name":"Greegman","email":"obeagug@gmail.com","username":"Greegman"},"change_message_id":"41e598dd9bec7cf667921f3351546e63fb92dca3","unresolved":false,"context_lines":[{"line_number":269,"context_line":"        \u0027metadata\u0027: {"},{"line_number":270,"context_line":"            \u0027type\u0027: \u0027object\u0027,"},{"line_number":271,"context_line":"            \u0027patternProperties\u0027: {"},{"line_number":272,"context_line":"                \u0027^[a-zA-Z0-9-_:. ]{1,255}$\u0027: {"},{"line_number":273,"context_line":"                    \u0027type\u0027: \u0027string\u0027"},{"line_number":274,"context_line":"                }"},{"line_number":275,"context_line":"            },"}],"source_content_type":"text/x-python","patch_set":5,"id":"e8865e7b_4303ce72","line":272,"updated":"2026-11-05 15:47:17.000000000","message":"Hi Olamide, could we preserve the existing metadata key rules here?\n\nI compared `common.check_metadata_properties({\u0027owner@example\u0027: \u0027alice\u0027})` with this patch set’s request schema. The helper accepts the key, but the schema rejects it because `@` does not match this pattern. `_validate_metadata_for_update()` also has no character whitelist.\n\nSince this schema applies from API 2.0, could this introduce a compatibility change? Could we avoid adding a character restriction and add a regression test for a key containing `@`?\n\nThis comparison was at the helper/schema level; I haven’t tested a full HTTP request.","commit_id":"b661948d1fa39ca2882820e5339c16d8cb0395ff"},{"author":{"_account_id":37843,"name":"Olamide Ojo","display_name":"olamidepeterojo","email":"peterojoolamide@gmail.com","username":"olamidepeterojo"},"change_message_id":"8ae2777a3b8020800c9f5a2fc4401ab0846fb029","unresolved":false,"context_lines":[{"line_number":269,"context_line":"        \u0027metadata\u0027: {"},{"line_number":270,"context_line":"            \u0027type\u0027: \u0027object\u0027,"},{"line_number":271,"context_line":"            \u0027patternProperties\u0027: {"},{"line_number":272,"context_line":"                \u0027^[a-zA-Z0-9-_:. ]{1,255}$\u0027: {"},{"line_number":273,"context_line":"                    \u0027type\u0027: \u0027string\u0027"},{"line_number":274,"context_line":"                }"},{"line_number":275,"context_line":"            },"}],"source_content_type":"text/x-python","patch_set":5,"id":"c29c0b78_d7257ccd","line":272,"in_reply_to":"90f37b47_12b8d02b","updated":"2026-11-05 16:50:53.000000000","message":"Done","commit_id":"b661948d1fa39ca2882820e5339c16d8cb0395ff"},{"author":{"_account_id":37843,"name":"Olamide Ojo","display_name":"olamidepeterojo","email":"peterojoolamide@gmail.com","username":"olamidepeterojo"},"change_message_id":"8cd52d82882ecd7328e40ff8f06bd5d5ece808a1","unresolved":true,"context_lines":[{"line_number":269,"context_line":"        \u0027metadata\u0027: {"},{"line_number":270,"context_line":"            \u0027type\u0027: \u0027object\u0027,"},{"line_number":271,"context_line":"            \u0027patternProperties\u0027: {"},{"line_number":272,"context_line":"                \u0027^[a-zA-Z0-9-_:. ]{1,255}$\u0027: {"},{"line_number":273,"context_line":"                    \u0027type\u0027: \u0027string\u0027"},{"line_number":274,"context_line":"                }"},{"line_number":275,"context_line":"            },"}],"source_content_type":"text/x-python","patch_set":5,"id":"90f37b47_12b8d02b","line":272,"in_reply_to":"df6a576e_34f30b19","updated":"2026-11-05 16:36:08.000000000","message":"Hey, Greegman, I really appreciate you pointing this out to me. It\u0027s quite a coincidence cause I earlier inspected the common.check_metadata_properties and found the discrepancy in my schema that you pointed out. So my intentions are in line with your suggestion, which is to preserve the existing metadata key rules because this helper is going to be removed once we ensure other endpoints are not dependent on it. So I\u0027m going to make sure my schema accepts what the legacy helper accepts. So to answer your questions, I don\u0027t think it would introduce a compatibility change, the final patch won\u0027t include character restrictions, and to increase test coverage, a regression test can definitely and would be added.\n\nThank you once again for this review","commit_id":"b661948d1fa39ca2882820e5339c16d8cb0395ff"},{"author":{"_account_id":39572,"name":"Gracious Obeagu","display_name":"Greegman","email":"obeagug@gmail.com","username":"Greegman"},"change_message_id":"05231d27228e7a0a6200cdbcdc4e3024105d9949","unresolved":true,"context_lines":[{"line_number":269,"context_line":"        \u0027metadata\u0027: {"},{"line_number":270,"context_line":"            \u0027type\u0027: \u0027object\u0027,"},{"line_number":271,"context_line":"            \u0027patternProperties\u0027: {"},{"line_number":272,"context_line":"                \u0027^[a-zA-Z0-9-_:. ]{1,255}$\u0027: {"},{"line_number":273,"context_line":"                    \u0027type\u0027: \u0027string\u0027"},{"line_number":274,"context_line":"                }"},{"line_number":275,"context_line":"            },"}],"source_content_type":"text/x-python","patch_set":5,"id":"df6a576e_34f30b19","line":272,"in_reply_to":"e8865e7b_4303ce72","updated":"2026-11-05 15:58:04.000000000","message":"Marked as unresolved.","commit_id":"b661948d1fa39ca2882820e5339c16d8cb0395ff"}],"manila/api/v2/metadata.py":[{"author":{"_account_id":39572,"name":"Gracious Obeagu","display_name":"Greegman","email":"obeagug@gmail.com","username":"Greegman"},"change_message_id":"4cd8e18d27a2a0e82bf7fc06ba97d253b57b572e","unresolved":true,"context_lines":[{"line_number":178,"context_line":"        \"\"\"Updates the specified metadata item.\"\"\""},{"line_number":179,"context_line":""},{"line_number":180,"context_line":"        context \u003d req.environ[\u0027manila.context\u0027]"},{"line_number":181,"context_line":"        meta_item \u003d body[\u0027metadata\u0027]"},{"line_number":182,"context_line":""},{"line_number":183,"context_line":"        if key not in meta_item:"},{"line_number":184,"context_line":"            expl \u003d _(\u0027Request body and URI mismatch\u0027)"}],"source_content_type":"text/x-python","patch_set":6,"id":"94c7c558_7eed2fce","line":181,"range":{"start_line":181,"start_character":0,"end_line":181,"end_character":2},"updated":"2026-11-07 04:24:12.000000000","message":"Could we retain the validation in this shared helper for now? The snapshot and replica update_metadata_item() methods still call it without request-body schema decorators.\n\nI compared the parent and patch set 6 by calling this helper with body\u003d{} and a request containing manila.context. The parent raises HTTPBadRequest(\"Malformed request body\"), but patch set 6 raises KeyError(\u0027metadata\u0027).\n\nCould we keep these checks until all callers have equivalent schema validation? This reproduction is at the helper level; I haven’t tested a full HTTP request.","commit_id":"bf217f431191ff270baa271851b23369448dfdaa"},{"author":{"_account_id":37843,"name":"Olamide Ojo","display_name":"olamidepeterojo","email":"peterojoolamide@gmail.com","username":"olamidepeterojo"},"change_message_id":"6beb25069ea7f5626f4f4defe45b70778e18c977","unresolved":false,"context_lines":[{"line_number":178,"context_line":"        \"\"\"Updates the specified metadata item.\"\"\""},{"line_number":179,"context_line":""},{"line_number":180,"context_line":"        context \u003d req.environ[\u0027manila.context\u0027]"},{"line_number":181,"context_line":"        meta_item \u003d body[\u0027metadata\u0027]"},{"line_number":182,"context_line":""},{"line_number":183,"context_line":"        if key not in meta_item:"},{"line_number":184,"context_line":"            expl \u003d _(\u0027Request body and URI mismatch\u0027)"}],"source_content_type":"text/x-python","patch_set":6,"id":"6e462cef_2172245c","line":181,"range":{"start_line":181,"start_character":0,"end_line":181,"end_character":2},"in_reply_to":"94c7c558_7eed2fce","updated":"2026-11-07 09:48:30.000000000","message":"oops! It skipped my mind to check if other endpoints were dependent on it. My bad, I\u0027ll revert it","commit_id":"bf217f431191ff270baa271851b23369448dfdaa"}],"manila/api/v2/shares.py":[{"author":{"_account_id":37860,"name":"Adeola Adesina","email":"adeolaadesina46@gmail.com","username":"AdeolaAdesina"},"change_message_id":"93cb960ddb7fdb19022fc32ce5c0b719025f1d43","unresolved":true,"context_lines":[{"line_number":1704,"context_line":"    @wsgi.Controller.api_version(\"2.0\")"},{"line_number":1705,"context_line":"    @wsgi.Controller.authorize(\"update_share_metadata\")"},{"line_number":1706,"context_line":"    def update_metadata_item(self, req, resource_id, body, key):"},{"line_number":1707,"context_line":"        if not self.is_valid_body(body, \u0027meta\u0027):"},{"line_number":1708,"context_line":"            expl \u003d _(\u0027Malformed request body\u0027)"},{"line_number":1709,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dexpl)"},{"line_number":1710,"context_line":"        _metadata \u003d self._validate_metadata_for_update(req, resource_id,"}],"source_content_type":"text/x-python","patch_set":2,"id":"3779348c_6dc78634","side":"PARENT","line":1707,"range":{"start_line":1707,"start_character":20,"end_line":1707,"end_character":33},"updated":"2026-10-19 11:31:09.000000000","message":"is_valid_body is a lagacy validation function that need to be replaced by jsonschema validation. \nI will advise you ensure the json-schema you created performs all the checks in is_valid_body function.","commit_id":"c1bdce74db3b496857f7db2838184c7fa417c403"},{"author":{"_account_id":37843,"name":"Olamide Ojo","display_name":"olamidepeterojo","email":"peterojoolamide@gmail.com","username":"olamidepeterojo"},"change_message_id":"33463db215a9c2301c28aab51a870e661de421b0","unresolved":false,"context_lines":[{"line_number":1704,"context_line":"    @wsgi.Controller.api_version(\"2.0\")"},{"line_number":1705,"context_line":"    @wsgi.Controller.authorize(\"update_share_metadata\")"},{"line_number":1706,"context_line":"    def update_metadata_item(self, req, resource_id, body, key):"},{"line_number":1707,"context_line":"        if not self.is_valid_body(body, \u0027meta\u0027):"},{"line_number":1708,"context_line":"            expl \u003d _(\u0027Malformed request body\u0027)"},{"line_number":1709,"context_line":"            raise exc.HTTPBadRequest(explanation\u003dexpl)"},{"line_number":1710,"context_line":"        _metadata \u003d self._validate_metadata_for_update(req, resource_id,"}],"source_content_type":"text/x-python","patch_set":2,"id":"c806163b_8a8561ff","side":"PARENT","line":1707,"range":{"start_line":1707,"start_character":20,"end_line":1707,"end_character":33},"in_reply_to":"3779348c_6dc78634","updated":"2026-10-20 17:38:02.000000000","message":"Acknowledged","commit_id":"c1bdce74db3b496857f7db2838184c7fa417c403"}],"manila/tests/api/v2/test_shares.py":[{"author":{"_account_id":37860,"name":"Adeola Adesina","email":"adeolaadesina46@gmail.com","username":"AdeolaAdesina"},"change_message_id":"22778a6723c0bb2fb9646ce1c3b7777d3e76db08","unresolved":true,"context_lines":[{"line_number":2692,"context_line":"            self.controller, \u0027_validate_metadata_for_update\u0027,"},{"line_number":2693,"context_line":"            mock.Mock(return_value\u003dbody[\u0027metadata\u0027]))"},{"line_number":2694,"context_line":"        mock_update \u003d self.mock_object("},{"line_number":2695,"context_line":"            self.controller, \u0027_update_metadata_item\u0027,"},{"line_number":2696,"context_line":"            mock.Mock(return_value\u003dbody))"},{"line_number":2697,"context_line":"        self.mock_object(share_api.API, \u0027update_share_from_metadata\u0027)"},{"line_number":2698,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"326e0211_f23111d5","line":2695,"range":{"start_line":2695,"start_character":30,"end_line":2695,"end_character":51},"updated":"2026-11-02 07:50:55.000000000","message":"Hello Olamide, well done! I can see that your tests cover both valid and invalid scenarios.\n\nJust a suggestion to make the tests more robust. I would recommend testing the actual response returned by \u0027_update_metadata_item()\u0027 rather than mocking the method to return a predefined body.\n\nWhile testing, I noticed that the mocked method always returns the specified value when called, even in scenarios where the actual helper would raise an error.\n\nAllowing the helper to execute and mocking only its dependencies would help verify that the controller returns the expected response and that the response matches the defined schema.","commit_id":"76b86165cd32488bbfa7f49eee995d6a35bda66f"},{"author":{"_account_id":37843,"name":"Olamide Ojo","display_name":"olamidepeterojo","email":"peterojoolamide@gmail.com","username":"olamidepeterojo"},"change_message_id":"2ae06fb2b7f01c79aecf78b4a2129e51bc4eaab2","unresolved":false,"context_lines":[{"line_number":2692,"context_line":"            self.controller, \u0027_validate_metadata_for_update\u0027,"},{"line_number":2693,"context_line":"            mock.Mock(return_value\u003dbody[\u0027metadata\u0027]))"},{"line_number":2694,"context_line":"        mock_update \u003d self.mock_object("},{"line_number":2695,"context_line":"            self.controller, \u0027_update_metadata_item\u0027,"},{"line_number":2696,"context_line":"            mock.Mock(return_value\u003dbody))"},{"line_number":2697,"context_line":"        self.mock_object(share_api.API, \u0027update_share_from_metadata\u0027)"},{"line_number":2698,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"b03cb6bf_377adf60","line":2695,"range":{"start_line":2695,"start_character":30,"end_line":2695,"end_character":51},"in_reply_to":"326e0211_f23111d5","updated":"2026-11-02 11:36:09.000000000","message":"Thank you, Adeola. This is much appreciated. Instead of mocking the helper, I let it generate the response so the tests validate the actual response schema.","commit_id":"76b86165cd32488bbfa7f49eee995d6a35bda66f"}]}
