)]}'
{"dragonflow/db/api_nb.py":[{"author":{"_account_id":11343,"name":"Gal Sagie","email":"gal.sagie@gmail.com","username":"GalSagie"},"change_message_id":"a0cea62cbf7ef526e0ee21397487b539134049fa","unresolved":false,"context_lines":[{"line_number":217,"context_line":"            else:"},{"line_number":218,"context_line":"                ovs_port_id \u003d key"},{"line_number":219,"context_line":"                self.controller.ovs_port_deleted(ovs_port_id)"},{"line_number":220,"context_line":"        elif \u0027_test\u0027 \u003d\u003d table:"},{"line_number":221,"context_line":"            # Do nothing. This table is for testing only."},{"line_number":222,"context_line":"            pass"},{"line_number":223,"context_line":"        else:"}],"source_content_type":"text/x-python","patch_set":1,"id":"da0c15f0_ca79ab31","line":220,"updated":"2016-03-25 13:00:02.000000000","message":"Also if you are using a constant, then it make sense to also use it here, but as my comment below we should avoid bringing testing logic into our normal logic","commit_id":"386d000f7446a99daae883429d3884e108870f84"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"c15efa89b5fa90440f9eeea9694f931bf0558845","unresolved":false,"context_lines":[{"line_number":217,"context_line":"            else:"},{"line_number":218,"context_line":"                ovs_port_id \u003d key"},{"line_number":219,"context_line":"                self.controller.ovs_port_deleted(ovs_port_id)"},{"line_number":220,"context_line":"        elif \u0027_test\u0027 \u003d\u003d table:"},{"line_number":221,"context_line":"            # Do nothing. This table is for testing only."},{"line_number":222,"context_line":"            pass"},{"line_number":223,"context_line":"        else:"}],"source_content_type":"text/x-python","patch_set":1,"id":"da0c15f0_99c6ce47","line":220,"in_reply_to":"da0c15f0_ca79ab31","updated":"2016-03-27 04:48:23.000000000","message":"Will do, if the whole thing doesn\u0027t get revamped.","commit_id":"386d000f7446a99daae883429d3884e108870f84"},{"author":{"_account_id":7805,"name":"Li Ma","email":"skywalker.nick@gmail.com","username":"Nick"},"change_message_id":"1123acaf1d2ab0acf16cb883551e81462856ab4a","unresolved":false,"context_lines":[{"line_number":217,"context_line":"            else:"},{"line_number":218,"context_line":"                ovs_port_id \u003d key"},{"line_number":219,"context_line":"                self.controller.ovs_port_deleted(ovs_port_id)"},{"line_number":220,"context_line":"        elif \u0027_test\u0027 \u003d\u003d table:"},{"line_number":221,"context_line":"            # Do nothing. This table is for testing only."},{"line_number":222,"context_line":"            pass"},{"line_number":223,"context_line":"        else:"},{"line_number":224,"context_line":"            LOG.error(_LE(\u0027Unknown table %s\u0027), table)"},{"line_number":225,"context_line":""},{"line_number":226,"context_line":"    def sync(self):"},{"line_number":227,"context_line":"        pass"}],"source_content_type":"text/x-python","patch_set":1,"id":"da0c15f0_5b5bc554","line":224,"range":{"start_line":220,"start_character":8,"end_line":224,"end_character":53},"updated":"2016-03-25 01:50:27.000000000","message":"In my opinion, we just need to LOG.debug these unknown table.","commit_id":"386d000f7446a99daae883429d3884e108870f84"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"97c2631cbbbbfd42046f32d91a86bbd3d22ae11d","unresolved":false,"context_lines":[{"line_number":217,"context_line":"            else:"},{"line_number":218,"context_line":"                ovs_port_id \u003d key"},{"line_number":219,"context_line":"                self.controller.ovs_port_deleted(ovs_port_id)"},{"line_number":220,"context_line":"        elif \u0027_test\u0027 \u003d\u003d table:"},{"line_number":221,"context_line":"            # Do nothing. This table is for testing only."},{"line_number":222,"context_line":"            pass"},{"line_number":223,"context_line":"        else:"},{"line_number":224,"context_line":"            LOG.error(_LE(\u0027Unknown table %s\u0027), table)"},{"line_number":225,"context_line":""},{"line_number":226,"context_line":"    def sync(self):"},{"line_number":227,"context_line":"        pass"}],"source_content_type":"text/x-python","patch_set":1,"id":"da0c15f0_8f81854d","line":224,"range":{"start_line":220,"start_character":8,"end_line":224,"end_character":53},"in_reply_to":"da0c15f0_061d6d73","updated":"2016-03-25 12:34:27.000000000","message":"In theory, we should never reach the point where we get an event on an unknown table. This is something I would like to know. As it is something that should never happen, I don\u0027t think it needs to be suppressed.\n\nOn the other hand, it isn\u0027t an error, just a warning. If you agree, I\u0027ll change that here as well.","commit_id":"386d000f7446a99daae883429d3884e108870f84"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"c15efa89b5fa90440f9eeea9694f931bf0558845","unresolved":false,"context_lines":[{"line_number":217,"context_line":"            else:"},{"line_number":218,"context_line":"                ovs_port_id \u003d key"},{"line_number":219,"context_line":"                self.controller.ovs_port_deleted(ovs_port_id)"},{"line_number":220,"context_line":"        elif \u0027_test\u0027 \u003d\u003d table:"},{"line_number":221,"context_line":"            # Do nothing. This table is for testing only."},{"line_number":222,"context_line":"            pass"},{"line_number":223,"context_line":"        else:"},{"line_number":224,"context_line":"            LOG.error(_LE(\u0027Unknown table %s\u0027), table)"},{"line_number":225,"context_line":""},{"line_number":226,"context_line":"    def sync(self):"},{"line_number":227,"context_line":"        pass"}],"source_content_type":"text/x-python","patch_set":1,"id":"da0c15f0_b9cbd252","line":224,"range":{"start_line":220,"start_character":8,"end_line":224,"end_character":53},"in_reply_to":"da0c15f0_0f7f35ab","updated":"2016-03-27 04:48:23.000000000","message":"In general, I agree. However, in this case, the DF controller and publisher service are already running as services when the tests begin. Modifying them by setting mock objects is not possible. By using the publisher service, the event must be reached here.","commit_id":"386d000f7446a99daae883429d3884e108870f84"},{"author":{"_account_id":13070,"name":"Eran Gampel","email":"eran@gampel.net","username":"Gampel"},"change_message_id":"59d0dd2641c5af5786f24ca1374a5c9bec770ac9","unresolved":false,"context_lines":[{"line_number":217,"context_line":"            else:"},{"line_number":218,"context_line":"                ovs_port_id \u003d key"},{"line_number":219,"context_line":"                self.controller.ovs_port_deleted(ovs_port_id)"},{"line_number":220,"context_line":"        elif \u0027_test\u0027 \u003d\u003d table:"},{"line_number":221,"context_line":"            # Do nothing. This table is for testing only."},{"line_number":222,"context_line":"            pass"},{"line_number":223,"context_line":"        else:"},{"line_number":224,"context_line":"            LOG.error(_LE(\u0027Unknown table %s\u0027), table)"},{"line_number":225,"context_line":""},{"line_number":226,"context_line":"    def sync(self):"},{"line_number":227,"context_line":"        pass"}],"source_content_type":"text/x-python","patch_set":1,"id":"da0c15f0_061d6d73","line":224,"range":{"start_line":220,"start_character":8,"end_line":224,"end_character":53},"in_reply_to":"da0c15f0_5b5bc554","updated":"2016-03-25 07:27:31.000000000","message":"I agree \nNo need to add the _test table","commit_id":"386d000f7446a99daae883429d3884e108870f84"},{"author":{"_account_id":11343,"name":"Gal Sagie","email":"gal.sagie@gmail.com","username":"GalSagie"},"change_message_id":"61c92d0f9e729465079306a53c29ce50cd62c687","unresolved":false,"context_lines":[{"line_number":217,"context_line":"            else:"},{"line_number":218,"context_line":"                ovs_port_id \u003d key"},{"line_number":219,"context_line":"                self.controller.ovs_port_deleted(ovs_port_id)"},{"line_number":220,"context_line":"        elif \u0027_test\u0027 \u003d\u003d table:"},{"line_number":221,"context_line":"            # Do nothing. This table is for testing only."},{"line_number":222,"context_line":"            pass"},{"line_number":223,"context_line":"        else:"},{"line_number":224,"context_line":"            LOG.error(_LE(\u0027Unknown table %s\u0027), table)"},{"line_number":225,"context_line":""},{"line_number":226,"context_line":"    def sync(self):"},{"line_number":227,"context_line":"        pass"}],"source_content_type":"text/x-python","patch_set":1,"id":"da0c15f0_0f7f35ab","line":224,"range":{"start_line":220,"start_character":8,"end_line":224,"end_character":53},"in_reply_to":"da0c15f0_8f81854d","updated":"2016-03-25 12:46:48.000000000","message":"I don\u0027t think we should add testing logic inside our normal logic, we can alter the tests, just send an object that we deal with like lswitch or router and mock the handling methods in the relevant test like self.controller.logical_switch_updated","commit_id":"386d000f7446a99daae883429d3884e108870f84"},{"author":{"_account_id":11343,"name":"Gal Sagie","email":"gal.sagie@gmail.com","username":"GalSagie"},"change_message_id":"3e758a56bf8fbfefbc2ba46aac73d4c17a4cfa7f","unresolved":false,"context_lines":[{"line_number":143,"context_line":"            LOG.debug(\"Event update: %s\", self.next_update)"},{"line_number":144,"context_line":"            try:"},{"line_number":145,"context_line":"                value \u003d self.next_update.value"},{"line_number":146,"context_line":"                if not value and \\"},{"line_number":147,"context_line":"                        self.next_update.action not in {\u0027delete\u0027, \u0027log\u0027}:"},{"line_number":148,"context_line":"                    if self.next_update.table and self.next_update.key:"},{"line_number":149,"context_line":"                        value \u003d self.driver.get_key(self.next_update.table,"}],"source_content_type":"text/x-python","patch_set":3,"id":"ba0121b8_0de1ccfe","line":146,"updated":"2016-03-30 06:59:03.000000000","message":"the coding standards require \"()\" instead of using \u0027\\\u0027","commit_id":"c189be9b006a84f8ea9c75350f75be10e263a402"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"f6b461d5b20ccb7e852cd927de3454d894d6c87f","unresolved":false,"context_lines":[{"line_number":143,"context_line":"            LOG.debug(\"Event update: %s\", self.next_update)"},{"line_number":144,"context_line":"            try:"},{"line_number":145,"context_line":"                value \u003d self.next_update.value"},{"line_number":146,"context_line":"                if not value and \\"},{"line_number":147,"context_line":"                        self.next_update.action not in {\u0027delete\u0027, \u0027log\u0027}:"},{"line_number":148,"context_line":"                    if self.next_update.table and self.next_update.key:"},{"line_number":149,"context_line":"                        value \u003d self.driver.get_key(self.next_update.table,"}],"source_content_type":"text/x-python","patch_set":3,"id":"ba0121b8_2813de67","line":146,"in_reply_to":"ba0121b8_0de1ccfe","updated":"2016-03-30 07:42:52.000000000","message":"Done","commit_id":"c189be9b006a84f8ea9c75350f75be10e263a402"},{"author":{"_account_id":11343,"name":"Gal Sagie","email":"gal.sagie@gmail.com","username":"GalSagie"},"change_message_id":"3e758a56bf8fbfefbc2ba46aac73d4c17a4cfa7f","unresolved":false,"context_lines":[{"line_number":219,"context_line":"                ovs_port_id \u003d key"},{"line_number":220,"context_line":"                self.controller.ovs_port_deleted(ovs_port_id)"},{"line_number":221,"context_line":"        elif \u0027log\u0027 \u003d\u003d action:"},{"line_number":222,"context_line":"            if table \u003d\u003d \u0027error\u0027:"},{"line_number":223,"context_line":"                LOG.error(_LE(\u0027Log event (Error): %s\u0027), str(value))"},{"line_number":224,"context_line":"            elif table \u003d\u003d \u0027warning\u0027:"},{"line_number":225,"context_line":"                LOG.warning(_LW(\u0027Log event (Warning): %s\u0027), str(value))"}],"source_content_type":"text/x-python","patch_set":3,"id":"ba0121b8_8dc4bc5f","line":222,"updated":"2016-03-30 06:59:03.000000000","message":"i would change this to just LOG the table, key and value, if this used as debugging tool all the rest of the things needs to be the same.\n\nI think the level can be warning or info","commit_id":"c189be9b006a84f8ea9c75350f75be10e263a402"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"f6b461d5b20ccb7e852cd927de3454d894d6c87f","unresolved":false,"context_lines":[{"line_number":219,"context_line":"                ovs_port_id \u003d key"},{"line_number":220,"context_line":"                self.controller.ovs_port_deleted(ovs_port_id)"},{"line_number":221,"context_line":"        elif \u0027log\u0027 \u003d\u003d action:"},{"line_number":222,"context_line":"            if table \u003d\u003d \u0027error\u0027:"},{"line_number":223,"context_line":"                LOG.error(_LE(\u0027Log event (Error): %s\u0027), str(value))"},{"line_number":224,"context_line":"            elif table \u003d\u003d \u0027warning\u0027:"},{"line_number":225,"context_line":"                LOG.warning(_LW(\u0027Log event (Warning): %s\u0027), str(value))"}],"source_content_type":"text/x-python","patch_set":3,"id":"ba0121b8_c81b427f","line":222,"in_reply_to":"ba0121b8_8dc4bc5f","updated":"2016-03-30 07:42:52.000000000","message":"Done","commit_id":"c189be9b006a84f8ea9c75350f75be10e263a402"},{"author":{"_account_id":13070,"name":"Eran Gampel","email":"eran@gampel.net","username":"Gampel"},"change_message_id":"44cf4ddbb62968bd0c37f1e9be874cdfbf482133","unresolved":false,"context_lines":[{"line_number":144,"context_line":"            try:"},{"line_number":145,"context_line":"                value \u003d self.next_update.value"},{"line_number":146,"context_line":"                if (not value and"},{"line_number":147,"context_line":"                        self.next_update.action not in {\u0027delete\u0027, \u0027log\u0027}):"},{"line_number":148,"context_line":"                    if self.next_update.table and self.next_update.key:"},{"line_number":149,"context_line":"                        value \u003d self.driver.get_key(self.next_update.table,"},{"line_number":150,"context_line":"                                                self.next_update.key)"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba0121b8_1d96ef3e","line":147,"range":{"start_line":147,"start_character":65,"end_line":147,"end_character":72},"updated":"2016-03-30 16:55:59.000000000","message":"I am not sure this is needed as you added the value in case of log","commit_id":"b021b216f1ecf761d3b6f8a9a88afdaea79b5829"},{"author":{"_account_id":20229,"name":"Omer Anson","email":"omer.anson@toganetworks.com","username":"oanson"},"change_message_id":"7795925b01ad8c5800d24ed77f303d044d08d4ac","unresolved":false,"context_lines":[{"line_number":144,"context_line":"            try:"},{"line_number":145,"context_line":"                value \u003d self.next_update.value"},{"line_number":146,"context_line":"                if (not value and"},{"line_number":147,"context_line":"                        self.next_update.action not in {\u0027delete\u0027, \u0027log\u0027}):"},{"line_number":148,"context_line":"                    if self.next_update.table and self.next_update.key:"},{"line_number":149,"context_line":"                        value \u003d self.driver.get_key(self.next_update.table,"},{"line_number":150,"context_line":"                                                self.next_update.key)"}],"source_content_type":"text/x-python","patch_set":4,"id":"ba0121b8_0a804bf6","line":147,"range":{"start_line":147,"start_character":65,"end_line":147,"end_character":72},"in_reply_to":"ba0121b8_1d96ef3e","updated":"2016-03-31 07:24:43.000000000","message":"This exists since currently we don\u0027t force anyone to send action log with a value. I want to avoid a DB exception in such a case.","commit_id":"b021b216f1ecf761d3b6f8a9a88afdaea79b5829"}]}
