)]}'
{"trove/taskmanager/models.py":[{"author":{"_account_id":13355,"name":"Edmond Kotowski","email":"ekotowski@gmail.com","username":"ekotowski"},"change_message_id":"dcd882cfb46c9460df4473e7e8b2fb3dffdcd223","unresolved":false,"context_lines":[{"line_number":912,"context_line":""},{"line_number":913,"context_line":"        # If volume has been resized it must be manually removed in cinder"},{"line_number":914,"context_line":"        try:"},{"line_number":915,"context_line":"            volume_client \u003d create_cinder_client(self.context)"},{"line_number":916,"context_line":"            volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":917,"context_line":"            if volume.status \u003d\u003d \"available\":"},{"line_number":918,"context_line":"                LOG.debug(\"Deleting volume for instance: %s\" % self.id)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a961159_1721254d","line":915,"updated":"2014-12-10 17:41:21.000000000","message":"Create the cinder client in the constructor of the class. If we ever want to unit test the delete_resources method in the future, it won\u0027t require us to have a real cinder client and we can mock it out.","commit_id":"39885ab2ec7ef75519e480e3528c62e4ffa5e0d3"},{"author":{"_account_id":11783,"name":"Shayne Burgess","email":"shayne.burgess@hp.com","username":"shayne-burgess"},"change_message_id":"a1801d599269d16a6587082256fabf3cf2ba8364","unresolved":false,"context_lines":[{"line_number":912,"context_line":""},{"line_number":913,"context_line":"        # If volume has been resized it must be manually removed in cinder"},{"line_number":914,"context_line":"        try:"},{"line_number":915,"context_line":"            volume_client \u003d create_cinder_client(self.context)"},{"line_number":916,"context_line":"            volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":917,"context_line":"            if volume.status \u003d\u003d \"available\":"},{"line_number":918,"context_line":"                LOG.debug(\"Deleting volume for instance: %s\" % self.id)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a961159_85b95817","line":915,"in_reply_to":"3a961159_1721254d","updated":"2014-12-10 22:44:09.000000000","message":"Fair point but it looks like we are creating cinder clients everywhere. We would need to refactor more than just this line too accomplish what you are suggesting.","commit_id":"39885ab2ec7ef75519e480e3528c62e4ffa5e0d3"},{"author":{"_account_id":13355,"name":"Edmond Kotowski","email":"ekotowski@gmail.com","username":"ekotowski"},"change_message_id":"5ad243ff41fdabaf33240fb2bc7e1df710e967ef","unresolved":false,"context_lines":[{"line_number":912,"context_line":""},{"line_number":913,"context_line":"        # If volume has been resized it must be manually removed in cinder"},{"line_number":914,"context_line":"        try:"},{"line_number":915,"context_line":"            volume_client \u003d create_cinder_client(self.context)"},{"line_number":916,"context_line":"            volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":917,"context_line":"            if volume.status \u003d\u003d \"available\":"},{"line_number":918,"context_line":"                LOG.debug(\"Deleting volume for instance: %s\" % self.id)"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a961159_00442419","line":915,"in_reply_to":"3a961159_85b95817","updated":"2014-12-12 22:37:59.000000000","message":"Agree, do not need to change this because that refactor is out of scope for this patch.","commit_id":"39885ab2ec7ef75519e480e3528c62e4ffa5e0d3"},{"author":{"_account_id":8415,"name":"Denis M.","email":"lildee1991@gmail.com","username":"dmakogon"},"change_message_id":"37f7c12bf904908d34607106fbe163295005e8da","unresolved":false,"context_lines":[{"line_number":917,"context_line":"            if volume.status \u003d\u003d \"available\":"},{"line_number":918,"context_line":"                LOG.debug(\"Deleting volume for instance: %s\" % self.id)"},{"line_number":919,"context_line":"                volume.delete()"},{"line_number":920,"context_line":"                LOG.debug(\"Deleted volume: %s\" % self.volume_id)"},{"line_number":921,"context_line":"        except Exception as ex:"},{"line_number":922,"context_line":"            LOG.exception(_(\"Error deleting volume of instance %(id)s: \""},{"line_number":923,"context_line":"                            \"%(ex)s\") % {\u0027id\u0027: self.db_info.id, \u0027ex\u0027: ex})"}],"source_content_type":"text/x-python","patch_set":2,"id":"3a961159_0e7c92eb","line":920,"updated":"2014-12-11 14:11:44.000000000","message":"this two debug log calls can be merged into one","commit_id":"39885ab2ec7ef75519e480e3528c62e4ffa5e0d3"},{"author":{"_account_id":8415,"name":"Denis M.","email":"lildee1991@gmail.com","username":"dmakogon"},"change_message_id":"37f7c12bf904908d34607106fbe163295005e8da","unresolved":false,"context_lines":[{"line_number":918,"context_line":"                LOG.debug(\"Deleting volume for instance: %s\" % self.id)"},{"line_number":919,"context_line":"                volume.delete()"},{"line_number":920,"context_line":"                LOG.debug(\"Deleted volume: %s\" % self.volume_id)"},{"line_number":921,"context_line":"        except Exception as ex:"},{"line_number":922,"context_line":"            LOG.exception(_(\"Error deleting volume of instance %(id)s: \""},{"line_number":923,"context_line":"                            \"%(ex)s\") % {\u0027id\u0027: self.db_info.id, \u0027ex\u0027: ex})"},{"line_number":924,"context_line":""}],"source_content_type":"text/x-python","patch_set":2,"id":"3a961159_6e10b6a8","line":921,"updated":"2014-12-11 14:11:44.000000000","message":"As for me, we should not expect too broad exception, if you know the list of exception that may take its place here, please add then instead Exception class","commit_id":"39885ab2ec7ef75519e480e3528c62e4ffa5e0d3"},{"author":{"_account_id":8214,"name":"Auston McReynolds","email":"amcreynolds@ebaysf.com","username":"amcreynolds"},"change_message_id":"a9bc35c71e6cdd5732f5a7a0ce06fe89c013fc8c","unresolved":false,"context_lines":[{"line_number":910,"context_line":"                            \"Timeout deleting compute server %(server_id)s\") %"},{"line_number":911,"context_line":"                          {\u0027instance_id\u0027: self.id, \u0027server_id\u0027: server_id})"},{"line_number":912,"context_line":""},{"line_number":913,"context_line":"        # If volume has been resized it must be manually removed in cinder"},{"line_number":914,"context_line":"        try:"},{"line_number":915,"context_line":"            volume_client \u003d create_cinder_client(self.context)"},{"line_number":916,"context_line":"            volume \u003d volume_client.volumes.get(self.volume_id)"}],"source_content_type":"text/x-python","patch_set":4,"id":"3a961159_9fb22004","line":913,"updated":"2014-12-23 21:07:07.000000000","message":"if volume support is not turned on, this logic logs \"error deleting volume of instance\", which is extremely misleading considering there is no volume.\n\ncan the logic be amended to check for a volume_id prior to attempting the client get \u0026 delete?","commit_id":"45cdebfb08bb83594d7c4a949c1f06732699273b"},{"author":{"_account_id":13355,"name":"Edmond Kotowski","email":"ekotowski@gmail.com","username":"ekotowski"},"change_message_id":"5726b7904e647b481a89c18dd9ddc0d7cefebc2f","unresolved":false,"context_lines":[{"line_number":914,"context_line":"        try:"},{"line_number":915,"context_line":"            volume_client \u003d create_cinder_client(self.context)"},{"line_number":916,"context_line":"            volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":917,"context_line":"            if volume.status \u003d\u003d \"available\":"},{"line_number":918,"context_line":"                LOG.debug(\"Deleting volume %(v)s for instance: %(i)s\" %"},{"line_number":919,"context_line":"                          {\u0027i\u0027: self.id, \u0027v\u0027: self.volume_id})"},{"line_number":920,"context_line":"                volume.delete()"}],"source_content_type":"text/x-python","patch_set":4,"id":"3a961159_cfb7b638","line":917,"updated":"2014-12-22 21:47:12.000000000","message":"Is there a case here when the nova instance gets removed and the volume status could still be \"in-use\" when it goes over this code? Would there be any benefit in having something like this: \n\n        def volume_available():\n            volume \u003d self.instance.volume_client.volumes.get(\n                self.instance.volume_id)\n            return volume.status \u003d\u003d \u0027available\u0027\n        utils.poll_until(volume_available,\n                         sleep_time\u003d2,\n                         time_out\u003dCONF.volume_time_out)\n\nThat way we make sure we get an available status and avoid any possible race condition when the cinder volume could status could still be in-use?","commit_id":"45cdebfb08bb83594d7c4a949c1f06732699273b"},{"author":{"_account_id":13355,"name":"Edmond Kotowski","email":"ekotowski@gmail.com","username":"ekotowski"},"change_message_id":"a150f0ec50cf9dfd1697d994adf7c0a501e0f7be","unresolved":false,"context_lines":[{"line_number":914,"context_line":"        try:"},{"line_number":915,"context_line":"            volume_client \u003d create_cinder_client(self.context)"},{"line_number":916,"context_line":"            volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":917,"context_line":"            if volume.status \u003d\u003d \"available\":"},{"line_number":918,"context_line":"                LOG.debug(\"Deleting volume %(v)s for instance: %(i)s\" %"},{"line_number":919,"context_line":"                          {\u0027i\u0027: self.id, \u0027v\u0027: self.volume_id})"},{"line_number":920,"context_line":"                volume.delete()"}],"source_content_type":"text/x-python","patch_set":4,"id":"3a961159_724e8c39","line":917,"in_reply_to":"3a961159_1ec71946","updated":"2014-12-23 19:33:22.000000000","message":"Sounds good was just making sure we have thought about this case. Wasn\u0027t sure if nova already polled cinder after it deletes.","commit_id":"45cdebfb08bb83594d7c4a949c1f06732699273b"},{"author":{"_account_id":8415,"name":"Denis M.","email":"lildee1991@gmail.com","username":"dmakogon"},"change_message_id":"c316b5eb0caeb1daa5d1cc037435ecfd450e6ed8","unresolved":false,"context_lines":[{"line_number":914,"context_line":"        try:"},{"line_number":915,"context_line":"            volume_client \u003d create_cinder_client(self.context)"},{"line_number":916,"context_line":"            volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":917,"context_line":"            if volume.status \u003d\u003d \"available\":"},{"line_number":918,"context_line":"                LOG.debug(\"Deleting volume %(v)s for instance: %(i)s\" %"},{"line_number":919,"context_line":"                          {\u0027i\u0027: self.id, \u0027v\u0027: self.volume_id})"},{"line_number":920,"context_line":"                volume.delete()"}],"source_content_type":"text/x-python","patch_set":4,"id":"3a961159_edd8f054","line":917,"in_reply_to":"3a961159_cfb7b638","updated":"2014-12-23 11:30:54.000000000","message":"It seems like Nova would not allow such case, if compute instance still exist then volume will be in \"in-use\" status, but once compute instance would be completely gone, volume would be in \"available\" state.","commit_id":"45cdebfb08bb83594d7c4a949c1f06732699273b"},{"author":{"_account_id":11783,"name":"Shayne Burgess","email":"shayne.burgess@hp.com","username":"shayne-burgess"},"change_message_id":"10c2d2a2cf0fa171d254e3b141de85dd576eb0b6","unresolved":false,"context_lines":[{"line_number":914,"context_line":"        try:"},{"line_number":915,"context_line":"            volume_client \u003d create_cinder_client(self.context)"},{"line_number":916,"context_line":"            volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":917,"context_line":"            if volume.status \u003d\u003d \"available\":"},{"line_number":918,"context_line":"                LOG.debug(\"Deleting volume %(v)s for instance: %(i)s\" %"},{"line_number":919,"context_line":"                          {\u0027i\u0027: self.id, \u0027v\u0027: self.volume_id})"},{"line_number":920,"context_line":"                volume.delete()"}],"source_content_type":"text/x-python","patch_set":4,"id":"3a961159_1ec71946","line":917,"in_reply_to":"3a961159_edd8f054","updated":"2014-12-23 17:50:59.000000000","message":"I agree with Denis\u0027 comment. As well I considered polling for the volume state as you suggest but we already poll for the instance delete above and the volume should be marked available at the same time the instance is deleted so polling again here is unnecessary.","commit_id":"45cdebfb08bb83594d7c4a949c1f06732699273b"},{"author":{"_account_id":14009,"name":"Dan Ritchie","email":"dan.ritchie@hp.com","username":"danr"},"change_message_id":"15b35316612726174d1bdd1ba78cfb957076b859","unresolved":false,"context_lines":[{"line_number":916,"context_line":"            if self.volume_support:"},{"line_number":917,"context_line":"                volume_client \u003d create_cinder_client(self.context)"},{"line_number":918,"context_line":"                volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":919,"context_line":"                if volume.status \u003d\u003d \"available\":"},{"line_number":920,"context_line":"                    LOG.debug(\"Deleting volume %(v)s for instance: %(i)s\""},{"line_number":921,"context_line":"                              % {\u0027i\u0027: self.id, \u0027v\u0027: self.volume_id})"},{"line_number":922,"context_line":"                    volume.delete()"}],"source_content_type":"text/x-python","patch_set":5,"id":"3a961159_54dd4013","line":919,"updated":"2015-01-06 17:31:30.000000000","message":"Can we add a null check on volume before dereferencing it?  If it has been deleted and comes back null, we\u0027ll catch the exception here and report an error deleting the volume when it was actually successfully deleted.","commit_id":"8778a17535036ceba554eff235e2b6d9449ad883"},{"author":{"_account_id":8214,"name":"Auston McReynolds","email":"amcreynolds@ebaysf.com","username":"amcreynolds"},"change_message_id":"55f95f5426b47971696a21b35bc1104aae4d5785","unresolved":false,"context_lines":[{"line_number":913,"context_line":""},{"line_number":914,"context_line":"        # If volume has been resized it must be manually removed in cinder"},{"line_number":915,"context_line":"        try:"},{"line_number":916,"context_line":"            if self.volume_support:"},{"line_number":917,"context_line":"                volume_client \u003d create_cinder_client(self.context)"},{"line_number":918,"context_line":"                volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":919,"context_line":"                if volume is not None:"}],"source_content_type":"text/x-python","patch_set":7,"id":"3a961159_f847964a","line":916,"updated":"2015-01-09 22:59:47.000000000","message":"a better condition would be\n\n    if self.volume_id:\n\na datastore throughout its life can have volume_support toggled on and off, meaning it\u0027s possible to have active/live instances with and without a volume for the exact same datastore + datastore-version.","commit_id":"4b9104d631547451c6e703d66f00c021bad4e66f"},{"author":{"_account_id":8415,"name":"Denis M.","email":"lildee1991@gmail.com","username":"dmakogon"},"change_message_id":"e3b5879304628f30d89957888c4ed03537ae99b9","unresolved":false,"context_lines":[{"line_number":918,"context_line":"                volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":919,"context_line":"                if volume is not None:"},{"line_number":920,"context_line":"                    if volume.status \u003d\u003d \"available\":"},{"line_number":921,"context_line":"                        LOG.debug(\"Deleting volume %(v)s for instance: %(i)s\""},{"line_number":922,"context_line":"                                  % {\u0027i\u0027: self.id, \u0027v\u0027: self.volume_id})"},{"line_number":923,"context_line":"                        volume.delete()"},{"line_number":924,"context_line":"        except Exception as ex:"}],"source_content_type":"text/x-python","patch_set":7,"id":"3a961159_32408ba4","line":921,"updated":"2015-01-08 11:59:36.000000000","message":"missing period","commit_id":"4b9104d631547451c6e703d66f00c021bad4e66f"},{"author":{"_account_id":8415,"name":"Denis M.","email":"lildee1991@gmail.com","username":"dmakogon"},"change_message_id":"e3b5879304628f30d89957888c4ed03537ae99b9","unresolved":false,"context_lines":[{"line_number":923,"context_line":"                        volume.delete()"},{"line_number":924,"context_line":"        except Exception as ex:"},{"line_number":925,"context_line":"            LOG.exception(_(\"Error deleting volume of instance %(id)s: \""},{"line_number":926,"context_line":"                            \"%(ex)s\") % {\u0027id\u0027: self.db_info.id, \u0027ex\u0027: ex})"},{"line_number":927,"context_line":""},{"line_number":928,"context_line":"        self.send_usage_event(\u0027delete\u0027,"},{"line_number":929,"context_line":"                              deleted_at\u003dtimeutils.isotime(deleted_at),"}],"source_content_type":"text/x-python","patch_set":7,"id":"3a961159_12362f51","line":926,"updated":"2015-01-08 11:59:36.000000000","message":"missing period","commit_id":"4b9104d631547451c6e703d66f00c021bad4e66f"},{"author":{"_account_id":10725,"name":"Sergey Gotliv","email":"sgotliv@redhat.com","username":"sgotliv"},"change_message_id":"ee71fc542fc4a646dc1d4e6b59bc68288e730305","unresolved":false,"context_lines":[{"line_number":915,"context_line":"        try:"},{"line_number":916,"context_line":"            if self.volume_id:"},{"line_number":917,"context_line":"                volume_client \u003d create_cinder_client(self.context)"},{"line_number":918,"context_line":"                volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":919,"context_line":"                if volume is not None:"},{"line_number":920,"context_line":"                    if volume.status \u003d\u003d \"available\":"},{"line_number":921,"context_line":"                        LOG.debug(\"Deleting volume %(v)s for instance: %(i)s\""}],"source_content_type":"text/x-python","patch_set":8,"id":"3a961159_38283797","line":918,"updated":"2015-01-19 21:34:45.000000000","message":"I would compact try/except block:\n\nIf lines 917-918 can raise then message in line 925 is not accurate\nif lines 917-918 can\u0027t raise so why they placed in the try/except block?","commit_id":"3168cc204da2125661009b2e363df84d5a4713f0"},{"author":{"_account_id":8415,"name":"Denis M.","email":"lildee1991@gmail.com","username":"dmakogon"},"change_message_id":"5440fec4e5376ed334d79f59266a9a8b52b17e3d","unresolved":false,"context_lines":[{"line_number":915,"context_line":"        try:"},{"line_number":916,"context_line":"            if self.volume_id:"},{"line_number":917,"context_line":"                volume_client \u003d create_cinder_client(self.context)"},{"line_number":918,"context_line":"                volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":919,"context_line":"                if volume is not None:"},{"line_number":920,"context_line":"                    if volume.status \u003d\u003d \"available\":"},{"line_number":921,"context_line":"                        LOG.debug(\"Deleting volume %(v)s for instance: %(i)s\""}],"source_content_type":"text/x-python","patch_set":8,"id":"1a930d6b_94cd8a89","line":918,"in_reply_to":"3a961159_38283797","updated":"2015-01-20 21:30:18.000000000","message":"+1 to Serg\u0027s concern","commit_id":"3168cc204da2125661009b2e363df84d5a4713f0"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"852e5a0705faf5a344bbe4dd2a743dc0261bf6f8","unresolved":false,"context_lines":[{"line_number":915,"context_line":"        try:"},{"line_number":916,"context_line":"            if self.volume_id:"},{"line_number":917,"context_line":"                volume_client \u003d create_cinder_client(self.context)"},{"line_number":918,"context_line":"                volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":919,"context_line":"                if volume is not None:"},{"line_number":920,"context_line":"                    if volume.status \u003d\u003d \"available\":"},{"line_number":921,"context_line":"                        LOG.debug(\"Deleting volume %(v)s for instance: %(i)s\""}],"source_content_type":"text/x-python","patch_set":8,"id":"da86d52c_c6f718f4","line":918,"in_reply_to":"3a961159_38283797","updated":"2015-02-02 20:04:38.000000000","message":"Agree on the try/except messages, need to get placements correct.","commit_id":"3168cc204da2125661009b2e363df84d5a4713f0"},{"author":{"_account_id":8415,"name":"Denis M.","email":"lildee1991@gmail.com","username":"dmakogon"},"change_message_id":"5440fec4e5376ed334d79f59266a9a8b52b17e3d","unresolved":false,"context_lines":[{"line_number":916,"context_line":"            if self.volume_id:"},{"line_number":917,"context_line":"                volume_client \u003d create_cinder_client(self.context)"},{"line_number":918,"context_line":"                volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":919,"context_line":"                if volume is not None:"},{"line_number":920,"context_line":"                    if volume.status \u003d\u003d \"available\":"},{"line_number":921,"context_line":"                        LOG.debug(\"Deleting volume %(v)s for instance: %(i)s\""},{"line_number":922,"context_line":"                                  % {\u0027i\u0027: self.id, \u0027v\u0027: self.volume_id})"}],"source_content_type":"text/x-python","patch_set":8,"id":"1a930d6b_d49e3263","line":919,"updated":"2015-01-20 21:30:18.000000000","message":"if volume.get would work and will end with HTTP 200, then this check is redundant, in other case like HTTP 404 this code wouldn\u0027t work, because exception would take its place.","commit_id":"3168cc204da2125661009b2e363df84d5a4713f0"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"852e5a0705faf5a344bbe4dd2a743dc0261bf6f8","unresolved":false,"context_lines":[{"line_number":916,"context_line":"            if self.volume_id:"},{"line_number":917,"context_line":"                volume_client \u003d create_cinder_client(self.context)"},{"line_number":918,"context_line":"                volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":919,"context_line":"                if volume is not None:"},{"line_number":920,"context_line":"                    if volume.status \u003d\u003d \"available\":"},{"line_number":921,"context_line":"                        LOG.debug(\"Deleting volume %(v)s for instance: %(i)s\""},{"line_number":922,"context_line":"                                  % {\u0027i\u0027: self.id, \u0027v\u0027: self.volume_id})"}],"source_content_type":"text/x-python","patch_set":8,"id":"da86d52c_e6c41c94","line":919,"in_reply_to":"1a930d6b_d49e3263","updated":"2015-02-02 20:04:38.000000000","message":"+1, for Denis comment, there is no need of if statement as in case of exception from line 918 control wont flow to 919.","commit_id":"3168cc204da2125661009b2e363df84d5a4713f0"},{"author":{"_account_id":8415,"name":"Denis M.","email":"lildee1991@gmail.com","username":"dmakogon"},"change_message_id":"5440fec4e5376ed334d79f59266a9a8b52b17e3d","unresolved":false,"context_lines":[{"line_number":918,"context_line":"                volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":919,"context_line":"                if volume is not None:"},{"line_number":920,"context_line":"                    if volume.status \u003d\u003d \"available\":"},{"line_number":921,"context_line":"                        LOG.debug(\"Deleting volume %(v)s for instance: %(i)s\""},{"line_number":922,"context_line":"                                  % {\u0027i\u0027: self.id, \u0027v\u0027: self.volume_id})"},{"line_number":923,"context_line":"                        volume.delete()"},{"line_number":924,"context_line":"        except Exception as ex:"}],"source_content_type":"text/x-python","patch_set":8,"id":"1a930d6b_54824201","line":921,"updated":"2015-01-20 21:30:18.000000000","message":"this should be an INFO level, but not DEBUG.","commit_id":"3168cc204da2125661009b2e363df84d5a4713f0"},{"author":{"_account_id":10215,"name":"Peter Stachowski","email":"peter@tesora.com","username":"peterstac"},"change_message_id":"ccaea5879f8ad67f6ea9412b1ca267ff732191f1","unresolved":false,"context_lines":[{"line_number":919,"context_line":"                if volume is not None:"},{"line_number":920,"context_line":"                    if volume.status \u003d\u003d \"available\":"},{"line_number":921,"context_line":"                        LOG.debug(\"Deleting volume %(v)s for instance: %(i)s\""},{"line_number":922,"context_line":"                                  % {\u0027i\u0027: self.id, \u0027v\u0027: self.volume_id})"},{"line_number":923,"context_line":"                        volume.delete()"},{"line_number":924,"context_line":"        except Exception as ex:"},{"line_number":925,"context_line":"            LOG.exception(_(\"Error deleting volume of instance %(id)s: \""}],"source_content_type":"text/x-python","patch_set":8,"id":"1a930d6b_00adf3e8","line":922,"updated":"2015-01-27 17:02:35.000000000","message":"This is a nit-pick, but it would be clearer if you put the variables in the same order as they\u0027re being referenced.\n\n  LOG.info(_(\"Deleting volume %(vol_id)s for instance: %(id)s\")\n           % {\u0027vol_id\u0027: self.volume_id, \u0027id\u0027: self.id})\n\nAnd I agree with Denis, it should probably be an INFO message.","commit_id":"3168cc204da2125661009b2e363df84d5a4713f0"},{"author":{"_account_id":8415,"name":"Denis M.","email":"lildee1991@gmail.com","username":"dmakogon"},"change_message_id":"5440fec4e5376ed334d79f59266a9a8b52b17e3d","unresolved":false,"context_lines":[{"line_number":921,"context_line":"                        LOG.debug(\"Deleting volume %(v)s for instance: %(i)s\""},{"line_number":922,"context_line":"                                  % {\u0027i\u0027: self.id, \u0027v\u0027: self.volume_id})"},{"line_number":923,"context_line":"                        volume.delete()"},{"line_number":924,"context_line":"        except Exception as ex:"},{"line_number":925,"context_line":"            LOG.exception(_(\"Error deleting volume of instance %(id)s: \""},{"line_number":926,"context_line":"                            \"%(ex)s\") % {\u0027id\u0027: self.db_info.id, \u0027ex\u0027: ex})"},{"line_number":927,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"1a930d6b_f4724e48","line":924,"updated":"2015-01-20 21:30:18.000000000","message":"disagree about generic exception, you need to figure our a list of concrete exceptions that are might be raisen by cinderclient.","commit_id":"3168cc204da2125661009b2e363df84d5a4713f0"},{"author":{"_account_id":8415,"name":"Denis M.","email":"lildee1991@gmail.com","username":"dmakogon"},"change_message_id":"5440fec4e5376ed334d79f59266a9a8b52b17e3d","unresolved":false,"context_lines":[{"line_number":923,"context_line":"                        volume.delete()"},{"line_number":924,"context_line":"        except Exception as ex:"},{"line_number":925,"context_line":"            LOG.exception(_(\"Error deleting volume of instance %(id)s: \""},{"line_number":926,"context_line":"                            \"%(ex)s\") % {\u0027id\u0027: self.db_info.id, \u0027ex\u0027: ex})"},{"line_number":927,"context_line":""},{"line_number":928,"context_line":"        self.send_usage_event(\u0027delete\u0027,"},{"line_number":929,"context_line":"                              deleted_at\u003dtimeutils.isotime(deleted_at),"}],"source_content_type":"text/x-python","patch_set":8,"id":"1a930d6b_f4edeef0","line":926,"updated":"2015-01-20 21:30:18.000000000","message":"LOG.exception logs exception trace so, we don\u0027t need to do it explicitly.","commit_id":"3168cc204da2125661009b2e363df84d5a4713f0"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"852e5a0705faf5a344bbe4dd2a743dc0261bf6f8","unresolved":false,"context_lines":[{"line_number":923,"context_line":"                        volume.delete()"},{"line_number":924,"context_line":"        except Exception as ex:"},{"line_number":925,"context_line":"            LOG.exception(_(\"Error deleting volume of instance %(id)s: \""},{"line_number":926,"context_line":"                            \"%(ex)s\") % {\u0027id\u0027: self.db_info.id, \u0027ex\u0027: ex})"},{"line_number":927,"context_line":""},{"line_number":928,"context_line":"        self.send_usage_event(\u0027delete\u0027,"},{"line_number":929,"context_line":"                              deleted_at\u003dtimeutils.isotime(deleted_at),"}],"source_content_type":"text/x-python","patch_set":8,"id":"da86d52c_66066cd0","line":926,"in_reply_to":"1a930d6b_8c983f1d","updated":"2015-02-02 20:04:38.000000000","message":"Agree that there should be more exceptions caught before we get to the generic level, to provide the correct info to the user in case of a failure.","commit_id":"3168cc204da2125661009b2e363df84d5a4713f0"},{"author":{"_account_id":10215,"name":"Peter Stachowski","email":"peter@tesora.com","username":"peterstac"},"change_message_id":"ccaea5879f8ad67f6ea9412b1ca267ff732191f1","unresolved":false,"context_lines":[{"line_number":923,"context_line":"                        volume.delete()"},{"line_number":924,"context_line":"        except Exception as ex:"},{"line_number":925,"context_line":"            LOG.exception(_(\"Error deleting volume of instance %(id)s: \""},{"line_number":926,"context_line":"                            \"%(ex)s\") % {\u0027id\u0027: self.db_info.id, \u0027ex\u0027: ex})"},{"line_number":927,"context_line":""},{"line_number":928,"context_line":"        self.send_usage_event(\u0027delete\u0027,"},{"line_number":929,"context_line":"                              deleted_at\u003dtimeutils.isotime(deleted_at),"}],"source_content_type":"text/x-python","patch_set":8,"id":"1a930d6b_8c983f1d","line":926,"in_reply_to":"1a930d6b_f4edeef0","updated":"2015-01-27 17:02:35.000000000","message":"I agree with this - having more than one stack trace of the same issue gets confusing.  You could probably change the message here to, to alleviate the above concerns about tighter try/catch blocks (and the stack trace can show where the actual error occurred).\n\n  LOG.exception(_(\"An error occurred trying to delete volume \"\n                \"%(vol_id)s from instance %(id)s\")\n                % {\u0027vol_id\u0027: self.volume_id, \u0027id\u0027: self.id})","commit_id":"3168cc204da2125661009b2e363df84d5a4713f0"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"53d3fbe69cfc067d5a0ae8b0ba2dc9a75dc91cb7","unresolved":false,"context_lines":[{"line_number":916,"context_line":""},{"line_number":917,"context_line":"        # If volume has been resized it must be manually removed in cinder"},{"line_number":918,"context_line":"        try:"},{"line_number":919,"context_line":"            if self.volume_id:"},{"line_number":920,"context_line":"                volume_client \u003d create_cinder_client(self.context)"},{"line_number":921,"context_line":"                volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":922,"context_line":"                if volume.status \u003d\u003d \"available\":"}],"source_content_type":"text/x-python","patch_set":10,"id":"da86d52c_febf85a8","line":919,"updated":"2015-02-06 20:29:57.000000000","message":"Why did we just move the next three lines back into the try block?","commit_id":"f651e498b74b716a0c998c6e16b02aaeba0adcb7"},{"author":{"_account_id":11783,"name":"Shayne Burgess","email":"shayne.burgess@hp.com","username":"shayne-burgess"},"change_message_id":"18effbbf078d59cc5c1ab71c3f4efa304c248001","unresolved":false,"context_lines":[{"line_number":916,"context_line":""},{"line_number":917,"context_line":"        # If volume has been resized it must be manually removed in cinder"},{"line_number":918,"context_line":"        try:"},{"line_number":919,"context_line":"            if self.volume_id:"},{"line_number":920,"context_line":"                volume_client \u003d create_cinder_client(self.context)"},{"line_number":921,"context_line":"                volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":922,"context_line":"                if volume.status \u003d\u003d \"available\":"}],"source_content_type":"text/x-python","patch_set":10,"id":"da86d52c_be598d5d","line":919,"in_reply_to":"da86d52c_3e7d9de8","updated":"2015-02-06 20:41:20.000000000","message":"Scratch, that my first point about it throwing if the volume wasn\u0027t resized is wrong. I still think the second point is valid though.","commit_id":"f651e498b74b716a0c998c6e16b02aaeba0adcb7"},{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"749772ba38d40a3b9c46fbc92384be22a64765f2","unresolved":false,"context_lines":[{"line_number":916,"context_line":""},{"line_number":917,"context_line":"        # If volume has been resized it must be manually removed in cinder"},{"line_number":918,"context_line":"        try:"},{"line_number":919,"context_line":"            if self.volume_id:"},{"line_number":920,"context_line":"                volume_client \u003d create_cinder_client(self.context)"},{"line_number":921,"context_line":"                volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":922,"context_line":"                if volume.status \u003d\u003d \"available\":"}],"source_content_type":"text/x-python","patch_set":10,"id":"da86d52c_be07cd1c","line":919,"in_reply_to":"da86d52c_be598d5d","updated":"2015-02-06 20:43:28.000000000","message":"Yeah, I think it is a valid point anyhow. +1","commit_id":"f651e498b74b716a0c998c6e16b02aaeba0adcb7"},{"author":{"_account_id":11783,"name":"Shayne Burgess","email":"shayne.burgess@hp.com","username":"shayne-burgess"},"change_message_id":"9aa0865567bd90219e21edc0ba2c883f615eb193","unresolved":false,"context_lines":[{"line_number":916,"context_line":""},{"line_number":917,"context_line":"        # If volume has been resized it must be manually removed in cinder"},{"line_number":918,"context_line":"        try:"},{"line_number":919,"context_line":"            if self.volume_id:"},{"line_number":920,"context_line":"                volume_client \u003d create_cinder_client(self.context)"},{"line_number":921,"context_line":"                volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":922,"context_line":"                if volume.status \u003d\u003d \"available\":"}],"source_content_type":"text/x-python","patch_set":10,"id":"da86d52c_3e7d9de8","line":919,"in_reply_to":"da86d52c_febf85a8","updated":"2015-02-06 20:33:49.000000000","message":"Because volumes.get will throw if the volume doesn\u0027t exist. This will happen if the volume was not resized and was deleted during instance delete. This is a better implementation anyway, IMO, because the point of this is that no-matter what happens this operation does not fail the overall workflow. let\u0027s say the create cinder client call fails for an unknown reason, we want the rest of the delete cleanup to continue.","commit_id":"f651e498b74b716a0c998c6e16b02aaeba0adcb7"},{"author":{"_account_id":9664,"name":"amrith","email":"amrith.kumar@gmail.com","username":"amrith"},"change_message_id":"64bc35d07297b47a67fec0bf1c6249803e921fa5","unresolved":false,"context_lines":[{"line_number":919,"context_line":"            if self.volume_id:"},{"line_number":920,"context_line":"                volume_client \u003d create_cinder_client(self.context)"},{"line_number":921,"context_line":"                volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":922,"context_line":"                if volume.status \u003d\u003d \"available\":"},{"line_number":923,"context_line":"                    LOG.info(\"Deleting volume %(v)s for instance: %(i)s\""},{"line_number":924,"context_line":"                             % {\u0027v\u0027: self.volume_id, \u0027i\u0027: self.id})"},{"line_number":925,"context_line":"                    volume.delete()"}],"source_content_type":"text/x-python","patch_set":10,"id":"da86d52c_f064df4a","line":922,"updated":"2015-02-09 16:15:41.000000000","message":"I would\u0027ve thought the nice API would have a manifest constant for this instead of having each client use a literal string. I think that may not be the case? If there is such a constant that we could use, I\u0027d rather use that.","commit_id":"f651e498b74b716a0c998c6e16b02aaeba0adcb7"},{"author":{"_account_id":10215,"name":"Peter Stachowski","email":"peter@tesora.com","username":"peterstac"},"change_message_id":"5cd89f344c8e4fa71e3cb8d3bde9e98f0a6d4e83","unresolved":false,"context_lines":[{"line_number":919,"context_line":"            if self.volume_id:"},{"line_number":920,"context_line":"                volume_client \u003d create_cinder_client(self.context)"},{"line_number":921,"context_line":"                volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":922,"context_line":"                if volume.status \u003d\u003d \"available\":"},{"line_number":923,"context_line":"                    LOG.info(\"Deleting volume %(v)s for instance: %(i)s\""},{"line_number":924,"context_line":"                             % {\u0027v\u0027: self.volume_id, \u0027i\u0027: self.id})"},{"line_number":925,"context_line":"                    volume.delete()"}],"source_content_type":"text/x-python","patch_set":10,"id":"da86d52c_5d2f7688","line":922,"in_reply_to":"da86d52c_66882c23","updated":"2015-02-09 20:15:36.000000000","message":"Thinking about this some more, in the absence of a \u0027openstack/common/constants\u0027 lib (or some equivalent) that all projects used, even if there were a cinder constants file, it would tie our repo to theirs - probably not what we want.","commit_id":"f651e498b74b716a0c998c6e16b02aaeba0adcb7"},{"author":{"_account_id":13355,"name":"Edmond Kotowski","email":"ekotowski@gmail.com","username":"ekotowski"},"change_message_id":"f01372d4d6776341f420dd40f269e8578f469dd0","unresolved":false,"context_lines":[{"line_number":919,"context_line":"            if self.volume_id:"},{"line_number":920,"context_line":"                volume_client \u003d create_cinder_client(self.context)"},{"line_number":921,"context_line":"                volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":922,"context_line":"                if volume.status \u003d\u003d \"available\":"},{"line_number":923,"context_line":"                    LOG.info(\"Deleting volume %(v)s for instance: %(i)s\""},{"line_number":924,"context_line":"                             % {\u0027v\u0027: self.volume_id, \u0027i\u0027: self.id})"},{"line_number":925,"context_line":"                    volume.delete()"}],"source_content_type":"text/x-python","patch_set":10,"id":"da86d52c_66882c23","line":922,"in_reply_to":"da86d52c_f064df4a","updated":"2015-02-09 19:42:14.000000000","message":"I just checked python-novaclient, python-cinderclient, and cinder and there doesn\u0027t appear to be a constants file for the cinder volume status. The cinder source refers to the string name directly. Ex from Cinder: volume_ref[\u0027status\u0027] \u003d \u0027in-use\u0027","commit_id":"f651e498b74b716a0c998c6e16b02aaeba0adcb7"},{"author":{"_account_id":10215,"name":"Peter Stachowski","email":"peter@tesora.com","username":"peterstac"},"change_message_id":"a7cc917a20677aeeb8b2310f04a2bf1e30c06e27","unresolved":false,"context_lines":[{"line_number":920,"context_line":"                volume_client \u003d create_cinder_client(self.context)"},{"line_number":921,"context_line":"                volume \u003d volume_client.volumes.get(self.volume_id)"},{"line_number":922,"context_line":"                if volume.status \u003d\u003d \"available\":"},{"line_number":923,"context_line":"                    LOG.info(\"Deleting volume %(v)s for instance: %(i)s\""},{"line_number":924,"context_line":"                             % {\u0027v\u0027: self.volume_id, \u0027i\u0027: self.id})"},{"line_number":925,"context_line":"                    volume.delete()"},{"line_number":926,"context_line":"        except Exception as ex:"}],"source_content_type":"text/x-python","patch_set":10,"id":"da86d52c_ab5aed80","line":923,"updated":"2015-02-09 19:29:59.000000000","message":"This needs to be internationalized:\n\n  LOG.info(_(\"Deleting volume %(v)s for instance: %(i)s\")\n           % {\u0027v\u0027: self.volume_id, \u0027i\u0027: self.id})","commit_id":"f651e498b74b716a0c998c6e16b02aaeba0adcb7"},{"author":{"_account_id":10215,"name":"Peter Stachowski","email":"peter@tesora.com","username":"peterstac"},"change_message_id":"a7cc917a20677aeeb8b2310f04a2bf1e30c06e27","unresolved":false,"context_lines":[{"line_number":923,"context_line":"                    LOG.info(\"Deleting volume %(v)s for instance: %(i)s\""},{"line_number":924,"context_line":"                             % {\u0027v\u0027: self.volume_id, \u0027i\u0027: self.id})"},{"line_number":925,"context_line":"                    volume.delete()"},{"line_number":926,"context_line":"        except Exception as ex:"},{"line_number":927,"context_line":"            LOG.exception(_(\"Error deleting volume of instance %(id)s: \") %"},{"line_number":928,"context_line":"                          {\u0027id\u0027: self.db_info.id})"},{"line_number":929,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"da86d52c_cb7001df","line":926,"range":{"start_line":926,"start_character":8,"end_line":926,"end_character":24},"updated":"2015-02-09 19:29:59.000000000","message":"Unused variable here (left over from the removal of the explicit exception logging)\n\n  except Exception:","commit_id":"f651e498b74b716a0c998c6e16b02aaeba0adcb7"},{"author":{"_account_id":9664,"name":"amrith","email":"amrith.kumar@gmail.com","username":"amrith"},"change_message_id":"64bc35d07297b47a67fec0bf1c6249803e921fa5","unresolved":false,"context_lines":[{"line_number":923,"context_line":"                    LOG.info(\"Deleting volume %(v)s for instance: %(i)s\""},{"line_number":924,"context_line":"                             % {\u0027v\u0027: self.volume_id, \u0027i\u0027: self.id})"},{"line_number":925,"context_line":"                    volume.delete()"},{"line_number":926,"context_line":"        except Exception as ex:"},{"line_number":927,"context_line":"            LOG.exception(_(\"Error deleting volume of instance %(id)s: \") %"},{"line_number":928,"context_line":"                          {\u0027id\u0027: self.db_info.id})"},{"line_number":929,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"da86d52c_f0677f23","line":926,"updated":"2015-02-09 16:15:41.000000000","message":"everything, and the kitchen sink. Wonder just what one may catch here. \n\nAlso, having just a single catch for the whole lot doesn\u0027t make it easy to tell whether the user should attempt to retry the operation or not. For example, if the volume is not available, the course of action would be different from the course one would pursue if volume.delete() failed.\n\nI wonder whether an improvement to this code would break those two apart.","commit_id":"f651e498b74b716a0c998c6e16b02aaeba0adcb7"},{"author":{"_account_id":10215,"name":"Peter Stachowski","email":"peter@tesora.com","username":"peterstac"},"change_message_id":"a7cc917a20677aeeb8b2310f04a2bf1e30c06e27","unresolved":false,"context_lines":[{"line_number":923,"context_line":"                    LOG.info(\"Deleting volume %(v)s for instance: %(i)s\""},{"line_number":924,"context_line":"                             % {\u0027v\u0027: self.volume_id, \u0027i\u0027: self.id})"},{"line_number":925,"context_line":"                    volume.delete()"},{"line_number":926,"context_line":"        except Exception as ex:"},{"line_number":927,"context_line":"            LOG.exception(_(\"Error deleting volume of instance %(id)s: \") %"},{"line_number":928,"context_line":"                          {\u0027id\u0027: self.db_info.id})"},{"line_number":929,"context_line":""}],"source_content_type":"text/x-python","patch_set":10,"id":"da86d52c_abd10dcf","line":926,"in_reply_to":"da86d52c_f0677f23","updated":"2015-02-09 19:29:59.000000000","message":"The user operation here is to delete an instance.  If the volume doesn\u0027t get deleted for whatever reason, they can\u0027t re-run the original command (they\u0027ll have to delete the volume manually).  I think it\u0027s correct that *any* error deleting here shouldn\u0027t fail the instance delete.","commit_id":"f651e498b74b716a0c998c6e16b02aaeba0adcb7"},{"author":{"_account_id":10725,"name":"Sergey Gotliv","email":"sgotliv@redhat.com","username":"sgotliv"},"change_message_id":"c79c6aca49ce9d440f7d53a953ad9d7aa5665e16","unresolved":false,"context_lines":[{"line_number":925,"context_line":"                    volume.delete()"},{"line_number":926,"context_line":"        except Exception as ex:"},{"line_number":927,"context_line":"            LOG.exception(_(\"Error deleting volume of instance %(id)s: \") %"},{"line_number":928,"context_line":"                          {\u0027id\u0027: self.db_info.id})"},{"line_number":929,"context_line":""},{"line_number":930,"context_line":"        self.send_usage_event(\u0027delete\u0027,"},{"line_number":931,"context_line":"                              deleted_at\u003dtimeutils.isotime(deleted_at),"}],"source_content_type":"text/x-python","patch_set":10,"id":"da86d52c_c06c8d0b","line":928,"updated":"2015-02-07 22:46:50.000000000","message":"Please, print the exception.","commit_id":"f651e498b74b716a0c998c6e16b02aaeba0adcb7"},{"author":{"_account_id":13355,"name":"Edmond Kotowski","email":"ekotowski@gmail.com","username":"ekotowski"},"change_message_id":"967e6c73150080ed11a699e947f3379122b62144","unresolved":false,"context_lines":[{"line_number":925,"context_line":"                    volume.delete()"},{"line_number":926,"context_line":"        except Exception as ex:"},{"line_number":927,"context_line":"            LOG.exception(_(\"Error deleting volume of instance %(id)s: \") %"},{"line_number":928,"context_line":"                          {\u0027id\u0027: self.db_info.id})"},{"line_number":929,"context_line":""},{"line_number":930,"context_line":"        self.send_usage_event(\u0027delete\u0027,"},{"line_number":931,"context_line":"                              deleted_at\u003dtimeutils.isotime(deleted_at),"}],"source_content_type":"text/x-python","patch_set":10,"id":"da86d52c_638ccb80","line":928,"in_reply_to":"da86d52c_03394fd8","updated":"2015-02-07 23:52:42.000000000","message":"That is correct. I just tested this and the stack trace gets logged with LOG.exception without explicitly passing in ex.","commit_id":"f651e498b74b716a0c998c6e16b02aaeba0adcb7"},{"author":{"_account_id":10725,"name":"Sergey Gotliv","email":"sgotliv@redhat.com","username":"sgotliv"},"change_message_id":"e2d53446330839c3dc9a870203dcff3e579aab22","unresolved":false,"context_lines":[{"line_number":925,"context_line":"                    volume.delete()"},{"line_number":926,"context_line":"        except Exception as ex:"},{"line_number":927,"context_line":"            LOG.exception(_(\"Error deleting volume of instance %(id)s: \") %"},{"line_number":928,"context_line":"                          {\u0027id\u0027: self.db_info.id})"},{"line_number":929,"context_line":""},{"line_number":930,"context_line":"        self.send_usage_event(\u0027delete\u0027,"},{"line_number":931,"context_line":"                              deleted_at\u003dtimeutils.isotime(deleted_at),"}],"source_content_type":"text/x-python","patch_set":10,"id":"da86d52c_0fac0e35","line":928,"in_reply_to":"da86d52c_638ccb80","updated":"2015-02-08 17:49:05.000000000","message":"Thanks for clarification.","commit_id":"f651e498b74b716a0c998c6e16b02aaeba0adcb7"},{"author":{"_account_id":11783,"name":"Shayne Burgess","email":"shayne.burgess@hp.com","username":"shayne-burgess"},"change_message_id":"43abc8da10e666449dc915bbf3b4b878f1aeb20b","unresolved":false,"context_lines":[{"line_number":925,"context_line":"                    volume.delete()"},{"line_number":926,"context_line":"        except Exception as ex:"},{"line_number":927,"context_line":"            LOG.exception(_(\"Error deleting volume of instance %(id)s: \") %"},{"line_number":928,"context_line":"                          {\u0027id\u0027: self.db_info.id})"},{"line_number":929,"context_line":""},{"line_number":930,"context_line":"        self.send_usage_event(\u0027delete\u0027,"},{"line_number":931,"context_line":"                              deleted_at\u003dtimeutils.isotime(deleted_at),"}],"source_content_type":"text/x-python","patch_set":10,"id":"da86d52c_03394fd8","line":928,"in_reply_to":"da86d52c_c06c8d0b","updated":"2015-02-07 23:26:47.000000000","message":"I removed the exception because of this comment: \n\n\tDenis M.\t\tJan 20 1:30 PM\nLOG.exception logs exception trace so, we don\u0027t need to do it explicitly.","commit_id":"f651e498b74b716a0c998c6e16b02aaeba0adcb7"}],"trove/tests/api/instances.py":[{"author":{"_account_id":14576,"name":"Petr Malik","email":"pmalik@tesora.com","username":"pmalik"},"change_message_id":"7ad5135736955cd0e0c3f7a1a6dd77544bb0f464","unresolved":false,"context_lines":[{"line_number":1297,"context_line":"        try:"},{"line_number":1298,"context_line":"            while True:"},{"line_number":1299,"context_line":"                instance \u003d dbaas.instances.get(instance_info.id)"},{"line_number":1300,"context_line":"                assert_equal(instance.volume[\u0027status\u0027] \u003d\u003d \"available\")"},{"line_number":1301,"context_line":"                time.sleep(1)"},{"line_number":1302,"context_line":"        except exceptions.NotFound:"},{"line_number":1303,"context_line":"            pass"}],"source_content_type":"text/x-python","patch_set":8,"id":"1a930d6b_ccfde76f","line":1300,"updated":"2015-01-27 16:59:01.000000000","message":"Hmm, shouldn\u0027t this be assert_equal(instance.volume[\u0027status\u0027], \"available\")\" instead?","commit_id":"3168cc204da2125661009b2e363df84d5a4713f0"},{"author":{"_account_id":7806,"name":"Sushil Kumar","email":"skm.net@gmail.com","username":"sushilkm"},"change_message_id":"852e5a0705faf5a344bbe4dd2a743dc0261bf6f8","unresolved":false,"context_lines":[{"line_number":1297,"context_line":"        try:"},{"line_number":1298,"context_line":"            while True:"},{"line_number":1299,"context_line":"                instance \u003d dbaas.instances.get(instance_info.id)"},{"line_number":1300,"context_line":"                assert_equal(instance.volume[\u0027status\u0027] \u003d\u003d \"available\")"},{"line_number":1301,"context_line":"                time.sleep(1)"},{"line_number":1302,"context_line":"        except exceptions.NotFound:"},{"line_number":1303,"context_line":"            pass"}],"source_content_type":"text/x-python","patch_set":8,"id":"da86d52c_06f5b0ca","line":1300,"in_reply_to":"1a930d6b_600877da","updated":"2015-02-02 20:04:38.000000000","message":"+1","commit_id":"3168cc204da2125661009b2e363df84d5a4713f0"},{"author":{"_account_id":10215,"name":"Peter Stachowski","email":"peter@tesora.com","username":"peterstac"},"change_message_id":"ccaea5879f8ad67f6ea9412b1ca267ff732191f1","unresolved":false,"context_lines":[{"line_number":1297,"context_line":"        try:"},{"line_number":1298,"context_line":"            while True:"},{"line_number":1299,"context_line":"                instance \u003d dbaas.instances.get(instance_info.id)"},{"line_number":1300,"context_line":"                assert_equal(instance.volume[\u0027status\u0027] \u003d\u003d \"available\")"},{"line_number":1301,"context_line":"                time.sleep(1)"},{"line_number":1302,"context_line":"        except exceptions.NotFound:"},{"line_number":1303,"context_line":"            pass"}],"source_content_type":"text/x-python","patch_set":8,"id":"1a930d6b_600877da","line":1300,"in_reply_to":"1a930d6b_ccfde76f","updated":"2015-01-27 17:02:35.000000000","message":"Good catch","commit_id":"3168cc204da2125661009b2e363df84d5a4713f0"},{"author":{"_account_id":9664,"name":"amrith","email":"amrith.kumar@gmail.com","username":"amrith"},"change_message_id":"c76acf6578a4f7f1637f4e4172e88506e7f09309","unresolved":false,"context_lines":[{"line_number":1361,"context_line":"                time.sleep(1)"},{"line_number":1362,"context_line":"        except exceptions.NotFound:"},{"line_number":1363,"context_line":"            pass"},{"line_number":1364,"context_line":"        except Exception as ex:"},{"line_number":1365,"context_line":"            fail(\"Failure: %s\" % str(ex))"},{"line_number":1366,"context_line":""},{"line_number":1367,"context_line":"    #TODO(tim-simpson): make sure that the actual instance, volume,"}],"source_content_type":"text/x-python","patch_set":11,"id":"da86d52c_b3341ae0","line":1364,"updated":"2015-02-10 01:15:37.000000000","message":"at some point we should fix these last two tests to use assert_raises() instead of actually having the exception thrown.","commit_id":"2d4cd5fae1b07e09d5c70ec3736a18737795a6c5"}]}
