)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"ed205e98672e566bd7bc4a368be8beabfc41c28d","unresolved":false,"context_lines":[{"line_number":13,"context_line":"Since there is a problem with Mock()\u0027ing a system entry point (like"},{"line_number":14,"context_line":"os.unlink) there is an inherent instability in these tests. The safe"},{"line_number":15,"context_line":"way around this is to make write_config() accept arguments that can be"},{"line_number":16,"context_line":"Mock()\u0027ed for the purpose of testing."},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"Also, there was a redundant test that has been eliminated."},{"line_number":19,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"3a961159_44f6f291","line":16,"updated":"2014-12-29 08:47:23.000000000","message":"So are we writing the code just to write the tests.\nArguments being defined not to be used in the code but to be used for writing the tests looks objectionable, as the same would open the gates for all mocking being used in the code while writing tests to be coded similarly.","commit_id":"a19c49601ad93a9e92e66af7d47388c68205fec5"},{"author":{"_account_id":9664,"name":"amrith","email":"amrith.kumar@gmail.com","username":"amrith"},"change_message_id":"9a53e810d683dfac6cd383c8904f5d503e967c49","unresolved":false,"context_lines":[{"line_number":13,"context_line":"Since there is a problem with Mock()\u0027ing a system entry point (like"},{"line_number":14,"context_line":"os.unlink) there is an inherent instability in these tests. The safe"},{"line_number":15,"context_line":"way around this is to make write_config() accept arguments that can be"},{"line_number":16,"context_line":"Mock()\u0027ed for the purpose of testing."},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"Also, there was a redundant test that has been eliminated."},{"line_number":19,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":6,"id":"3a961159_8d02ba70","line":16,"in_reply_to":"3a961159_44f6f291","updated":"2014-12-29 14:33:12.000000000","message":"Sushi, it is called writing code that is testable. And this is the only way to write that portion of code to be testable that I could come up with.\n\nI don\u0027t understand what is objectionable about writing code that would include arguments that facilitate testing and yes, I do intend to make more code look like that just so that we can make the gate more predictable. Otherwise, remember that two test paths that choose to Mock() os.unlink have an implicit dependency on each other; they cannot run at the same time safely.\n\nIf you have other suggestions on how to make the code testable and also thread safe, I\u0027m all ears. Otherwise, your comment above is a stated opinion and not an undeniable fact and therefore isn\u0027t something that should warrant a -1 [IMHO].","commit_id":"a19c49601ad93a9e92e66af7d47388c68205fec5"}],"trove/guestagent/datastore/cassandra/service.py":[{"author":{"_account_id":13355,"name":"Edmond Kotowski","email":"ekotowski@gmail.com","username":"ekotowski"},"change_message_id":"1907d1584856e23d8989a10390b0e94bbfac6cb2","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        LOG.debug(\"Finished installing Cassandra server\")"},{"line_number":121,"context_line":""},{"line_number":122,"context_line":"    def write_config(self, config_contents,"},{"line_number":123,"context_line":"                     execute\u003dutils.execute_with_timeout,"},{"line_number":124,"context_line":"                     mktemp\u003dtempfile.mktemp,"},{"line_number":125,"context_line":"                     chmod\u003dos.chmod, unlink\u003dos.unlink):"},{"line_number":126,"context_line":"        temp_conf \u003d \u0027\u0027"}],"source_content_type":"text/x-python","patch_set":6,"id":"3a961159_135ef276","line":123,"updated":"2014-12-29 01:52:22.000000000","message":"(Optional) Rename \"execute\" param to \"execute_func\" to make it more obvious it is a function.","commit_id":"a19c49601ad93a9e92e66af7d47388c68205fec5"},{"author":{"_account_id":10725,"name":"Sergey Gotliv","email":"sgotliv@redhat.com","username":"sgotliv"},"change_message_id":"c5d0539dddb04672e06ec700c22b4a68edb6460c","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        LOG.debug(\"Finished installing Cassandra server\")"},{"line_number":121,"context_line":""},{"line_number":122,"context_line":"    def write_config(self, config_contents,"},{"line_number":123,"context_line":"                     execute_function\u003dutils.execute_with_timeout,"},{"line_number":124,"context_line":"                     mktemp\u003dtempfile.mktemp,"},{"line_number":125,"context_line":"                     chmod\u003dos.chmod, unlink\u003dos.unlink):"},{"line_number":126,"context_line":"        temp_conf \u003d \u0027\u0027"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a961159_9c166657","line":123,"updated":"2014-12-29 19:18:21.000000000","message":"Why you have to mock trove utils that way? According to the commit message the problem exists for \"os\" module only.","commit_id":"a53bf10c078aba2fff3bbf4588390bd6a1931091"},{"author":{"_account_id":9664,"name":"amrith","email":"amrith.kumar@gmail.com","username":"amrith"},"change_message_id":"4ad2baee3bf1bb71d4b687dec0a5877c5b57b9eb","unresolved":false,"context_lines":[{"line_number":120,"context_line":"        LOG.debug(\"Finished installing Cassandra server\")"},{"line_number":121,"context_line":""},{"line_number":122,"context_line":"    def write_config(self, config_contents,"},{"line_number":123,"context_line":"                     execute_function\u003dutils.execute_with_timeout,"},{"line_number":124,"context_line":"                     mktemp\u003dtempfile.mktemp,"},{"line_number":125,"context_line":"                     chmod\u003dos.chmod, unlink\u003dos.unlink):"},{"line_number":126,"context_line":"        temp_conf \u003d \u0027\u0027"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a961159_4298986a","line":123,"in_reply_to":"3a961159_9c166657","updated":"2014-12-29 19:56:00.000000000","message":"Same problem, other threads use execute_with_timeout. The issue is for a modules that is used in multiple threads.","commit_id":"a53bf10c078aba2fff3bbf4588390bd6a1931091"},{"author":{"_account_id":10725,"name":"Sergey Gotliv","email":"sgotliv@redhat.com","username":"sgotliv"},"change_message_id":"c5d0539dddb04672e06ec700c22b4a68edb6460c","unresolved":false,"context_lines":[{"line_number":121,"context_line":""},{"line_number":122,"context_line":"    def write_config(self, config_contents,"},{"line_number":123,"context_line":"                     execute_function\u003dutils.execute_with_timeout,"},{"line_number":124,"context_line":"                     mktemp\u003dtempfile.mktemp,"},{"line_number":125,"context_line":"                     chmod\u003dos.chmod, unlink\u003dos.unlink):"},{"line_number":126,"context_line":"        temp_conf \u003d \u0027\u0027"},{"line_number":127,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"3a961159_bc2ec2f8","line":124,"updated":"2014-12-29 19:18:21.000000000","message":"tempfile.mktemp is deprecated since Python 2.3... Please, consider to use mkstemp.","commit_id":"a53bf10c078aba2fff3bbf4588390bd6a1931091"},{"author":{"_account_id":9664,"name":"amrith","email":"amrith.kumar@gmail.com","username":"amrith"},"change_message_id":"dceed1b00b230629df983459305851dabad6c611","unresolved":false,"context_lines":[{"line_number":121,"context_line":""},{"line_number":122,"context_line":"    def write_config(self, config_contents,"},{"line_number":123,"context_line":"                     execute_function\u003dutils.execute_with_timeout,"},{"line_number":124,"context_line":"                     mktemp\u003dtempfile.mktemp,"},{"line_number":125,"context_line":"                     chmod\u003dos.chmod, unlink\u003dos.unlink):"},{"line_number":126,"context_line":"        temp_conf \u003d \u0027\u0027"},{"line_number":127,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"3a961159_621034a9","line":124,"in_reply_to":"3a961159_bc2ec2f8","updated":"2014-12-29 19:59:56.000000000","message":"Yes, I should do this. I\u0027ll use mkstemp.","commit_id":"a53bf10c078aba2fff3bbf4588390bd6a1931091"},{"author":{"_account_id":10725,"name":"Sergey Gotliv","email":"sgotliv@redhat.com","username":"sgotliv"},"change_message_id":"c5d0539dddb04672e06ec700c22b4a68edb6460c","unresolved":false,"context_lines":[{"line_number":126,"context_line":"        temp_conf \u003d \u0027\u0027"},{"line_number":127,"context_line":""},{"line_number":128,"context_line":"        try:"},{"line_number":129,"context_line":"            temp_conf \u003d mktemp()"},{"line_number":130,"context_line":""},{"line_number":131,"context_line":"            LOG.debug(\u0027Defining temporary configuration at %s.\u0027 %"},{"line_number":132,"context_line":"                      temp_conf)"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a961159_7c445ab7","line":129,"updated":"2014-12-29 19:18:21.000000000","message":"You probably can move it out of the try/except block, if it fails trying to unlink it will probably fail as well.","commit_id":"a53bf10c078aba2fff3bbf4588390bd6a1931091"},{"author":{"_account_id":10725,"name":"Sergey Gotliv","email":"sgotliv@redhat.com","username":"sgotliv"},"change_message_id":"c5d0539dddb04672e06ec700c22b4a68edb6460c","unresolved":false,"context_lines":[{"line_number":132,"context_line":"                      temp_conf)"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"            with open(temp_conf, \u0027w+\u0027) as conf:"},{"line_number":135,"context_line":"                chmod(temp_conf, stat.S_IRUSR | stat.S_IWUSR)"},{"line_number":136,"context_line":"                conf.write(config_contents)"},{"line_number":137,"context_line":""},{"line_number":138,"context_line":"            LOG.info(_(\u0027Writing new Cassandra configuration.\u0027))"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a961159_dc39cef3","line":135,"updated":"2014-12-29 19:18:21.000000000","message":"1. Why \"chmod\" is needed?\n\n2. Just in case its really needed, please consider to do that right after the file was created.","commit_id":"a53bf10c078aba2fff3bbf4588390bd6a1931091"},{"author":{"_account_id":10725,"name":"Sergey Gotliv","email":"sgotliv@redhat.com","username":"sgotliv"},"change_message_id":"e7e4a8a82f91b53386b9f0e4ae7bb747d1924ef1","unresolved":false,"context_lines":[{"line_number":132,"context_line":"                      temp_conf)"},{"line_number":133,"context_line":""},{"line_number":134,"context_line":"            with open(temp_conf, \u0027w+\u0027) as conf:"},{"line_number":135,"context_line":"                chmod(temp_conf, stat.S_IRUSR | stat.S_IWUSR)"},{"line_number":136,"context_line":"                conf.write(config_contents)"},{"line_number":137,"context_line":""},{"line_number":138,"context_line":"            LOG.info(_(\u0027Writing new Cassandra configuration.\u0027))"}],"source_content_type":"text/x-python","patch_set":14,"id":"3a961159_222aac7e","line":135,"in_reply_to":"3a961159_dc39cef3","updated":"2014-12-29 19:21:56.000000000","message":"Regarding 2 is probably my bad, because file doesn\u0027t exists before.","commit_id":"a53bf10c078aba2fff3bbf4588390bd6a1931091"},{"author":{"_account_id":10725,"name":"Sergey Gotliv","email":"sgotliv@redhat.com","username":"sgotliv"},"change_message_id":"c5d0539dddb04672e06ec700c22b4a68edb6460c","unresolved":false,"context_lines":[{"line_number":141,"context_line":"                             temp_conf,"},{"line_number":142,"context_line":"                             system.CASSANDRA_CONF)"},{"line_number":143,"context_line":""},{"line_number":144,"context_line":"        except Exception:"},{"line_number":145,"context_line":"            unlink(temp_conf)"},{"line_number":146,"context_line":"            raise"},{"line_number":147,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"3a961159_7c71ba43","line":144,"updated":"2014-12-29 19:18:21.000000000","message":"1. I think that \"finally\" instead of except/re-raise is more appropriate here.\n\n2. \"unlink\" can throw an Exception...","commit_id":"a53bf10c078aba2fff3bbf4588390bd6a1931091"},{"author":{"_account_id":9664,"name":"amrith","email":"amrith.kumar@gmail.com","username":"amrith"},"change_message_id":"4ad2baee3bf1bb71d4b687dec0a5877c5b57b9eb","unresolved":false,"context_lines":[{"line_number":141,"context_line":"                             temp_conf,"},{"line_number":142,"context_line":"                             system.CASSANDRA_CONF)"},{"line_number":143,"context_line":""},{"line_number":144,"context_line":"        except Exception:"},{"line_number":145,"context_line":"            unlink(temp_conf)"},{"line_number":146,"context_line":"            raise"},{"line_number":147,"context_line":""}],"source_content_type":"text/x-python","patch_set":14,"id":"3a961159_0203f076","line":144,"in_reply_to":"3a961159_7c71ba43","updated":"2014-12-29 19:56:00.000000000","message":"No, not finally! Only if there is an exception. If there\u0027s no exception we\u0027d move the file ;)\n\n2. Yes, unlink can thrown an exception.","commit_id":"a53bf10c078aba2fff3bbf4588390bd6a1931091"},{"author":{"_account_id":10725,"name":"Sergey Gotliv","email":"sgotliv@redhat.com","username":"sgotliv"},"change_message_id":"c424b18adad708dc6c1b873939df0b22aca9c3db","unresolved":false,"context_lines":[{"line_number":124,"context_line":"                     unlink\u003dos.unlink):"},{"line_number":125,"context_line":""},{"line_number":126,"context_line":"        conf_name \u003d \u0027\u0027"},{"line_number":127,"context_line":"        conf_handle \u003d 0"},{"line_number":128,"context_line":""},{"line_number":129,"context_line":"        # first securely create a temp file. mkstemp() will set"},{"line_number":130,"context_line":"        # os.O_EXCL on the open() call, and we get a file with"}],"source_content_type":"text/x-python","patch_set":15,"id":"3a961159_d78b6066","line":127,"updated":"2014-12-30 08:18:49.000000000","message":"1. You don\u0027t need this, conf_name and conf_handle will be initialized anyway.\n\n2. Technically Its not a conf_name its a path.\n\n3. conf_handle is actually fd(more standard way to call file descriptors).","commit_id":"43e643d153a74e2f4975e14648964c062106bb3f"},{"author":{"_account_id":9664,"name":"amrith","email":"amrith.kumar@gmail.com","username":"amrith"},"change_message_id":"e28e07db4c7ac6f8846bed5600b203ad37140f76","unresolved":false,"context_lines":[{"line_number":124,"context_line":"                     unlink\u003dos.unlink):"},{"line_number":125,"context_line":""},{"line_number":126,"context_line":"        conf_name \u003d \u0027\u0027"},{"line_number":127,"context_line":"        conf_handle \u003d 0"},{"line_number":128,"context_line":""},{"line_number":129,"context_line":"        # first securely create a temp file. mkstemp() will set"},{"line_number":130,"context_line":"        # os.O_EXCL on the open() call, and we get a file with"}],"source_content_type":"text/x-python","patch_set":15,"id":"3a961159_58a15c94","line":127,"in_reply_to":"3a961159_d78b6066","updated":"2014-12-30 13:12:45.000000000","message":"At some point i needed them, not sure any longer why that was the case, something to do with scoping. but now it is no longer needed. Done.","commit_id":"43e643d153a74e2f4975e14648964c062106bb3f"},{"author":{"_account_id":10725,"name":"Sergey Gotliv","email":"sgotliv@redhat.com","username":"sgotliv"},"change_message_id":"c424b18adad708dc6c1b873939df0b22aca9c3db","unresolved":false,"context_lines":[{"line_number":130,"context_line":"        # os.O_EXCL on the open() call, and we get a file with"},{"line_number":131,"context_line":"        # permissions of 600 by default."},{"line_number":132,"context_line":"        try:"},{"line_number":133,"context_line":"            (conf_handle, conf_name) \u003d mkstemp()"},{"line_number":134,"context_line":"        except Exception:"},{"line_number":135,"context_line":"            LOG.exception(_(\"Could not create a temporary file.\"))"},{"line_number":136,"context_line":"            raise"}],"source_content_type":"text/x-python","patch_set":15,"id":"3a961159_377bc47c","line":133,"updated":"2014-12-30 08:18:49.000000000","message":"Consider to remove this try/except block, it only prints a custom exception message in the log which doesn\u0027t provide any additional info and you re-raise the exception anyway.","commit_id":"43e643d153a74e2f4975e14648964c062106bb3f"},{"author":{"_account_id":9664,"name":"amrith","email":"amrith.kumar@gmail.com","username":"amrith"},"change_message_id":"e28e07db4c7ac6f8846bed5600b203ad37140f76","unresolved":false,"context_lines":[{"line_number":130,"context_line":"        # os.O_EXCL on the open() call, and we get a file with"},{"line_number":131,"context_line":"        # permissions of 600 by default."},{"line_number":132,"context_line":"        try:"},{"line_number":133,"context_line":"            (conf_handle, conf_name) \u003d mkstemp()"},{"line_number":134,"context_line":"        except Exception:"},{"line_number":135,"context_line":"            LOG.exception(_(\"Could not create a temporary file.\"))"},{"line_number":136,"context_line":"            raise"}],"source_content_type":"text/x-python","patch_set":15,"id":"3a961159_789e1856","line":133,"in_reply_to":"3a961159_377bc47c","updated":"2014-12-30 13:12:45.000000000","message":"Done","commit_id":"43e643d153a74e2f4975e14648964c062106bb3f"},{"author":{"_account_id":10725,"name":"Sergey Gotliv","email":"sgotliv@redhat.com","username":"sgotliv"},"change_message_id":"c424b18adad708dc6c1b873939df0b22aca9c3db","unresolved":false,"context_lines":[{"line_number":142,"context_line":"        # error. only unlink if there is a problem. In normal course,"},{"line_number":143,"context_line":"        # we move the file."},{"line_number":144,"context_line":"        try:"},{"line_number":145,"context_line":"            os.write(conf_handle, config_contents)"},{"line_number":146,"context_line":"            os.close(conf_handle)"},{"line_number":147,"context_line":"            execute_function(\"sudo\", \"mv\", conf_name, system.CASSANDRA_CONF)"},{"line_number":148,"context_line":"        except Exception:"}],"source_content_type":"text/x-python","patch_set":15,"id":"3a961159_979e3853","line":145,"updated":"2014-12-30 08:18:49.000000000","message":"If os.write raises then fd will remain opened even after os.unlink.","commit_id":"43e643d153a74e2f4975e14648964c062106bb3f"},{"author":{"_account_id":9664,"name":"amrith","email":"amrith.kumar@gmail.com","username":"amrith"},"change_message_id":"e28e07db4c7ac6f8846bed5600b203ad37140f76","unresolved":false,"context_lines":[{"line_number":142,"context_line":"        # error. only unlink if there is a problem. In normal course,"},{"line_number":143,"context_line":"        # we move the file."},{"line_number":144,"context_line":"        try:"},{"line_number":145,"context_line":"            os.write(conf_handle, config_contents)"},{"line_number":146,"context_line":"            os.close(conf_handle)"},{"line_number":147,"context_line":"            execute_function(\"sudo\", \"mv\", conf_name, system.CASSANDRA_CONF)"},{"line_number":148,"context_line":"        except Exception:"}],"source_content_type":"text/x-python","patch_set":15,"id":"3a961159_b8a88078","line":145,"in_reply_to":"3a961159_979e3853","updated":"2014-12-30 13:12:45.000000000","message":"Done","commit_id":"43e643d153a74e2f4975e14648964c062106bb3f"},{"author":{"_account_id":10725,"name":"Sergey Gotliv","email":"sgotliv@redhat.com","username":"sgotliv"},"change_message_id":"c424b18adad708dc6c1b873939df0b22aca9c3db","unresolved":false,"context_lines":[{"line_number":143,"context_line":"        # we move the file."},{"line_number":144,"context_line":"        try:"},{"line_number":145,"context_line":"            os.write(conf_handle, config_contents)"},{"line_number":146,"context_line":"            os.close(conf_handle)"},{"line_number":147,"context_line":"            execute_function(\"sudo\", \"mv\", conf_name, system.CASSANDRA_CONF)"},{"line_number":148,"context_line":"        except Exception:"},{"line_number":149,"context_line":"            unlink(conf_name)"}],"source_content_type":"text/x-python","patch_set":15,"id":"3a961159_57b850e5","line":146,"updated":"2014-12-30 08:18:49.000000000","message":"You use os.write and os.close directly but os.unlink and utils... via parameters, I find it very confusing.","commit_id":"43e643d153a74e2f4975e14648964c062106bb3f"},{"author":{"_account_id":9664,"name":"amrith","email":"amrith.kumar@gmail.com","username":"amrith"},"change_message_id":"e28e07db4c7ac6f8846bed5600b203ad37140f76","unresolved":false,"context_lines":[{"line_number":143,"context_line":"        # we move the file."},{"line_number":144,"context_line":"        try:"},{"line_number":145,"context_line":"            os.write(conf_handle, config_contents)"},{"line_number":146,"context_line":"            os.close(conf_handle)"},{"line_number":147,"context_line":"            execute_function(\"sudo\", \"mv\", conf_name, system.CASSANDRA_CONF)"},{"line_number":148,"context_line":"        except Exception:"},{"line_number":149,"context_line":"            unlink(conf_name)"}],"source_content_type":"text/x-python","patch_set":15,"id":"3a961159_b8bfa0a9","line":146,"in_reply_to":"3a961159_57b850e5","updated":"2014-12-30 13:12:45.000000000","message":"I\u0027ve tried and rename the functions to help.","commit_id":"43e643d153a74e2f4975e14648964c062106bb3f"},{"author":{"_account_id":10725,"name":"Sergey Gotliv","email":"sgotliv@redhat.com","username":"sgotliv"},"change_message_id":"c424b18adad708dc6c1b873939df0b22aca9c3db","unresolved":false,"context_lines":[{"line_number":146,"context_line":"            os.close(conf_handle)"},{"line_number":147,"context_line":"            execute_function(\"sudo\", \"mv\", conf_name, system.CASSANDRA_CONF)"},{"line_number":148,"context_line":"        except Exception:"},{"line_number":149,"context_line":"            unlink(conf_name)"},{"line_number":150,"context_line":"            LOG.exception("},{"line_number":151,"context_line":"                _(\"Exception generating Cassandra configuration %s.\") %"},{"line_number":152,"context_line":"                conf_name)"}],"source_content_type":"text/x-python","patch_set":15,"id":"3a961159_d7a8c079","line":149,"updated":"2014-12-30 08:18:49.000000000","message":"If unlink raises we\u0027ll never see an exception message in the line 150. You probably should change the order (message, unlink).","commit_id":"43e643d153a74e2f4975e14648964c062106bb3f"},{"author":{"_account_id":9664,"name":"amrith","email":"amrith.kumar@gmail.com","username":"amrith"},"change_message_id":"e28e07db4c7ac6f8846bed5600b203ad37140f76","unresolved":false,"context_lines":[{"line_number":146,"context_line":"            os.close(conf_handle)"},{"line_number":147,"context_line":"            execute_function(\"sudo\", \"mv\", conf_name, system.CASSANDRA_CONF)"},{"line_number":148,"context_line":"        except Exception:"},{"line_number":149,"context_line":"            unlink(conf_name)"},{"line_number":150,"context_line":"            LOG.exception("},{"line_number":151,"context_line":"                _(\"Exception generating Cassandra configuration %s.\") %"},{"line_number":152,"context_line":"                conf_name)"}],"source_content_type":"text/x-python","patch_set":15,"id":"3a961159_f8e048ce","line":149,"in_reply_to":"3a961159_d7a8c079","updated":"2014-12-30 13:12:45.000000000","message":"Done","commit_id":"43e643d153a74e2f4975e14648964c062106bb3f"}],"trove/tests/unittests/guestagent/test_dbaas.py":[{"author":{"_account_id":8415,"name":"Denis M.","email":"lildee1991@gmail.com","username":"dmakogon"},"change_message_id":"079afbc65ecce0e1631efad8faead6fea08b016a","unresolved":false,"context_lines":[{"line_number":1577,"context_line":"        # method properly invoked execute, but also that it properly"},{"line_number":1578,"context_line":"        # attempted to unlink the file (as a result of the exception)"},{"line_number":1579,"context_line":"        from trove.common.exception import ProcessExecutionError"},{"line_number":1580,"context_line":"        execute_with_timeout \u003d Mock(side_effect\u003dProcessExecutionError(\u0027some exception\u0027))"},{"line_number":1581,"context_line":"        local_unlink \u003d Mock(return_value\u003d0)"},{"line_number":1582,"context_line":"        temporary_config_file \u003d \u0027/tmp/test_cassandra_error_in_write_config_verify_unlink\u0027"},{"line_number":1583,"context_line":"        configuration \u003d \u0027this is my configuration\u0027"}],"source_content_type":"text/x-python","patch_set":3,"id":"5a890539_7bbbd40e","line":1580,"updated":"2014-12-04 08:25:05.000000000","message":"2014-12-03 20:52:32.728 | ./trove/tests/unittests/guestagent/test_dbaas.py:1580:80: E501 line too long (88 \u003e 79 characters)","commit_id":"f799f7862d59480ba6a6c2a66fd63af2ed5a098f"},{"author":{"_account_id":8415,"name":"Denis M.","email":"lildee1991@gmail.com","username":"dmakogon"},"change_message_id":"079afbc65ecce0e1631efad8faead6fea08b016a","unresolved":false,"context_lines":[{"line_number":1579,"context_line":"        from trove.common.exception import ProcessExecutionError"},{"line_number":1580,"context_line":"        execute_with_timeout \u003d Mock(side_effect\u003dProcessExecutionError(\u0027some exception\u0027))"},{"line_number":1581,"context_line":"        local_unlink \u003d Mock(return_value\u003d0)"},{"line_number":1582,"context_line":"        temporary_config_file \u003d \u0027/tmp/test_cassandra_error_in_write_config_verify_unlink\u0027"},{"line_number":1583,"context_line":"        configuration \u003d \u0027this is my configuration\u0027"},{"line_number":1584,"context_line":""},{"line_number":1585,"context_line":"        self.assertRaises(ProcessExecutionError,"}],"source_content_type":"text/x-python","patch_set":3,"id":"5a890539_bb38dca0","line":1582,"updated":"2014-12-04 08:25:05.000000000","message":"./trove/tests/unittests/guestagent/test_dbaas.py:1582:80: E501 line too long (89 \u003e 79 characters)","commit_id":"f799f7862d59480ba6a6c2a66fd63af2ed5a098f"},{"author":{"_account_id":13355,"name":"Edmond Kotowski","email":"ekotowski@gmail.com","username":"ekotowski"},"change_message_id":"1907d1584856e23d8989a10390b0e94bbfac6cb2","unresolved":false,"context_lines":[{"line_number":1591,"context_line":"                          mktemp\u003dMock(return_value\u003dtemporary_config_file),"},{"line_number":1592,"context_line":"                          unlink\u003dlocal_unlink)"},{"line_number":1593,"context_line":""},{"line_number":1594,"context_line":"        self.assertEqual(execute_with_timeout.call_count, 1)"},{"line_number":1595,"context_line":"        self.assertEqual(local_unlink.call_count, 1)"},{"line_number":1596,"context_line":""},{"line_number":1597,"context_line":"        # really delete the temporary_config_file"}],"source_content_type":"text/x-python","patch_set":6,"id":"3a961159_d3caaa19","line":1594,"updated":"2014-12-29 01:52:22.000000000","message":"This assert is redundant considering you are already asserting the ProcessExecutionError from execute_with_time_out function.","commit_id":"a19c49601ad93a9e92e66af7d47388c68205fec5"},{"author":{"_account_id":9664,"name":"amrith","email":"amrith.kumar@gmail.com","username":"amrith"},"change_message_id":"43499498603967bc7cf0eae7b5302e3d71d47f4d","unresolved":false,"context_lines":[{"line_number":1591,"context_line":"                          mktemp\u003dMock(return_value\u003dtemporary_config_file),"},{"line_number":1592,"context_line":"                          unlink\u003dlocal_unlink)"},{"line_number":1593,"context_line":""},{"line_number":1594,"context_line":"        self.assertEqual(execute_with_timeout.call_count, 1)"},{"line_number":1595,"context_line":"        self.assertEqual(local_unlink.call_count, 1)"},{"line_number":1596,"context_line":""},{"line_number":1597,"context_line":"        # really delete the temporary_config_file"}],"source_content_type":"text/x-python","patch_set":6,"id":"3a961159_6d1bceca","line":1594,"in_reply_to":"3a961159_d3caaa19","updated":"2014-12-29 14:37:24.000000000","message":"Yup, good catch.","commit_id":"a19c49601ad93a9e92e66af7d47388c68205fec5"}]}
