)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"af3e8266246091eba1b53a2d133f41396529e256","unresolved":true,"context_lines":[{"line_number":5,"context_line":"CommitDate: 2023-05-18 15:14:09 -0700"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Refactor for extract closure to method"},{"line_number":8,"context_line":"Replace for py3 nonlocal variables"},{"line_number":9,"context_line":""},{"line_number":10,"context_line":"Change-Id: Iccf43ec7d355e26ae4efe58b167ffccd89b158b3"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"44221167_c50155be","line":8,"updated":"2023-05-19 09:46:45.000000000","message":"It\u0027s usual to have a blank line between the commit message subject (first line) and the rest of the message.\n\nIn fact, you have not needed to use nonlocal variables (https://realpython.com/python-scope-legb-rule/#the-nonlocal-statement) because you have moved inner methods and made them class methods. So the second line can be deleted.","commit_id":"50f3ee842eff077333b1a23c8a941d00e40054c5"},{"author":{"_account_id":35790,"name":"Shreeya Deshpande","email":"shreeyad@nvidia.com","username":"shreeyad"},"change_message_id":"1e426e3c6734e971ee5159624f666ac37790bbf8","unresolved":false,"context_lines":[{"line_number":5,"context_line":"CommitDate: 2023-05-18 15:14:09 -0700"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Refactor for extract closure to method"},{"line_number":8,"context_line":"Replace for py3 nonlocal variables"},{"line_number":9,"context_line":""},{"line_number":10,"context_line":"Change-Id: Iccf43ec7d355e26ae4efe58b167ffccd89b158b3"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"b2d83494_c0e6bc55","line":8,"in_reply_to":"44221167_c50155be","updated":"2023-05-22 01:45:16.000000000","message":"Done","commit_id":"50f3ee842eff077333b1a23c8a941d00e40054c5"}],"/PATCHSET_LEVEL":[{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"bf0fae166db91f7a0be9d413e1e805115eefeca9","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":1,"id":"38881be9_ea21074f","updated":"2023-05-11 16:52:00.000000000","message":"this is the right idea, but i don\u0027t think CI is going to be happy with it - see if you can get those scopes correct","commit_id":"07169f09597eba21ae20e72cc63bf8893c9159a3"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"0366caf5ad2c15febb5c32dbc01e6afed30e8500","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":2,"id":"89c7dd5e_f1ccfa30","updated":"2023-05-16 21:06:27.000000000","message":"this is not better than what\u0027s on master, you\u0027ll have to keep trying\n\nI think you should be able to fix a number of the bugs you\u0027ve introduced, try to run some of the failing tests individually and dig in e.g. \n\n    pytest swift/test/unit/proxy/test_server.py::TestReplicatedObjectController::test_GET_respects_read_affinity\n\n^ that\u0027s just a simple AttributeError and it gives you a line number with the typo, fix that and then move onto another one","commit_id":"a99b300f37a7365461d6cb76ce8d44ebcbe855b8"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"35851beebe8ec8a043dd372d7b5ba94b9f64d90d","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":4,"id":"6684c692_0b3155f6","updated":"2023-05-18 18:46:10.000000000","message":"this might be suitable to carry, but I think the handling of some of the node state (e.g. node_timeout) could be cleaner.\n\nwe\u0027ll see what zuul testing thinks!","commit_id":"37a7a5d6a23208c57184455b05b7100fa14b0f16"},{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"18a66ccef2e8a64f8d8b57a356de96242a9209d4","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"fdefaf97_d49e364f","updated":"2023-05-19 09:40:45.000000000","message":"apart from the unit test changes and pep8 errors, I think this is looking good","commit_id":"50f3ee842eff077333b1a23c8a941d00e40054c5"},{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"44e9a39eb0f2c99883afac63fb1e40dd6bb359d7","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"c51ea066_68566699","updated":"2023-05-19 09:27:10.000000000","message":"the test failures are because some tests are calling GetOrHeadHandler._make_app_iter directly, e.g. https://github.com/openstack/swift/blob/e2682f4a830cceb80affd1eef40ca0344ed3c9de/test/unit/proxy/controllers/test_base.py#L1274\n\nThe signature of that method has changed: it no longer takes source and node args because these have become class attributes.\n\nSo, in the tests you\u0027ll need to set handler.source and handler.node before calling handler._make_app_iter(req)","commit_id":"50f3ee842eff077333b1a23c8a941d00e40054c5"},{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"7bd7a9fff5acd7f8d68d052ecd4d99995a52ded7","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"7d7f8c24_fde6b503","updated":"2023-05-19 09:28:52.000000000","message":"to check for pep8 style violations before pushing to gerrit, you can either use\n\ntox -e pep8\n\nor in a virtualenv with test-requirements.txt installed,\n\nflake8 swift/proxy/controllers.base.py\n\nThe second is quicker (just checking the one file you have touched)","commit_id":"50f3ee842eff077333b1a23c8a941d00e40054c5"},{"author":{"_account_id":35790,"name":"Shreeya Deshpande","email":"shreeyad@nvidia.com","username":"shreeyad"},"change_message_id":"1e426e3c6734e971ee5159624f666ac37790bbf8","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":6,"id":"9bdc1a2a_e3c11a1e","in_reply_to":"7d7f8c24_fde6b503","updated":"2023-05-22 01:45:16.000000000","message":"I used flake8 before pushing the changes but did not get any errors. I\u0027ll do tox -e pep8 from now on.","commit_id":"50f3ee842eff077333b1a23c8a941d00e40054c5"},{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"d6b3f1385699ff3c1b53e51d4d34edcd62d0f719","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":8,"id":"764f6d8d_26996b67","updated":"2023-05-23 13:03:35.000000000","message":"Apart from the few lines of redundant code setting self.node_timeout, I think this can be merged.\n\nThere is plenty of other opportunity to clean up this class, but this refactor gets GetOrHeadHandler aligned with ECFragGetter and it might be worth considering de-duplicating the code in the two classes.","commit_id":"4f463c72970b4aa0c1f8f04d2f917172c67bf5bb"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"31e89ac4b3ef90a1af71080ad92256d6efe944c8","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":8,"id":"c7ccf9a7_af5ced1a","updated":"2023-05-22 21:07:21.000000000","message":"I think digging into the handling of self.source/self.node is going to open up another round of refactor sprawl\n\nhttps://review.opendev.org/c/openstack/swift/+/883878\n\nwe may have already pushed this one too far","commit_id":"4f463c72970b4aa0c1f8f04d2f917172c67bf5bb"},{"author":{"_account_id":15343,"name":"Tim Burke","email":"tburke@nvidia.com","username":"tburke"},"change_message_id":"07dd72c50cb12fb14f053a8bb0289e45e7ffa726","unresolved":false,"context_lines":[],"source_content_type":"","patch_set":8,"id":"fec2c422_1fd29b05","in_reply_to":"c7ccf9a7_af5ced1a","updated":"2023-05-23 00:01:11.000000000","message":"... it\u0027s gonna just keep going...\n\nShould we maybe go poking at `controllers/obj.py`, too? https://github.com/openstack/swift/blob/2.31.1/swift/proxy/controllers/obj.py#L2583","commit_id":"4f463c72970b4aa0c1f8f04d2f917172c67bf5bb"}],"swift/proxy/controllers/base.py":[{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"bf0fae166db91f7a0be9d413e1e805115eefeca9","unresolved":true,"context_lines":[{"line_number":1193,"context_line":"            # on it, so no IO is performed."},{"line_number":1194,"context_line":"            parts_iter \u003d ["},{"line_number":1195,"context_line":"                http_response_to_document_iters("},{"line_number":1196,"context_line":"                    source[0], read_chunk_size\u003dself.app.object_chunk_size)]"},{"line_number":1197,"context_line":""},{"line_number":1198,"context_line":"            def get_next_doc_part():"},{"line_number":1199,"context_line":"                while True:"}],"source_content_type":"text/x-python","patch_set":1,"id":"81652925_1cb9c245","side":"PARENT","line":1196,"updated":"2023-05-11 16:52:00.000000000","message":"before python had a nonlocal kwarg we\u0027d stick variables inside a mutlable so that our closed scope wouldn\u0027t try to re-declare them:\n\n\tclayg@banana:~/Workspace/scratch/closure$ cat closure.py \n\tdef outer():\n\t    foo \u003d \u0027bar\u0027\n\t    fooz \u003d [\u0027bar\u0027]\n\t    def inner():\n\t\tfoo \u003d \u0027baz\u0027\n\t\tfooz[0] \u003d \u0027baz\u0027\n\t\tprint(\u0027inner foo\u0027, foo)\n\t\tprint(\u0027inner fooz\u0027, fooz)\n\t    inner()\n\t    print(\u0027outer foo\u0027, foo)\n\t    print(\u0027outer fooz\u0027, fooz)\n\n\touter()\n\tclayg@banana:~/Workspace/scratch/closure$ python closure.py \n\t(\u0027inner foo\u0027, \u0027baz\u0027)\n\t(\u0027inner fooz\u0027, [\u0027baz\u0027])\n\t(\u0027outer foo\u0027, \u0027bar\u0027)\n\t(\u0027outer fooz\u0027, [\u0027baz\u0027])\n\nsee https://review.opendev.org/c/openstack/swift/+/881151","commit_id":"89e2050d7f99b8eb392cc35a3d23e4e8eb54fb7a"},{"author":{"_account_id":35790,"name":"Shreeya Deshpande","email":"shreeyad@nvidia.com","username":"shreeyad"},"change_message_id":"00489056d15253c90c82b59a1df8aa3385a3d263","unresolved":false,"context_lines":[{"line_number":1193,"context_line":"            # on it, so no IO is performed."},{"line_number":1194,"context_line":"            parts_iter \u003d ["},{"line_number":1195,"context_line":"                http_response_to_document_iters("},{"line_number":1196,"context_line":"                    source[0], read_chunk_size\u003dself.app.object_chunk_size)]"},{"line_number":1197,"context_line":""},{"line_number":1198,"context_line":"            def get_next_doc_part():"},{"line_number":1199,"context_line":"                while True:"}],"source_content_type":"text/x-python","patch_set":1,"id":"4609ce6a_490e1eeb","side":"PARENT","line":1196,"in_reply_to":"81652925_1cb9c245","updated":"2023-05-18 21:43:53.000000000","message":"Ack","commit_id":"89e2050d7f99b8eb392cc35a3d23e4e8eb54fb7a"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"bf0fae166db91f7a0be9d413e1e805115eefeca9","unresolved":true,"context_lines":[{"line_number":1209,"context_line":"                    self.node[0] \u003d new_node"},{"line_number":1210,"context_line":"                    # This is safe; it sets up a generator but does"},{"line_number":1211,"context_line":"                    # not call next() on it, so no IO is performed."},{"line_number":1212,"context_line":"                    self.parts_iter[0] \u003d http_response_to_document_iters("},{"line_number":1213,"context_line":"                        new_source,"},{"line_number":1214,"context_line":"                        read_chunk_size\u003dself.app.object_chunk_size)"},{"line_number":1215,"context_line":"                else:"}],"source_content_type":"text/x-python","patch_set":1,"id":"cfb2fcb1_252620ce","line":1212,"updated":"2023-05-11 16:52:00.000000000","message":"pretty sure this is going to attribute error","commit_id":"07169f09597eba21ae20e72cc63bf8893c9159a3"},{"author":{"_account_id":35790,"name":"Shreeya Deshpande","email":"shreeyad@nvidia.com","username":"shreeyad"},"change_message_id":"00489056d15253c90c82b59a1df8aa3385a3d263","unresolved":false,"context_lines":[{"line_number":1209,"context_line":"                    self.node[0] \u003d new_node"},{"line_number":1210,"context_line":"                    # This is safe; it sets up a generator but does"},{"line_number":1211,"context_line":"                    # not call next() on it, so no IO is performed."},{"line_number":1212,"context_line":"                    self.parts_iter[0] \u003d http_response_to_document_iters("},{"line_number":1213,"context_line":"                        new_source,"},{"line_number":1214,"context_line":"                        read_chunk_size\u003dself.app.object_chunk_size)"},{"line_number":1215,"context_line":"                else:"}],"source_content_type":"text/x-python","patch_set":1,"id":"8dfc7472_c0e80ac1","line":1212,"in_reply_to":"cfb2fcb1_252620ce","updated":"2023-05-18 21:43:53.000000000","message":"Done","commit_id":"07169f09597eba21ae20e72cc63bf8893c9159a3"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"0366caf5ad2c15febb5c32dbc01e6afed30e8500","unresolved":true,"context_lines":[{"line_number":1029,"context_line":"        self.path \u003d path"},{"line_number":1030,"context_line":"        self.backend_headers \u003d backend_headers"},{"line_number":1031,"context_line":"        self.client_chunk_size \u003d client_chunk_size"},{"line_number":1032,"context_line":"        self.node_timeout \u003d 0"},{"line_number":1033,"context_line":"        self.logger \u003d logger or app.logger"},{"line_number":1034,"context_line":"        self.skip_bytes \u003d 0"},{"line_number":1035,"context_line":"        self.bytes_used_from_backend \u003d 0"}],"source_content_type":"text/x-python","patch_set":2,"id":"c0a43777_dbe0463a","line":1032,"updated":"2023-05-16 21:06:27.000000000","message":"I think if you\u0027re going to make node_timeout an attribute you should just set it correctly right here\n\n            if self.server_type \u003d\u003d \u0027Object\u0027:\n                self.node_timeout \u003d self.app.recoverable_node_timeout\n            else:\n                self.node_timeout \u003d self.app.node_timeout\n\n... and then be done with it","commit_id":"a99b300f37a7365461d6cb76ce8d44ebcbe855b8"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"35851beebe8ec8a043dd372d7b5ba94b9f64d90d","unresolved":true,"context_lines":[{"line_number":1029,"context_line":"        self.path \u003d path"},{"line_number":1030,"context_line":"        self.backend_headers \u003d backend_headers"},{"line_number":1031,"context_line":"        self.client_chunk_size \u003d client_chunk_size"},{"line_number":1032,"context_line":"        self.node_timeout \u003d 0"},{"line_number":1033,"context_line":"        self.logger \u003d logger or app.logger"},{"line_number":1034,"context_line":"        self.skip_bytes \u003d 0"},{"line_number":1035,"context_line":"        self.bytes_used_from_backend \u003d 0"}],"source_content_type":"text/x-python","patch_set":2,"id":"c0a81a06_865d9138","line":1032,"in_reply_to":"c0a43777_dbe0463a","updated":"2023-05-18 18:46:10.000000000","message":"bump!","commit_id":"a99b300f37a7365461d6cb76ce8d44ebcbe855b8"},{"author":{"_account_id":35790,"name":"Shreeya Deshpande","email":"shreeyad@nvidia.com","username":"shreeyad"},"change_message_id":"00489056d15253c90c82b59a1df8aa3385a3d263","unresolved":false,"context_lines":[{"line_number":1029,"context_line":"        self.path \u003d path"},{"line_number":1030,"context_line":"        self.backend_headers \u003d backend_headers"},{"line_number":1031,"context_line":"        self.client_chunk_size \u003d client_chunk_size"},{"line_number":1032,"context_line":"        self.node_timeout \u003d 0"},{"line_number":1033,"context_line":"        self.logger \u003d logger or app.logger"},{"line_number":1034,"context_line":"        self.skip_bytes \u003d 0"},{"line_number":1035,"context_line":"        self.bytes_used_from_backend \u003d 0"}],"source_content_type":"text/x-python","patch_set":2,"id":"eaef66e9_d8602e9f","line":1032,"in_reply_to":"c0a81a06_865d9138","updated":"2023-05-18 21:43:53.000000000","message":"Done","commit_id":"a99b300f37a7365461d6cb76ce8d44ebcbe855b8"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"0366caf5ad2c15febb5c32dbc01e6afed30e8500","unresolved":true,"context_lines":[{"line_number":1253,"context_line":"                    if getattr(self.source[0], \u0027swift_conn\u0027, None):"},{"line_number":1254,"context_line":"                        close_swift_conn(self.source[0])"},{"line_number":1255,"context_line":"                    self.source[0] \u003d new_source"},{"line_number":1256,"context_line":"                    self.node[0] \u003d new_node"},{"line_number":1257,"context_line":"                    # This is safe; it just sets up a generator but"},{"line_number":1258,"context_line":"                    # does not call next() on it, so no IO is"},{"line_number":1259,"context_line":"                    # performed."}],"source_content_type":"text/x-python","patch_set":2,"id":"df315bf3_9c76a997","line":1256,"updated":"2023-05-16 21:06:27.000000000","message":"this [0] smells, is self.source *a list* ??? or just a reference to the source?","commit_id":"a99b300f37a7365461d6cb76ce8d44ebcbe855b8"},{"author":{"_account_id":35790,"name":"Shreeya Deshpande","email":"shreeyad@nvidia.com","username":"shreeyad"},"change_message_id":"00489056d15253c90c82b59a1df8aa3385a3d263","unresolved":false,"context_lines":[{"line_number":1253,"context_line":"                    if getattr(self.source[0], \u0027swift_conn\u0027, None):"},{"line_number":1254,"context_line":"                        close_swift_conn(self.source[0])"},{"line_number":1255,"context_line":"                    self.source[0] \u003d new_source"},{"line_number":1256,"context_line":"                    self.node[0] \u003d new_node"},{"line_number":1257,"context_line":"                    # This is safe; it just sets up a generator but"},{"line_number":1258,"context_line":"                    # does not call next() on it, so no IO is"},{"line_number":1259,"context_line":"                    # performed."}],"source_content_type":"text/x-python","patch_set":2,"id":"2b1fee50_e73668b0","line":1256,"in_reply_to":"df315bf3_9c76a997","updated":"2023-05-18 21:43:53.000000000","message":"Changed. source and node isn\u0027t a list anymore.","commit_id":"a99b300f37a7365461d6cb76ce8d44ebcbe855b8"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"0366caf5ad2c15febb5c32dbc01e6afed30e8500","unresolved":true,"context_lines":[{"line_number":1260,"context_line":"                    self.source_parts_iter \u003d \\"},{"line_number":1261,"context_line":"                        http_response_to_document_iters("},{"line_number":1262,"context_line":"                            new_source,"},{"line_number":1263,"context_line":"                            read_chunk_size\u003dself.app.object_chunk_size)"},{"line_number":1264,"context_line":""},{"line_number":1265,"context_line":"                    try:"},{"line_number":1266,"context_line":"                        _junk, _junk, _junk, _junk, part_file \u003d \\"}],"source_content_type":"text/x-python","patch_set":2,"id":"47d05569_ee7091da","line":1263,"updated":"2023-05-16 21:06:27.000000000","message":"here we\u0027re setting self.source_parts_iter to the return value of http_response_to_document_iters - that seems reasonable","commit_id":"a99b300f37a7365461d6cb76ce8d44ebcbe855b8"},{"author":{"_account_id":35790,"name":"Shreeya Deshpande","email":"shreeyad@nvidia.com","username":"shreeyad"},"change_message_id":"00489056d15253c90c82b59a1df8aa3385a3d263","unresolved":false,"context_lines":[{"line_number":1260,"context_line":"                    self.source_parts_iter \u003d \\"},{"line_number":1261,"context_line":"                        http_response_to_document_iters("},{"line_number":1262,"context_line":"                            new_source,"},{"line_number":1263,"context_line":"                            read_chunk_size\u003dself.app.object_chunk_size)"},{"line_number":1264,"context_line":""},{"line_number":1265,"context_line":"                    try:"},{"line_number":1266,"context_line":"                        _junk, _junk, _junk, _junk, part_file \u003d \\"}],"source_content_type":"text/x-python","patch_set":2,"id":"afb22ef7_e829a037","line":1263,"in_reply_to":"47d05569_ee7091da","updated":"2023-05-18 21:43:53.000000000","message":"Ack","commit_id":"a99b300f37a7365461d6cb76ce8d44ebcbe855b8"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"0366caf5ad2c15febb5c32dbc01e6afed30e8500","unresolved":true,"context_lines":[{"line_number":1332,"context_line":"                    sleep()"},{"line_number":1333,"context_line":""},{"line_number":1334,"context_line":"    def _get_response_parts_iter(self, req, node, source):"},{"line_number":1335,"context_line":"        # Someday we can replace this [mess] with python 3\u0027s \"nonlocal\""},{"line_number":1336,"context_line":"        source \u003d [source]"},{"line_number":1337,"context_line":"        node \u003d [node]"},{"line_number":1338,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"be5b1572_a11fc7cf","line":1335,"updated":"2023-05-16 21:06:27.000000000","message":"today is that day!  but instead of nonlocal we\u0027re just going to use instance atters like real OOO programmers","commit_id":"a99b300f37a7365461d6cb76ce8d44ebcbe855b8"},{"author":{"_account_id":35790,"name":"Shreeya Deshpande","email":"shreeyad@nvidia.com","username":"shreeyad"},"change_message_id":"00489056d15253c90c82b59a1df8aa3385a3d263","unresolved":false,"context_lines":[{"line_number":1332,"context_line":"                    sleep()"},{"line_number":1333,"context_line":""},{"line_number":1334,"context_line":"    def _get_response_parts_iter(self, req, node, source):"},{"line_number":1335,"context_line":"        # Someday we can replace this [mess] with python 3\u0027s \"nonlocal\""},{"line_number":1336,"context_line":"        source \u003d [source]"},{"line_number":1337,"context_line":"        node \u003d [node]"},{"line_number":1338,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"45193725_e9c8681d","line":1335,"in_reply_to":"be5b1572_a11fc7cf","updated":"2023-05-18 21:43:53.000000000","message":"Done","commit_id":"a99b300f37a7365461d6cb76ce8d44ebcbe855b8"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"0366caf5ad2c15febb5c32dbc01e6afed30e8500","unresolved":true,"context_lines":[{"line_number":1334,"context_line":"    def _get_response_parts_iter(self, req, node, source):"},{"line_number":1335,"context_line":"        # Someday we can replace this [mess] with python 3\u0027s \"nonlocal\""},{"line_number":1336,"context_line":"        source \u003d [source]"},{"line_number":1337,"context_line":"        node \u003d [node]"},{"line_number":1338,"context_line":""},{"line_number":1339,"context_line":"        try:"},{"line_number":1340,"context_line":"            client_chunk_size \u003d self.client_chunk_size"}],"source_content_type":"text/x-python","patch_set":2,"id":"f4d4d301_762e8e9e","line":1337,"updated":"2023-05-16 21:06:27.000000000","message":"it seems like we have a self.source now, I think we should remove these","commit_id":"a99b300f37a7365461d6cb76ce8d44ebcbe855b8"},{"author":{"_account_id":35790,"name":"Shreeya Deshpande","email":"shreeyad@nvidia.com","username":"shreeyad"},"change_message_id":"00489056d15253c90c82b59a1df8aa3385a3d263","unresolved":false,"context_lines":[{"line_number":1334,"context_line":"    def _get_response_parts_iter(self, req, node, source):"},{"line_number":1335,"context_line":"        # Someday we can replace this [mess] with python 3\u0027s \"nonlocal\""},{"line_number":1336,"context_line":"        source \u003d [source]"},{"line_number":1337,"context_line":"        node \u003d [node]"},{"line_number":1338,"context_line":""},{"line_number":1339,"context_line":"        try:"},{"line_number":1340,"context_line":"            client_chunk_size \u003d self.client_chunk_size"}],"source_content_type":"text/x-python","patch_set":2,"id":"1b7d06e2_c81cbb9f","line":1337,"in_reply_to":"f4d4d301_762e8e9e","updated":"2023-05-18 21:43:53.000000000","message":"Done","commit_id":"a99b300f37a7365461d6cb76ce8d44ebcbe855b8"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"0366caf5ad2c15febb5c32dbc01e6afed30e8500","unresolved":true,"context_lines":[{"line_number":1348,"context_line":"            # on it, so no IO is performed."},{"line_number":1349,"context_line":"            self.source_parts_iter \u003d ["},{"line_number":1350,"context_line":"                http_response_to_document_iters("},{"line_number":1351,"context_line":"                    source, read_chunk_size\u003dself.app.object_cchunk_size)]"},{"line_number":1352,"context_line":""},{"line_number":1353,"context_line":"            part_iter \u003d None"},{"line_number":1354,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":2,"id":"4cd8bd69_4f5e4848","line":1351,"updated":"2023-05-16 21:06:27.000000000","message":"here we\u0027re setting self.source_parts_iter to a LIST that contains a single element, the return value of http_response_to_document_iters\n\nI think that\u0027s a hold over to the non-local trick","commit_id":"a99b300f37a7365461d6cb76ce8d44ebcbe855b8"},{"author":{"_account_id":35790,"name":"Shreeya Deshpande","email":"shreeyad@nvidia.com","username":"shreeyad"},"change_message_id":"00489056d15253c90c82b59a1df8aa3385a3d263","unresolved":false,"context_lines":[{"line_number":1348,"context_line":"            # on it, so no IO is performed."},{"line_number":1349,"context_line":"            self.source_parts_iter \u003d ["},{"line_number":1350,"context_line":"                http_response_to_document_iters("},{"line_number":1351,"context_line":"                    source, read_chunk_size\u003dself.app.object_cchunk_size)]"},{"line_number":1352,"context_line":""},{"line_number":1353,"context_line":"            part_iter \u003d None"},{"line_number":1354,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":2,"id":"12429780_c657c6ec","line":1351,"in_reply_to":"4cd8bd69_4f5e4848","updated":"2023-05-18 21:43:53.000000000","message":"Ack","commit_id":"a99b300f37a7365461d6cb76ce8d44ebcbe855b8"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"35851beebe8ec8a043dd372d7b5ba94b9f64d90d","unresolved":true,"context_lines":[{"line_number":1214,"context_line":"                    # not call next() on it, so no IO is performed."},{"line_number":1215,"context_line":"                    self.source_parts_iter \u003d http_response_to_document_iters("},{"line_number":1216,"context_line":"                        new_source,"},{"line_number":1217,"context_line":"                        read_chunk_size\u003dself.app.object_chunk_size)"},{"line_number":1218,"context_line":"                else:"},{"line_number":1219,"context_line":"                    raise StopIteration()"},{"line_number":1220,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"e663a12a_d7010575","line":1217,"updated":"2023-05-18 18:46:10.000000000","message":"this looks like a clean reset of the class state node/source/source_parts_iter - kudso!","commit_id":"37a7a5d6a23208c57184455b05b7100fa14b0f16"},{"author":{"_account_id":35790,"name":"Shreeya Deshpande","email":"shreeyad@nvidia.com","username":"shreeyad"},"change_message_id":"00489056d15253c90c82b59a1df8aa3385a3d263","unresolved":false,"context_lines":[{"line_number":1214,"context_line":"                    # not call next() on it, so no IO is performed."},{"line_number":1215,"context_line":"                    self.source_parts_iter \u003d http_response_to_document_iters("},{"line_number":1216,"context_line":"                        new_source,"},{"line_number":1217,"context_line":"                        read_chunk_size\u003dself.app.object_chunk_size)"},{"line_number":1218,"context_line":"                else:"},{"line_number":1219,"context_line":"                    raise StopIteration()"},{"line_number":1220,"context_line":""}],"source_content_type":"text/x-python","patch_set":4,"id":"95aaa939_c30d4e30","line":1217,"in_reply_to":"e663a12a_d7010575","updated":"2023-05-18 21:43:53.000000000","message":"Ack","commit_id":"37a7a5d6a23208c57184455b05b7100fa14b0f16"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"35851beebe8ec8a043dd372d7b5ba94b9f64d90d","unresolved":true,"context_lines":[{"line_number":1338,"context_line":"            if self.server_type \u003d\u003d \u0027Object\u0027:"},{"line_number":1339,"context_line":"                node_timeout \u003d self.app.recoverable_node_timeout"},{"line_number":1340,"context_line":"            self.node_timeout \u003d node_timeout"},{"line_number":1341,"context_line":"            self.client_chunk_size \u003d client_chunk_size"},{"line_number":1342,"context_line":""},{"line_number":1343,"context_line":"            # This is safe; it sets up a generator but does not call next()"},{"line_number":1344,"context_line":"            # on it, so no IO is performed."}],"source_content_type":"text/x-python","patch_set":4,"id":"00f38f03_cffd5947","line":1341,"updated":"2023-05-18 18:46:10.000000000","message":"this makes no sense in conjunction with L1336","commit_id":"37a7a5d6a23208c57184455b05b7100fa14b0f16"},{"author":{"_account_id":35790,"name":"Shreeya Deshpande","email":"shreeyad@nvidia.com","username":"shreeyad"},"change_message_id":"64c9e697cc241c5b5cfd1c80c3c8907f0d551376","unresolved":false,"context_lines":[{"line_number":1338,"context_line":"            if self.server_type \u003d\u003d \u0027Object\u0027:"},{"line_number":1339,"context_line":"                node_timeout \u003d self.app.recoverable_node_timeout"},{"line_number":1340,"context_line":"            self.node_timeout \u003d node_timeout"},{"line_number":1341,"context_line":"            self.client_chunk_size \u003d client_chunk_size"},{"line_number":1342,"context_line":""},{"line_number":1343,"context_line":"            # This is safe; it sets up a generator but does not call next()"},{"line_number":1344,"context_line":"            # on it, so no IO is performed."}],"source_content_type":"text/x-python","patch_set":4,"id":"af386920_5705b83b","line":1341,"in_reply_to":"00f38f03_cffd5947","updated":"2023-05-18 22:15:41.000000000","message":"Ack","commit_id":"37a7a5d6a23208c57184455b05b7100fa14b0f16"},{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"18a66ccef2e8a64f8d8b57a356de96242a9209d4","unresolved":true,"context_lines":[{"line_number":1605,"context_line":"            boundary, is_multipart, self.logger)"},{"line_number":1606,"context_line":""},{"line_number":1607,"context_line":"    def get_working_response(self, req):"},{"line_number":1608,"context_line":"        source, node \u003d self._get_source_and_node()"},{"line_number":1609,"context_line":"        res \u003d None"},{"line_number":1610,"context_line":"        if source:"},{"line_number":1611,"context_line":"            res \u003d Response(request\u003dreq)"}],"source_content_type":"text/x-python","patch_set":6,"id":"aee56313_ebfdfe2e","line":1608,"updated":"2023-05-19 09:40:45.000000000","message":"I\u0027d prefer to set self.source, self.node here and then refer to self.source and self.node throughout the method.\n\nNote: we do NOT want to set self.source, self.node inside _get_source_and_node() because of the way it is used in get_next_doc_part()","commit_id":"50f3ee842eff077333b1a23c8a941d00e40054c5"},{"author":{"_account_id":35790,"name":"Shreeya Deshpande","email":"shreeyad@nvidia.com","username":"shreeyad"},"change_message_id":"1e426e3c6734e971ee5159624f666ac37790bbf8","unresolved":false,"context_lines":[{"line_number":1605,"context_line":"            boundary, is_multipart, self.logger)"},{"line_number":1606,"context_line":""},{"line_number":1607,"context_line":"    def get_working_response(self, req):"},{"line_number":1608,"context_line":"        source, node \u003d self._get_source_and_node()"},{"line_number":1609,"context_line":"        res \u003d None"},{"line_number":1610,"context_line":"        if source:"},{"line_number":1611,"context_line":"            res \u003d Response(request\u003dreq)"}],"source_content_type":"text/x-python","patch_set":6,"id":"e9392a5b_8d7d5a90","line":1608,"in_reply_to":"aee56313_ebfdfe2e","updated":"2023-05-22 01:45:16.000000000","message":"Done","commit_id":"50f3ee842eff077333b1a23c8a941d00e40054c5"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"31e89ac4b3ef90a1af71080ad92256d6efe944c8","unresolved":true,"context_lines":[{"line_number":1177,"context_line":"            return True"},{"line_number":1178,"context_line":"        return is_success(src.status) or is_redirection(src.status)"},{"line_number":1179,"context_line":""},{"line_number":1180,"context_line":"    def _get_response_parts_iter(self, req, node, source):"},{"line_number":1181,"context_line":"        # Someday we can replace this [mess] with python 3\u0027s \"nonlocal\""},{"line_number":1182,"context_line":"        source \u003d [source]"},{"line_number":1183,"context_line":"        node \u003d [node]"}],"source_content_type":"text/x-python","patch_set":8,"id":"4b16c958_a7ae9e49","side":"PARENT","line":1180,"updated":"2023-05-22 21:07:21.000000000","message":"so we used to pass in node and source","commit_id":"ef64b63fdfd3a3c644cd7f64a94f83e952091d10"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"31e89ac4b3ef90a1af71080ad92256d6efe944c8","unresolved":true,"context_lines":[{"line_number":1317,"context_line":"            node_timeout \u003d self.app.node_timeout"},{"line_number":1318,"context_line":"            if self.server_type \u003d\u003d \u0027Object\u0027:"},{"line_number":1319,"context_line":"                node_timeout \u003d self.app.recoverable_node_timeout"},{"line_number":1320,"context_line":"            self.node_timeout \u003d node_timeout"},{"line_number":1321,"context_line":""},{"line_number":1322,"context_line":"            # This is safe; it sets up a generator but does not call next()"},{"line_number":1323,"context_line":"            # on it, so no IO is performed."}],"source_content_type":"text/x-python","patch_set":8,"id":"ddc0e849_2246cb49","line":1320,"updated":"2023-05-22 21:07:21.000000000","message":"it seems like this is all handled in `__init__` now","commit_id":"4f463c72970b4aa0c1f8f04d2f917172c67bf5bb"},{"author":{"_account_id":35790,"name":"Shreeya Deshpande","email":"shreeyad@nvidia.com","username":"shreeyad"},"change_message_id":"efef662fcd406ece7a614d161dc4a7503eabb084","unresolved":false,"context_lines":[{"line_number":1317,"context_line":"            node_timeout \u003d self.app.node_timeout"},{"line_number":1318,"context_line":"            if self.server_type \u003d\u003d \u0027Object\u0027:"},{"line_number":1319,"context_line":"                node_timeout \u003d self.app.recoverable_node_timeout"},{"line_number":1320,"context_line":"            self.node_timeout \u003d node_timeout"},{"line_number":1321,"context_line":""},{"line_number":1322,"context_line":"            # This is safe; it sets up a generator but does not call next()"},{"line_number":1323,"context_line":"            # on it, so no IO is performed."}],"source_content_type":"text/x-python","patch_set":8,"id":"94bbb36a_232b5e71","line":1320,"in_reply_to":"223d911b_072178f0","updated":"2023-05-23 18:38:57.000000000","message":"Done","commit_id":"4f463c72970b4aa0c1f8f04d2f917172c67bf5bb"},{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"d6b3f1385699ff3c1b53e51d4d34edcd62d0f719","unresolved":true,"context_lines":[{"line_number":1317,"context_line":"            node_timeout \u003d self.app.node_timeout"},{"line_number":1318,"context_line":"            if self.server_type \u003d\u003d \u0027Object\u0027:"},{"line_number":1319,"context_line":"                node_timeout \u003d self.app.recoverable_node_timeout"},{"line_number":1320,"context_line":"            self.node_timeout \u003d node_timeout"},{"line_number":1321,"context_line":""},{"line_number":1322,"context_line":"            # This is safe; it sets up a generator but does not call next()"},{"line_number":1323,"context_line":"            # on it, so no IO is performed."}],"source_content_type":"text/x-python","patch_set":8,"id":"223d911b_072178f0","line":1320,"in_reply_to":"ddc0e849_2246cb49","updated":"2023-05-23 13:03:35.000000000","message":"agree, lines 1317-1320 can be deleted","commit_id":"4f463c72970b4aa0c1f8f04d2f917172c67bf5bb"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"31e89ac4b3ef90a1af71080ad92256d6efe944c8","unresolved":true,"context_lines":[{"line_number":1322,"context_line":"            # This is safe; it sets up a generator but does not call next()"},{"line_number":1323,"context_line":"            # on it, so no IO is performed."},{"line_number":1324,"context_line":"            self.source_parts_iter \u003d http_response_to_document_iters("},{"line_number":1325,"context_line":"                self.source, read_chunk_size\u003dself.app.object_chunk_size)"},{"line_number":1326,"context_line":""},{"line_number":1327,"context_line":"            part_iter \u003d None"},{"line_number":1328,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":8,"id":"5279980a_81446122","line":1325,"updated":"2023-05-22 21:07:21.000000000","message":"in all the other places where we reset self.souce_parts_iter we\u0027re also setting self.node/self.source","commit_id":"4f463c72970b4aa0c1f8f04d2f917172c67bf5bb"},{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"d6b3f1385699ff3c1b53e51d4d34edcd62d0f719","unresolved":true,"context_lines":[{"line_number":1322,"context_line":"            # This is safe; it sets up a generator but does not call next()"},{"line_number":1323,"context_line":"            # on it, so no IO is performed."},{"line_number":1324,"context_line":"            self.source_parts_iter \u003d http_response_to_document_iters("},{"line_number":1325,"context_line":"                self.source, read_chunk_size\u003dself.app.object_chunk_size)"},{"line_number":1326,"context_line":""},{"line_number":1327,"context_line":"            part_iter \u003d None"},{"line_number":1328,"context_line":"            try:"}],"source_content_type":"text/x-python","patch_set":8,"id":"dc858d38_83ba4dcf","line":1325,"in_reply_to":"5279980a_81446122","updated":"2023-05-23 13:03:35.000000000","message":"This is the first time source_parts_iter is set. In the other places we\u0027re *re*-setting node, source and source_parts_iter.\n\nIt might be nice to see all three set together, BUT the exact same pattern is followed in the obj.ECFragGetter class (that was also recently refactored in the exact same fashion as this patch) i.e. \n\nECFragGetter.response_parts_iter() sets self.source and self.node, and then calls ECFragGetter._get_response_parts_iter() which sets self.source_parts_iter. Then down in ECFragGetter.iter_bytes_from_response_part() self.source, self.node and self source_parts_iter may be reset.\n\nIn fact, there is a huge amount of duplicated code between these refactored methods in ECFragGetter and GetOrHeadHandler, so much so that I would advocate leaving this as it is so that the two can be combined, and then improve the elegance ONCE. \n\nOh, but it appears that the code duplication was a deliberate choice https://review.opendev.org/c/openstack/swift/+/733911 ? I\u0027m curious if that helped duplication, given that we\u0027ve now repeated the same refactoring in two places (and maybe we\u0027re fixing, or forgetting to fix, other things in two places).","commit_id":"4f463c72970b4aa0c1f8f04d2f917172c67bf5bb"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"31e89ac4b3ef90a1af71080ad92256d6efe944c8","unresolved":true,"context_lines":[{"line_number":1544,"context_line":"            # has two versions of the same object, we might end up switching"},{"line_number":1545,"context_line":"            # between old and new mid-stream and giving garbage to the client."},{"line_number":1546,"context_line":"            self.used_source_etag \u003d normalize_etag(src_headers.get(\u0027etag\u0027, \u0027\u0027))"},{"line_number":1547,"context_line":"            self.node \u003d node"},{"line_number":1548,"context_line":"            return source, node"},{"line_number":1549,"context_line":"        return None, None"},{"line_number":1550,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"20ee17ad_9b9e55eb","line":1547,"updated":"2023-05-22 21:07:21.000000000","message":"weird that we set self.node here - and then also return it?  And we don\u0027t handle self.source, much less the new self.source_parts_iter\n\nmaybe this method should manage all the state and just return True/False","commit_id":"4f463c72970b4aa0c1f8f04d2f917172c67bf5bb"},{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"d6b3f1385699ff3c1b53e51d4d34edcd62d0f719","unresolved":true,"context_lines":[{"line_number":1544,"context_line":"            # has two versions of the same object, we might end up switching"},{"line_number":1545,"context_line":"            # between old and new mid-stream and giving garbage to the client."},{"line_number":1546,"context_line":"            self.used_source_etag \u003d normalize_etag(src_headers.get(\u0027etag\u0027, \u0027\u0027))"},{"line_number":1547,"context_line":"            self.node \u003d node"},{"line_number":1548,"context_line":"            return source, node"},{"line_number":1549,"context_line":"        return None, None"},{"line_number":1550,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"e93b4378_4758e5d6","line":1547,"in_reply_to":"20ee17ad_9b9e55eb","updated":"2023-05-23 13:03:35.000000000","message":"OH, that\u0027s a bug surely? In fact, over in ECFragGetter._source_and_node_gen the bug was spotted https://review.opendev.org/c/openstack/swift/+/796735, but not in both places! and the bug remains here 😭","commit_id":"4f463c72970b4aa0c1f8f04d2f917172c67bf5bb"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"31e89ac4b3ef90a1af71080ad92256d6efe944c8","unresolved":true,"context_lines":[{"line_number":1595,"context_line":"                    source.status in (HTTP_OK, HTTP_PARTIAL_CONTENT):"},{"line_number":1596,"context_line":"                self.source \u003d source"},{"line_number":1597,"context_line":"                self.node \u003d node"},{"line_number":1598,"context_line":"                res.app_iter \u003d self._make_app_iter(req)"},{"line_number":1599,"context_line":"                # See NOTE: swift_conn at top of file about this."},{"line_number":1600,"context_line":"                res.swift_conn \u003d source.swift_conn"},{"line_number":1601,"context_line":"            if not res.environ:"}],"source_content_type":"text/x-python","patch_set":8,"id":"29f81f97_e7f1a9ce","line":1598,"updated":"2023-05-22 21:07:21.000000000","message":"oic, the call signature changed (and has the requirement to set source and node first","commit_id":"4f463c72970b4aa0c1f8f04d2f917172c67bf5bb"},{"author":{"_account_id":35790,"name":"Shreeya Deshpande","email":"shreeyad@nvidia.com","username":"shreeyad"},"change_message_id":"efef662fcd406ece7a614d161dc4a7503eabb084","unresolved":false,"context_lines":[{"line_number":1595,"context_line":"                    source.status in (HTTP_OK, HTTP_PARTIAL_CONTENT):"},{"line_number":1596,"context_line":"                self.source \u003d source"},{"line_number":1597,"context_line":"                self.node \u003d node"},{"line_number":1598,"context_line":"                res.app_iter \u003d self._make_app_iter(req)"},{"line_number":1599,"context_line":"                # See NOTE: swift_conn at top of file about this."},{"line_number":1600,"context_line":"                res.swift_conn \u003d source.swift_conn"},{"line_number":1601,"context_line":"            if not res.environ:"}],"source_content_type":"text/x-python","patch_set":8,"id":"b6fb5cc8_a5508e38","line":1598,"in_reply_to":"29f81f97_e7f1a9ce","updated":"2023-05-23 18:38:57.000000000","message":"Ack","commit_id":"4f463c72970b4aa0c1f8f04d2f917172c67bf5bb"}],"test/unit/proxy/controllers/test_base.py":[{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"31e89ac4b3ef90a1af71080ad92256d6efe944c8","unresolved":true,"context_lines":[{"line_number":1301,"context_line":""},{"line_number":1302,"context_line":"        handler.source \u003d source"},{"line_number":1303,"context_line":"        handler.node \u003d node"},{"line_number":1304,"context_line":"        app_iter \u003d handler._make_app_iter(req)"},{"line_number":1305,"context_line":"        client_chunks \u003d list(app_iter)"},{"line_number":1306,"context_line":"        self.assertEqual(client_chunks, ["},{"line_number":1307,"context_line":"            b\u0027abcd1234\u0027, b\u0027abcd1234\u0027, b\u0027abcd1234\u0027, b\u0027abcd12\u0027])"}],"source_content_type":"text/x-python","patch_set":8,"id":"fe59949c_0ffe091c","line":1304,"updated":"2023-05-22 21:07:21.000000000","message":"this is a weird change in this interface - it used to be we had to pass in the source/node, now we have to set it before we call _make_app_iter","commit_id":"4f463c72970b4aa0c1f8f04d2f917172c67bf5bb"},{"author":{"_account_id":7847,"name":"Alistair Coles","email":"alistairncoles@gmail.com","username":"acoles"},"change_message_id":"d6b3f1385699ff3c1b53e51d4d34edcd62d0f719","unresolved":true,"context_lines":[{"line_number":1301,"context_line":""},{"line_number":1302,"context_line":"        handler.source \u003d source"},{"line_number":1303,"context_line":"        handler.node \u003d node"},{"line_number":1304,"context_line":"        app_iter \u003d handler._make_app_iter(req)"},{"line_number":1305,"context_line":"        client_chunks \u003d list(app_iter)"},{"line_number":1306,"context_line":"        self.assertEqual(client_chunks, ["},{"line_number":1307,"context_line":"            b\u0027abcd1234\u0027, b\u0027abcd1234\u0027, b\u0027abcd1234\u0027, b\u0027abcd12\u0027])"}],"source_content_type":"text/x-python","patch_set":8,"id":"fd9fb996_bd90f405","line":1304,"in_reply_to":"fe59949c_0ffe091c","updated":"2023-05-23 13:03:35.000000000","message":"I\u0027m not sure it\u0027s so weird given that _make_app_iter is not part of a \"public\" interface - the test wants to dig into the internals of the class and so it has to set up some pre-requisites.\n\nThe same would be needed if for example we wanted to directly call _get_response_parts_iter from a test.\n\nThe tests have taken a shortcut - I\u0027ve re-written them to call the public method here https://review.opendev.org/c/openstack/swift/+/883936","commit_id":"4f463c72970b4aa0c1f8f04d2f917172c67bf5bb"}]}
