)]}'
{"swift/obj/replicator.py":[{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"d14c11ba6d143252e70e4f22f3793a8f7b1f4fc7","unresolved":false,"context_lines":[{"line_number":488,"context_line":"                                          node)"},{"line_number":489,"context_line":"                    else:"},{"line_number":490,"context_line":"                        self.logger.exception(\"Error syncing with node: %s\" %"},{"line_number":491,"context_line":"                                              node)"},{"line_number":492,"context_line":"            self.suffix_count +\u003d len(local_hash)"},{"line_number":493,"context_line":"        except (Exception, Timeout) as e:"},{"line_number":494,"context_line":"            failure_devs_info.update(target_devs_info)"}],"source_content_type":"text/x-python","patch_set":1,"id":"7f287b81_942e3341","line":491,"updated":"2017-08-24 19:50:32.000000000","message":"idk, one nice thing about the built-in exception handling for timeouts is that it includes the value of the timeout:\n\nhttps://github.com/openstack/swift/blob/master/swift/common/utils.py#L1753\n\nI don\u0027t understand the trade off here to change:\n\nError syncing with node: \u003cdetails\u003e: Timeout (Xs)\n\nto:\n\nTimeout syncing with node: \u003cdetails\u003e\n\nPlus it\u0027s nice for grep/gork to have some commonality between log message prefix and various errors.  idk...","commit_id":"1bca067ec1b3aa8c5b0991558131697af3df349f"}],"test/unit/obj/test_replicator.py":[{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"ba4ed2c6f2abbc3f2f27db7109643482002a2603","unresolved":false,"context_lines":[{"line_number":1557,"context_line":"            def raise_exception_rmdir(exception_class, error_no):"},{"line_number":1558,"context_line":"                instance \u003d exception_class()"},{"line_number":1559,"context_line":"                instance.errno \u003d error_no"},{"line_number":1560,"context_line":"                instance.strerror \u003d os.strerror(error_no)"},{"line_number":1561,"context_line":""},{"line_number":1562,"context_line":"                def func(directory):"},{"line_number":1563,"context_line":"                    if directory \u003d\u003d suffix_dir_path:"}],"source_content_type":"text/x-python","patch_set":2,"id":"bf8cb3f7_a931c1ee","line":1560,"updated":"2017-12-27 22:26:13.000000000","message":"oh yeah, that\u0027s always a good idea.","commit_id":"61fe6aae81d00597c777a64ac337a8dfb990f0c2"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"ba4ed2c6f2abbc3f2f27db7109643482002a2603","unresolved":false,"context_lines":[{"line_number":1599,"context_line":"            self.assertEqual(mock_logger.get_lines_for_level(\u0027error\u0027), ["},{"line_number":1600,"context_line":"                \u0027Unexpected error trying to cleanup suffix dir:%r: \u0027 %"},{"line_number":1601,"context_line":"                os.path.dirname(df._datadir),"},{"line_number":1602,"context_line":"            ])"},{"line_number":1603,"context_line":"            self.assertFalse(os.access(whole_path_from, os.F_OK))"},{"line_number":1604,"context_line":"            self.assertTrue(os.access(suffix_dir_path, os.F_OK))"},{"line_number":1605,"context_line":"            self.assertTrue(os.access(part_path, os.F_OK))"}],"source_content_type":"text/x-python","patch_set":2,"id":"bf8cb3f7_494ef56f","line":1602,"updated":"2017-12-27 22:26:13.000000000","message":"#winning","commit_id":"61fe6aae81d00597c777a64ac337a8dfb990f0c2"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"ba4ed2c6f2abbc3f2f27db7109643482002a2603","unresolved":false,"context_lines":[{"line_number":1695,"context_line":"                            mock_http_connect(200)):"},{"line_number":1696,"context_line":"                with mock.patch(\u0027swift.obj.replicator.dump_recon_cache\u0027):"},{"line_number":1697,"context_line":"                    replicator \u003d object_replicator.ObjectReplicator("},{"line_number":1698,"context_line":"                        conf, logger\u003dself.logger)"},{"line_number":1699,"context_line":""},{"line_number":1700,"context_line":"                    self.get_hash_count \u003d 0"},{"line_number":1701,"context_line":"                    with mock.patch.object(replicator, \u0027sync\u0027, fake_sync):"}],"source_content_type":"text/x-python","patch_set":2,"id":"bf8cb3f7_a946a14e","line":1698,"updated":"2017-12-27 22:26:13.000000000","message":"yes, this is nice.","commit_id":"61fe6aae81d00597c777a64ac337a8dfb990f0c2"},{"author":{"_account_id":1179,"name":"Clay Gerrard","email":"clay.gerrard@gmail.com","username":"clay-gerrard"},"change_message_id":"ba4ed2c6f2abbc3f2f27db7109643482002a2603","unresolved":false,"context_lines":[{"line_number":1846,"context_line":"        # Check successful http_connection and exception with"},{"line_number":1847,"context_line":"        # incorrect pickle.loads(resp.read())"},{"line_number":1848,"context_line":"        resp.status \u003d 200"},{"line_number":1849,"context_line":"        resp.read.return_value \u003d \u0027garbage\u0027"},{"line_number":1850,"context_line":"        expect \u003d \u0027Error syncing with node: %r: \u0027"},{"line_number":1851,"context_line":"        for job in jobs:"},{"line_number":1852,"context_line":"            set_default(self)"}],"source_content_type":"text/x-python","patch_set":2,"id":"bf8cb3f7_894b9d57","line":1849,"updated":"2017-12-27 22:26:13.000000000","message":"The tests passes without this change still, but the difference is in the logging:\n\n    test-replicator ERROR: Error syncing with node: {\u0027index\u0027: 0, \u0027replication_port\u0027: 6200, \u0027zone\u0027: 2, \u0027ip\u0027: \u0027127.0.0.2\u0027, \u0027region\u0027: 3, \u0027port\u0027: 6200, \u0027replication_ip\u0027: \u0027127.0.0.2\u0027, \u0027device\u0027: \u0027sda\u0027, \u0027id\u0027: 2}: \n    Traceback (most recent call last):\n      File \"/home/ubuntu/swift/swift/obj/replicator.py\", line 448, in update\n        remote_hash \u003d pickle.loads(resp.read())\n    BadPickleGet: arbag\n\ninstead of on master:\n\n    test-replicator ERROR: Error syncing with node: {\u0027index\u0027: 0, \u0027replication_port\u0027: 6200, \u0027zone\u0027: 2, \u0027ip\u0027: \u0027127.0.0.2\u0027, \u0027region\u0027: 3, \u0027port\u0027: 6200, \u0027replication_ip\u0027: \u0027127.0.0.2\u0027, \u0027device\u0027: \u0027sda\u0027, \u0027id\u0027: 2}: \n    Traceback (most recent call last):\n      File \"/home/ubuntu/swift/swift/obj/replicator.py\", line 448, in update\n        remote_hash \u003d pickle.loads(resp.read())\n    TypeError: loads() argument 1 must be string, not MagicMock","commit_id":"61fe6aae81d00597c777a64ac337a8dfb990f0c2"}]}
