)]}'
{"/PATCHSET_LEVEL":[{"author":{"_account_id":13861,"name":"yatin","email":"ykarel@redhat.com","username":"yatinkarel"},"change_message_id":"7a892c31eeb84dfc74ba11caebf5adcbc45242da","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"c9cfe6cf_7a6f9751","updated":"2022-06-01 07:42:33.000000000","message":"LGTM","commit_id":"c2786554ad99c6017dd46802b532b5eb5bd4a009"}],"neutron/objects/db/api.py":[{"author":{"_account_id":1131,"name":"Brian Haley","email":"haleyb.dev@gmail.com","username":"brian-haley"},"change_message_id":"302518dc9ba4545a82ca284a939ce5f5d6ad6a16","unresolved":true,"context_lines":[{"line_number":117,"context_line":"    with obj_cls.db_context_writer(context):"},{"line_number":118,"context_line":"        if not values:"},{"line_number":119,"context_line":"            return count(obj_cls, context, **kwargs)"},{"line_number":120,"context_line":"        q \u003d _get_filter_query(obj_cls, context, **kwargs)"},{"line_number":121,"context_line":"        return q.update(values, synchronize_session\u003dFalse)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"037a0708_2441e74c","line":120,"updated":"2022-05-31 18:00:03.000000000","message":"What about this one, should the method have the writer decorator?","commit_id":"c2786554ad99c6017dd46802b532b5eb5bd4a009"},{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"6686b39e8d8e61d1cd71a74a32cd3d4eb4b2dd67","unresolved":true,"context_lines":[{"line_number":117,"context_line":"    with obj_cls.db_context_writer(context):"},{"line_number":118,"context_line":"        if not values:"},{"line_number":119,"context_line":"            return count(obj_cls, context, **kwargs)"},{"line_number":120,"context_line":"        q \u003d _get_filter_query(obj_cls, context, **kwargs)"},{"line_number":121,"context_line":"        return q.update(values, synchronize_session\u003dFalse)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"658cf947_f102c164","line":120,"in_reply_to":"037a0708_2441e74c","updated":"2022-06-01 07:05:04.000000000","message":"This method call, same as in other places in this module, is done inside a DB context. In this case created in L117.\n\nI\u0027ve refactored some of those private methods in other modules and I try to add the decorator just in the public method, to avoid nesting them.","commit_id":"c2786554ad99c6017dd46802b532b5eb5bd4a009"},{"author":{"_account_id":8313,"name":"Lajos Katona","display_name":"lajoskatona","email":"katonalala@gmail.com","username":"elajkat","status":"Ericsson Software Technology"},"change_message_id":"1121ad43895a5aca0e1d87aa8b875b64b571b99c","unresolved":true,"context_lines":[{"line_number":117,"context_line":"    with obj_cls.db_context_writer(context):"},{"line_number":118,"context_line":"        if not values:"},{"line_number":119,"context_line":"            return count(obj_cls, context, **kwargs)"},{"line_number":120,"context_line":"        q \u003d _get_filter_query(obj_cls, context, **kwargs)"},{"line_number":121,"context_line":"        return q.update(values, synchronize_session\u003dFalse)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"f727a939_9ba3fc26","line":120,"in_reply_to":"658cf947_f102c164","updated":"2022-06-01 10:51:54.000000000","message":"I just thought about it, shall we write a few lines of contributor guideline how to use these decorators, how we use them now, etc ?\nI thought of things like:\n* order of these decorators\n* to which method decorate in the call chain\n* even trivial things like when to use READER/WRITER contexts\n* mix with retry decorators\n* I don\u0027t know....","commit_id":"c2786554ad99c6017dd46802b532b5eb5bd4a009"},{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"06257045d7499c61a9113683574400b60067483b","unresolved":true,"context_lines":[{"line_number":117,"context_line":"    with obj_cls.db_context_writer(context):"},{"line_number":118,"context_line":"        if not values:"},{"line_number":119,"context_line":"            return count(obj_cls, context, **kwargs)"},{"line_number":120,"context_line":"        q \u003d _get_filter_query(obj_cls, context, **kwargs)"},{"line_number":121,"context_line":"        return q.update(values, synchronize_session\u003dFalse)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"3971aca0_462156a1","line":120,"in_reply_to":"d6740b96_b35ff507","updated":"2022-06-01 14:43:44.000000000","message":"Ah no, the DB contexts are both context managers and decorators. There is no difference between both. It is usually cleaner to use the decorator but in this case I see no need to change the existing code.","commit_id":"c2786554ad99c6017dd46802b532b5eb5bd4a009"},{"author":{"_account_id":16688,"name":"Rodolfo Alonso","email":"ralonsoh@redhat.com","username":"rodolfo-alonso-hernandez"},"change_message_id":"285f4c1b82d99430db02cd75ff6fb6c246311d30","unresolved":true,"context_lines":[{"line_number":117,"context_line":"    with obj_cls.db_context_writer(context):"},{"line_number":118,"context_line":"        if not values:"},{"line_number":119,"context_line":"            return count(obj_cls, context, **kwargs)"},{"line_number":120,"context_line":"        q \u003d _get_filter_query(obj_cls, context, **kwargs)"},{"line_number":121,"context_line":"        return q.update(values, synchronize_session\u003dFalse)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"f9817184_63ec70e1","line":120,"in_reply_to":"f727a939_9ba3fc26","updated":"2022-06-01 11:41:14.000000000","message":"Give me some time and I\u0027ll push a patch. For sure we need something in the contributors guide to provide some tips about how to access to the DB.","commit_id":"c2786554ad99c6017dd46802b532b5eb5bd4a009"},{"author":{"_account_id":1131,"name":"Brian Haley","email":"haleyb.dev@gmail.com","username":"brian-haley"},"change_message_id":"8008c1134758963f8a236cedc28d36c115bca3d7","unresolved":true,"context_lines":[{"line_number":117,"context_line":"    with obj_cls.db_context_writer(context):"},{"line_number":118,"context_line":"        if not values:"},{"line_number":119,"context_line":"            return count(obj_cls, context, **kwargs)"},{"line_number":120,"context_line":"        q \u003d _get_filter_query(obj_cls, context, **kwargs)"},{"line_number":121,"context_line":"        return q.update(values, synchronize_session\u003dFalse)"},{"line_number":122,"context_line":""},{"line_number":123,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"d6740b96_b35ff507","line":120,"in_reply_to":"f9817184_63ec70e1","updated":"2022-06-01 13:54:32.000000000","message":"Rodolfo - ack, the code looked correct as-is with L117, I just thought using the decorator was the future, so I\u0027ll look forward to your doc patch :)","commit_id":"c2786554ad99c6017dd46802b532b5eb5bd4a009"}]}
