)]}'
{"neutron/tests/common/net_helpers.py":[{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"fc35910a7dee50c99c8e7e51e68886dae8dbfac0","unresolved":false,"context_lines":[{"line_number":928,"context_line":"    def allocate_port(self):"},{"line_number":929,"context_line":"        try:"},{"line_number":930,"context_line":"            return self.unallocated_ports.pop()"},{"line_number":931,"context_line":"        except KeyError:"},{"line_number":932,"context_line":"            tools.fail(\u0027All FakeBridge ports (%s) are already allocated.\u0027 %"},{"line_number":933,"context_line":"                       len(self.ports))"},{"line_number":934,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"7f231b9d_00bacabf","line":931,"range":{"start_line":931,"start_character":15,"end_line":931,"end_character":23},"updated":"2017-06-14 16:20:11.000000000","message":"IndexError","commit_id":"d514a51253edad788d269e20c6f08dbe3cefe2bf"},{"author":{"_account_id":21798,"name":"Bernard Cafarelli","email":"bcafarel@redhat.com","username":"bcafarel"},"change_message_id":"1569abb2255272432b6cba54dd4eef76e0fc2b79","unresolved":false,"context_lines":[{"line_number":928,"context_line":"    def allocate_port(self):"},{"line_number":929,"context_line":"        try:"},{"line_number":930,"context_line":"            return self.unallocated_ports.pop()"},{"line_number":931,"context_line":"        except KeyError:"},{"line_number":932,"context_line":"            tools.fail(\u0027All FakeBridge ports (%s) are already allocated.\u0027 %"},{"line_number":933,"context_line":"                       len(self.ports))"},{"line_number":934,"context_line":""}],"source_content_type":"text/x-python","patch_set":1,"id":"7f231b9d_fb29c389","line":931,"range":{"start_line":931,"start_character":15,"end_line":931,"end_character":23},"in_reply_to":"7f231b9d_00bacabf","updated":"2017-06-14 16:30:12.000000000","message":"Oh indeed, thanks!","commit_id":"d514a51253edad788d269e20c6f08dbe3cefe2bf"},{"author":{"_account_id":841,"name":"Akihiro Motoki","email":"amotoki@gmail.com","username":"amotoki"},"change_message_id":"804181b7e309f88f4f9627d6dfbd6681d02a0827","unresolved":false,"context_lines":[{"line_number":923,"context_line":""},{"line_number":924,"context_line":"    def __init__(self, ports):"},{"line_number":925,"context_line":"        self.ports \u003d ports"},{"line_number":926,"context_line":"        self.unallocated_ports \u003d list(self.ports)"},{"line_number":927,"context_line":""},{"line_number":928,"context_line":"    def allocate_port(self):"},{"line_number":929,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":2,"id":"7f231b9d_4410b6a8","line":926,"updated":"2017-06-15 14:09:12.000000000","message":"This is a test helper, so I think we can assume developers specify unique entries. A safer way is:\n\n  list(set(self.ports))\n\nbut I am not sure we need such.","commit_id":"681f61124915209d5e20c9640c27166200803aac"},{"author":{"_account_id":8655,"name":"Jakub Libosvar","email":"libosvar@redhat.com","username":"jlibosva"},"change_message_id":"773264bd3ce6596f525daacd7e9221a20a5ff90b","unresolved":false,"context_lines":[{"line_number":923,"context_line":""},{"line_number":924,"context_line":"    def __init__(self, ports):"},{"line_number":925,"context_line":"        self.ports \u003d ports"},{"line_number":926,"context_line":"        self.unallocated_ports \u003d list(self.ports)"},{"line_number":927,"context_line":""},{"line_number":928,"context_line":"    def allocate_port(self):"},{"line_number":929,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":2,"id":"7f231b9d_94a6fdaa","line":926,"in_reply_to":"7f231b9d_4410b6a8","updated":"2017-06-15 15:30:46.000000000","message":"set(self.ports) doesn\u0027t work with py3\n\nwhich makes me think if we should implement the __hash__ instead for IPDevice?","commit_id":"681f61124915209d5e20c9640c27166200803aac"},{"author":{"_account_id":841,"name":"Akihiro Motoki","email":"amotoki@gmail.com","username":"amotoki"},"change_message_id":"49dcaa73575e70a5d86e7eca9c28003c9934638e","unresolved":false,"context_lines":[{"line_number":923,"context_line":""},{"line_number":924,"context_line":"    def __init__(self, ports):"},{"line_number":925,"context_line":"        self.ports \u003d ports"},{"line_number":926,"context_line":"        self.unallocated_ports \u003d list(self.ports)"},{"line_number":927,"context_line":""},{"line_number":928,"context_line":"    def allocate_port(self):"},{"line_number":929,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":2,"id":"7f231b9d_8abff4a8","line":926,"in_reply_to":"7f231b9d_94a6fdaa","updated":"2017-06-15 16:28:31.000000000","message":"Ah... I forgot the original problem.\n\nImplementing __hash__ sounds a good idea.\n\n  def __hash__(self):\n      return hash((self._name, self.namespace))\n\nDoes this work?","commit_id":"681f61124915209d5e20c9640c27166200803aac"},{"author":{"_account_id":21798,"name":"Bernard Cafarelli","email":"bcafarel@redhat.com","username":"bcafarel"},"change_message_id":"d08e740da88f378c1614cc4aabf1a9eebdb71876","unresolved":false,"context_lines":[{"line_number":923,"context_line":""},{"line_number":924,"context_line":"    def __init__(self, ports):"},{"line_number":925,"context_line":"        self.ports \u003d ports"},{"line_number":926,"context_line":"        self.unallocated_ports \u003d list(self.ports)"},{"line_number":927,"context_line":""},{"line_number":928,"context_line":"    def allocate_port(self):"},{"line_number":929,"context_line":"        try:"}],"source_content_type":"text/x-python","patch_set":2,"id":"7f231b9d_ca672ce9","line":926,"in_reply_to":"7f231b9d_94a6fdaa","updated":"2017-06-15 16:16:51.000000000","message":"Yes, that was the other option (probably returning id or something like that)","commit_id":"681f61124915209d5e20c9640c27166200803aac"}]}
