)]}'
{"/COMMIT_MSG":[{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"e38e94962188c5bf37174a970bd044b0b5ec0985","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     gstepanov \u003cgstepanov@mirantis.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2015-03-20 15:34:27 +0200"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Fix wrong attribte name."},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Fix wrong attribute name in repr method and host"},{"line_number":10,"context_line":"unit test. Name changed from host to host_name,"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"1a6ced46_dcc99a7a","line":7,"updated":"2015-03-24 16:19:30.000000000","message":"s/attribte/attribute/\n\nAnd better to reword it specifying more details:\n\n\"\"\"Fix usage of hostname for \u0027Host\u0027 resource\"\"\"","commit_id":"6c6feaf5462dec7352b7055ed82d400bd4314edf"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"9ba8f2b809bdf14f790353e7422a0cbef8d92b3e","unresolved":false,"context_lines":[{"line_number":4,"context_line":"Commit:     gstepanov \u003cgstepanov@mirantis.com\u003e"},{"line_number":5,"context_line":"CommitDate: 2015-03-20 15:34:27 +0200"},{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Fix wrong attribte name."},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Fix wrong attribute name in repr method and host"},{"line_number":10,"context_line":"unit test. Name changed from host to host_name,"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"1a6ced46_15686586","line":7,"in_reply_to":"1a6ced46_dcc99a7a","updated":"2015-03-24 16:26:08.000000000","message":"P.S. How to write good commit messages: https://wiki.openstack.org/wiki/GitCommitMessages","commit_id":"6c6feaf5462dec7352b7055ed82d400bd4314edf"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"e38e94962188c5bf37174a970bd044b0b5ec0985","unresolved":false,"context_lines":[{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Fix wrong attribute name in repr method and host"},{"line_number":10,"context_line":"unit test. Name changed from host to host_name,"},{"line_number":11,"context_line":"that corresponds to nova api."},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Change-Id: Ib14ce7570ab4f6101038f93d6ef15a823f8074e7"},{"line_number":14,"context_line":"Closes-Bug: #1434167"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":4,"id":"1a6ced46_9ab482d2","line":11,"updated":"2015-03-24 16:19:30.000000000","message":"There are two of keys that correspond to Nova API.\n\nSo, goal is not described as well as could be:\n\n\"\"\"\n\nNova API \"list hosts\" and other \"host\" APIs have different names for one thing. For the former it is \"host_name\" and for the latter it is \"host\".\n\nSo, make client understand both to avoid unhandled exception \"AttributeError\".\n\n\"\"\"","commit_id":"6c6feaf5462dec7352b7055ed82d400bd4314edf"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"ebaa7ce1623dead8f268cc3764f1004b90f1695e","unresolved":false,"context_lines":[{"line_number":6,"context_line":""},{"line_number":7,"context_line":"Fix hostname usage for Host resource."},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Adding property to deal with different Nova API"},{"line_number":10,"context_line":"calls, that use different attribute names to"},{"line_number":11,"context_line":"avoid AttributeError"},{"line_number":12,"context_line":""}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"1a6ced46_b90cc7ee","line":9,"updated":"2015-03-25 11:57:16.000000000","message":"It is recommended to use imperative mood.\n\ns/Adding/Add/","commit_id":"c454c9f7713eaf607c26b117b5ee0ac66cf9bd25"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"ebaa7ce1623dead8f268cc3764f1004b90f1695e","unresolved":false,"context_lines":[{"line_number":7,"context_line":"Fix hostname usage for Host resource."},{"line_number":8,"context_line":""},{"line_number":9,"context_line":"Adding property to deal with different Nova API"},{"line_number":10,"context_line":"calls, that use different attribute names to"},{"line_number":11,"context_line":"avoid AttributeError"},{"line_number":12,"context_line":""},{"line_number":13,"context_line":"Change-Id: Ib14ce7570ab4f6101038f93d6ef15a823f8074e7"}],"source_content_type":"text/x-gerrit-commit-message","patch_set":5,"id":"1a6ced46_19d07b1e","line":10,"updated":"2015-03-25 11:57:16.000000000","message":"Also commit message does not mention \"Host\", \"resource\" /host/host_name at all.","commit_id":"c454c9f7713eaf607c26b117b5ee0ac66cf9bd25"}],"bug_reproduce.py":[{"author":{"_account_id":2750,"name":"Sean Dague","email":"sean@dague.net","username":"sdague"},"change_message_id":"dc8c561bde9ad3d61a7c808efe8366868a387a4d","unresolved":false,"context_lines":[{"line_number":1,"context_line":"__author__ \u003d \u0027gstepanov\u0027"}],"source_content_type":"text/x-python","patch_set":1,"id":"9a80dd14_ebd640f1","line":1,"updated":"2015-03-19 16:32:50.000000000","message":"why is this file here?","commit_id":"6b1477c7c80c2084ac743bc4777bf4634bec6562"}],"novaclient/tests/unit/fixture_data/hosts.py":[{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"043ebf515bd988cc92430d4440d57026d626ed42","unresolved":false,"context_lines":[{"line_number":25,"context_line":""},{"line_number":26,"context_line":"        get_os_hosts_host \u003d {"},{"line_number":27,"context_line":"            \u0027host\u0027: ["},{"line_number":28,"context_line":"                {\u0027resource\u0027: {\u0027project\u0027: \u0027(total)\u0027, \u0027host_name\u0027: \u0027dummy\u0027,"},{"line_number":29,"context_line":"                 \u0027cpu\u0027: 16, \u0027memory_mb\u0027: 32234, \u0027disk_gb\u0027: 128}},"},{"line_number":30,"context_line":"                {\u0027resource\u0027: {\u0027project\u0027: \u0027(used_now)\u0027, \u0027host_name\u0027: \u0027dummy\u0027,"},{"line_number":31,"context_line":"                 \u0027cpu\u0027: 1, \u0027memory_mb\u0027: 2075, \u0027disk_gb\u0027: 45}},"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6ced46_f6bbf3c1","line":28,"updated":"2015-03-24 00:18:20.000000000","message":"The original format \"host\" is correct for this call, equivalent of\n\n /v2/{tenant_id}/os-hosts/{host_name}\n\nso we shouldn\u0027t be changing this.","commit_id":"6c6feaf5462dec7352b7055ed82d400bd4314edf"},{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"043ebf515bd988cc92430d4440d57026d626ed42","unresolved":false,"context_lines":[{"line_number":62,"context_line":"            return {"},{"line_number":63,"context_line":"                \u0027hosts\u0027: ["},{"line_number":64,"context_line":"                    {"},{"line_number":65,"context_line":"                        \u0027host\u0027: \u0027host1\u0027,"},{"line_number":66,"context_line":"                        \u0027service\u0027: service or \u0027nova-compute\u0027,"},{"line_number":67,"context_line":"                        \u0027zone\u0027: zone"},{"line_number":68,"context_line":"                    },"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6ced46_76c70346","line":65,"updated":"2015-03-24 00:18:20.000000000","message":"But this one is wrong, this should be \u0027host_name\u0027 according to the nova api documentation, equivalent of\n\n /v2/{tenant_id}/os-hosts","commit_id":"6c6feaf5462dec7352b7055ed82d400bd4314edf"}],"novaclient/v2/hosts.py":[{"author":{"_account_id":4690,"name":"melanie witt","display_name":"melwitt","email":"melwittt@gmail.com","username":"melwitt"},"change_message_id":"043ebf515bd988cc92430d4440d57026d626ed42","unresolved":false,"context_lines":[{"line_number":21,"context_line":""},{"line_number":22,"context_line":"class Host(base.Resource):"},{"line_number":23,"context_line":"    def __repr__(self):"},{"line_number":24,"context_line":"        return \"\u003cHost: %s\u003e\" % self.host_name"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"    def _add_details(self, info):"},{"line_number":27,"context_line":"        dico \u003d \u0027resource\u0027 in info and info[\u0027resource\u0027] or info"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6ced46_56f8477c","line":24,"updated":"2015-03-24 00:18:20.000000000","message":"This is actually conditional, unfortunately. For the listing of hosts, host_name is correct, but for all other calls, host is correct.","commit_id":"6c6feaf5462dec7352b7055ed82d400bd4314edf"},{"author":{"_account_id":8851,"name":"Valeriy Ponomaryov","email":"kiparis.kh@gmail.com","username":"vponomaryov"},"change_message_id":"e38e94962188c5bf37174a970bd044b0b5ec0985","unresolved":false,"context_lines":[{"line_number":21,"context_line":""},{"line_number":22,"context_line":"class Host(base.Resource):"},{"line_number":23,"context_line":"    def __repr__(self):"},{"line_number":24,"context_line":"        return \"\u003cHost: %s\u003e\" % self.host_name"},{"line_number":25,"context_line":""},{"line_number":26,"context_line":"    def _add_details(self, info):"},{"line_number":27,"context_line":"        dico \u003d \u0027resource\u0027 in info and info[\u0027resource\u0027] or info"}],"source_content_type":"text/x-python","patch_set":4,"id":"1a6ced46_3f00e000","line":24,"in_reply_to":"1a6ced46_56f8477c","updated":"2015-03-24 16:19:30.000000000","message":"Since Nova provides two different keys for the same thing then need to consider them both.\n\nYou can achieve it, for example, using property as abstraction, that will be used in all places as well.\n\nExample:\n\n\"\"\"\n\n# getter:\n\n@property\n\ndef host(self):\n\n    if not hasattr(self, \u0027_hostname\u0027):\n\n        self.host \u003d getattr(self, \u0027host\u0027, getattr(self, \u0027host_name\u0027))\n\n    return self._hostname\n\n# and setter:\n\n@host.setter\n\ndef host(self, value):\n\n    self._hostname \u003d value\n\n\"\"\"","commit_id":"6c6feaf5462dec7352b7055ed82d400bd4314edf"},{"author":{"_account_id":679,"name":"Kevin L. Mitchell","email":"klmitch@mit.edu","username":"klmitch"},"change_message_id":"05af231f845663cfd498b30381025ad785404f5b","unresolved":false,"context_lines":[{"line_number":29,"context_line":"            setattr(self, k, v)"},{"line_number":30,"context_line":""},{"line_number":31,"context_line":"    def update(self, values):"},{"line_number":32,"context_line":"        return self.manager.update(self.host, values)"},{"line_number":33,"context_line":""},{"line_number":34,"context_line":"    def startup(self):"},{"line_number":35,"context_line":"        return self.manager.host_action(self.host, \u0027startup\u0027)"}],"source_content_type":"text/x-python","patch_set":4,"id":"9a80dd14_b04647a5","line":32,"updated":"2015-03-20 14:48:28.000000000","message":"The problem you\u0027re fixing has wider ramifications, apparently.  Almost all of the methods in the resource use the incorrect \"host\" attribute, instead of \"host_name\".  Since this is related to the original bug, I\u0027d appreciate it if you could correct all the methods that are using \"host\".\n\n(For that matter, given the change to the fakes, I suspect tests may not pass without correcting these methods…)","commit_id":"6c6feaf5462dec7352b7055ed82d400bd4314edf"}]}
