)]}'
{"swiftclient/service.py":[{"author":{"_account_id":9216,"name":"Joel Wright","email":"joel.wright@gmail.com","username":"jjw-sohonet"},"change_message_id":"21a52fff443bd5488e6e601279097a1dbfbd7fb9","unresolved":false,"context_lines":[{"line_number":379,"context_line":"        self._actual_md5 \u003d None"},{"line_number":380,"context_line":"        self._expected_md5 \u003d headers.get(\u0027etag\u0027, \u0027\u0027)"},{"line_number":381,"context_line":""},{"line_number":382,"context_line":"        if len(self._expected_md5) \u003e 1 and self._expected_md5[0] \u003d\u003d \u0027\"\u0027 \\"},{"line_number":383,"context_line":"                and self._expected_md5[-1] \u003d\u003d \u0027\"\u0027:"},{"line_number":384,"context_line":"            self._expected_md5 \u003d self._expected_md5[1:-1]"},{"line_number":385,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"7ffa3b31_35f85f47","line":382,"range":{"start_line":382,"start_character":11,"end_line":382,"end_character":38},"updated":"2017-04-19 18:16:25.000000000","message":"I suppose that at the moment we could check for \u003e32 instead... not that it makes a big difference","commit_id":"8e6a47e37ac20546c5167b86ec96a9f584ef4e1a"},{"author":{"_account_id":9216,"name":"Joel Wright","email":"joel.wright@gmail.com","username":"jjw-sohonet"},"change_message_id":"21a52fff443bd5488e6e601279097a1dbfbd7fb9","unresolved":false,"context_lines":[{"line_number":396,"context_line":"            ])"},{"line_number":397,"context_line":"            if bad_md5_headers.intersection(headers):"},{"line_number":398,"context_line":"                raise ValueError"},{"line_number":399,"context_line":"        except ValueError:"},{"line_number":400,"context_line":"            # This isn\u0027t a useful checksum"},{"line_number":401,"context_line":"            self._expected_md5 \u003d \u0027\u0027"},{"line_number":402,"context_line":""},{"line_number":403,"context_line":"        if self._expected_md5 and checksum:"},{"line_number":404,"context_line":"            self._actual_md5 \u003d md5()"}],"source_content_type":"text/x-python","patch_set":1,"id":"7ffa3b31_55908bed","line":401,"range":{"start_line":399,"start_character":8,"end_line":401,"end_character":35},"updated":"2017-04-19 18:16:25.000000000","message":"Are there some cases where we want to report an error when we get a nonsensical etag? Is silently ignoring it always the right thing to do?","commit_id":"8e6a47e37ac20546c5167b86ec96a9f584ef4e1a"},{"author":{"_account_id":15343,"name":"Tim Burke","email":"tburke@nvidia.com","username":"tburke"},"change_message_id":"ed4bce5ded6afcc0a722842771939dbe38c2ec1a","unresolved":false,"context_lines":[{"line_number":396,"context_line":"            ])"},{"line_number":397,"context_line":"            if bad_md5_headers.intersection(headers):"},{"line_number":398,"context_line":"                raise ValueError"},{"line_number":399,"context_line":"        except ValueError:"},{"line_number":400,"context_line":"            # This isn\u0027t a useful checksum"},{"line_number":401,"context_line":"            self._expected_md5 \u003d \u0027\u0027"},{"line_number":402,"context_line":""},{"line_number":403,"context_line":"        if self._expected_md5 and checksum:"},{"line_number":404,"context_line":"            self._actual_md5 \u003d md5()"}],"source_content_type":"text/x-python","patch_set":1,"id":"7ffa3b31_58c7a265","line":401,"range":{"start_line":399,"start_character":8,"end_line":401,"end_character":35},"in_reply_to":"7ffa3b31_55908bed","updated":"2017-04-19 18:34:27.000000000","message":"Kinda depends on what we expect to cause the nonsensical ETag; I can see a few possibilities:\n\n* I\u0027m kinda hoping to address https://bugs.launchpad.net/swift3/+bug/1522578 (with some revamped version of https://review.openstack.org/#/c/302475/) in the near future; that may or may not involve having swift3 overriding etags in swift API requests -- it depends on how much effort I want to put into trying to support having two usable ETags. But I guess we\u0027d still include the X-Static-Large-Object header, so maybe that doesn\u0027t matter.\n\n* ProxyFS objects aren\u0027t going to have the ETag-is-MD5 semantic, but will at least have an ETag that doesn\u0027t look like an MD5. Of course, that isn\u0027t public yet, either, so... :-/\n\n* On the other hand, if something goes off the rails such that a cluster with encryption enabled starts sending out the encrypted etags (not the ciphertext ETag, but the one with all the crypto meta), it\u0027d probably be nice to surface that sooner rather than later.\n\nI could be talked into logging a warning, but I think that\u0027s just going to end up with us carving out exceptions for the warning later.","commit_id":"8e6a47e37ac20546c5167b86ec96a9f584ef4e1a"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"48b39b6a61e3b5ca0c92e323de74618e8eeaa41d","unresolved":false,"context_lines":[{"line_number":393,"context_line":"            # This isn\u0027t a useful checksum"},{"line_number":394,"context_line":"            self._expected_md5 \u003d \u0027\u0027"},{"line_number":395,"context_line":""},{"line_number":396,"context_line":"        if self._expected_md5 and checksum:"},{"line_number":397,"context_line":"            self._actual_md5 \u003d md5()"},{"line_number":398,"context_line":""},{"line_number":399,"context_line":"        if \u0027content-length\u0027 in headers:"}],"source_content_type":"text/x-python","patch_set":2,"id":"5ff73747_e3464622","line":396,"updated":"2017-06-21 21:09:14.000000000","message":"this is a good bit more readable, well commented and less crufty if you ask me.  kudos.","commit_id":"64da481ccde9863b0b062cadb27402a5e18b876e"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"48b39b6a61e3b5ca0c92e323de74618e8eeaa41d","unresolved":false,"context_lines":[{"line_number":411,"context_line":"        self._check_contents()"},{"line_number":412,"context_line":""},{"line_number":413,"context_line":"    def _check_contents(self):"},{"line_number":414,"context_line":"        if self._actual_md5 and self._expected_md5:"},{"line_number":415,"context_line":"            etag \u003d self._actual_md5.hexdigest()"},{"line_number":416,"context_line":"            if etag !\u003d self._expected_md5:"},{"line_number":417,"context_line":"                raise SwiftError(\u0027Error downloading {0}: md5sum !\u003d etag, \u0027"}],"source_content_type":"text/x-python","patch_set":2,"id":"5ff73747_a3695e8c","line":414,"updated":"2017-06-21 21:09:14.000000000","message":"yeah this is perfect","commit_id":"64da481ccde9863b0b062cadb27402a5e18b876e"}],"tests/unit/test_service.py":[{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"48b39b6a61e3b5ca0c92e323de74618e8eeaa41d","unresolved":false,"context_lines":[{"line_number":130,"context_line":"        self.assertEqual(sr._path, \u0027path\u0027)"},{"line_number":131,"context_line":"        self.assertEqual(sr._body, \u0027body\u0027)"},{"line_number":132,"context_line":"        self.assertIsNone(sr._content_length)"},{"line_number":133,"context_line":"        self.assertFalse(sr._expected_md5)"},{"line_number":134,"context_line":"        self.assertIsNone(sr._actual_md5)"},{"line_number":135,"context_line":""},{"line_number":136,"context_line":"        sr \u003d self.sr(\u0027path\u0027, \u0027body\u0027, {\u0027x-static-large-object\u0027: \u0027test\u0027,"}],"source_content_type":"text/x-python","patch_set":2,"id":"5ff73747_63a596b5","line":133,"updated":"2017-06-21 21:09:14.000000000","message":"right quotes or no quotes we never expect large objects to md5","commit_id":"64da481ccde9863b0b062cadb27402a5e18b876e"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"48b39b6a61e3b5ca0c92e323de74618e8eeaa41d","unresolved":false,"context_lines":[{"line_number":185,"context_line":""},{"line_number":186,"context_line":"        # Should still work if etag was quoted"},{"line_number":187,"context_line":"        sr \u003d self.sr(\u0027path\u0027, BytesIO(b\u0027body\u0027),"},{"line_number":188,"context_line":"                     {\u0027etag\u0027: \u0027\"%s\"\u0027 % md5(b\u0027body\u0027).hexdigest()})"},{"line_number":189,"context_line":"        _consume(sr)"},{"line_number":190,"context_line":""},{"line_number":191,"context_line":"        # Check error is raised if SwiftReader doesn\u0027t read the same length"}],"source_content_type":"text/x-python","patch_set":2,"id":"5ff73747_c31a2a16","line":188,"updated":"2017-06-21 21:09:14.000000000","message":"nice.","commit_id":"64da481ccde9863b0b062cadb27402a5e18b876e"}]}
