)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":11047,"name":"Mark Sturdevant","email":"mark.sturdevant@ibm.com","username":"markstur"},"change_message_id":"768d81253712e55858bfd729506f795519688a11","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     Vladimir Vechkanov \u003cvvechkanov@mirantis.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2014-10-22 05:25:55 -0400"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Fix share maneger to save data after drivers error"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"While creating share servers and shares exceptions can be raises."},{"line_number":10,"context_line":"At the moment when error occurs some detail information about"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"9aa7fdbe_97917ff3","line":7,"updated":"2014-10-23 16:42:38.000000000","message":"s/maneger/manager/","commit_id":"11865310229821f46c37bc2a421b71bbfdad006e"},{"author":{"_account_id":6529,"name":"Vladimir Vechkanov","email":"vvechkanov@mirantis.com","username":"vvechkanov"},"change_message_id":"1b011efe6b521a908c0552b59ed1c3d62a40a9ab","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     Vladimir Vechkanov \u003cvvechkanov@mirantis.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2014-10-22 05:25:55 -0400"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Fix share maneger to save data after drivers error"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"While creating share servers and shares exceptions can be raises."},{"line_number":10,"context_line":"At the moment when error occurs some detail information about"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"9aa7fdbe_69cef2b5","line":7,"in_reply_to":"9aa7fdbe_97917ff3","updated":"2014-10-24 07:55:23.000000000","message":"Done","commit_id":"11865310229821f46c37bc2a421b71bbfdad006e"},{"author":{"_account_id":11047,"name":"Mark Sturdevant","email":"mark.sturdevant@ibm.com","username":"markstur"},"change_message_id":"768d81253712e55858bfd729506f795519688a11","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Fix share maneger to save data after drivers error"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"While creating share servers and shares exceptions can be raises."},{"line_number":10,"context_line":"At the moment when error occurs some detail information about"},{"line_number":11,"context_line":"server/share can already exist. This information should be returned"},{"line_number":12,"context_line":"to the manager and stored in database. The best way to send this"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"9aa7fdbe_f7f56b57","line":9,"updated":"2014-10-23 16:42:38.000000000","message":"s/raises/raised/","commit_id":"11865310229821f46c37bc2a421b71bbfdad006e"},{"author":{"_account_id":6529,"name":"Vladimir Vechkanov","email":"vvechkanov@mirantis.com","username":"vvechkanov"},"change_message_id":"1b011efe6b521a908c0552b59ed1c3d62a40a9ab","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Fix share maneger to save data after drivers error"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"While creating share servers and shares exceptions can be raises."},{"line_number":10,"context_line":"At the moment when error occurs some detail information about"},{"line_number":11,"context_line":"server/share can already exist. This information should be returned"},{"line_number":12,"context_line":"to the manager and stored in database. The best way to send this"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"9aa7fdbe_49c92eab","line":9,"in_reply_to":"9aa7fdbe_f7f56b57","updated":"2014-10-24 07:55:23.000000000","message":"Done","commit_id":"11865310229821f46c37bc2a421b71bbfdad006e"},{"author":{"_account_id":11047,"name":"Mark Sturdevant","email":"mark.sturdevant@ibm.com","username":"markstur"},"change_message_id":"768d81253712e55858bfd729506f795519688a11","unresolved":false,"context_lines":[{"line_number":13,"context_line":"information is using exception which is thrown."},{"line_number":14,"context_line":"Add field detail_data to this exceptions."},{"line_number":15,"context_line":"Also make manager to save data from new field to the database"},{"line_number":16,"context_line":"when drivers throw excpetions."},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"Change-Id: I41397c881d0efd28a02c358b64229b5dc60785b3"},{"line_number":19,"context_line":"Patrialy-implemented: blueprint enhance-share-manager"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"9aa7fdbe_f79c8b11","line":16,"updated":"2014-10-23 16:42:38.000000000","message":"s/excpetions/exceptions/","commit_id":"11865310229821f46c37bc2a421b71bbfdad006e"},{"author":{"_account_id":6529,"name":"Vladimir Vechkanov","email":"vvechkanov@mirantis.com","username":"vvechkanov"},"change_message_id":"1b011efe6b521a908c0552b59ed1c3d62a40a9ab","unresolved":false,"context_lines":[{"line_number":13,"context_line":"information is using exception which is thrown."},{"line_number":14,"context_line":"Add field detail_data to this exceptions."},{"line_number":15,"context_line":"Also make manager to save data from new field to the database"},{"line_number":16,"context_line":"when drivers throw excpetions."},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"Change-Id: I41397c881d0efd28a02c358b64229b5dc60785b3"},{"line_number":19,"context_line":"Patrialy-implemented: blueprint enhance-share-manager"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"9aa7fdbe_09d3a660","line":16,"in_reply_to":"9aa7fdbe_f79c8b11","updated":"2014-10-24 07:55:23.000000000","message":"Done","commit_id":"11865310229821f46c37bc2a421b71bbfdad006e"},{"author":{"_account_id":11047,"name":"Mark Sturdevant","email":"mark.sturdevant@ibm.com","username":"markstur"},"change_message_id":"768d81253712e55858bfd729506f795519688a11","unresolved":false,"context_lines":[{"line_number":16,"context_line":"when drivers throw excpetions."},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"Change-Id: I41397c881d0efd28a02c358b64229b5dc60785b3"},{"line_number":19,"context_line":"Patrialy-implemented: blueprint enhance-share-manager"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"9aa7fdbe_77da5be9","line":19,"updated":"2014-10-23 16:42:38.000000000","message":"s/Patrialy/Partially/","commit_id":"11865310229821f46c37bc2a421b71bbfdad006e"},{"author":{"_account_id":6529,"name":"Vladimir Vechkanov","email":"vvechkanov@mirantis.com","username":"vvechkanov"},"change_message_id":"1b011efe6b521a908c0552b59ed1c3d62a40a9ab","unresolved":false,"context_lines":[{"line_number":16,"context_line":"when drivers throw excpetions."},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"Change-Id: I41397c881d0efd28a02c358b64229b5dc60785b3"},{"line_number":19,"context_line":"Patrialy-implemented: blueprint enhance-share-manager"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":2,"id":"9aa7fdbe_29d86a7a","line":19,"in_reply_to":"9aa7fdbe_77da5be9","updated":"2014-10-24 07:55:23.000000000","message":"Done","commit_id":"11865310229821f46c37bc2a421b71bbfdad006e"},{"author":{"_account_id":11878,"name":"Rushil Chugh","email":"rushil.chugh@gmail.com","username":"rushil"},"change_message_id":"a3490bee405dd543bbb5a139af0ef6741b350470","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     Vladimir Vechkanov \u003cvvechkanov@mirantis.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2014-10-24 03:44:43 -0400"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Fix share manager to save data after drivers error"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"While creating share servers and shares exceptions can be raised."},{"line_number":10,"context_line":"At the moment when error occurs some detail information about"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"9aa7fdbe_ca01706b","line":7,"updated":"2014-10-26 03:05:41.000000000","message":"\u0027after driver error\u0027","commit_id":"9ed0ebb5da5e7ddbd030f10bbd23667136d4296c"},{"author":{"_account_id":11878,"name":"Rushil Chugh","email":"rushil.chugh@gmail.com","username":"rushil"},"change_message_id":"a3490bee405dd543bbb5a139af0ef6741b350470","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Fix share manager to save data after drivers error"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"While creating share servers and shares exceptions can be raised."},{"line_number":10,"context_line":"At the moment when error occurs some detail information about"},{"line_number":11,"context_line":"server/share can already exist. This information should be returned"},{"line_number":12,"context_line":"to the manager and stored in database. The best way to send this"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"9aa7fdbe_eaf9d480","line":9,"updated":"2014-10-26 03:05:41.000000000","message":"\u0027shares, exceptions\u0027","commit_id":"9ed0ebb5da5e7ddbd030f10bbd23667136d4296c"},{"author":{"_account_id":11878,"name":"Rushil Chugh","email":"rushil.chugh@gmail.com","username":"rushil"},"change_message_id":"a3490bee405dd543bbb5a139af0ef6741b350470","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Fix share manager to save data after drivers error"},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"While creating share servers and shares exceptions can be raised."},{"line_number":10,"context_line":"At the moment when error occurs some detail information about"},{"line_number":11,"context_line":"server/share can already exist. This information should be returned"},{"line_number":12,"context_line":"to the manager and stored in database. The best way to send this"},{"line_number":13,"context_line":"information is using exception which is thrown."}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"9aa7fdbe_0af7f88b","line":10,"updated":"2014-10-26 03:05:41.000000000","message":"\u0027some information\u0027","commit_id":"9ed0ebb5da5e7ddbd030f10bbd23667136d4296c"},{"author":{"_account_id":11878,"name":"Rushil Chugh","email":"rushil.chugh@gmail.com","username":"rushil"},"change_message_id":"a3490bee405dd543bbb5a139af0ef6741b350470","unresolved":false,"context_lines":[{"line_number":11,"context_line":"server/share can already exist. This information should be returned"},{"line_number":12,"context_line":"to the manager and stored in database. The best way to send this"},{"line_number":13,"context_line":"information is using exception which is thrown."},{"line_number":14,"context_line":"Add field detail_data to this exceptions."},{"line_number":15,"context_line":"Also make manager to save data from new field to the database"},{"line_number":16,"context_line":"when drivers throw excpetions."},{"line_number":17,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":3,"id":"9aa7fdbe_2af03c90","line":14,"updated":"2014-10-26 03:05:41.000000000","message":"\u0027to these exceptions\u0027","commit_id":"9ed0ebb5da5e7ddbd030f10bbd23667136d4296c"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"b524786c8e6ce0dbf2ed262a13f65e33ff1fafd4","unresolved":false,"context_lines":[{"line_number":13,"context_line":"information is using exception which is thrown."},{"line_number":14,"context_line":"Add field detail_data to these exceptions."},{"line_number":15,"context_line":"Also make manager to save data from new field to the database"},{"line_number":16,"context_line":"when drivers throw excpetions."},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"Change-Id: I41397c881d0efd28a02c358b64229b5dc60785b3"},{"line_number":19,"context_line":"Partially-implemented: blueprint enhance-share-manager"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":7,"id":"7a8c0949_8c62bfd6","line":16,"updated":"2014-10-31 09:52:37.000000000","message":"s/excpetions/exceptions/","commit_id":"7fcde2673d2abf810419ed60302b6d72e213260f"},{"author":{"_account_id":11047,"name":"Mark Sturdevant","email":"mark.sturdevant@ibm.com","username":"markstur"},"change_message_id":"457850be54d3b6f776831038dfb5f2db19c9c472","unresolved":false,"context_lines":[{"line_number":13,"context_line":"information is using exception which is thrown."},{"line_number":14,"context_line":"Add field detail_data to these exceptions."},{"line_number":15,"context_line":"Also make manager to save data from new field to the database"},{"line_number":16,"context_line":"when drivers throw excpetions."},{"line_number":17,"context_line":""},{"line_number":18,"context_line":"Change-Id: I41397c881d0efd28a02c358b64229b5dc60785b3"},{"line_number":19,"context_line":"Partially-implemented: blueprint enhance-share-manager"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":8,"id":"7a8c0949_85cedbb2","line":16,"updated":"2014-11-05 17:26:10.000000000","message":"s/excpetions/exceptions/  -- You didn\u0027t address the old review comment.","commit_id":"11e5756d38acee7c9b67e38a93e23af81d6ad314"}],"manila/exception.py":[{"author":{"_account_id":11047,"name":"Mark Sturdevant","email":"mark.sturdevant@ibm.com","username":"markstur"},"change_message_id":"457850be54d3b6f776831038dfb5f2db19c9c472","unresolved":false,"context_lines":[{"line_number":94,"context_line":"                LOG.exception(_LE(\u0027Exception in string format operation.\u0027))"},{"line_number":95,"context_line":"                for name, value in six.iteritems(kwargs):"},{"line_number":96,"context_line":"                    LOG.error(_LE(\"%(name)s: %(value)s\"), {"},{"line_number":97,"context_line":"                        \u0027name\u0027: name, \u0027value\u0027: value})"},{"line_number":98,"context_line":"                if CONF.fatal_exception_format_errors:"},{"line_number":99,"context_line":"                    raise e"},{"line_number":100,"context_line":"                else:"}],"source_content_type":"text/x-python","patch_set":8,"id":"7a8c0949_05ff4bab","line":97,"updated":"2014-11-05 17:26:10.000000000","message":"I think you should log message so you can see what was expected.  The kwargs loop log.error seems like it should be part of the exception message instead of something separate and whether you use LOG.exception or LOG.error, it just seems to me they belong together.  Did you get this to look perfect in the log or am I maybe right?\n\nNot sure why we would localize name: value.  I don\u0027t think there is anything localizable in there (does anywhere in the world change the python colon or make k:v go right to left?).","commit_id":"11e5756d38acee7c9b67e38a93e23af81d6ad314"},{"author":{"_account_id":11878,"name":"Rushil Chugh","email":"rushil.chugh@gmail.com","username":"rushil"},"change_message_id":"892c2fc764847d8e48c6143b45417965521f305d","unresolved":false,"context_lines":[{"line_number":94,"context_line":"                LOG.exception(_LE(\u0027Exception in string format operation.\u0027))"},{"line_number":95,"context_line":"                for name, value in six.iteritems(kwargs):"},{"line_number":96,"context_line":"                    LOG.error(_LE(\"%(name)s: %(value)s\"), {"},{"line_number":97,"context_line":"                        \u0027name\u0027: name, \u0027value\u0027: value})"},{"line_number":98,"context_line":"                if CONF.fatal_exception_format_errors:"},{"line_number":99,"context_line":"                    raise e"},{"line_number":100,"context_line":"                else:"}],"source_content_type":"text/x-python","patch_set":8,"id":"7a8c0949_c0f451d1","line":97,"in_reply_to":"7a8c0949_05ff4bab","updated":"2014-11-05 18:31:54.000000000","message":"+1","commit_id":"11e5756d38acee7c9b67e38a93e23af81d6ad314"}],"manila/share/manager.py":[{"author":{"_account_id":11047,"name":"Mark Sturdevant","email":"mark.sturdevant@ibm.com","username":"markstur"},"change_message_id":"768d81253712e55858bfd729506f795519688a11","unresolved":false,"context_lines":[{"line_number":242,"context_line":"        except Exception as e:"},{"line_number":243,"context_line":"            with excutils.save_and_reraise_exception():"},{"line_number":244,"context_line":"                LOG.error(_(\"Share %s failed on creation.\"), share_id)"},{"line_number":245,"context_line":"                if getattr(e, \u0027detail_data\u0027):"},{"line_number":246,"context_line":"                    self.db.share_update("},{"line_number":247,"context_line":"                        context, share_id,"},{"line_number":248,"context_line":"                        {\u0027export_location\u0027: getattr(e, \u0027detail_data\u0027)})"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_4dfb08c1","line":245,"updated":"2014-10-23 16:42:38.000000000","message":"I think I\u0027d like \u0027export_location\u0027 instead of \u0027detail_data\u0027 so that we\u0027re more clear that this exception attribute is really meant to be used as the export_location.\n\nI would really prefer model_update. I might be wrong but I think that would be more like cinder and more powerful, but that would be a model change to return a dict containing export_location and possibly other future things to merge into a model update both in the API return value and a matching exception attribute.  Not sure if that makes sense at the moment, but I thought I\u0027d throw that out there. In case there is interest.","commit_id":"11865310229821f46c37bc2a421b71bbfdad006e"},{"author":{"_account_id":6529,"name":"Vladimir Vechkanov","email":"vvechkanov@mirantis.com","username":"vvechkanov"},"change_message_id":"1b011efe6b521a908c0552b59ed1c3d62a40a9ab","unresolved":false,"context_lines":[{"line_number":242,"context_line":"        except Exception as e:"},{"line_number":243,"context_line":"            with excutils.save_and_reraise_exception():"},{"line_number":244,"context_line":"                LOG.error(_(\"Share %s failed on creation.\"), share_id)"},{"line_number":245,"context_line":"                if getattr(e, \u0027detail_data\u0027):"},{"line_number":246,"context_line":"                    self.db.share_update("},{"line_number":247,"context_line":"                        context, share_id,"},{"line_number":248,"context_line":"                        {\u0027export_location\u0027: getattr(e, \u0027detail_data\u0027)})"}],"source_content_type":"text/x-python","patch_set":2,"id":"9aa7fdbe_e944a2b8","line":245,"in_reply_to":"9aa7fdbe_4dfb08c1","updated":"2014-10-24 07:55:23.000000000","message":"Thank you for comment. I do not like an idea to have export_location as a field in exception. Because we need export location field for share creation, server details for instance creation and so on. But I also agree with you that it is not safe to use detail_data field for any type information. So I made detail_data a dictionary and use export_location and server_details as keys in this dictionary. \n\nI also very like your idea with model update, but I think it needs more discussion and researching. But idea is great and I\u0027ll look how it can be implemented in manila share manager.","commit_id":"11865310229821f46c37bc2a421b71bbfdad006e"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"7386afe0202cb3bdff9cb8482dfe3c870144ed83","unresolved":false,"context_lines":[{"line_number":459,"context_line":"                        self.db.share_server_backend_details_set("},{"line_number":460,"context_line":"                            context, share_server[\u0027id\u0027], serv_details)"},{"line_number":461,"context_line":"                    else:"},{"line_number":462,"context_line":"                        LOG.warning(\u0027Detail server info in exeption \u0027"},{"line_number":463,"context_line":"                                    \u0027is not a dict\u0027)"},{"line_number":464,"context_line":""},{"line_number":465,"context_line":"                self.db.share_server_update(context, share_server[\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":3,"id":"9aa7fdbe_78978c3a","line":462,"updated":"2014-10-24 17:28:34.000000000","message":"Translation func should be used.","commit_id":"9ed0ebb5da5e7ddbd030f10bbd23667136d4296c"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"7386afe0202cb3bdff9cb8482dfe3c870144ed83","unresolved":false,"context_lines":[{"line_number":460,"context_line":"                            context, share_server[\u0027id\u0027], serv_details)"},{"line_number":461,"context_line":"                    else:"},{"line_number":462,"context_line":"                        LOG.warning(\u0027Detail server info in exeption \u0027"},{"line_number":463,"context_line":"                                    \u0027is not a dict\u0027)"},{"line_number":464,"context_line":""},{"line_number":465,"context_line":"                self.db.share_server_update(context, share_server[\u0027id\u0027],"},{"line_number":466,"context_line":"                                            {\u0027status\u0027: constants.STATUS_ERROR})"}],"source_content_type":"text/x-python","patch_set":3,"id":"9aa7fdbe_18a84076","line":463,"updated":"2014-10-24 17:28:34.000000000","message":"Also need provide what we have if not dict to the message.\n\nAnd little nit - dot at the end is missing.","commit_id":"9ed0ebb5da5e7ddbd030f10bbd23667136d4296c"},{"author":{"_account_id":11047,"name":"Mark Sturdevant","email":"mark.sturdevant@ibm.com","username":"markstur"},"change_message_id":"36a482b733454679cfc9384bb7b38355603143ea","unresolved":false,"context_lines":[{"line_number":461,"context_line":"                    else:"},{"line_number":462,"context_line":"                        LOG.warning(_(\u0027Detail server information in exeption \u0027"},{"line_number":463,"context_line":"                                      \u0027contains %s and it is not \u0027"},{"line_number":464,"context_line":"                                      \u0027 a dictionary.\u0027) % serv_details)"},{"line_number":465,"context_line":""},{"line_number":466,"context_line":"                self.db.share_server_update(context, share_server[\u0027id\u0027],"},{"line_number":467,"context_line":"                                            {\u0027status\u0027: constants.STATUS_ERROR})"}],"source_content_type":"text/x-python","patch_set":4,"id":"9aa7fdbe_3ddb0d7d","line":464,"updated":"2014-10-27 16:41:25.000000000","message":"Extra space at beginning (there is one at end of previous line.","commit_id":"d660032b97df1a4043527559d21ce3a9ff553929"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"b2db987a63d9ef014df1eae0703529bb4cc2d7a9","unresolved":false,"context_lines":[{"line_number":242,"context_line":"        except Exception as e:"},{"line_number":243,"context_line":"            with excutils.save_and_reraise_exception():"},{"line_number":244,"context_line":"                LOG.error(_(\"Share %s failed on creation.\"), share_id)"},{"line_number":245,"context_line":"                detail_data \u003d getattr(e, \u0027detail_data\u0027, None)"},{"line_number":246,"context_line":"                if detail_data and detail_data.get(\u0027export_location\u0027):"},{"line_number":247,"context_line":"                    self.db.share_update("},{"line_number":248,"context_line":"                        context, share_id,"}],"source_content_type":"text/x-python","patch_set":5,"id":"9aa7fdbe_4e0b98d5","line":245,"updated":"2014-10-28 17:59:54.000000000","message":"Here you can replace None with empty dict","commit_id":"1009950ab59c3e9a522298b1528edbca06bc87f1"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"b2db987a63d9ef014df1eae0703529bb4cc2d7a9","unresolved":false,"context_lines":[{"line_number":243,"context_line":"            with excutils.save_and_reraise_exception():"},{"line_number":244,"context_line":"                LOG.error(_(\"Share %s failed on creation.\"), share_id)"},{"line_number":245,"context_line":"                detail_data \u003d getattr(e, \u0027detail_data\u0027, None)"},{"line_number":246,"context_line":"                if detail_data and detail_data.get(\u0027export_location\u0027):"},{"line_number":247,"context_line":"                    self.db.share_update("},{"line_number":248,"context_line":"                        context, share_id,"},{"line_number":249,"context_line":"                        {\u0027export_location\u0027: detail_data[\u0027export_location\u0027]})"}],"source_content_type":"text/x-python","patch_set":5,"id":"9aa7fdbe_0efd10b1","line":246,"updated":"2014-10-28 17:59:54.000000000","message":"And here simplify condition as following:\n\nif detail_data.get(\u0027export_location\u0027):","commit_id":"1009950ab59c3e9a522298b1528edbca06bc87f1"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"b2db987a63d9ef014df1eae0703529bb4cc2d7a9","unresolved":false,"context_lines":[{"line_number":452,"context_line":"        except Exception as e:"},{"line_number":453,"context_line":"            with excutils.save_and_reraise_exception():"},{"line_number":454,"context_line":"                detail_data \u003d getattr(e, \u0027detail_data\u0027, None)"},{"line_number":455,"context_line":"                if detail_data and detail_data.get(\u0027server_details\u0027):"},{"line_number":456,"context_line":"                    serv_details \u003d detail_data[\u0027server_details\u0027]"},{"line_number":457,"context_line":""},{"line_number":458,"context_line":"                    if isinstance(serv_details, dict):"}],"source_content_type":"text/x-python","patch_set":5,"id":"9aa7fdbe_ae22444f","line":455,"updated":"2014-10-28 17:59:54.000000000","message":"Ditto","commit_id":"1009950ab59c3e9a522298b1528edbca06bc87f1"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"b2db987a63d9ef014df1eae0703529bb4cc2d7a9","unresolved":false,"context_lines":[{"line_number":453,"context_line":"            with excutils.save_and_reraise_exception():"},{"line_number":454,"context_line":"                detail_data \u003d getattr(e, \u0027detail_data\u0027, None)"},{"line_number":455,"context_line":"                if detail_data and detail_data.get(\u0027server_details\u0027):"},{"line_number":456,"context_line":"                    serv_details \u003d detail_data[\u0027server_details\u0027]"},{"line_number":457,"context_line":""},{"line_number":458,"context_line":"                    if isinstance(serv_details, dict):"},{"line_number":459,"context_line":"                        self.db.share_server_backend_details_set("}],"source_content_type":"text/x-python","patch_set":5,"id":"9aa7fdbe_8eb660f7","line":456,"updated":"2014-10-28 17:59:54.000000000","message":"Can you please rename it to \"server_details\" instead of \"serv_details\"?","commit_id":"1009950ab59c3e9a522298b1528edbca06bc87f1"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"b2db987a63d9ef014df1eae0703529bb4cc2d7a9","unresolved":false,"context_lines":[{"line_number":461,"context_line":"                    else:"},{"line_number":462,"context_line":"                        LOG.warning(_(\u0027Detail server information in exeption \u0027"},{"line_number":463,"context_line":"                                      \u0027contains %s and it is not \u0027"},{"line_number":464,"context_line":"                                      \u0027a dictionary.\u0027) % serv_details)"},{"line_number":465,"context_line":""},{"line_number":466,"context_line":"                self.db.share_server_update(context, share_server[\u0027id\u0027],"},{"line_number":467,"context_line":"                                            {\u0027status\u0027: constants.STATUS_ERROR})"}],"source_content_type":"text/x-python","patch_set":5,"id":"9aa7fdbe_6eaa1c86","line":464,"updated":"2014-10-28 17:59:54.000000000","message":"It is recommended to use \"replace\" obj as second parameter to LOG action.\n\nSee lines 499 and 500 below in this document.","commit_id":"1009950ab59c3e9a522298b1528edbca06bc87f1"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"ddc783c0ebd921c168726ef1687826a8c9efb482","unresolved":false,"context_lines":[{"line_number":459,"context_line":"                        self.db.share_server_backend_details_set("},{"line_number":460,"context_line":"                            context, share_server[\u0027id\u0027], server_details)"},{"line_number":461,"context_line":"                    else:"},{"line_number":462,"context_line":"                        LOG.warning(_(\u0027Detail server information in exeption \u0027"},{"line_number":463,"context_line":"                                      \u0027contains %s and it is not \u0027"},{"line_number":464,"context_line":"                                      \u0027a dictionary.\u0027), server_details)"},{"line_number":465,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"7a8c0949_fc6ce038","line":462,"updated":"2014-10-30 18:58:46.000000000","message":"Please use here \"_LW\" from i18n module.\n\nSee related change: https://review.openstack.org/#/c/131265/","commit_id":"7104820e33672db72f347a18a364a4efd04361ef"},{"author":{"_account_id":6547,"name":"Andreas Jaeger","email":"jaegerandi@gmail.com","username":"jaegerandi"},"change_message_id":"0439915967e03187eacbbed3ce4c6fd3d0e50bdc","unresolved":false,"context_lines":[{"line_number":459,"context_line":"                        self.db.share_server_backend_details_set("},{"line_number":460,"context_line":"                            context, share_server[\u0027id\u0027], server_details)"},{"line_number":461,"context_line":"                    else:"},{"line_number":462,"context_line":"                        LOG.warning(_(\u0027Detail server information in exeption \u0027"},{"line_number":463,"context_line":"                                      \u0027contains %s and it is not \u0027"},{"line_number":464,"context_line":"                                      \u0027a dictionary.\u0027), server_details)"},{"line_number":465,"context_line":""}],"source_content_type":"text/x-python","patch_set":6,"id":"7a8c0949_f73eb928","line":462,"updated":"2014-10-30 19:41:41.000000000","message":"Typo: exception","commit_id":"7104820e33672db72f347a18a364a4efd04361ef"},{"author":{"_account_id":11047,"name":"Mark Sturdevant","email":"mark.sturdevant@ibm.com","username":"markstur"},"change_message_id":"457850be54d3b6f776831038dfb5f2db19c9c472","unresolved":false,"context_lines":[{"line_number":175,"context_line":"                share_server \u003d self._setup_server(context, share_server)"},{"line_number":176,"context_line":"                LOG.info(_LI(\"Share server created successfully.\"))"},{"line_number":177,"context_line":"            else:"},{"line_number":178,"context_line":"                LOG.info(_LI(\"Used already existed share server \""},{"line_number":179,"context_line":"                             \"\u0027%(share_server_id)s\u0027\"),"},{"line_number":180,"context_line":"                         {\u0027share_server_id\u0027: share_server[\u0027id\u0027]})"},{"line_number":181,"context_line":"            return share_server, share_ref"}],"source_content_type":"text/x-python","patch_set":8,"id":"7a8c0949_e51a3f16","line":178,"updated":"2014-11-05 17:26:10.000000000","message":"I would s/existed/existing/","commit_id":"11e5756d38acee7c9b67e38a93e23af81d6ad314"},{"author":{"_account_id":11878,"name":"Rushil Chugh","email":"rushil.chugh@gmail.com","username":"rushil"},"change_message_id":"892c2fc764847d8e48c6143b45417965521f305d","unresolved":false,"context_lines":[{"line_number":463,"context_line":"                        self.db.share_server_backend_details_set("},{"line_number":464,"context_line":"                            context, share_server[\u0027id\u0027], server_details)"},{"line_number":465,"context_line":"                    else:"},{"line_number":466,"context_line":"                        LOG.warning(_LW(\u0027Detail server information in \u0027"},{"line_number":467,"context_line":"                                        \u0027exception contains %s and it is not \u0027"},{"line_number":468,"context_line":"                                        \u0027a dictionary.\u0027), server_details)"},{"line_number":469,"context_line":""}],"source_content_type":"text/x-python","patch_set":8,"id":"7a8c0949_001659f1","line":466,"updated":"2014-11-05 18:31:54.000000000","message":"s/Detail server information/Server Information","commit_id":"11e5756d38acee7c9b67e38a93e23af81d6ad314"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"c15df36fde18d9eb51508a1e05d856812f62534f","unresolved":false,"context_lines":[{"line_number":464,"context_line":"                            context, share_server[\u0027id\u0027], server_details)"},{"line_number":465,"context_line":"                    else:"},{"line_number":466,"context_line":"                        LOG.warning(_LW(\u0027Server Information in \u0027"},{"line_number":467,"context_line":"                                        \u0027exception contains %s and it is not \u0027"},{"line_number":468,"context_line":"                                        \u0027a dictionary.\u0027), server_details)"},{"line_number":469,"context_line":""},{"line_number":470,"context_line":"                self.db.share_server_update(context, share_server[\u0027id\u0027],"}],"source_content_type":"text/x-python","patch_set":9,"id":"5a890539_36ee998c","line":467,"updated":"2014-11-09 10:30:03.000000000","message":"The message should also say that server information cannot be saved in the database.","commit_id":"b2d3bb0db1a71a85cf0e0257a4b0d754c5b64324"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"3269e328dbd492df456d29ee8f6308c18e8a7a8e","unresolved":false,"context_lines":[{"line_number":247,"context_line":"            with excutils.save_and_reraise_exception():"},{"line_number":248,"context_line":"                LOG.error(_LE(\"Share %s failed on creation.\"), share_id)"},{"line_number":249,"context_line":"                detail_data \u003d getattr(e, \u0027detail_data\u0027, {})"},{"line_number":250,"context_line":"                if detail_data.get(\u0027export_location\u0027):"},{"line_number":251,"context_line":"                    self.db.share_update("},{"line_number":252,"context_line":"                        context, share_id,"},{"line_number":253,"context_line":"                        {\u0027export_location\u0027: detail_data[\u0027export_location\u0027]})"}],"source_content_type":"text/x-python","patch_set":10,"id":"5a890539_4ad36938","line":250,"updated":"2014-11-10 13:52:25.000000000","message":"If it is set and not dict you will get attribute error exception here. Need to add here verification for it and add related tests that cover that change.","commit_id":"258de56b9aa843be2f62e6131259942e42d177ef"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"cee136ca1dd271e5629b8f7d2df7cd77167f07eb","unresolved":false,"context_lines":[{"line_number":247,"context_line":"            with excutils.save_and_reraise_exception():"},{"line_number":248,"context_line":"                LOG.error(_LE(\"Share %s failed on creation.\"), share_id)"},{"line_number":249,"context_line":"                detail_data \u003d getattr(e, \u0027detail_data\u0027, {})"},{"line_number":250,"context_line":"                if (type(detail_data) is dict and"},{"line_number":251,"context_line":"                        detail_data.get(\u0027export_location\u0027)):"},{"line_number":252,"context_line":"                    self.db.share_update("},{"line_number":253,"context_line":"                        context, share_id,"}],"source_content_type":"text/x-python","patch_set":11,"id":"5a890539_532cea47","line":250,"updated":"2014-11-11 16:30:28.000000000","message":"Please, use \"isinstance(...)\" instead of \"type(...) is ..\"","commit_id":"c2f1b5c0857acf11c37252339767a9cea029fb2a"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"cee136ca1dd271e5629b8f7d2df7cd77167f07eb","unresolved":false,"context_lines":[{"line_number":251,"context_line":"                        detail_data.get(\u0027export_location\u0027)):"},{"line_number":252,"context_line":"                    self.db.share_update("},{"line_number":253,"context_line":"                        context, share_id,"},{"line_number":254,"context_line":"                        {\u0027export_location\u0027: detail_data[\u0027export_location\u0027]})"},{"line_number":255,"context_line":"                self.db.share_update(context, share_id, {\u0027status\u0027: \u0027error\u0027})"},{"line_number":256,"context_line":"        else:"},{"line_number":257,"context_line":"            LOG.info(_LI(\"Share created successfully.\"))"}],"source_content_type":"text/x-python","patch_set":11,"id":"5a890539_33de7e40","line":254,"updated":"2014-11-11 16:30:28.000000000","message":"Also, I propose add here some logging as you did for share server creation operation.","commit_id":"c2f1b5c0857acf11c37252339767a9cea029fb2a"},{"author":{"_account_id":7102,"name":"Thomas Bechtold","email":"thomas.bechtold@chainguard.dev","username":"toabctl"},"change_message_id":"1fb30033fb4a26c1212104a14ed1c658048f4dfe","unresolved":false,"context_lines":[{"line_number":457,"context_line":"        except Exception as e:"},{"line_number":458,"context_line":"            with excutils.save_and_reraise_exception():"},{"line_number":459,"context_line":"                detail_data \u003d getattr(e, \u0027detail_data\u0027, {})"},{"line_number":460,"context_line":"                if (type(detail_data) is dict and"},{"line_number":461,"context_line":"                        detail_data.get(\u0027server_details\u0027)):"},{"line_number":462,"context_line":""},{"line_number":463,"context_line":"                    server_details \u003d detail_data[\u0027server_details\u0027]"}],"source_content_type":"text/x-python","patch_set":11,"id":"5a890539_ce558d1e","line":460,"updated":"2014-11-11 17:13:02.000000000","message":"As Valeriy already mentioned earlier, please use also here isinstance() instead of type()","commit_id":"c2f1b5c0857acf11c37252339767a9cea029fb2a"}],"manila/tests/share/test_manager.py":[{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"7386afe0202cb3bdff9cb8482dfe3c870144ed83","unresolved":false,"context_lines":[{"line_number":951,"context_line":"            context, share_server[\u0027id\u0027], {\u0027status\u0027: constants.STATUS_ERROR})"},{"line_number":952,"context_line":"        self.share_manager.network_api.deallocate_network.\\"},{"line_number":953,"context_line":"            assert_called_once_with(context, share_network)"},{"line_number":954,"context_line":""},{"line_number":955,"context_line":"    def test_setup_server_exception_in_driver(self):"},{"line_number":956,"context_line":"        # Setup required test data"},{"line_number":957,"context_line":"        context \u003d \"fake_context\""}],"source_content_type":"text/x-python","patch_set":3,"id":"9aa7fdbe_588008c0","line":954,"updated":"2014-10-24 17:28:34.000000000","message":"Absent test that verifies db update for share creation failure.","commit_id":"9ed0ebb5da5e7ddbd030f10bbd23667136d4296c"},{"author":{"_account_id":11878,"name":"Rushil Chugh","email":"rushil.chugh@gmail.com","username":"rushil"},"change_message_id":"a3490bee405dd543bbb5a139af0ef6741b350470","unresolved":false,"context_lines":[{"line_number":951,"context_line":"            context, share_server[\u0027id\u0027], {\u0027status\u0027: constants.STATUS_ERROR})"},{"line_number":952,"context_line":"        self.share_manager.network_api.deallocate_network.\\"},{"line_number":953,"context_line":"            assert_called_once_with(context, share_network)"},{"line_number":954,"context_line":""},{"line_number":955,"context_line":"    def test_setup_server_exception_in_driver(self):"},{"line_number":956,"context_line":"        # Setup required test data"},{"line_number":957,"context_line":"        context \u003d \"fake_context\""}],"source_content_type":"text/x-python","patch_set":3,"id":"9aa7fdbe_aafc2c73","line":954,"in_reply_to":"9aa7fdbe_588008c0","updated":"2014-10-26 03:05:41.000000000","message":"+1","commit_id":"9ed0ebb5da5e7ddbd030f10bbd23667136d4296c"},{"author":{"_account_id":11878,"name":"Rushil Chugh","email":"rushil.chugh@gmail.com","username":"rushil"},"change_message_id":"a3490bee405dd543bbb5a139af0ef6741b350470","unresolved":false,"context_lines":[{"line_number":964,"context_line":"        network_info \u003d {\u0027fake_network_info_key\u0027: \u0027fake_network_info_value\u0027}"},{"line_number":965,"context_line":"        allocation_number \u003d 0"},{"line_number":966,"context_line":""},{"line_number":967,"context_line":"        # mock required stuff"},{"line_number":968,"context_line":"        self.stubs.Set(self.share_manager.db, \u0027share_network_get\u0027,"},{"line_number":969,"context_line":"                       mock.Mock(return_value\u003dshare_network))"},{"line_number":970,"context_line":"        self.stubs.Set(self.share_manager.driver,"}],"source_content_type":"text/x-python","patch_set":3,"id":"9aa7fdbe_4ad660f2","line":967,"updated":"2014-10-26 03:05:41.000000000","message":"\u0027Stuff\u0027 is not appropriate here. \u0027Mock required parameters\u0027 is a more suitable comment.","commit_id":"9ed0ebb5da5e7ddbd030f10bbd23667136d4296c"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"8df02505071a6d561b46f632dfebdf0e16ffb709","unresolved":false,"context_lines":[{"line_number":581,"context_line":"            self.context,"},{"line_number":582,"context_line":"            share_id"},{"line_number":583,"context_line":"        )"},{"line_number":584,"context_line":"        self.share_manager.driver.create_share.assert_called_once()"},{"line_number":585,"context_line":"        shr \u003d db.share_get(self.context, share_id)"},{"line_number":586,"context_line":"        self.assertEqual(shr[\u0027export_location\u0027], some_data)"},{"line_number":587,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"9aa7fdbe_2ed3b460","line":584,"updated":"2014-10-28 17:55:42.000000000","message":"mock obj does not have method \"assert_called_once\". So, you do not assert here nothing.\n\nSee bug: https://bugs.launchpad.net/manila/+bug/1330391","commit_id":"1009950ab59c3e9a522298b1528edbca06bc87f1"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"6de4d1de6d0b4da67f877f62ae9257b37b61abb9","unresolved":false,"context_lines":[{"line_number":581,"context_line":"            self.context,"},{"line_number":582,"context_line":"            share_id"},{"line_number":583,"context_line":"        )"},{"line_number":584,"context_line":"        self.share_manager.driver.create_share.assert_called_once()"},{"line_number":585,"context_line":"        shr \u003d db.share_get(self.context, share_id)"},{"line_number":586,"context_line":"        self.assertEqual(shr[\u0027export_location\u0027], some_data)"},{"line_number":587,"context_line":""}],"source_content_type":"text/x-python","patch_set":5,"id":"7a8c0949_88256bad","line":584,"in_reply_to":"9aa7fdbe_2ed3b460","updated":"2014-10-30 04:56:38.000000000","message":"Agree with Valeriy.","commit_id":"1009950ab59c3e9a522298b1528edbca06bc87f1"},{"author":{"_account_id":6491,"name":"xing-yang","email":"xingyang105@gmail.com","username":"xing-yang"},"change_message_id":"6de4d1de6d0b4da67f877f62ae9257b37b61abb9","unresolved":false,"context_lines":[{"line_number":583,"context_line":"        )"},{"line_number":584,"context_line":"        self.share_manager.driver.create_share.assert_called_once()"},{"line_number":585,"context_line":"        shr \u003d db.share_get(self.context, share_id)"},{"line_number":586,"context_line":"        self.assertEqual(shr[\u0027export_location\u0027], some_data)"},{"line_number":587,"context_line":""},{"line_number":588,"context_line":"    def test_create_share_with_server_created(self):"},{"line_number":589,"context_line":"        \"\"\"Test share can be created and share server is created.\"\"\""}],"source_content_type":"text/x-python","patch_set":5,"id":"7a8c0949_e8334ff4","line":586,"updated":"2014-10-30 04:56:38.000000000","message":"This should be reversed as some_data is expected and shr[\u0027export_location\u0027] is actual.","commit_id":"1009950ab59c3e9a522298b1528edbca06bc87f1"},{"author":{"_account_id":11878,"name":"Rushil Chugh","email":"rushil.chugh@gmail.com","username":"rushil"},"change_message_id":"892c2fc764847d8e48c6143b45417965521f305d","unresolved":false,"context_lines":[{"line_number":570,"context_line":"        \"\"\"Test db updates if share creation fails in driver.\"\"\""},{"line_number":571,"context_line":"        share \u003d self._create_share()"},{"line_number":572,"context_line":"        share_id \u003d share[\u0027id\u0027]"},{"line_number":573,"context_line":"        some_data \u003d \"fake_location\""},{"line_number":574,"context_line":"        self.share_manager.driver \u003d mock.Mock()"},{"line_number":575,"context_line":"        e \u003d exception.ManilaException("},{"line_number":576,"context_line":"            detail_data\u003d{\u0027export_location\u0027: some_data})"}],"source_content_type":"text/x-python","patch_set":8,"id":"7a8c0949_20bb55e6","line":573,"updated":"2014-11-05 18:31:54.000000000","message":"The quotes should be uniform, either double or single. As, in all the other places I see single quotes -\u003e s/\"fake_location\"/\u0027fake_location\u0027","commit_id":"11e5756d38acee7c9b67e38a93e23af81d6ad314"}]}
