)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":20676,"name":"daniel.pawlik","display_name":"Daniel Pawlik","email":"dpawlik@redhat.com","username":"daniel.pawlik"},"change_message_id":"7677c810500fe3d62f48f13488d3a9d580c3aa18","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"12ca8afb_b4e3ce3d","updated":"2026-11-27 11:11:18.000000000","message":"recheck","commit_id":"bbd09471df2c73722bb69aa7d3c4b380543af3b7"},{"author":{"_account_id":34975,"name":"Jaromír Wysoglad","email":"jwysogla@redhat.com","username":"jwysogla"},"change_message_id":"847587083b8f32e890f40ac07bf3b43c062f41f3","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"67e2086f_2bcd1b71","updated":"2026-11-30 10:08:50.000000000","message":"the rest lgtm","commit_id":"bbd09471df2c73722bb69aa7d3c4b380543af3b7"},{"author":{"_account_id":9816,"name":"Takashi Kajinami","email":"kajinamit@oss.nttdata.com","username":"kajinamit"},"change_message_id":"d211b5c26fa6b7b1cfa94700fb69ee78f1b88f7b","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":4,"id":"8edd5c72_e02675aa","updated":"2026-12-01 13:49:01.000000000","message":"I\u0027ll put +W on hold just in case Jaromir has additional inputs.\n\nIMHO we should really consider introducing a format PromQL parser like promql-parser and replace these regex hack...","commit_id":"91b13bd2f1b9998965d2edebf75dab15957c6de0"},{"author":{"_account_id":34975,"name":"Jaromír Wysoglad","email":"jwysogla@redhat.com","username":"jwysogla"},"change_message_id":"3b076fcba70076dcecd80521c810bee0d4c64593","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":4,"id":"8d386276_78d2eb8c","updated":"2026-12-01 14:16:16.000000000","message":"This looks good to me. Thank you.","commit_id":"91b13bd2f1b9998965d2edebf75dab15957c6de0"},{"author":{"_account_id":32968,"name":"Juan Larriba","email":"jlarriba@redhat.com","username":"jlarriba"},"change_message_id":"dacc66a5ab45adc47504c332bbfbf67dd053c1b2","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":4,"id":"4370abb0_9d30f8cd","updated":"2026-12-01 11:36:53.000000000","message":"looks good to me","commit_id":"91b13bd2f1b9998965d2edebf75dab15957c6de0"},{"author":{"_account_id":34975,"name":"Jaromír Wysoglad","email":"jwysogla@redhat.com","username":"jwysogla"},"change_message_id":"3b076fcba70076dcecd80521c810bee0d4c64593","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":4,"id":"001b401e_1ad4ecd4","in_reply_to":"8edd5c72_e02675aa","updated":"2026-12-01 14:16:16.000000000","message":"I\u0027m all for getting rid of this code in favor of something else. This is probably one of the weakest pieces of code we have in telemetry currently, so if there is a good replacement, then let\u0027s go for it.\n\n I investigated py-promql-parser (and I was looking for other alternatives as well, but not successfully), that\u0027s just python bindings for a rust library, there are 3 things I don\u0027t really like about it:\n- The underlying library is in rust. If something doesn\u0027t work, I\u0027m not sure if anyone of us would be able to do anything about it. Do we have anyone who knows rust? I don\u0027t.\n- The rust project says it\u0027s compatible with prometheus 3.8 from 2025-11-28. We now have prometheus 3.16 released with the latest LTS version being 3.13. What if we need to support newer prometheus?\n- the py-promql-parser from PYPI just ships a precompiled binary, which seems to be based on https://github.com/GreptimeTeam/promql-parser . I don\u0027t know whether that\u0027s something we should rely on and what various downstreams would think about it. It seems a little strange to include binaries as part of python packages.\n\nWhat I\u0027m regularly checking is https://prometheus.io/docs/prometheus/latest/querying/api/#parsing-a-promql-expressions-into-a-abstract-syntax-tree-ast . But that\u0027s \"experimantal\" and \"It may also be removed\". If those messages ever disappear from the Prometheus docs, I\u0027ll have a change on gerrit to use that endpoint instead of these hacks within a few hours :D","commit_id":"91b13bd2f1b9998965d2edebf75dab15957c6de0"}],"observabilityclient/rbac.py":[{"author":{"_account_id":34975,"name":"Jaromír Wysoglad","email":"jwysogla@redhat.com","username":"jwysogla"},"change_message_id":"847587083b8f32e890f40ac07bf3b43c062f41f3","unresolved":true,"context_lines":[{"line_number":128,"context_line":"        # NOTE(dpawlik): Metric names and braces inside quoted label"},{"line_number":129,"context_line":"        # values aren\u0027t selectors. An unclosed value runs to the end"},{"line_number":130,"context_line":"        # of the query."},{"line_number":131,"context_line":"        masked \u003d re.sub(r\"\"\"\u0027(?:\\\\.|[^\u0027\\\\])*(?:\u0027|$)|\"(?:\\\\.|[^\"\\\\])*(?:\"|$)\"\"\","},{"line_number":132,"context_line":"                        _blank, query)"},{"line_number":133,"context_line":"        # NOTE(dpawlik): Every label section is a selector, with or"},{"line_number":134,"context_line":"        # without a metric name in front of it, e.g. {__name__\u003d~\"...\"}."}],"source_content_type":"text/x-python","patch_set":2,"id":"4db06b31_73346eaa","line":131,"updated":"2026-11-30 10:08:50.000000000","message":"regexes are often hard to read by humans. Could we add an explanation comment above? I see the note you added about WHY this line is there, but I think in this case also having a WHAT this line is doing kind of comment would be useful. So I guess we could add something like \"mask all quoted strings, including ones that aren\u0027t closed\" (TBH I\u0027m unsure if that\u0027s actually what the line does)","commit_id":"bbd09471df2c73722bb69aa7d3c4b380543af3b7"},{"author":{"_account_id":34975,"name":"Jaromír Wysoglad","email":"jwysogla@redhat.com","username":"jwysogla"},"change_message_id":"319955190ed615e74bcb4d7eb856295080cc2475","unresolved":false,"context_lines":[{"line_number":128,"context_line":"        # NOTE(dpawlik): Metric names and braces inside quoted label"},{"line_number":129,"context_line":"        # values aren\u0027t selectors. An unclosed value runs to the end"},{"line_number":130,"context_line":"        # of the query."},{"line_number":131,"context_line":"        masked \u003d re.sub(r\"\"\"\u0027(?:\\\\.|[^\u0027\\\\])*(?:\u0027|$)|\"(?:\\\\.|[^\"\\\\])*(?:\"|$)\"\"\","},{"line_number":132,"context_line":"                        _blank, query)"},{"line_number":133,"context_line":"        # NOTE(dpawlik): Every label section is a selector, with or"},{"line_number":134,"context_line":"        # without a metric name in front of it, e.g. {__name__\u003d~\"...\"}."}],"source_content_type":"text/x-python","patch_set":2,"id":"23c0c1cc_8be72511","line":131,"in_reply_to":"4db06b31_73346eaa","updated":"2026-11-30 10:56:22.000000000","message":"Done","commit_id":"bbd09471df2c73722bb69aa7d3c4b380543af3b7"},{"author":{"_account_id":32968,"name":"Juan Larriba","email":"jlarriba@redhat.com","username":"jlarriba"},"change_message_id":"270251f6be1f7e37e7ee443843a5fb60ffa6cb8f","unresolved":true,"context_lines":[{"line_number":135,"context_line":"        #                            isn\u0027t \u0027 or \\, up to \u0027 or end of query"},{"line_number":136,"context_line":"        #   \"(?:\\\\.|[^\"\\\\])*(?:\"|$)  the same for \""},{"line_number":137,"context_line":"        # e.g. foo{a\u003d\"x{y\", b\u003d\u0027it\\\u0027s\u0027} -\u003e foo{a\u003d     , b\u003d       }"},{"line_number":138,"context_line":"        masked \u003d re.sub(r\"\"\"\u0027(?:\\\\.|[^\u0027\\\\])*(?:\u0027|$)|\"(?:\\\\.|[^\"\\\\])*(?:\"|$)\"\"\","},{"line_number":139,"context_line":"                        _blank, query)"},{"line_number":140,"context_line":"        # NOTE(dpawlik): Every label section is a selector, with or"},{"line_number":141,"context_line":"        # without a metric name in front of it, e.g. {__name__\u003d~\"...\"}."}],"source_content_type":"text/x-python","patch_set":3,"id":"abbd5377_66590cd9","line":138,"updated":"2026-12-01 08:28:53.000000000","message":"There is an error in how this regex. It only knows about \u0027...\u0027 and \"...\" strings. It doesn\u0027t recognise PromQL # comments, which run to the end of the line, or backtick strings. In bar # it\u0027s\\nor foo # \u0027, the apostrophe in it\u0027s is treated as the start of a string. Everything up to the next \u0027 gets blanked, and that includes foo.","commit_id":"2ed092bde9f623a030f670941fd78ddbc951704c"},{"author":{"_account_id":20676,"name":"daniel.pawlik","display_name":"Daniel Pawlik","email":"dpawlik@redhat.com","username":"daniel.pawlik"},"change_message_id":"5723dff7f6bb89c55305fc69e925da5216e8b578","unresolved":false,"context_lines":[{"line_number":135,"context_line":"        #                            isn\u0027t \u0027 or \\, up to \u0027 or end of query"},{"line_number":136,"context_line":"        #   \"(?:\\\\.|[^\"\\\\])*(?:\"|$)  the same for \""},{"line_number":137,"context_line":"        # e.g. foo{a\u003d\"x{y\", b\u003d\u0027it\\\u0027s\u0027} -\u003e foo{a\u003d     , b\u003d       }"},{"line_number":138,"context_line":"        masked \u003d re.sub(r\"\"\"\u0027(?:\\\\.|[^\u0027\\\\])*(?:\u0027|$)|\"(?:\\\\.|[^\"\\\\])*(?:\"|$)\"\"\","},{"line_number":139,"context_line":"                        _blank, query)"},{"line_number":140,"context_line":"        # NOTE(dpawlik): Every label section is a selector, with or"},{"line_number":141,"context_line":"        # without a metric name in front of it, e.g. {__name__\u003d~\"...\"}."}],"source_content_type":"text/x-python","patch_set":3,"id":"ce255bea_82317349","line":138,"in_reply_to":"789f36ab_20b37d7c","updated":"2026-12-01 11:10:57.000000000","message":"\u003e nice catch\nI was also considering to use - https://github.com/messense/py-promql-parser  but the patch would not be simply","commit_id":"2ed092bde9f623a030f670941fd78ddbc951704c"},{"author":{"_account_id":34975,"name":"Jaromír Wysoglad","email":"jwysogla@redhat.com","username":"jwysogla"},"change_message_id":"c0bc5308643d0b58267751c529cab301683c5a63","unresolved":false,"context_lines":[{"line_number":135,"context_line":"        #                            isn\u0027t \u0027 or \\, up to \u0027 or end of query"},{"line_number":136,"context_line":"        #   \"(?:\\\\.|[^\"\\\\])*(?:\"|$)  the same for \""},{"line_number":137,"context_line":"        # e.g. foo{a\u003d\"x{y\", b\u003d\u0027it\\\u0027s\u0027} -\u003e foo{a\u003d     , b\u003d       }"},{"line_number":138,"context_line":"        masked \u003d re.sub(r\"\"\"\u0027(?:\\\\.|[^\u0027\\\\])*(?:\u0027|$)|\"(?:\\\\.|[^\"\\\\])*(?:\"|$)\"\"\","},{"line_number":139,"context_line":"                        _blank, query)"},{"line_number":140,"context_line":"        # NOTE(dpawlik): Every label section is a selector, with or"},{"line_number":141,"context_line":"        # without a metric name in front of it, e.g. {__name__\u003d~\"...\"}."}],"source_content_type":"text/x-python","patch_set":3,"id":"7e5e1364_a8be98bc","line":138,"in_reply_to":"949afdba_ebb39b5d","updated":"2026-12-01 14:18:08.000000000","message":"Let\u0027s stay with this rather than the alternative. I\u0027m not against regexes. Regexes are good and they handle a lot of thing for not much effort from us. The bad thing about regexes is, that once merged, they aren\u0027t really readable by humans again, which is why I wanted you to explain what it\u0027s supposed to be doing in a comment. Now that we have it, this is good.","commit_id":"2ed092bde9f623a030f670941fd78ddbc951704c"},{"author":{"_account_id":20676,"name":"daniel.pawlik","display_name":"Daniel Pawlik","email":"dpawlik@redhat.com","username":"daniel.pawlik"},"change_message_id":"10840f15ae26a8125a70dbeaee322acdc7aeaf90","unresolved":true,"context_lines":[{"line_number":135,"context_line":"        #                            isn\u0027t \u0027 or \\, up to \u0027 or end of query"},{"line_number":136,"context_line":"        #   \"(?:\\\\.|[^\"\\\\])*(?:\"|$)  the same for \""},{"line_number":137,"context_line":"        # e.g. foo{a\u003d\"x{y\", b\u003d\u0027it\\\u0027s\u0027} -\u003e foo{a\u003d     , b\u003d       }"},{"line_number":138,"context_line":"        masked \u003d re.sub(r\"\"\"\u0027(?:\\\\.|[^\u0027\\\\])*(?:\u0027|$)|\"(?:\\\\.|[^\"\\\\])*(?:\"|$)\"\"\","},{"line_number":139,"context_line":"                        _blank, query)"},{"line_number":140,"context_line":"        # NOTE(dpawlik): Every label section is a selector, with or"},{"line_number":141,"context_line":"        # without a metric name in front of it, e.g. {__name__\u003d~\"...\"}."}],"source_content_type":"text/x-python","patch_set":3,"id":"789f36ab_20b37d7c","line":138,"in_reply_to":"abbd5377_66590cd9","updated":"2026-12-01 09:36:15.000000000","message":"nice catch","commit_id":"2ed092bde9f623a030f670941fd78ddbc951704c"},{"author":{"_account_id":20676,"name":"daniel.pawlik","display_name":"Daniel Pawlik","email":"dpawlik@redhat.com","username":"daniel.pawlik"},"change_message_id":"f57581076b40ae8c65c08a216a59075db1cae8c3","unresolved":false,"context_lines":[{"line_number":135,"context_line":"        #                            isn\u0027t \u0027 or \\, up to \u0027 or end of query"},{"line_number":136,"context_line":"        #   \"(?:\\\\.|[^\"\\\\])*(?:\"|$)  the same for \""},{"line_number":137,"context_line":"        # e.g. foo{a\u003d\"x{y\", b\u003d\u0027it\\\u0027s\u0027} -\u003e foo{a\u003d     , b\u003d       }"},{"line_number":138,"context_line":"        masked \u003d re.sub(r\"\"\"\u0027(?:\\\\.|[^\u0027\\\\])*(?:\u0027|$)|\"(?:\\\\.|[^\"\\\\])*(?:\"|$)\"\"\","},{"line_number":139,"context_line":"                        _blank, query)"},{"line_number":140,"context_line":"        # NOTE(dpawlik): Every label section is a selector, with or"},{"line_number":141,"context_line":"        # without a metric name in front of it, e.g. {__name__\u003d~\"...\"}."}],"source_content_type":"text/x-python","patch_set":3,"id":"949afdba_ebb39b5d","line":138,"in_reply_to":"ce255bea_82317349","updated":"2026-12-01 12:23:01.000000000","message":"Alternative way: https://review.opendev.org/c/openstack/python-observabilityclient/+/1018206","commit_id":"2ed092bde9f623a030f670941fd78ddbc951704c"}]}
